minigst (Python)
The companion Python package for gstlearn.
This Python package wraps gstlearn functions to offer access to some basic geostatistical methods (mainly variography and kriging).
Installation
Prerequisites
You need Python 3.8 or higher. You will also need to install the gstlearn Python package. Please refer to the gstlearn documentation for installation instructions.
Installing minigst from our pypi (official release)
You can install the official release of minigst package using pip:
cd python
pip install minigst
Installing minigst from sources
After cloning the github repo, you can install the minigst package from source using pip:
git clone https://github.com/gstlearn/minigst
cd minigst
cd python
pip install .
Or for development:
git clone https://github.com/gstlearn/minigst
cd minigst
cd python
pip install -e .
Usage
import minigst as mg
import gstlearn as gl
import pandas as pd
# Load data from a pandas DataFrame
df = pd.read_csv("data.csv")
db = mg.df_to_db(df, coord_names=["x", "y"])
# Compute experimental variogram
vario_exp = mg.vario_exp(db, vname="variable", nlag=20, dlag=10.0)
# Fit a model
model = mg.model_fit(vario_exp, struct=["NUGGET", "SPHERICAL"])
# Perform kriging
target_db = mg.create_db_grid(nx=[100, 100], dx=[1.0, 1.0])
mg.minikriging(db, target_db, vname="variable", model=model)
# Plot results
mg.dbplot_grid(target_db, color="K.variable.estim")
Features
The minigst Python package provides wrapper functions for:
- Database operations: Convert pandas DataFrames to gstlearn Db objects, create grids, manipulate variables
- Plotting: Visualize spatial data and grids using matplotlib
- Variography: Compute experimental variograms and fit models
- Kriging: Perform simple, ordinary, and universal kriging
- Simulation: Generate Gaussian random fields
Documentation
For more information about the underlying gstlearn library, please visit gstlearn.org.
License
This package is distributed under the BSD-3 license.
Metadata
Release files for minigst 0.1.4
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| minigst-0.1.4-py3-none-any.whl | Python 3 | none | any | Details for minigst-0.1.4-py3-none-any.whl |
Release files / minigst-0.1.4-py3-none-any.whl
| Download URL | minigst-0.1.4-py3-none-any.whl |
|---|---|
| Size | 146.5 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
eba42a199e8eb1011a5d0055d0b2826e1944b0b86ef757a5f17681e4d6b541c5
|
|
BLAKE2b-256 checksum How to use checksums |
cd2458ac08d5abc6c55ff66eee56c5fb89b131b87bd998cc5bfb45ea7c1a9c9a
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.12.3
|
Security for minigst 0.1.4
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.