Skip to main content

Read StatsCan data into python, mostly pandas dataframes

Project description

Python api for Statistics Canada New Data Model (NDM)

Tests Documentation Status PyPI version Anaconda-Server Badge

API documentation for StatsCan can be found on the web data service docs

If you're looking for Table/Vector IDs to use in the app you can find them through the StatCan data page

Anaconda package

Read the docs

Introduction

This library implements most of the functions defined by the Statistics Canada Web Data Service. It also has a number of helper functions that make it easy to read Statistics Canada tables or vectors into pandas dataframes.

Installation

The package can either be installed with pip or conda:

conda install -c conda-forge stats_can

Or:

pip install stats-can

The code is also available on

github.

Contributing

Contributions to this project are welcome. Fork the repository from github.

You'll need a python environment with poetry installed. A good guide for setting up an environment and project (that I used for this library) is hypermodern python.

I've configured the project to use nix for environment creation. If you use nix then the makefile in the root of the project will let you create development environments and run tests. However you like to configure a uv project should work though.

I'd also welcome contributions to the docs, or anything else that would make this tool better for you or others.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

stats_can-3.1.0.tar.gz (9.6 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

stats_can-3.1.0-py3-none-any.whl (11.2 kB view details)

Uploaded Python 3

File details

Details for the file stats_can-3.1.0.tar.gz.

File metadata

  • Download URL: stats_can-3.1.0.tar.gz
  • Upload date:
  • Size: 9.6 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: uv/0.9.18 {"installer":{"name":"uv","version":"0.9.18","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

File hashes

Hashes for stats_can-3.1.0.tar.gz
Algorithm Hash digest
SHA256 9cc37b813f9d01bc6cac877d4cd36a8a4205b568fead3e4449dd697bb4932858
MD5 aa4b1bbd546beffe63ee6aede0f3d4da
BLAKE2b-256 2b58e57f21c25deb58d93a9ea9cf845b987818ba958e2d42086879d764ba8ec6

See more details on using hashes here.

File details

Details for the file stats_can-3.1.0-py3-none-any.whl.

File metadata

  • Download URL: stats_can-3.1.0-py3-none-any.whl
  • Upload date:
  • Size: 11.2 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: uv/0.9.18 {"installer":{"name":"uv","version":"0.9.18","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"Ubuntu","version":"24.04","id":"noble","libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":true}

File hashes

Hashes for stats_can-3.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 251afda1c3e1e05f6d06d9d58d6150cf663bc5394249c3114893b66f4a88c54f
MD5 b7040d05969d654f8aaca8c33c021176
BLAKE2b-256 44894e0372bc15691c770989b47e091ec178ef5ba6e42698f62269e92bd568e2

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page