kaitlyngaynor / gorongosa-shiny

Code for Gorongosa Camera Trap Shiny App
https://kaitlyngaynor.shinyapps.io/gorongosa-shiny/
Apache License 2.0
2 stars 0 forks source link

RAI is NA when it should be 0 #6

Closed kaitlyngaynor closed 4 years ago

kaitlyngaynor commented 4 years ago

https://github.com/kaitlyngaynor/gorongosa-camera-traps/blob/d35c695e9e7e3fb172da392db907b1171a3abf1d/shiny-rai/global.R#L165

When I modified the RAI code to be for a single species rather than multiple, something else got messed up and now RAI appears as NA when it should be 0 (no detections, but camera was operating.)

kaitlyngaynor commented 4 years ago

Issue was that not all cameras are present anymore in the Detections output, if species was not found there. The fix was as simple as doing a join from the camera operation sheet (with all 60 cameras) to detections, rather than the other way around.