Prepare Synthetic Data Table
prepare_table.RdPrepare Synthetic Benthic Data Table
Arguments
- data_fixed_locs_points
An
sfobject containing synthetic fine-scale point or quadrat data generated bysampling_design_fine_scale_points()or equivalent. Must include:Reef,Site,Transect,Year,DateDepth,Latitude,LongitudeFor points:
POINT_NO,GroupFor quadrats/cover:
Value,Quad,GroupGeometry column
- data_type
A string specifying the structure of the input dataset:
"points"– raw point-level classifications (HCC, SC, MA, etc.)"cover"– aggregated quadrat or percentage cover measurements
Value
A processed data.frame containing:
Project, site, transect and survey metadata
Coordinates and depth
Either:
Point identifiers and benthic class (for
data_type = "points")Quadrat numbers and numeric cover (for
data_type = "cover")
Reef and site identifiers extracted and standardised
Final benthic metrics (
COUNT,COVER,COVER_TRUE) after reef selection and processing byselect_process_reefs()
Details
Converts synthetic point- or cover-based benthic sampling observations into a
standardised data table suitable for downstream processing and ReefCloud-style
export. The function harmonises identifiers (site, transect, survey), formats
benthic attributes, and then applies reef-selection and cover calculations via
select_process_reefs().
The function:
Creates consistent project, site, survey, and transect identifiers
Adds point-level or quadrat-level variables depending on
data_typeSelects only the variables required for synthetic export
Calls
select_process_reefs()to:Select a subset of reefs according to
config_lrgeCompute TRUE and selected cover values
Extract and standardise reef and site codes
Attach year and benthic cover metrics