This function scrapes MRIP trip data from the MRIP Query tool and saves it as an Rds. Used as a helper function to automate data pulls.
Usage
save_trips(
this_species,
this_year,
this_region,
out_folder,
wait = TRUE,
return_fname = TRUE
)
Arguments
- this_species
the common name of the species as it appears in the MRIP data. capitalization does not matter.
- this_year
the year of data to query. Must be a single value. The earliest year possible is 1981.
- this_region
the name of the region. Can be a state name, "North Atlantic", "Mid-Atlantic", etc. Capitalization does not matter.
- out_folder
where to save the data
- wait
whether to pause after saving the data. Default is TRUE.
- return_fmane
whether to return the file name of the saved data. Default is TRUE.