Skip to content

Conversation

@acnromanmtz
Copy link

added a class for acs1st based off of acs5st
added function to fetch acs variables based off of the definitions url
added function to partially match variables fetched to make it easier for users to find the table values they are looking for based on the label and group

open to any edits by maintainers

Copy link
Contributor

@antidipyramid antidipyramid left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks for the PR, @acnromanmtz! Left a couple comments inline.

dataset = 'acs5/subject'

class ACS1StClient(ACSClient): # added
default_year = 2019
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you please add the supported years to this class?

For example:

class ACS1DpClient(ACS1Client):

    dataset = 'acs1/profile'

    years = (2022, 2021, 2019, 2018, 2017, 2016, 2015, 2014, 2013, 2012)
    ...

# Pass it out
return resp.json()['groups']

def variables(self, year=None) -> list: # added
Copy link
Contributor

@antidipyramid antidipyramid Jan 9, 2025

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Great idea here. We do plan on taking on a more general project of fetching API metadata from the
Census Data API Discovery Tool. Would you mind separating this out into another PR?

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

Successfully merging this pull request may close these issues.

2 participants