View source: R/landscape_gen.R
Function to generate the alpha parameters for a dirichlet distribution, which will provide a particular proportion of the maximum variance for different numbers of peaks. Uses a simple numerical optimization to find alpha values generating a particular variance, as calculated from the formula for the variance in a dirichlet.
@param prop_variance Vector of proportions of the maximum variance to calculate. @param num_peaks Vector of number of carrying capacity peaks to use
@return Data.frame containing the dirichlet parameter in the last column
1 | gen_dirichlet(prop_variance = c(0.1, 0.3, 0.5), num_peaks = c(2, 6, 10))
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.