Closed apdlbalb closed 4 months ago
Hello!
In v0.2.0
, the parameter was called old_uid
. In v0.2.1
, it was changed to uid
. Mixing them up in either version won't flat out lead to a parameter error because the function will accept pretty much anything through ...
. Do you think that could be causing this issue?
Also, would you be able to check if this issue persists in the latest commit?
If things still aren't working out, would you mind sending me a minimal toy version of your dataset that can lead to this error?
Found it!! With the latest version, the function runs smoothly if I don't explicitly write type =
. The error can be reproduced like this:
> test <- data.frame(subjectkey, a = 1:278)
> dl <- generate_data_list(list(test, "a","a",type = "discrete"), uid = "subjectkey")
Error in convert_uids(data_list, uid) :
The specified original UID (subjectkey) is not present in this data list. Are you sure you spelled it correctly?
> dl <- generate_data_list(list(test, "a","a","discrete"), uid = "subjectkey")
[1] "Existing `subjectkey` column will be treated as UID."
Thank you for always getting back so quickly!
Ooooo.... that's an ugly bug!
Working on it now, thanks for spotting this!
Problem is fixed in version 0.4.2 (latest).
generate_data_list
intentionally was supposed to error on partial component naming, but that error wasn't triggering properly. Specifically line 127 here: https://github.com/BRANCHlab/metasnf/commit/0ba3675cf850996a0923b76a8af0db83f914d26c#diff-6b672bdc19d81ec20cb23ac6808e4aa0234a5de6a7250f2cb80aabc1df1e52dbL127
Hello!
I've been getting this error when I run
generate_data_list
:After some investigation, it looks like the issue is associated with the v0.2.1 update! In v.0.2.0, I get this feedback as expected
For reference, the lines prior to the function call are: