Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
28 changes: 28 additions & 0 deletions plots/line-timeseries-rolling/specification.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
# line-timeseries-rolling: Time Series with Rolling Average Overlay

## Description

A time series plot that displays raw data points alongside a smoothed rolling average (moving average) line. The raw data shows actual observations while the rolling average reveals underlying trends by reducing noise and short-term fluctuations. This dual-layer visualization is essential for trend identification, making patterns visible that might be obscured by day-to-day volatility.

## Applications

- Analyzing stock price movements with a moving average to identify buy/sell signals and trend reversals
- Monitoring website traffic or user engagement metrics with smoothed trends for seasonal pattern detection
- Tracking sensor data (temperature, humidity) with noise reduction to reveal true environmental trends

## Data

- `date` (datetime) - Timestamp values representing points in time
- `value` (numeric) - Raw measurements or observations at each timestamp
- `rolling_avg` (numeric) - Computed rolling average (e.g., 7-day, 30-day window)
- Size: 50-500 points (enough data for meaningful rolling window calculation)
- Example: Daily stock closing prices with 20-day moving average, hourly temperature readings with 24-hour rolling mean

## Notes

- Use a lighter, semi-transparent style for raw data (thin line or markers with alpha)
- Display the rolling average as a prominent, smooth line in a contrasting color
- Include a legend clearly distinguishing "Raw Data" from "Rolling Average (N-day)"
- Consider showing the window size in the legend or title (e.g., "7-Day Rolling Average")
- Grid lines on both axes improve readability of underlying values
- The rolling average line will be shorter than raw data due to window requirements
31 changes: 31 additions & 0 deletions plots/line-timeseries-rolling/specification.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
# Specification-level metadata for line-timeseries-rolling
# Auto-synced to PostgreSQL on push to main

spec_id: line-timeseries-rolling
title: Time Series with Rolling Average Overlay

# Specification tracking
created: 2025-12-30T17:31:12Z
updated: null
issue: 2786
suggested: MarkusNeusinger

# Classification tags (applies to all library implementations)
# See docs/concepts/tagging-system.md for detailed guidelines
tags:
plot_type:
- line
- timeseries
data_type:
- timeseries
- numeric
- continuous
domain:
- general
- finance
- statistics
features:
- smoothing
- rolling-average
- trend-analysis
- overlay