linelist icon indicating copy to clipboard operation
linelist copied to clipboard

check for entirely missing columns in guess_dates

Open zkamvar opened this issue 5 years ago • 6 comments

This will return the column unchanged if encountered and will fix #108

zkamvar avatar Feb 10 '20 15:02 zkamvar

@aspina7, can you check this with remotes::install_github("reconhub/linelist#109") and confirm that it works for you?

zkamvar avatar Feb 10 '20 15:02 zkamvar

so it works for a character NA variable (returns only NAs). But i think the default for an entirely NA var is to be logical....

aspina7 avatar Feb 10 '20 15:02 aspina7

so it works for a character NA variable (returns only NAs). But i think the default for an entirely NA var is to be logical....

Okay, I've set it so that it will return the unmodified NA column before it panics about vector types. Try it now.

zkamvar avatar Feb 10 '20 16:02 zkamvar

works a charm - maybe just specify in the warning which variable?

aspina7 avatar Feb 10 '20 16:02 aspina7

works a charm - maybe just specify in the warning which variable?

Again, difficult to do because the context of this function is on individual vectors. It doesn't know that these vectors come from a data frame.

zkamvar avatar Feb 10 '20 16:02 zkamvar

ah true true sorry!

aspina7 avatar Feb 10 '20 16:02 aspina7