sample_data-class
),
which in the phyloseq-package
is represented as a special
extension of the data.frame-class
.
When the
argument is a data.frame
, sample_data
will create
a sample_data-class object.
In this case, the rows should be named to match the
sample_names
of the other objects to which it will ultimately be paired.
Alternatively, if the first argument is an experiment-level (phyloseq-class
)
object, then the corresponding sample_data
is returned.
Like other accessors (see See Also, below), the default behavior of this method
is to stop with an
error if object
is a phyloseq-class
but does not
contain a sample_data
.sample_data(object, errorIfNULL=TRUE)## S3 method for class 'ANY':
sample_data(object, errorIfNULL = TRUE)
## S3 method for class 'data.frame':
sample_data(object)
data.frame-class
,
or a phyloseq-class
object.NULL
)? Default TRUE
.sample_data-class
object
representing the sample variates of an experiment.phy_tree
, tax_table
, otu_table
phyloseq
, merge_phyloseq
#
data(soilrep)
head(sample_data(soilrep))
Run the code above in your browser using DataLab