Description Usage Arguments Value Author(s) See Also
makefeature
generates the missing rate matrix from the data frame of metabolomics signal (generated by read.metfile
), according to specified window size and slide size.
With the missing rate matrix, makefeature
gives 3 features characterizing the missing rates pattern of the metabolites, including variance of missing rate, number of switches and longest block.
1 | makefeature(data, wsize = 100, ssize = 0.5, defswitch = 0.2)
|
data |
A data frame of metabolites signal. Rows are metabolites and columns are samples in injection order. The data frame can be created by |
wsize |
Window size. Default is 100. |
ssize |
Slide size. Default is 0.5. |
defswitch |
Definition of a switch. If the absolute missing rate difference of adjacent windows is greater than defswitch, it will be defined as a switch. Default is 0.2. |
A list contains features generated from the metabolites signal matrix. The list contains the following entries:
mbnames: A vector. Name list of metabolites.
snames: A vector. Name list of samples.
wsize: A scalar. Window size.
ssize: A scalar. Slide size.
defswitch: A scalar. Definition of switch.
mrate: Missing rate matrix. Each cell of the matrix is a missing rate of a window.
variance: A vector. Missing rate variance for each metabolite.
nswitches: A vector. Number of switches for each metabolite.
longestblock: A vector. Number of windows of the longest block for each metabolite.
Liu Cao
See read.metfile
for how to generate the the input metabolites signal data frame.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.