conv_vec_to_mse_df: Convert a vector of aggregated values into a data.frame...

View source: R/utils-conv-vec-to-mse-df.R

conv_vec_to_mse_dfR Documentation

Convert a vector of aggregated values into a data.frame containing the year, run, value, and possibly country as columns

Description

Convert a vector of aggregated values into a data.frame containing the year, run, value, and possibly country as columns

Usage

conv_vec_to_mse_df(
  vec = NULL,
  col = NULL,
  yr_vec = NULL,
  country = NULL,
  probs = c(0.05, 0.25, 0.5, 0.75, 0.95),
  inc_mean = TRUE
)

Arguments

vec

The aggregated vector of data. This must be the same length as run_vecand yr_vec

col

The name of the column to create in the new data frame

yr_vec

The vector of years to place in the data.frame. This must be the same length as vec

country

The name for the country. If NULL, no country column will be added

probs

A vector of quantiles to pass to stats::quantile()

inc_mean

Logical. Include the mean (as column avg)

Value

A data.frame containing the year, run, value, and possibly country as columns


pacific-hake/pacifichakemse documentation built on June 11, 2024, 4:07 a.m.