Skip to main content

Documentation Status

scipy for xarray

xr-scipy is a thin wrapper of scipy for the xarray eco-system. You can read the documentation here.

Many scipy functions, such as scipy.integrate.trapezoid requires coordinate array as an argument. xr-scipy wraps these functions to use native coordinate objects of xarray and returns an xarray object with the computed data. This enables more xarray-oriented data analysis with scipy.

Other usage/options are kept almost the same as the original scipy function.

Example

import xarray as xr
import numpy as np
import xrscipy.integrate

In[1]: da = xr.DataArray([0, 3, 2, 4, 6], coords={'x': np.linspace(0, 1, 5)})
In[2]: da
Out[2]:
<xarray.DataArray (x: 5)>
array([0, 3, 2, 4, 6])
Coordinates:
  * x        (x) float64 0.0 0.25 0.5 0.75 1.0

In[3]: xrscipy.integrate.cumulative_trapezoid(da, coord='x')
Out[3]:
<xarray.DataArray (x: 5)>
array([0.   , 0.375, 1.   , 1.75 , 3.   ])
Coordinates:
  * x        (x) float64 0.0 0.25 0.5 0.75 1.0

Installation

pip install xrscipy

Metadata

Release files for xrscipy 3.1.0

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

Source distribution (sdist)

Source distribution for xrscipy 3.1.0
File Size Uploaded Provenance Actions
xrscipy-3.1.0.tar.gz 23.7 kB Without provenance Details for xrscipy-3.1.0.tar.gz

Built distribution (wheel)

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

Total release size: 45.1 kB

Release files / xrscipy-3.1.0.tar.gz

Download URL xrscipy-3.1.0.tar.gz
Size 23.7 kB
Tags Source
SHA-256 checksum
How to use checksums
5d6d27d78234185ba9b709a6bcc4ec07f7f0260250bd0a5eb1ead340ae038086
BLAKE2b-256 checksum
How to use checksums
3757adcd6c3f31776f4fdfaa657c08246de0d595fe870315bb6c6a55ba4aa599
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.13.7

Release files / xrscipy-3.1.0-py3-none-any.whl

Download URL xrscipy-3.1.0-py3-none-any.whl
Size 21.4 kB
Tags Python 3
SHA-256 checksum
How to use checksums
34c3eebd682230648b52586c7d84c634061401a63530934dc8f477ec7eb14533
BLAKE2b-256 checksum
How to use checksums
a2789f27e68b155fed9e7916b2a48faedda19d7152d3dbd4670940bfc130d0d9
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/6.2.0 CPython/3.13.7

Security for xrscipy 3.1.0

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

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