View source: R/getSignatures.R
getMetaSignatures | R Documentation |
Functionality for obtaining meta-signatures for a column of interest
getMetaSignatures(
df,
column,
direction = c("BOTH", "UP", "DOWN"),
min.studies = 2,
min.taxa = 5,
comb.fun = sum,
...
)
df |
|
column |
character. Column of interest. Need to be a valid column name
of |
direction |
character. Indicates direction of abundance change for signatures
to be included in the computation of meta-signatures. Use |
min.studies |
integer. Minimum number of studies for a category in |
min.taxa |
integer. Minimum size for meta-signatures. Defaults to 5, which will then only include meta-signatures containing at least 5 taxa. |
comb.fun |
function. Function for combining sample size of the exposed group
and sample size of the unexposed group into an overall study sample size. Defaults
to |
... |
additionals argument passed on to |
A list
of meta-signatures, each meta-signature being a named
numeric vector. Names are the taxa of the meta-signature, numeric values
correspond to sample size weights associated with each taxon.
getSignatures
df <- importBugSigDB()
# Body-site specific meta-signatures composed from signatures reported as both
# increased or decreased across all conditions of study:
bs.meta.sigs <- getMetaSignatures(df, column = "Body site")
# Condition-specific meta-signatures from fecal samples, increased
# in conditions of study. Use taxonomic names instead of the default NCBI IDs:
df.feces <- df[df$`Body site` == "Feces", ]
cond.meta.sigs <- getMetaSignatures(df.feces, column = "Condition",
direction = "UP", tax.id.type = "taxname")
# Inspect the results
names(cond.meta.sigs)
cond.meta.sigs["Bipolar disorder"]
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.