feature-engineering

Convert raw hockey data into model-ready features with lagging and rolling windows.

2|1|Updated May 1, 2026
One-click install
npx skills add https://github.com/PuckAPI/claude-sports-analytics --skill feature-engineering-puckapi
Or copy as Structured Prompt for Agent
Please help me install this Agent Skill.
Skill: feature-engineering
Source: https://github.com/PuckAPI/claude-sports-analytics/tree/main/skills/feature-engineering
Command: npx skills add https://github.com/PuckAPI/claude-sports-analytics --skill feature-engineering-puckapi

SYSTEM DOCUMENTATION & REQUIREMENTS

💡 This Skill includes scripts (resource) and references (resource) components.

What problem does it solve?

This Skill streamlines the process of converting raw hockey game, player, and goalie data into clean, predictive features suitable for modeling, ensuring no temporal data leakage occurs.

Core Features & Use Cases

  • Predictive Data Preparation: Create features for NHL analytics and prediction models, like rolling averages, schedule adjustments, and opponent effects.
  • Use Case: A data scientist wants to build a hockey game outcome model; this Skill aids in generating feature matrices that respect temporal integrity and prevent leakage.
  • Technical Scope: Computes lagged, rolling, home/away, schedule strength, goalie, Elo, and opponent-adjusted metrics using puckapi-tool and custom logic.

Quick Start

Use the feature-engineering skill to prepare your hockey dataset for model training and validation by generating features with no leakage or data bias.

Frequently Asked Questions about feature-engineering

High-intent search queries and answers about installing and using this skill.

FAQPage Schema
How do I prevent data leakage when building predictive hockey features?

To prevent data leakage in predictive hockey features, you apply lagging and rolling windows to historical game logs and team stats, ensuring future outcomes never influence past predictive metrics.

What's the best way to prepare raw NHL game data for outcome prediction models?

The best way to prepare raw NHL game data for outcome prediction is transforming game, player, and goalie logs into model-ready matrices using schedule adjustments and opponent-adjusted metrics.

How do I calculate rolling averages and schedule strength for hockey analytics?

You calculate rolling averages and schedule strength for hockey analytics by processing historical game logs with custom logic, computing lagged metrics and Elo ratings to produce structured features.

Can I use this feature engineering approach for both NHL game outcomes and player performance?

Yes, this feature engineering approach works for both NHL game outcomes and player performance modeling, transforming raw goalie and team data into reliable metrics without temporal data bias.

Why do my hockey prediction models fail even with rich historical game data?

Hockey prediction models fail with rich historical data when temporal integrity is compromised, making lagging and home/away schedule adjustments essential to prevent data leakage during model training.

Does this data preprocessing method support goalie-specific performance metrics?

Yes, this data preprocessing method supports goalie-specific performance metrics by transforming raw goalie data into structured features while applying schedule strength adjustments to maintain predictive integrity.