Skip to content
Back to skills

State Space Models

ASecurity

"Build PyFlux Gaussian, non-Gaussian, local-level, local-trend,

  • 247 stars
  • 0 votes
  • 0 copies
  • 3 views
  • Added September 8, 2026
toolsgoapi

Works with

  • api

Security analysis

A100/100

Pro scans all 4 files and shows the line behind each finding

Scanned September 8, 2026

npx -y skills add VectorSpaceLab/AREX-Skill --skill state-space-models --agent claude-code

Installs into .claude/skills of the current project.

Are you the author of State Space Models?

Add the live security badge to your README. It updates with every re-scan.

Security grade badge for State Space Models
[![Security: A — Skills Directory](https://www.skillsdirectory.com/api/skills/vectorspacelab-state-space-models/badge)](https://www.skillsdirectory.com/skills/vectorspacelab-state-space-models)

More formats (shields.io, HTML) on the badges page. Keep it an A: scan every change in CI with Pro.

Download with Pro
SKILL.md
---
name: state-space-models
description: "Build PyFlux Gaussian, non-Gaussian, local-level, local-trend,
  dynamic regression, and dynamic autoregression state-space models."
disable-model-invocation: true
metadata:
  disco-role: operating
license: BSD 3-Clause
---

# PyFlux state-space models

Use this sub-skill for PyFlux structural time-series work: local level/trend, dynamic regression, dynamic autoregression, and the family-dispatch wrappers that select the Gaussian or non-Gaussian implementation.

## Route here

- `LLEV(data, integ=0, target=None)` and `LLT(data, integ=0, target=None)` for Gaussian local-level and local-linear-trend models.
- `NLLEV(data, family, integ=0, target=None)` and `NLLT(data, family, integ=0, target=None)` for non-Gaussian local-level and local-linear-trend models.
- `DAR(data, ar, integ=0, target=None)` for dynamic autoregression.
- `DynReg(formula, data)` for Gaussian dynamic regression with Patsy formulas.
- `NDynReg(formula, data, family)` for non-Gaussian dynamic regression.
- `DynamicGLM(formula, data, family)` when you want a selector that returns `DynReg` for `Normal()` and `NDynReg` otherwise.
- `LocalLevel(data, family, integ=0, target=None)` and `LocalTrend(data, family, integ=0, target=None)` when you want the family object to route to the concrete class.

Route elsewhere:

- `GASLLEV` and `GASLLT` go to `../gas-models/`.
- `VAR` and `GPNARX` go to `../multivariate-models/`.
- GARCH/EGARCH-style volatility models go to `../volatility-models/`.
- Do not expose internal Kalman recursion helpers or Cython implementation details as user entry points.

## Default operating procedure

1. Pick the model family first: Gaussian/Kalman-style for continuous responses, non-Gaussian BBVI for counts or other non-Gaussian observations.
2. Use the convenience wrapper when the family should decide the concrete class: `LocalLevel`, `LocalTrend`, or `DynamicGLM`.
3. For formula models, make the training DataFrame columns match the Patsy formula exactly, and supply the same column names in `oos_data` for forecasting.
4. Fit the model, then check `summary()`, `plot_fit()`, `predict()`, and `predict_is()`. For Gaussian models, `predict()` can return intervals; for non-Gaussian point forecasts, `predict()` is simpler and `plot_predict()` carries the visual intervals.
5. Validate with the bundled smoke helper section: [`../../scripts/smoke_pyflux_models.py --section state-space`](../../scripts/smoke_pyflux_models.py).

## References

- [API reference](references/api-reference.md)
- [Workflows](references/workflows.md)
- [Troubleshooting](references/troubleshooting.md)
- Root [families and inference](../../references/families-and-inference.md) for priors, fit methods, result objects, and posterior diagnostics.
- Root [troubleshooting](../../references/troubleshooting.md) for install/build and legacy live-data failures shared across routes.

Files in this skill

  • SKILL.md2.8 KB
  • references/api-reference.md4.3 KB
  • references/troubleshooting.md2.8 KB
  • references/workflows.md3.9 KB

Attribution

Is this your skill, or is something wrong with this listing? Request removal or report an issue. Author removals are honored within 72 hours.

Comments

Loading comments…

Newsletter

Get the weekly list of safe new skills, and the ones we pulled.