Contents Menu Expand Light mode Dark mode Auto light/dark, in light mode Auto light/dark, in dark mode Skip to content
temporalcv
temporalcv

Getting Started

  • Quickstart Guide
  • Why Time Series Is Different
  • Common Pitfalls and Best Practices
  • Algorithm Decision Tree

Examples Gallery

  • Examples Gallery
    • Quickstart: temporalcv in 50 lines
    • Example 01: Detecting Data Leakage with the Shuffled Target Test
    • Example 02: Walk-Forward Cross-Validation with Gap Enforcement
    • Example 03: Statistical Tests for Forecast Comparison
    • Example 04: Handling High-Persistence Time Series
    • Example 05: Conformal Prediction for Time Series
    • Example 06: Financial Cross-Validation with PurgedKFold
    • Example 07: Nested Cross-Validation for Hyperparameter Tuning
    • Example 08: Regime-Stratified Evaluation
    • Example 09: Multi-Horizon Comparison
    • Example 10: End-to-End Time Series ML Pipeline
    • Example 11: Web Traffic Forecasting
    • Example 12: IoT Sensor Forecasting
    • Example 13: Macro GDP Forecasting
    • Example 14: Energy Load Forecasting
    • Example 15: Crypto Volatility Forecasting
    • Example 16: FAILURE CASE — Rolling Statistics on Full Series
    • Example 17: FAILURE CASE — Threshold Leakage
    • Example 18: FAILURE CASE — Using DM Test for Nested Models
    • Example 19: FAILURE CASE — Missing Gap for Multi-Step Forecasting
    • Example 20: FAILURE CASE — KFold Instead of WalkForward

Tutorials

  • Tutorials
    • Examples Index
    • Failure Cases Guide
    • Guardrails: The HALT/WARN/PASS Framework
    • Lag Selection Guide
    • Multi-Horizon Forecasting Tutorial
    • Feature Engineering Safety Guide
    • Metric Selection Guide
    • Validation Diagnostic Flowchart
    • Tutorial: Leakage Detection with Validation Gates
    • Tutorial: Walk-Forward Cross-Validation
    • Tutorial: High-Persistence Time Series
    • Tutorial: Uncertainty Quantification

API Guides

  • API Reference: Validation Gates
  • Guardrails
  • API Reference: Walk-Forward Cross-Validation
  • Financial Cross-Validation
  • API Reference: Statistical Tests
  • Stationarity Tests
  • Lag Selection
  • API Reference: Conformal Prediction
  • API Reference: High-Persistence Metrics
  • API Reference: Regime Classification
  • API Reference: Time Series Bagging
  • Diagnostics
  • Changepoint Detection
  • Inference
  • API Reference: Metrics
  • Benchmarks
  • Model Comparison
  • Visualization Module

Reference

  • Glossary
  • Mathematical Foundations
  • Assumptions by Module
  • Notation Guide
  • Testing Strategy
  • Validation Evidence

Model Cards

  • Model Cards
  • WalkForwardCV Model Card
  • gate_signal_verification Model Card

Benchmarks

  • Benchmark Results
  • Benchmark Methodology
  • Reproducing Benchmark Results

Help

  • Troubleshooting & FAQ
Back to top
View this page
Edit this page

Examples Gallery¶

21 real-world case studies demonstrating temporalcv’s capabilities across different domains and use cases.

Core Concepts (00-05)¶

Foundational examples introducing validation gates, walk-forward CV, statistical tests, persistence metrics, and conformal prediction.

Production Workflows (06-10)¶

Complete pipelines for real ML systems: financial CV with purging, nested CV for hyperparameter tuning, regime stratification, multi-horizon comparison, and end-to-end deployment.

Domain-Specific (11-15)¶

Industry-tailored examples: web traffic with seasonality, IoT sensors with anomalies, macro GDP forecasting, energy load prediction, and cryptocurrency with regime shifts.

Failure Cases (16-20)¶

Learn from common mistakes: each shows what goes wrong and how the validation gates catch the issue before it corrupts your results.

Note

All examples use synthetic data and require no external datasets. Run any example with python examples/XX_name.py.

Quickstart: temporalcv in 50 lines

Quickstart: temporalcv in 50 lines

Example 01: Detecting Data Leakage with the Shuffled Target Test

Example 01: Detecting Data Leakage with the Shuffled Target Test

Example 02: Walk-Forward Cross-Validation with Gap Enforcement

Example 02: Walk-Forward Cross-Validation with Gap Enforcement

Example 03: Statistical Tests for Forecast Comparison

Example 03: Statistical Tests for Forecast Comparison

Example 04: Handling High-Persistence Time Series

Example 04: Handling High-Persistence Time Series

Example 05: Conformal Prediction for Time Series

Example 05: Conformal Prediction for Time Series

Example 06: Financial Cross-Validation with PurgedKFold

Example 06: Financial Cross-Validation with PurgedKFold

Example 07: Nested Cross-Validation for Hyperparameter Tuning

Example 07: Nested Cross-Validation for Hyperparameter Tuning

Example 08: Regime-Stratified Evaluation

Example 08: Regime-Stratified Evaluation

Example 09: Multi-Horizon Comparison

Example 09: Multi-Horizon Comparison

Example 10: End-to-End Time Series ML Pipeline

Example 10: End-to-End Time Series ML Pipeline

Example 11: Web Traffic Forecasting

Example 11: Web Traffic Forecasting

Example 12: IoT Sensor Forecasting

Example 12: IoT Sensor Forecasting

Example 13: Macro GDP Forecasting

Example 13: Macro GDP Forecasting

Example 14: Energy Load Forecasting

Example 14: Energy Load Forecasting

Example 15: Crypto Volatility Forecasting

Example 15: Crypto Volatility Forecasting

Example 16: FAILURE CASE — Rolling Statistics on Full Series

Example 16: FAILURE CASE — Rolling Statistics on Full Series

Example 17: FAILURE CASE — Threshold Leakage

Example 17: FAILURE CASE — Threshold Leakage

Example 18: FAILURE CASE — Using DM Test for Nested Models

Example 18: FAILURE CASE — Using DM Test for Nested Models

Example 19: FAILURE CASE — Missing Gap for Multi-Step Forecasting

Example 19: FAILURE CASE — Missing Gap for Multi-Step Forecasting

Example 20: FAILURE CASE — KFold Instead of WalkForward

Example 20: FAILURE CASE — KFold Instead of WalkForward

Download all examples in Python source code: auto_examples_python.zip

Download all examples in Jupyter notebooks: auto_examples_jupyter.zip

Gallery generated by Sphinx-Gallery

Next
Quickstart: temporalcv in 50 lines
Previous
Algorithm Decision Tree
Copyright © 2025, Brandon Behring
Made with Sphinx and @pradyunsg's Furo
On this page
  • Examples Gallery
    • Core Concepts (00-05)
    • Production Workflows (06-10)
    • Domain-Specific (11-15)
    • Failure Cases (16-20)