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

Update error messaging for invalid queries #125

Open
vsriram24 opened this issue Sep 3, 2024 · 0 comments
Open

Update error messaging for invalid queries #125

vsriram24 opened this issue Sep 3, 2024 · 0 comments
Labels
documentation Improvements or additions to documentation

Comments

@vsriram24
Copy link

I tried to collect incidence data for all counties in Washington using the incidence_cancer(). I received an error in mutate(), stating that a data frame with 'NA' or empty names cannot be transformed. Either these situations should be accounted for, or a more informative error message should be generated to handle such a call.

Example code:
cancerprof::incidence_cancer( area = "wa", areatype = "county", cancer = "all cancer sites", race = "All Races (includes Hispanic)", sex = "both sexes", age = "all ages", stage = "all stages", year = "latest 5 year average" )

Error message:
Error in mutate(): ! Can't transform a data frame with NAor""` names.
Backtrace:

  1. cancerprof::incidence_cancer(...)
  2. dplyr:::mutate.data.frame(...)
    Error in mutate(., across(c(all_of(shared_names_to_numeric), "Recent_5_Year_Trend",`
@vsriram24 vsriram24 added the documentation Improvements or additions to documentation label Sep 3, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
documentation Improvements or additions to documentation
Projects
None yet
Development

No branches or pull requests

1 participant