Estimate simulation parameters for the mfa simulation from a real dataset.

mfaEstimate(counts, params = newMFAParams())

# S3 method for SingleCellExperiment
mfaEstimate(counts, params = newMFAParams())

# S3 method for matrix
mfaEstimate(counts, params = newMFAParams())

Arguments

counts

either a counts matrix or a SingleCellExperiment object containing count data to estimate parameters from.

params

MFAParams object to store estimated values in.

Value

MFAParams object containing the estimated parameters.

Details

The nGenes and nCells parameters are taken from the size of the input data. The dropout lambda parameter is estimate using empirical_lambda. See MFAParams for more details on the parameters.

Examples

# Load example data if (requireNamespace("mfa", quietly = TRUE)) { library(mfa) synth <- create_synthetic(C = 20, G = 5, zero_negative = TRUE, model_dropout = TRUE) params <- mfaEstimate(synth$X) params }
#> A Params object of class MFAParams #> Parameters can be (estimable) or [not estimable], 'Default' or 'NOT DEFAULT' #> Secondary parameters are usually set during simulation #> #> Global: #> (GENES) (CELLS) [Seed] #> 20 5 121054 #> #> 4 additional parameters #> #> Transient: #> [Proportion] #> 0 #> #> Negative: #> [Zero] #> TRUE #> #> Dropout: #> [Present] (LAMBDA) #> FALSE 0.267710565576343 #>