comp_complete_bam: Complete a length or age composition data frame so that all...

View source: R/comp_complete_bam.r

comp_complete_bamR Documentation

Complete a length or age composition data frame so that all have desired dimensions

Description

Complete a length or age composition data frame so that all have desired dimensions. This is a modified version of comp_complete. The two functions should probably be combined with options to choose between sub-functions.

Usage

comp_complete_bam(
  comp_mat,
  n_colnames = NULL,
  val_rownames = NULL,
  val_colnames = NULL,
  minusGroup = FALSE,
  plusGroup = FALSE
)

Arguments

comp_mat:

comp matrices, where column names are sample size columns (e.g. n.fish, n.trips) as well as bin values (e.g. length or age), and rows are unique observations (e.g. years)

n_colnames:

column names for sample size columns

val_rownames:

row names you want to have included in each comp matrix

val_colnames:

column names you want to have included in each comp matrix (excluding sample size columns)

minusGroup:

logical. When truncating bin range, should values below the smallest bin be summed into the smallest bin? The default is to simply truncate.

plusGroup:

logical. When truncating bin range, should values above the largest bin be summed into the largest bin? The default is to simply truncate.

Author(s)

Nikolai Klibansky


nikolaifish/bamExtras documentation built on July 21, 2023, 8:26 a.m.