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

time as difftime breaks calculate_kinematics() #53

Open
roaldarbol opened this issue Nov 1, 2024 · 5 comments
Open

time as difftime breaks calculate_kinematics() #53

roaldarbol opened this issue Nov 1, 2024 · 5 comments
Labels
bug Something isn't working
Milestone

Comments

@roaldarbol
Copy link
Owner

I need to come up with some concrete decisions about time. Should it be:

  1. A simple numeric (for seconds) - makes further calculations easier
  2. Difftime - is automatically generated from datetimes when subtracting them
  3. datetime - when we simply keep the absolute timings.

I think that we should probably just always convert difftime to numeric if we do so, and document that. Should include tests as well! Make the same decisions for respirometr for compatibility.

@roaldarbol roaldarbol added the bug Something isn't working label Nov 1, 2024
@roaldarbol roaldarbol added this to the Version 1.0 milestone Nov 1, 2024
@roaldarbol roaldarbol moved this to 🔬 Triage in animovement progress Nov 1, 2024
@Gerrry27
Copy link

Gerrry27 commented Nov 1, 2024

If you convert "time" to numeric it might be useful to add to the code a line copying "time" to another column ("Date_time"?) before it is converted. In this way, the time info is still always understandable and easy to read.

@roaldarbol
Copy link
Owner Author

Good point. Maybe we could always use "time" as the time since the beginning of the data, and have a separate column reserved for absolute/datetime, something like "datetime"/"dt"/"time_absolute"?

@Gerrry27
Copy link

Gerrry27 commented Nov 1, 2024

Sounds good to me! Maybe "datetime" is the easiest wording to comprehend what it is about.

@Gerrry27

This comment was marked as off-topic.

@roaldarbol
Copy link
Owner Author

@Gerrry27 Could do - I'm not wholly convinced though; if you then filter out the e.g. the first 3 minutes, then it will be wrong. Can you add the comment to #30 instead, as it's not really related to the time issue here. :-)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working
Projects
Status: 🔬 Triage
Development

No branches or pull requests

2 participants