rethomics / zeitgebr

Circadian rhythm analysis and visualisation in R
11 stars 7 forks source link

periodogram throws error message "...need at least two non-NA values to interpolate" #16

Open fschiefenhoevel opened 1 year ago

fschiefenhoevel commented 1 year ago

Hi!

I'm very happy to have found rethomics! At the moment, I am trying to assess circadian rhythmicity in vital parameters in the MIMIC-III dataset. In small numbers, this works very well, yet when I increase the number of individuals analysed (and therefore the volume of vital parameters, e.g. heartrate), the error message:

"Fehler in approx(d[["t"]], y = d[[var_of_interest]], xout = new_x) : need at least two non-NA values to interpolate"

pops up. I've looked at stackexchange, but can't get to the bottom of it.

EDIT: Double post because I also posted in rethomics/issues.

qgeissmann commented 1 year ago

Hi @fschiefenhoevel, Thanks for reaching out. that looks like a cool project. is there any chance you can provide a minimal/reproducible code sample? At the moment, it is hard to debug, as we do not know what function you are using... Happy holidays, Quentin

fschiefenhoevel commented 1 year ago

Hi @qgeissmann,

thanks for your answer! I'll try to provide an example of data where it fails. But we need to consider the credential access "license" of the MIMIC database, i.e. it is not an open data set (but something close to it). I guess (...) the problem is with "ties", but I'll look deeper!

Merry christmas/happy holidays to you too!