Combine data with multiple records for unique tows
combine_tows.Rd
Combine catch data by trawl_id
for data pulled using the
pull_catch function. Generally, only a single tow is returned
by species and in those instances this function is not needed.
For example, if data are pulled with all sample_types included,
then there will often be data from the same trawl_id
included
as multiple records. In these instances, this function allows
for the sample data to be combined for each unique trawl_id
.
This also occurs if cryptic species pairs are all returned
(e.g., rougheye rockfish and blackspotted rockfish)
Arguments
- data
A data frame of catches obtained by using the
pull_catch
function.- dir
Directory where output will be saved. The directory where the file should be saved. If dir = NULL no output will be saved.
- single_species
TRUE/FALSE Logical that indicates whether data should be grouped by
trawl_id
alone (TRUE, e.g., rougheye rockfish and blackspotted rockfish) or data should be grouped bycommon name
andtrawl_id
(FALSE).- verbose
A logical that specifies if you want to print messages and warnings to the console. The default is
TRUE
.