put_size_class_on_predator: Put size classes on predator from observed length.

View source: R/put_length_classes_on.R

put_size_class_on_predatorR Documentation

Put size classes on predator from observed length.

Description

Put size classes on predators

Usage

put_size_class_on_predator(stom, len_classes)

Arguments

stom

stomach contents data of class STOMobs.

len_classes

Data frame with size class definitions. See make_length_classes. Size class will be added just for the species included in len_classes. If length_classes include sprecies='ALL' all species will get size class.

Details

This function adds a size group to each predator based on the predator length (pred_l) if such exist, or based on the midpoint of the size range (pred_ll - pred_lu). Both approaches use an input definition of size groups, typically made by the function make_length_classes. The mean length of the predator (pred_l_mean) is added either copied from the variable pred_l or from the midpoint of the size range (pred_ll - pred_lu) The size clases are species independent if len_classes includes Species==ALL. . If length classes is given by predator in len_classes, species specific length classes will be added.

Value

stomach contents data of class STOMobs wit added size class for predators.


MortenVinther/FishStomachs documentation built on Feb. 14, 2025, 7:33 a.m.