Closed bbest closed 2 years ago
See: old cinms/rocky.R · noaa-onms/cinms
I checked in a big commit that's almost there with a new strategy to have sanctuary polygons and rocky intertidal MARINe data loaded internally to the onmsR package since we're the only ones who update that from the raw data and the file sizes are manageable:
rocky_clusters
: Rocky intertidal site Sanctuary groupingsrocky_cover
: Rocky intertidal percent cover datarocky_sites
: Rocky intertidal sitessanctuaries
: Sanctuaries with spatial informationThese were generated by rocky.R and sanctuaries.R in the data-raw/ folder and with usethis::use_data()
get saved into the data/ folder as zipped Rdata (*.rda
) objects for lazily loading with the package, per Chapter 14 External data | R Packages.
I need to do rocky_count
data next and then update the plotting functions.
The idea is that whenever new data is ready to ingest from MARINe, they share the raw percent cover and counts CSV files with us. We then run this script onmsR:data-raw/rocky.R which should do a bit more QA/QC like ensuring column names exist with proper data types. Then it processes all the data and saves the necessary data objects as tibbles and spatial feature objects listed as rocky_*
in Function reference • onmsR.
I hope to finish by Friday with the seastar counts raw data, which introduces new rocky_sites, and the funciton updates which will take advantage of these natively available data objects, so not rely on some external sites_csv or similar found who knows where.
Previously MARINe shared raw data files that got summarized by me for various interactive infographic Sanctuary websites. New data then became problematic with differences between sanctuary infographic websites.
The new strategy is to fold all of these data across sanctuaries into datasets native to this R package.