Skip to content

covidcast: support querying all counties of a state #380

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

Closed
sgratzl opened this issue Jan 19, 2021 · 3 comments
Closed

covidcast: support querying all counties of a state #380

sgratzl opened this issue Jan 19, 2021 · 3 comments

Comments

@sgratzl
Copy link
Member

sgratzl commented Jan 19, 2021

see also cmu-delphi/www-covidcast#721

a simple workaround would be to support prefix querie: e.g., geo_type = 'county' and geo_value like '06%' would query all counties in California (06).

with the upcoming Python version we could also have a simple mapping that supports the tree navigation from nation -> state -> county.

@krivard
Copy link
Contributor

krivard commented Jan 21, 2021

this is a good idea, though it does require storing a mapping from state codes to their numeric FIPS equivalents. that kind of thing will be much easier to build and test once we're in Flask, but if cmu-delphi/www-covidcast#721 needs the lift earlier than that we might be able to hack something together. There's a workaround using the R or Python clients that doesn't require typing in all the counties in a state by hand; I'll comment in the other thread.

@krivard
Copy link
Contributor

krivard commented Jan 21, 2021

...how do you get from "ca" to "06" then?

@sgratzl
Copy link
Member Author

sgratzl commented May 14, 2021

Duplicate of #542

@sgratzl sgratzl marked this as a duplicate of #542 May 14, 2021
@sgratzl sgratzl closed this as completed May 14, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants