make_analysis_data: Make Analysis Data

Description Usage Arguments Details Value

Description

Makes analysis_data object from a detect_data object. capture$PeriodCapture indicates the period during which the fish was caught. capture$PeriodTagExpire indicates the period during which the tag expired. detected is a logical matrix indicating for each individual-period whether it was detected during the period. moved is a logical matrix indicating for each individual-period whether it was detected to have moved during the period (based on being detected at multiple sections). reported is a logical matrix indicating for each individual-period whether it was reported to have been recaught during the period. released is a logical matrix indicating for each individual-period whether it was released during the period. tags is a logical array indicating for each individual-period-tbartag whether it was attached at the start of the period (note considered attached at the start of the period during which first caught).

Usage

1
2
3
make_analysis_data(data, capture = data$capture, section = data$section,
  interval_period = get_difftime(data), spawning = spawning_no,
  growth = growth_no, ...)

Arguments

data

A detect_data object to use.

capture

A data frame of the capture data to use.

section

A data frame of the section data to use.

interval_period

A difftime element that will be used to group the interval or a vector indicating the actual interval groupings.

spawning

A function that takes detections by date for a capture and period data and returns a logical vector indicating whether the individual spawned in each period.

growth

A function that takes the length of a fish at capture and predicts its length after a number of years.

...

additional arguments passed to growth.

Details

If a difftime element, interval_period cannot be greater than 28 days i.e. lubridate::make_difftime(60 * 60 * 24 * 28).

Value

A detect_data object.


poissonconsulting/lexr documentation built on Feb. 18, 2021, 11:12 p.m.