Skip to contents

Summarises the ManyAnalyst study data by calculating summary statistics for each subset of data.

Usage

summarise_study(
  ManyEcoEvo,
  ManyEcoEvo_results,
  id_subsets,
  subset_names,
  filter_vars = NULL
)

Arguments

ManyEcoEvo

A ManyAnalyst style tibble containing the data to be analysed.

ManyEcoEvo_results

A ManyAnalyst results style tibble containing the results of the data to be analysed.

id_subsets

A list of tibbles containing the id_col for each subset of data.

subset_names

A character vector equal to the length of id_subsets; the name of data subsets in id_subsets.

filter_vars

A list of expressions to filter ManyEcoEvo_results data

Value

A tibble containing summary statistics for each subset of data.

Examples

id_subsets <- list(ManyEcoEvo:::effect_ids, ManyEcoEvo:::prediction_ids)
subset_names <- c("effects", "predictions")
filter_vars <- rlang::exprs(
  exclusion_set == "complete",
  estimate_type == "Zr",
  publishable_subset == "All",
  expertise_subset == "All",
  collinearity_subset == "All"
)
summarise_study(ManyEcoEvo::ManyEcoEvo, ManyEcoEvo::ManyEcoEvo_results, id_subsets, subset_names, filter_vars = filter_vars)
#> # A tibble: 3 × 9
#>   subset_name data                n_teams sorensen_summary teams_per_subset  
#>   <chr>       <list>                <int> <list>           <list>            
#> 1 all         <tibble [302 × 40]>     145 <tibble [2 × 5]> <tibble [146 × 3]>
#> 2 effects     <tibble [210 × 40]>     102 <tibble [2 × 5]> <tibble [103 × 3]>
#> 3 predictions <tibble [88 × 40]>       56 <tibble [2 × 5]> <tibble [57 × 3]> 
#> # ℹ 4 more variables: conclusions_summary <list>,
#> #   variable_count_summary <list>, model_term_summary <list>,
#> #   model_type_summary <list>