D7b: a custom place is clipped to the cells that actually exist in the release's
cell table with coalesce(in_usa, TRUE). Everything downstream – scores,
species, area, N cells – then runs on ONE cell set, and land and foreign waters
never enter a coverage-blended score as zeros.
Usage
cells_in_study_area(con, cells)
Arguments
- con
a DBI connection to a release database
- cells
a tibble with cell_id and pct_covered
Value
the same tibble, keeping only in-study-area cells (column order and
pct_covered preserved), ordered by cell_id
Details
coalesce(in_usa, TRUE), not in_usa: v1-v7 have no such column, and a release
whose cell table is already the study area must not be emptied by its absence.