Skip to contents

Calculate and Aggregate Signed Log-Likelihood Contributions Loops through surveys, calculates signed NLL for each, and aggregates the results.

Usage

calculate_and_aggregate_likelihood(
  surveys,
  G,
  a,
  l,
  mu,
  kappa,
  annuli_date,
  annuli_min_age
)

Arguments

surveys

A data frame with survey age-at-length observations with columns survey_date, Length, K, and count.

G

Impulse-response matrix from the single-cohort simulation (rows = ages, cols = length classes).

a

Numeric vector of high-resolution ages corresponding to rows of G.

l

Numeric vector of length-class centers corresponding to columns of G.

mu

Mean spawning date as a fraction of a year in [0, 1).

kappa

Spawning concentration parameter.

annuli_date

Ring formation day as fraction of a year in [0, 1).

annuli_min_age

Minimum age (years) at which the first ring can form.

Value

A data frame with the total NLL contribution for each Length-K bin.