Skip to main content

AQIPython

Description

AQIPython is a Python module that calculates the Air Quality Index (AQI) for various air pollutants based on different standards. The module takes pollutant concentration values in parts per million (PPM), milligrams per cubic meter (mg/m³), and micrograms per cubic meter (µg/m³) and provides the corresponding AQI value.

Installation

To install AQIPython, you can use pip, the Python package manager. Open your terminal or command prompt and run the following command:

pip install AQIPython

Usage

Here's an example of how to use AQIPython to calculate the AQI for different pollutants:

from AQIPython import calculate_aqi

AQI = calculate_aqi('IN', 'CO', 3.5, "ug/m3")
print(AQi)

Make sure to replace the country code, pollutant code, concentration value, and unit with your actual data. The calculate_aqi() function takes four arguments: the country code (e.g., 'IN' for India), pollutant code (e.g., 'CO' for carbon monoxide), concentration value, and concentration unit (e.g., 'ug/m3' for micrograms per cubic meter).

Supported Pollutants

AQIPython supports the following pollutants for calculating AQI:

  • PM25 (particulate matter with a diameter of 2.5 micrometers or less)
  • PM10 (particulate matter with a diameter of 10 micrometers or less)
  • NO2 (nitrogen dioxide)
  • SO2 (sulfur dioxide)
  • CO (carbon monoxide)
  • O3 (ozone)
  • PB (Lead)** (Not for US)

Supported Standards

AQIPython supports the following Standards for calculating AQI:

  • IN (India)
  • US (United States of America)

Supported units

AQIPython supports the following Standards for calculating AQI:

  • ug/m3 (microgram per metercube)
  • mg/m3 (miligram per metercube)
  • ppm (parts per million)

Contributing

If you'd like to contribute to AQIPython, please take a look at Contributing Guidelines.

Author

Changelog

[1.0.0] - 2023-07-10

  • Initial release of AQIPython.
  • Support for Indian and US standard AQI calculation.
  • Calculate AQI for PM2.5, PM10, NO2, SO2, CO, and O3 pollutants.
  • Provide function calculate_aqi() to calculate AQI based on pollutant concentrations.

License

This module is released under the MIT License.

Metadata

Release files for AQIPython 1.0.1

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for AQIPython 1.0.1
File Size Uploaded
AQIPython-1.0.1.tar.gz 4.9 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for AQIPython 1.0.1
File Interpreter ABI Platform
AQIPython-1.0.1-py3-none-any.whl Python 3 none any Details

Total release size: 10.7 kB

Release files / AQIPython-1.0.1.tar.gz

Download URL AQIPython-1.0.1.tar.gz
Size 4.9 kB
Tags Source
SHA-256 checksum
How to use checksums
667a447924a12a00432f0b6cdb49b87abdacc8fbe0c26334ec9646f698b9241d
BLAKE2b-256 checksum
How to use checksums
5ce756e6dec720fd7bec293ca9d83d1b219a88c127bb1a0f990247fbe62182c5
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.2 CPython/3.7.13

Release files / AQIPython-1.0.1-py3-none-any.whl

Download URL AQIPython-1.0.1-py3-none-any.whl
Size 5.8 kB
Tags Python 3
SHA-256 checksum
How to use checksums
d99dfa75380c5898b68adeb8a14561cdb50361c5f94e379c649a030b0dacd680
BLAKE2b-256 checksum
How to use checksums
400b1bcf7793016bdc94dcae21654c85464fbf34c4018abdfbcab4c8f9efff67
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/4.0.2 CPython/3.7.13

Release history Release notifications | RSS feed

This release

1.0.1 This release

2 release files

1.0.0

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page