Internal wrapper for computing bootstrapping results on one sample, combining the functionality of compute_intermediate_results and summarise_intermediate_results.

helper_f_dplyr(
  sampled_id_list,
  compare_cpy,
  grouping_var,
  ps_flags = list(intermed = FALSE, summarise = FALSE),
  label_distribution = NULL,
  cost_fp = NULL
)

Arguments

sampled_id_list

A list of all doc_ids of this bootstrap.

compare_cpy

As created by create_comparison.

grouping_var

A vector of variables to be used for aggregation.

ps_flags

A list with logicals "intermed" and "summarise".

label_distribution

Expects a data.frame with columns "label_id", "label_freq", "n_docs". label_freq corresponds to the number of occurences a label has in the gold standard. n_docs corresponds to the total number of documents in the gold standard.

cost_fp

A numeric value > 0, defaults to NULL.

Value

A data.frame as returned by summarise_intermediate_results_dplyr.