Description Usage Arguments Value Examples
View source: R/datacollation.R
Generate summary dataframe of correlations with "waiting_time"
1 2 3 | get_wait_cor_summary(summary, col_names_list, num_parameters, min_count,
Verbose = FALSE, ReturnCI = FALSE, VariablesToNotGroupBy = NULL,
method = "spearman")
|
summary |
dataframe including columns named "seed", "Generation", "start_time", "start_size", "gap" and "waiting_time" |
col_names_list |
char vector of column names in the summary dataframe |
num_parameters |
number of parameters, accounting for the first set of columns in the dataframe |
min_count |
minimum number of items in each column (otherwise result will be NA) |
Verbose |
if TRUE, helpful to debug, print the name of the variables with which compute the correlation |
ReturnCI |
if true, also return the 0.95 level confidence interval computed by bootstraping. |
VariablesToNotGroupBy |
vector of column names by which we don't want to group the simulation. For example, if mutation rate (mu_driver_birth) are random, then we don't want to group the simulations by the variable mu_driver_birth, so we need to set VariablesToNotGroupBy=c("mu_driver_birth") This is more general than creating a boolean argument as CombinedMutationRate=TRUE/FALSE. |
Dataframe with one row for each unique combination of parameter values and start_size (i.e. it summarises over "seed"), and including columns containing the correlations between "waiting_time" and each variable in col_names_list and the associated pValues for the two.sided test of the correlation coefficient. If the argument ReturnCI=TRUE, the 0.95 Confidence Intervals for the correlation coefficients are also computed. Argument VariablesToNotGroupBy allows to compute the correlation coefficients while not grouping simulations by variables contained into VariablesToNotGroupBy.
1 2 3 4 5 6 | wait_cor_summary <- get_wait_cor_summary(sum_df,
c("DriverDiversity", "DriverEdgeDiversity"), 15, min_count = 2)
depth_wait_cor_summary <- get_wait_cor_summary(sum_df,
c(paste0("DriverDiversityFrom1SamplesAtDepth", 0:10),
paste0("DriverDiversityFrom4SamplesAtDepth", 0:10)),
15, min_count = 2)
|
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.