music2_prop | R Documentation |
This function is used to deconvolve bulk RNA-seq data using single-cell reference generated under a different condition.
music2_prop(
bulk.control.mtx,
bulk.case.mtx,
sc.sce,
clusters,
samples,
select.ct,
expr_low = 20,
prop_r = 0.1,
eps_c = 0.05,
eps_r = 0.01,
n_resample = 20,
sample_prop = 0.5,
cutoff_expr = 0.05,
cutoff_c = 0.05,
cutoff_r = 0.01,
maxiter = 200,
markers = NULL,
cell_size = NULL,
ct.cov = FALSE,
centered = FALSE,
normalize = FALSE
)
bulk.control.mtx |
Matrix of expression for bulk data, control group |
bulk.case.mtx |
Matrix of expression for bulk data, case group |
sc.sce |
SingleCellExperiment for single cell data |
clusters |
character, the phenoData of single cell dataset used as clusters; |
samples |
character, the phenoData of single cell dataset used as samples; |
select.ct |
vector of cell types, default as NULL. If NULL, then use all cell types provided by the single cell dataset; |
expr_low |
numeric, cutoff for defining lowly expressed genes in bulk data. Genes with mean expression across samples in bulk data < expr_low will be excluded from cell-type-specific DE gene detection. Default is 20; |
prop_r |
numeric, cutoff for defining rare cell types. Cell types with mean proportion across samples in bulk data < prop_r will be characterized as rare cell types. Otherwise, will be characterized as common cell types. Default is 0.1; |
eps_c |
numeric, convergence cutoff for common cell types. The cell type proportion estimate is converged if absolute relative change of proportion estimates for the current iteration against the previous iteration < eps_c. Default is 0.05; |
eps_r |
numeric, convergence cutoff for rare cell types. The cell type proportion estimate is converged if absolute change of proportion estimates for the current iteration against the previous iteration < eps_r. Default is 0.01; |
n_resample |
numeric, number of resamples used for detecting cell-type-specific DE genes. Default is 20; |
sample_prop |
numeric, proportion of samples to be randomly sampled without replacement under each condition at each resampling. Default is 0.5; |
cutoff_expr |
numeric, cutoff for defining lowly expressed genes over resamples. Genes with average cell-type-specific expression calculated over all resamples in the lower cutoff_expr quantile are excluded from cell-type-specific DE gene detection. Default is 0.05; |
cutoff_c |
numeric, cutoff for defining cell-type-specific DE genes for common cell types. Genes with the value of statistic, defined as the absolute value of the ratio of the mean and standard deviation of the log fold change over all resamples, in the upper cutoff_c quantile are considered as cell-type-specific DE genes. Default is 0.05; |
cutoff_r |
numeric, cutoff for defining cell-type-specific DE genes for rare cell types. Genes with the value of statistic, defined as the absolute value of the ratio of the mean and standard deviation of the log fold change over all resamples, in the upper cutoff_r quantile are considered as cell-type-specific DE genes. Default is 0.01; |
maxiter |
numeric, maximum number of iterations. Default is 200; |
markers |
vector or list of gene names. Default as NULL, i.e., use all genes that provided by both bulk and single cell datasets; |
cell_size |
data.frame of cell sizes. 1st column contains the names of cell types, 2nd column has the cell sizes per cell type. Default as NULL. If NULL, then estimate cell size from data; |
ct.cov |
logical. If TRUE, use the covariance across cell types; |
centered |
logic, subtract avg of Y and D; |
normalize |
logic, divide Y and D by their standard deviation; |
If MuSiC2 converges, return:
Est.prop: matrix, cell type proportion estimates.
convergence: logical, whether MuSiC2 converged or not.
n.iter: numeric, number of iterations.
DE.genes: vector, cell-type-specific DE genes being removed.
Or if MuSiC2 does not converge, return:
Est.prop: matrix, cell type proportion estimates.
convergence: logical, whether MuSiC2 converged or not.
id.not.converge: vector, sample ids that failed to converge.
music_prop
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.