get-rolling-window
Gets an array of size-period rolling windows from an numpy 1-D array
Install
$ pip install get-rolling-window
Usage
import numpy as np
from get_rolling_window import rolling_window
array = np.arange(1, 8)
rolling_window(array, 3, 2)
# array([[1, 2, 3],
# [3, 4, 5],
# [5, 6, 7]])
rolling_window(array, size, shift, stride) -> np.ndarray
|-------- size:3 --------|
|- stride:1 -| |
| | |
1 2 3 --------|---
shift:2
3 4 5 --------|---
5 6 7
- array
np.ndarrayThe 1-D numpy array. If the given array has more than one dimensions, it will be treated as a 1-D array. - size
intThe size of the window. - shift?
int=NoneTheshiftargument determines the number of input elements by which the window moves on each iteration. Defaults tosize. - stride?
int=1Determines the stride of the input elements. Defaults to1.
Returns np.ndarray
License
Metadata
Release files for get-rolling-window 1.0.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | |
|---|---|---|---|---|
| get-rolling-window-1.0.0.tar.gz | 3.2 kB | Without provenance | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| get_rolling_window-1.0.0-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 6.9 kB
Release files / get-rolling-window-1.0.0.tar.gz
| Download URL | get-rolling-window-1.0.0.tar.gz |
|---|---|
| Size | 3.2 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
477c83d2bc1e986e39038cff2362b7831dd6e669efe2450ca9534ea6715cc5aa
|
|
BLAKE2b-256 checksum How to use checksums |
bc7dcdc716cd69c5d6900e721885eccd15b55415c30e6f70ef12d79805bf7321
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/3.2.0 pkginfo/1.5.0.1 requests/2.24.0 setuptools/50.3.2 requests-toolbelt/0.9.1 tqdm/4.48.2 CPython/3.8.5
|
Release files / get_rolling_window-1.0.0-py3-none-any.whl
| Download URL | get_rolling_window-1.0.0-py3-none-any.whl |
|---|---|
| Size | 3.7 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
fb030aead7784c93fc431ea4c8f4afbee12a2f30d18ad31a57161da19cfd416b
|
|
BLAKE2b-256 checksum How to use checksums |
c552a4a312e7d1595545843a04810fd4059b4267afc2eafd0e0cd073567e7524
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/3.2.0 pkginfo/1.5.0.1 requests/2.24.0 setuptools/50.3.2 requests-toolbelt/0.9.1 tqdm/4.48.2 CPython/3.8.5
|
Security for get-rolling-window 1.0.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.