Injection Atlas
See repo atlas-injection[https://github.com/BiodiversiteQuebec/atlas-injection] for examples
Step for injection
- Create dataset and inject in table
datasets
(if not already existing) - Format taxonomy and inject in table
taxa_obs
(if not already existing) - Create/format observations variables (occurrence/abundance) and inject in table
variables
(if not already existing) - Proceed to general validation of the data (see below section)
- Retrieve datasets, taxa_obs and variables id (foreign keys) and inject observations data in table
observations
- Create effort sampling variables and the effort itself and inject in table
efforts
andvariables
(if not already existing) - Retrieve observations id and link them to the id_efforts of effort sampling for injection in table
obs_efforts
Validation of data
- Convert coordinates to WGS84 first and to WKT (Well-Known Text) and drop rows where coordinates information is missing
- Verify that the observations are within the Quebec bounding box (either manually or retrieve the polygon from Atlas)
- Make sure that we at least have a value for year_obs and that month_obs <= 12 and day_obs <= 31
- If there is time information (time_obs), convert it to 00:00:00 format (H%M%S%)
- Can check for whitespaces within strings values
Question to clarify with data providers
- Clarify the type of data if unclear (occurrence, absence, abundance etc.)
- Clarify the projection and SRID of coordinates if not provided
- Clarify if there is any precision data on coordinates
- Clarify if there is any effort sampling information
- Clarify all the required datasets fields if they are not provided