sample_log_normal_model {simDNAmixtures} | R Documentation |
Sample log normal model(s) with parameters according to priors
Description
Sample log normal model(s) with parameters according to priors
Usage
sample_log_normal_model(
number_of_contributors,
sampling_parameters,
model_settings
)
Arguments
number_of_contributors |
Integer |
sampling_parameters |
List. Needs to contain:
|
model_settings |
List. See log_normal_model. |
Details
In simulation studies involving many mixed DNA profiles, one often needs to generate various samples with different model parameters. This function samples a log normal model with parameters according to prior distributions. The template parameter for each contributor is sampled uniformly between min_template
and max_template
. The degradation parameter for each contributor is sampled from a gamma distribution with parameters degradation_shape
and degradation_scale
.
Value
When length(number_of_contributors)==1
, a single log_normal_model of class pg_model
. Otherwise, a list of these.
Examples
data(gf)
sampling_parameters <- list(min_template = 50., max_template = 1000.,
degradation_shape = 2.5, degradation_scale = 1e-3)
model_no_stutter <- sample_log_normal_model(number_of_contributors = 1,
sampling_parameters = sampling_parameters,
model_settings = gf$log_normal_settings)