Market Entropy Pass Node
Market Entropy — Series Input
Overview
The Market Entropy Pass Node measures the Shannon entropy of the return distribution within a rolling window. Entropy quantifies the randomness or complexity of a series: high entropy means returns are spread unpredictably across many bins, while low entropy indicates concentrated, repetitive behaviour.
Unlike fractal dimension or Hurst exponent, entropy is non-parametric and captures distributional complexity without assuming a specific model structure.
Formula
bins equal-width bucketsParameters
| Parameter | Default | Description |
|---|---|---|
| period | 20 | Rolling window in bars |
| bins | 10 | Number of histogram bins for the return distribution |
Inputs & Outputs
| Slot | Direction | Type | Description |
|---|---|---|---|
| input | Input | { values, timestamps } | Any upstream numeric series (returns preferred) |
| values | Output | (number | null)[] | Shannon entropy per bar; nulls during warm-up |
| timestamps | Output | number[] | Unix timestamps aligned to input |
Use Cases
Market Regime Detection
Low entropy = returns concentrated in a few bins = trending or crisis regime. High entropy = random, normal market.
Volatility Regime Complement
Entropy captures distributional complexity beyond standard deviation — useful when returns are non-Gaussian.
Pre-Trade Filter
Pause mean-reversion strategies when entropy drops significantly (returns becoming concentrated = trending conditions).
Tips & Best Practices
Use Returns Not Prices
Feed log or simple returns to measure the entropy of the return distribution. Raw prices produce misleading entropy values.
Bin Count Trade-Off
More bins = finer resolution but noisier for small period windows. A period/bins ratio of at least 2–3 is recommended.
Max Entropy Reference
Maximum possible entropy = log₂(bins). With 10 bins, max entropy ≈ 3.32 bits. Normalise if comparing across different bin counts.