Description Usage Arguments Value Examples
View source: R/calculate_first_minimum_density.R
This function is used to estimate the first local minimum of the density of a vector. It is meant to be used on the distribution of expression of genes in a sample; since the distribution tails off, finding the global minimum is not appropriate. The plot option can be used to visualise the process.
1 2 3 4 5 6 | calculate_first_minimum_density(
mat,
log.transform = TRUE,
adjust = 2,
makeplots = FALSE
)
|
mat |
matrix whose columns will be used; usually an expression matrix; it can also be a vector |
log.transform |
whether to log-transform the data before the density estimation; default is TRUE |
adjust |
adjust factor for the smoothing, passed to density(); default is 2 |
makeplots |
a logical value of whether a plot with a vertical line on the minimum found should be printed for each column of the matrix. |
The function outputs a single value corresponding to the median of the minima calculated for each column of the matrix. floor() is taken as a conservative estimate
1 2 3 4 |
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.