Package for calculating meteorological indices
Project description
DDC Meteorological Indices
This is the Danube Data Cube Meteorological Indices library, a python implementation for calculating common meteorological indices, utilizing data cubes.
The following indices are available:
- SPI, Standardized Precipitation Index, utilizing both gamma and Pearson Type III distributions
- SPEI, Standardized Precipitation Evapotranspiration Index, utilizing both gamma and Pearson Type III distributions
- PDSI, Palmer Drought Severity Index
- PNI, Percentage of Normal Precipitation Index
Installation
$ pip install ddc-indices
Example
$ python
# Calculating the Standardized Precipitation Index (SPI)
>>> import xarray as xr
>>> from ddc_indices import DdcIndices
>>> from ddc_indices import SpiConfig
# import my dataset containing precipitation data
>>> dataset = xr.open_zarr('path_to_zarr')
>>> config = SpiConfig(variables={'prec': 'prec'}, periodicity='daily')
>>> spi = DdcIndices().initialize(dataset, config)
>>> spi.compute()
>>> spi.index
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
ddc-indices-0.5.2.tar.gz
(18.5 kB
view hashes)
Built Distribution
Close
Hashes for ddc_indices-0.5.2-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | 539fc476ef17ea91cce1e803b2553c64f0315df5eb504b562fa32b2761e69196 |
|
MD5 | 464bac94b6eb41f0840fedbebf968d00 |
|
BLAKE2b-256 | 8d6aed9925bd95c99cee4723dcf708fb3f3b7ffb56d46d20181046565d25dbb9 |