Learn R Programming

phyloseq (version 1.16.2)

nsamples: Get the number of samples.

Description

Get the number of samples.

Usage

nsamples(physeq)

## S3 method for class 'ANY': nsamples(physeq)

## S3 method for class 'phyloseq': nsamples(physeq)

## S3 method for class 'otu_table': nsamples(physeq)

## S3 method for class 'sample_data': nsamples(physeq)

Arguments

Value

  • An integer indicating the total number of samples.

See Also

taxa_names, sample_names, ntaxa

Examples

Run this code
#
data("esophagus")
tree <- phy_tree(esophagus)
OTU1 <- otu_table(esophagus)
nsamples(OTU1)
physeq1 <- phyloseq(OTU1, tree)
nsamples(physeq1)

Run the code above in your browser using DataLab