View source: R/as_data_frame_asb.R
subset.asb | R Documentation |
summary
method for class asb
.
\Sexpr[results=rd, stage=render]{ lifecycle::badge("experimental") }
## S3 method for class 'asb'
subset(x, ..., taxa = NULL, exclude = NULL)
x |
Results of function |
... |
Rurther arguments to be passed to or from other methods. |
taxa |
A taxon or a vector of taxa to retain. |
exclude |
A taxon or a vector of taxa to exclude. For example, this option is useful to exclude alien taxa. |
data(macro_ex)
data_bio <- as_biomonitor(macro_ex)
# select EPT Taxa (Ephemeroptera, Plecoptera and Trichoptera)
subset(data_bio, taxa = c("Ephemeroptera", "Plecoptera", "Trichoptera"))
# select Trichoptera excluding the trichopteran family Hydropsychidae
tricho <- subset(data_bio, taxa = "Trichoptera", exclude = "Hydropsychidae")
tricho_agg <- aggregate_taxa(tricho)
# exclude Chironomidae
subset(data_bio, exclude = "Chironomidae")
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.