Public methods
Method new()
Usage
trans_func$new(dataset = NULL)
Arguments
dataset
the object of microtable
Class.
Returns
for_what : "prok" or "fungi" or NA, "prok" represent prokaryotes. "fungi" represent fungi. NA represent not identified according to the Kingdom information,
at this time, if you want to use the functions to identify species traits, you need provide "prok" or "fungi" manually, e.g. dataset$for_what <- "prok".
Examples
data(dataset)
t1 <- trans_func$new(dataset = dataset)
Method cal_spe_func()
Confirm traits of each OTU by matching the taxonomic assignments to the functional database;
Prokaryotes: based on the FAPROTAX database, please also cite the original FAPROTAX paper:
Louca, S., Parfrey, L. W., & Doebeli, M. (2016). Decoupling function and taxonomy in the global ocean microbiome. Science, 353(6305), 1272. <doi:10.1126/science.aaf4507>;
Fungi, based on the FUNGuild database, please also cite:
Nguyen, N. H., Song, Z., Bates, S. T., Branco, S., Tedersoo, L., Menke, J., <U+2026> Kennedy, P. G. (2016).
FUNGuild: An open annotation tool for parsing fungal community datasets by ecological guild. Fungal Ecology, 20(1), 241<U+2013>248. <doi:10.1016/j.funeco.2015.06.006>
Usage
trans_func$cal_spe_func()
Returns
res_spe_func in object.
Examples
\donttest{
t1$cal_spe_func()
}
Method cal_spe_func_perc()
Calculating the percentages of species with specific trait in communities or modules.
The percentages of the OTUs with specific trait can reflect the potential of the corresponding function in the community or the module in the network.
Usage
trans_func$cal_spe_func_perc(
use_community = TRUE,
node_type_table = NULL,
abundance_weighted = FALSE
)
Arguments
use_community
default TRUE; whether calculate community; if FALSE, use module.
node_type_table
default NULL; If use_community FALSE; provide the node_type_table with the module information, such as the result of cal_node_type.
abundance_weighted
default FALSE; whether use abundance. If FALSE, calculate the functional population percentage. If TRUE, calculate the functional individual percentage.
Returns
res_spe_func_perc in object.
Examples
\donttest{
t1$cal_spe_func_perc(use_community = TRUE)
}
Method show_prok_func()
Show the basic information for a specific function of prokaryotes.
Usage
trans_func$show_prok_func(use_func = NULL)
Arguments
use_func
default NULL; the function name.
Returns
None.
Examples
\donttest{
t1$show_prok_func(use_func = "methanotrophy")
}
Method plot_spe_func_perc()
Plot the percentages of species with specific trait in communities or modules.
Usage
trans_func$plot_spe_func_perc(
filter_func = NULL,
use_group_list = TRUE,
add_facet = TRUE,
select_samples = NULL
)
Arguments
filter_func
default NULL; a vector of function names.
use_group_list
default TRUE; If TRUE, use default group list; If use personalized group list, first set trans_func$func_group_list object with a list of group names and functions.
add_facet
default TRUE; whether use group names as the facets in the plot, see trans_func$func_group_list object.
select_samples
default NULL; character vector, select partial samples to show
Returns
ggplot2.
Examples
\donttest{
t1$plot_spe_func_perc(use_group_list = TRUE)
}
Method cal_FAPROTAX()
Predict functional potential of communities using FAPROTAX.
please also cite the original FAPROTAX paper:
Louca, S., Parfrey, L. W., & Doebeli, M. (2016). Decoupling function and taxonomy in the global ocean microbiome. Science, 353(6305), 1272. <doi:10.1126/science.aaf4507>;
Usage
trans_func$cal_FAPROTAX(keep_tem = TRUE, Ref_folder = "./FAPROTAX_1.2.1")
Arguments
keep_tem
default FALSE; whether keep the intermediate file, that is, the otu_table_for_FAPROTAX.txt in local place.
Ref_folder
default "./FAPROTAX_1.2.1"; see http://www.loucalab.com/archive/FAPROTAX
Returns
res_FAPROTAX in object.
Method cal_tax4fun()
Predict functional potential of communities using tax4fun.
please also cite: A<U+00DF>hauer, K. P., Wemheuer, B., Daniel, R., & Meinicke, P. (2015).
Tax4Fun: Predicting functional profiles from metagenomic 16S rRNA data. Bioinformatics, 31(17), 2882<U+2013>2884. <doi:10.1093/bioinformatics/btv287>
Usage
trans_func$cal_tax4fun(keep_tem = FALSE, folderReferenceData = NULL)
Arguments
keep_tem
default FALSE; whether keep the intermediate file, that is, the otu table in local place.
folderReferenceData
default NULL; the folder, see http://tax4fun.gobics.de/ and Tax4Fun function in Tax4Fun package.
Returns
tax4fun_KO and tax4fun_path in object.
Method print()
Print the trans_func object.
Usage
trans_func$print()
Method clone()
The objects of this class are cloneable with this method.
Usage
trans_func$clone(deep = FALSE)
Arguments
deep
Whether to make a deep clone.