Regular expression to check generate_sample_id_with_components() protocol IDs for Samples table
Source: R/fct_generate_IDs.R
sample_id_regex.RdReturns the regex pattern that matches sample IDs generated by
generate_sample_id_with_components().
Details
The pattern matches the format
SiteCode-ParamAbbrev-CompartmentAbbrev-Date-R-SubsampleAbbrev
as produced by generate_sample_id_with_components(), where:
SiteCode: one or more alphanumeric characters or hyphensParamAbbrev: up to 8 alphanumeric charactersCompartmentAbbrev: up to 12 alphanumeric charactersDate: ISO 8601 date (YYYY-MM-DD)R: literal separator characterSubsampleAbbrev: one or more alphanumeric characters
Example: SITE-001-Copper-AquaticSedi-2023-03-15-R-1