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

Enable g.calibrate to handle temperature data from ad-hoc csv file #993

Merged
merged 4 commits into from
Dec 13, 2023

Conversation

l-k-
Copy link
Collaborator

@l-k- l-k- commented Dec 13, 2023

Fixes #991

Checklist before merging:

  • Existing tests still work (check by running the test suite, e.g. from RStudio).
  • Added tests (if you added functionality) or fixed existing test (if you fixed a bug).
  • Updated or expanded the documentation.
  • Updated release notes in inst/NEWS.Rd with a user-readable summary. Please, include references to relevant issues or PR discussions.
  • Added your name to the contributors lists in the DESCRIPTION file, if you think you made a significant contribution.

@l-k- l-k- requested a review from vincentvanhees December 13, 2023 07:08
@l-k-
Copy link
Collaborator Author

l-k- commented Dec 13, 2023

I tested this using the file sent by Joanna on the message board, and I'm getting a bunch of warnings like this:

In max(ts$lightpeak[startM5[1]:(startM5[1] + (wini * 60 *  ... :
  no non-missing arguments to max; returning -Inf

This gets thrown from https://github.com/wadpac/GGIR/blob/master/R/g.part5_analyseSegment.R#L266 because ts$lightpeak column is all NA.
(I was still getting them with the code from your PR as well)

I'm not very familiar with part 5, so I thought I'd ask in case you'll know right away if this is a problem. Otherwise I'll take a closer look tomorrow (Wednesday).

Copy link

codecov bot commented Dec 13, 2023

Codecov Report

Attention: 6 lines in your changes are missing coverage. Please review.

Comparison is base (5777400) 78.44% compared to head (cc12bf8) 78.41%.
Report is 34 commits behind head on master.

❗ Current head cc12bf8 differs from pull request most recent head 83fe8dd. Consider uploading reports for the commit 83fe8dd to get more accurate results

Files Patch % Lines
R/g.calibrate.R 25.00% 6 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##           master     #993      +/-   ##
==========================================
- Coverage   78.44%   78.41%   -0.03%     
==========================================
  Files          99       99              
  Lines       13386    13370      -16     
==========================================
- Hits        10500    10484      -16     
  Misses       2886     2886              

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

@vincentvanhees
Copy link
Member

Thanks Lena! I now see that the underlying problem is that most of GGIR's code was not prepared to handle temperature data from adhoc csv format data. Although read.myacc.csv() can read that column, g.getmeta() and g.calibrate() have not been written to use it. I am now preparing a new PR into this PR to address this.

@vincentvanhees vincentvanhees mentioned this pull request Dec 13, 2023
5 tasks
@vincentvanhees vincentvanhees merged commit 0603c51 into master Dec 13, 2023
7 checks passed
@l-k- l-k- deleted the issue991_v2_tempcolumn_adhoccsv_calibration branch December 13, 2023 14:08
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Adhoc csv data processing cannot handle temperature column
2 participants