Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Feature request: append_activity_data #341

Open
MartijnUH opened this issue Sep 27, 2024 · 1 comment
Open

Feature request: append_activity_data #341

MartijnUH opened this issue Sep 27, 2024 · 1 comment
Assignees

Comments

@MartijnUH
Copy link
Collaborator

MartijnUH commented Sep 27, 2024

@damianooldoni in my opinion it would be nice to have a function that takes the output from get_record_table and adds two additional columns "clock" (clock time of the observation in radians) and "sun" (sun time of the observation in radians) that are frequently used by users of camera trap data to calculate daily activity levels, using the function activity::fitact. This would extend the possible workflows of camtraptor, which is now compatible with the unmarked package for analyses of occupancy and abundance-estimation, towards analyses of activity patterns using the activity package.

get_activity_data.zip: contains a minimal data example.

Things we need to decide are:

  • adjust get_record_table such that it automatically, or after calling a new boolean argument, appends clock and solar (Note: I refer to this as get_activity_data, but I thinkt it would be better to retain the name get_record_table for this) OR a new function append_activity_data that appends these columns after first calling get_record_table and another (potentially new) function get_coordinates.
  • always append columns longitude, latitude, clock and solar OR let the user choose which cols (e.g. only solar)
  • potentially, but this is on a more thecnical note, let users decide which type of function (overlap::sunTime or activity::solartime), and anchoring they would like to use for the computations of solar

@damianooldoni, @jimcasaer any other thoughts on this?

@MartijnUH MartijnUH changed the title Feature request: get_activity_data Feature request: append_activity_data Sep 27, 2024
@damianooldoni
Copy link
Member

About using overlap::sunTime or activity::solartime, the question is technically important: if we allow the users to choose, it means we have to add two dependencies to the package instead of one. I would avoid it, unless there is a real major benefit. @MartijnUH: can you help me about this? Is there a way to choose between the two? Is there a conceptual difference between the two?

After briefly discussing all the options with @peterdesmet, we think that the best way would be to add the 4 new columns directly in the output of get_record_table() unless using the returned record table in other functions will return errors. If this is the case, we could add a boolean argument where the columns are not added by default. But I am not a big fan of flags 🎏 @MartijnUH: can you help me about this?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants