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

covidcast_signal and empty results #519

Open
sgratzl opened this issue Mar 31, 2021 · 0 comments
Open

covidcast_signal and empty results #519

sgratzl opened this issue Mar 31, 2021 · 0 comments

Comments

@sgratzl
Copy link
Member

sgratzl commented Mar 31, 2021

in www-main: https://github.com/cmu-delphi/www-main/runs/2228785215?check_suite_focus=true

we currently have the problem that the build fails since it tries to select a field time_value that doesn't exist when covidcast_signal returns an empty set (due to bigint issue)

query_date <- "2020-08-01"
query_date <- "2020-08-01"
covidcast_signal(
  data_source = "quidel",
  signal = "covid_ag_raw_pct_positive",
  start_day = query_date,
  end_day = query_date,
  geo_type = "state",
  geo_value = "ny",
  issues = c(query_date, "2020-09-04")) %>%
    select(time_value, value, sample_size, issue, lag) %>%
    distinct(value, .keep_all=TRUE) %>%
    knitr::kable("html", digits = 2,
                 col.names = c("Test date", "Positivity rate (%)", "Sample size",
                               "Issued on", "Lag (days)"))

imo even if covidcast_signal doesn't return any result it should still have the common structure but no rows

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants