BiologicalRecordsCentre / sparta

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

Need more flexibility for includeJday in formatOccData #100

Closed JKSheard closed 5 years ago

JKSheard commented 5 years ago

It would be nice to be able to use includeJDay = TRUE in formatOccData when survey is not a date, but rather a combination of a date and something else, for example a gps coordinate.

Background: In the Ant Hunt, multiple participants might be conducting an experiment/an observation on the same day and in the same grid, but slightly different places. These should still count as individual surveys.

@drnickisaac

AugustT commented 5 years ago

I think the solution might be to have a 'visit_ID' optional column, which would over rule the create of a visit column internally (which is a combination of date and site). I don't think this issue is about Julian day... it's more about differentiating co-occurring visits.

AugustT commented 5 years ago

I guess the issue with my suggestion is that the name survey is then a bit misleading

drnickisaac commented 5 years ago

@galinajonsson and I may work on this "soon"

drnickisaac commented 5 years ago

Probably the solution is to revert to a Date column as optional.

drnickisaac commented 5 years ago

After consulting with @AugustT & @FrancescaMancini I have added an optional variable 'replicate'. I think this ensures backwards compatibility. @JKSheard & @galinajonsson would now enter the date in survey and additional information (e.g. GRIDREF) in replicate.

drnickisaac commented 5 years ago

In this solution, Survey should be entered as the Date. Survey can be other data types, but remains restricted to a Date if JulianDate is to be used. This formulation ensures backward compatibility. I forget the details, but I think @JKSheard previously had Survey = paste(Monad, Date) and site was defined by a hectad. In the new formulation, this would instead be replicate = Monad. There is sufficient flexibililty to identify individual users, e.g. replicate = paste(Monad, User)