DiffFiltLoss {PERFect} | R Documentation |
This function calculates differences in filtering loss due to removing a set of J taxa sequentially.
DiffFiltLoss(X, Order_Ind, Plot = TRUE, Taxa_Names = NULL)
X |
OTU table, where taxa are columns and samples are rows of the table. It should be a in dataframe format with columns corresponding to taxa names. |
Order_Ind |
Numeric column order corresponding to taxa importance arrangement. |
Plot |
A binary TRUE/FALSE value. If TRUE, the function returns plot of sequential differences in filtering loss. |
Taxa_Names |
Optional taxa labels corresponding to the columns ordering given by Order_Ind. |
This function calculates and plots (if Plot = TRUE) differences in filtering loss sequentially for removing the first j taxa as DFL(j+1) = FL(J_j+1) - FL(J_j) for taxa j=1, ..., p.
DFL |
Differences in filtering loss values. |
p_FL |
Plot of the differences in filtering loss. |
Ekaterina Smirnova
Smirnova, E., Huzurbazar, H., Jafari, F. “PERFect: permutation filtration of microbiome data', to be submitted.
data(mock2) # Proportion data matrix Prop <- mock2$Prop # Counts data matrix Counts <- mock2$Counts #arrange counts in order of increasing number of samples taxa are present in NP <- NP_Order(Counts) #obtain numeric column order corresponding to taxa importance arrangment Order_Ind <- match(NP, names(Prop)) DFL <- DiffFiltLoss(X=Prop, Order_Ind = Order_Ind, Plot = TRUE, Taxa_Names = NP) #Differences in filtering loss values DFL$DFL #Plot of the differences in filtering loss DFL$p_FL