Giter Site home page Giter Site logo

singerep / censaurus Goto Github PK

View Code? Open in Web Editor NEW
8.0 2.0 0.0 9.03 MB

A comprehensive, feature-rich, and user-oriented Python package that wraps the U.S. Census Bureau's Data and Geographic APIs.

Home Page: https://censaurus.readthedocs.io/en/latest/

License: BSD 3-Clause "New" or "Revised" License

Python 100.00%
census census-api census-data python

censaurus's Introduction

Censaurus

version_badge Documentation Status

censaurus logo

Not just another Census data tool. Seriously.

censaurus is a comprehensive, feature-rich, and user-oriented Python package that wraps the U.S. Census Bureau's Data and Geographic APIs.

Documentation

Check out the censaurus documentation. There you'll find an introduction to the package, a walkthrough of a censaurus workflow, and full API reference.

Installation

censaurus is available on the Python Package Index, so it can be installed by running the following in the command line:

pip install censaurus

Get Involved

All contributions are welcomed! Please feel free to submit a pull request or point out an issue.

censaurus's People

Contributors

singerep avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

censaurus's Issues

template missing when following the tutorial steps

From the tutorial:

from censaurus import ACS5
acs = ACS5()
acs.variables.filter_by_group(group='B01001').visualize()

Resulting error:

File "lib/python3.11/site-packages/censaurus/graph_utils.py", line 64, in visualize_graph
    g.show(filename)
  File "lib/python3.11/site-packages/pyvis/network.py", line 546, in show
    self.write_html(name, open_browser=False,notebook=True)
  File "lib/python3.11/site-packages/pyvis/network.py", line 515, in write_html
    self.html = self.generate_html(notebook=notebook)
                ^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^^
  File "lib/python3.11/site-packages/pyvis/network.py", line 479, in generate_html
    self.html = template.render(height=height,
                ^^^^^^^^^^^^^^^
AttributeError: 'NoneType' object has no attribute 'render'

missing ref in documents

Reading through the Tutorial, noticed this missing reference:

image

censaurus looks really good, I look forward to trying it out in the future!

using SIMPLE_RENAMER.rename as per the tutorial returns same variable names

acs = ACS5()
male_age_vars = acs.variables.children_of(variable='B01001_002E')
northeast = acs.areas.region('Northeast')
data = acs.tracts(within=northeast, variables=male_age_vars, return_geometry=True)
data = SIMPLE_RENAMER.rename(data)
data

outputs

B01001_003E B01001_004E B01001_005E B01001_006E ... GEO_ID state county tract
0 32 15 24 8 ... 1400000US23001010100 23 001 010100
... ... ... ... ... ... ... ... ... ...

[14704 rows x 29 columns]

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.