modify_metadata | R Documentation |
mutate() creates new fields in $metadata
that are functions of existing
metadata fields. It can also modify (if the name is the same as an existing
field) and delete fields (by setting their value to NULL).
## S3 method for class 'rbiom'
mutate(.data, ..., clone = TRUE)
## S3 method for class 'rbiom'
rename(.data, ..., clone = TRUE)
.data |
An rbiom object, such as from |
... |
Passed on to |
clone |
Create a copy of |
An rbiom object.
Other transformations:
rarefy()
,
rarefy_cols()
,
slice_metadata
,
subset()
,
with()
library(rbiom)
biom <- slice_max(hmp50, BMI, n = 6)
biom$metadata
# Add a new field to the metadata
biom <- mutate(biom, Obsese = BMI >= 30)
biom$metadata
# Rename a metadata field
biom <- rename(biom, 'Age (years)' = "Age")
biom$metadata
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.