jniedballa / camtrapR

R package for camera trap data management
https://jniedballa.github.io/camtrapR/
31 stars 5 forks source link

Add number of individuals as possible output value of `detectionHistory` function #26

Open damianooldoni opened 10 months ago

damianooldoni commented 10 months ago

Hi 👋

The function detectionHistory() allows us to choose output between the values "binary" and "count", where "count" is the counts of detections as described in the function documentation.

In the context of modelling research, @MartijnUH and @jimcasaer (Fauna management and Invasive Species team at INBO, Belgium) would like to add the number of individuals ("nind") as possible value of output argument. See minimal example below:

Record table for a given date with the number of individuals added as extra column, see #25.

station obsID nIndividuals
A 1 1
A 2 3
B 3 5

Detection history with output = "count"

station output
A 2
B 1

Detection history with the proposed new output = "nind"

station output
A 4
B 5

What do you think about it? I can work on this and send a PR if you wish.