BiologicalRecordsCentre / sparta

Species Presence/Absence R Trends Analyses
http://biologicalrecordscentre.github.io/sparta/index.html
MIT License
21 stars 24 forks source link

Add function to calculate simple dataset metadata (e.g. total number of records, sites) #207

Closed drnickisaac closed 3 years ago

drnickisaac commented 3 years ago

We have lots of statistics for the species, but few for the dataset from which it is drawn. Add function to calculate simple dataset metadata (e.g. total number of records, sites)

drnickisaac commented 3 years ago

Add an optional text field about dataset provenance (e.g. "scheme + iRecord data, December 2020")

drnickisaac commented 3 years ago

I've now done a full review of available metadata. Number of sites and years is, of course, already contained in the BUGS data object. The total number of records is easily added as sum(visitData$occDetdata$L). We need to figure out where to add this, noting #204. Another useful statistic would be, for the dataset, the proportion of visits with repeats. There is currently some code in dataMetrics() that calculates this, but only for the subset of site:year combinations on which the focal species was recorded.

drnickisaac commented 3 years ago

I have added these as totalObservations and propRepeats within a list dataset_Metrics within the metadata.

drnickisaac commented 3 years ago

And provenance is also added as an optional text field within the metadata