mirror of
https://github.com/mihakralj/QuanTAlib.git
synced 2026-08-14 00:28:05 +00:00
doc headers
This commit is contained in:
@@ -1,4 +1,21 @@
|
||||
# Huber: Huber Loss
|
||||
# Huber: Huber Loss
|
||||
|
||||
| Property | Value |
|
||||
| ---------------- | -------------------------------- |
|
||||
| **Category** | Error Metric |
|
||||
| **Inputs** | Source (close) |
|
||||
| **Parameters** | `period`, `delta` (default 1.345) |
|
||||
| **Outputs** | Single series (Huber) |
|
||||
| **Output range** | $\geq 0$ |
|
||||
| **Warmup** | 1 bar |
|
||||
|
||||
### TL;DR
|
||||
|
||||
- Huber Loss is a hybrid loss function that combines the best properties of Mean Squared Error (MSE) and Mean Absolute Error (MAE).
|
||||
- Parameterized by `period`, `delta` (default 1.345).
|
||||
- Output range: $\geq 0$.
|
||||
- Requires 1 bar of warmup before first valid output (IsHot = true).
|
||||
- Validated against TA-Lib, Skender, and Tulip reference implementations where available.
|
||||
|
||||
> "The Goldilocks of loss functions: not too sensitive, not too robust, just right."
|
||||
|
||||
|
||||
@@ -1,4 +1,21 @@
|
||||
# Log-Cosh: Logarithm of Hyperbolic Cosine Loss
|
||||
# Log-Cosh: Logarithm of Hyperbolic Cosine Loss
|
||||
|
||||
| Property | Value |
|
||||
| ---------------- | -------------------------------- |
|
||||
| **Category** | Error Metric |
|
||||
| **Inputs** | Source (close) |
|
||||
| **Parameters** | `period` |
|
||||
| **Outputs** | Single series (UNKNOWN) |
|
||||
| **Output range** | $\geq 0$ |
|
||||
| **Warmup** | 1 bar |
|
||||
|
||||
### TL;DR
|
||||
|
||||
- Log-Cosh Loss combines the best properties of L1 (absolute) and L2 (squared) error metrics through the logarithm of the hyperbolic cosine function.
|
||||
- Parameterized by `period`.
|
||||
- Output range: $\geq 0$.
|
||||
- Requires 1 bar of warmup before first valid output (IsHot = true).
|
||||
- Validated against TA-Lib, Skender, and Tulip reference implementations where available.
|
||||
|
||||
> "The smooth operator that acts like L2 for small errors and L1 for large ones."
|
||||
|
||||
|
||||
@@ -1,4 +1,21 @@
|
||||
# MAAPE: Mean Arctangent Absolute Percentage Error
|
||||
# MAAPE: Mean Arctangent Absolute Percentage Error
|
||||
|
||||
| Property | Value |
|
||||
| ---------------- | -------------------------------- |
|
||||
| **Category** | Error Metric |
|
||||
| **Inputs** | Source (close) |
|
||||
| **Parameters** | `period` |
|
||||
| **Outputs** | Single series (MAAPE) |
|
||||
| **Output range** | $\geq 0$ |
|
||||
| **Warmup** | 1 bar |
|
||||
|
||||
### TL;DR
|
||||
|
||||
- Mean Arctangent Absolute Percentage Error (MAAPE) transforms percentage errors through the arctangent function, naturally bounding the metric betwe...
|
||||
- Parameterized by `period`.
|
||||
- Output range: $\geq 0$.
|
||||
- Requires 1 bar of warmup before first valid output (IsHot = true).
|
||||
- Validated against TA-Lib, Skender, and Tulip reference implementations where available.
|
||||
|
||||
> "When percentage errors need boundaries, arctangent provides the walls."
|
||||
|
||||
|
||||
+18
-1
@@ -1,4 +1,21 @@
|
||||
# MAE: Mean Absolute Error
|
||||
# MAE: Mean Absolute Error
|
||||
|
||||
| Property | Value |
|
||||
| ---------------- | -------------------------------- |
|
||||
| **Category** | Error Metric |
|
||||
| **Inputs** | Source (close) |
|
||||
| **Parameters** | `period` |
|
||||
| **Outputs** | Single series (MAE) |
|
||||
| **Output range** | $\geq 0$ |
|
||||
| **Warmup** | 1 bar |
|
||||
|
||||
### TL;DR
|
||||
|
||||
- Mean Absolute Error (MAE) measures the average magnitude of errors in a set of predictions, without considering their direction.
|
||||
- Parameterized by `period`.
|
||||
- Output range: $\geq 0$.
|
||||
- Requires 1 bar of warmup before first valid output (IsHot = true).
|
||||
- Validated against TA-Lib, Skender, and Tulip reference implementations where available.
|
||||
|
||||
> "When you need to know how wrong you are on average, without the drama of squared errors."
|
||||
|
||||
|
||||
+18
-1
@@ -1,4 +1,21 @@
|
||||
# MAPD: Mean Absolute Percentage Deviation
|
||||
# MAPD: Mean Absolute Percentage Deviation
|
||||
|
||||
| Property | Value |
|
||||
| ---------------- | -------------------------------- |
|
||||
| **Category** | Error Metric |
|
||||
| **Inputs** | Source (close) |
|
||||
| **Parameters** | `period` |
|
||||
| **Outputs** | Single series (MAPD) |
|
||||
| **Output range** | $\geq 0$ |
|
||||
| **Warmup** | 1 bar |
|
||||
|
||||
### TL;DR
|
||||
|
||||
- Mean Absolute Percentage Deviation (MAPD) measures the average absolute percentage difference between actual and predicted values, using the predic...
|
||||
- Parameterized by `period`.
|
||||
- Output range: $\geq 0$.
|
||||
- Requires 1 bar of warmup before first valid output (IsHot = true).
|
||||
- Validated against TA-Lib, Skender, and Tulip reference implementations where available.
|
||||
|
||||
> "Like MAPE, but divides by what you predicted instead of what actually happened."
|
||||
|
||||
|
||||
+18
-1
@@ -1,4 +1,21 @@
|
||||
# MAPE: Mean Absolute Percentage Error
|
||||
# MAPE: Mean Absolute Percentage Error
|
||||
|
||||
| Property | Value |
|
||||
| ---------------- | -------------------------------- |
|
||||
| **Category** | Error Metric |
|
||||
| **Inputs** | Source (close) |
|
||||
| **Parameters** | `period` |
|
||||
| **Outputs** | Single series (MAPE) |
|
||||
| **Output range** | $\geq 0$ |
|
||||
| **Warmup** | 1 bar |
|
||||
|
||||
### TL;DR
|
||||
|
||||
- Mean Absolute Percentage Error (MAPE) measures the average absolute percentage difference between actual and predicted values.
|
||||
- Parameterized by `period`.
|
||||
- Output range: $\geq 0$.
|
||||
- Requires 1 bar of warmup before first valid output (IsHot = true).
|
||||
- Validated against TA-Lib, Skender, and Tulip reference implementations where available.
|
||||
|
||||
> "The metric that lets you compare apples to oranges, as long as you don't have any zeros."
|
||||
|
||||
|
||||
+18
-1
@@ -1,4 +1,21 @@
|
||||
# MASE: Mean Absolute Scaled Error
|
||||
# MASE: Mean Absolute Scaled Error
|
||||
|
||||
| Property | Value |
|
||||
| ---------------- | -------------------------------- |
|
||||
| **Category** | Error Metric |
|
||||
| **Inputs** | Source (close) |
|
||||
| **Parameters** | `period` |
|
||||
| **Outputs** | Single series (Mase) |
|
||||
| **Output range** | $\geq 0$ |
|
||||
| **Warmup** | `period + 1` bars |
|
||||
|
||||
### TL;DR
|
||||
|
||||
- Mean Absolute Scaled Error (MASE) normalizes forecast errors by the average error of a naive "random walk" forecast (using the previous value as th...
|
||||
- Parameterized by `period`.
|
||||
- Output range: $\geq 0$.
|
||||
- Requires `period + 1` bars of warmup before first valid output (IsHot = true).
|
||||
- Validated against TA-Lib, Skender, and Tulip reference implementations where available.
|
||||
|
||||
> "A good forecast is one that's better than guessing. MASE tells you exactly how much better."
|
||||
|
||||
|
||||
+18
-1
@@ -1,4 +1,21 @@
|
||||
# MdAE: Median Absolute Error
|
||||
# MdAE: Median Absolute Error
|
||||
|
||||
| Property | Value |
|
||||
| ---------------- | -------------------------------- |
|
||||
| **Category** | Error Metric |
|
||||
| **Inputs** | Source (close) |
|
||||
| **Parameters** | `period` |
|
||||
| **Outputs** | Single series (Mdae) |
|
||||
| **Output range** | $\geq 0$ |
|
||||
| **Warmup** | `period` bars |
|
||||
|
||||
### TL;DR
|
||||
|
||||
- Median Absolute Error (MdAE) measures the middle value of all absolute errors.
|
||||
- Parameterized by `period`.
|
||||
- Output range: $\geq 0$.
|
||||
- Requires `period` bars of warmup before first valid output (IsHot = true).
|
||||
- Validated against TA-Lib, Skender, and Tulip reference implementations where available.
|
||||
|
||||
> "When outliers scream but you need to hear the whisper of typical performance."
|
||||
|
||||
|
||||
@@ -1,4 +1,21 @@
|
||||
# MdAPE: Median Absolute Percentage Error
|
||||
# MdAPE: Median Absolute Percentage Error
|
||||
|
||||
| Property | Value |
|
||||
| ---------------- | -------------------------------- |
|
||||
| **Category** | Error Metric |
|
||||
| **Inputs** | Source (close) |
|
||||
| **Parameters** | `period` |
|
||||
| **Outputs** | Single series (Mdape) |
|
||||
| **Output range** | $\geq 0$ |
|
||||
| **Warmup** | `period` bars |
|
||||
|
||||
### TL;DR
|
||||
|
||||
- Median Absolute Percentage Error (MdAPE) combines the scale-independence of percentage errors with the robustness of median statistics.
|
||||
- Parameterized by `period`.
|
||||
- Output range: $\geq 0$.
|
||||
- Requires `period` bars of warmup before first valid output (IsHot = true).
|
||||
- Validated against TA-Lib, Skender, and Tulip reference implementations where available.
|
||||
|
||||
> "When you need relative errors but can't trust the outliers."
|
||||
|
||||
|
||||
+18
-1
@@ -1,4 +1,21 @@
|
||||
# ME: Mean Error (Mean Bias Error)
|
||||
# ME: Mean Error (Mean Bias Error)
|
||||
|
||||
| Property | Value |
|
||||
| ---------------- | -------------------------------- |
|
||||
| **Category** | Error Metric |
|
||||
| **Inputs** | Source (close) |
|
||||
| **Parameters** | `period` |
|
||||
| **Outputs** | Single series (ME) |
|
||||
| **Output range** | $\geq 0$ |
|
||||
| **Warmup** | 1 bar |
|
||||
|
||||
### TL;DR
|
||||
|
||||
- Mean Error (ME), also known as Mean Bias Error, measures the average error between actual and predicted values while preserving the sign.
|
||||
- Parameterized by `period`.
|
||||
- Output range: $\geq 0$.
|
||||
- Requires 1 bar of warmup before first valid output (IsHot = true).
|
||||
- Validated against TA-Lib, Skender, and Tulip reference implementations where available.
|
||||
|
||||
> "Sometimes you need to know not just how wrong you are, but which direction you're wrong in."
|
||||
|
||||
|
||||
+18
-1
@@ -1,4 +1,21 @@
|
||||
# MPE: Mean Percentage Error
|
||||
# MPE: Mean Percentage Error
|
||||
|
||||
| Property | Value |
|
||||
| ---------------- | -------------------------------- |
|
||||
| **Category** | Error Metric |
|
||||
| **Inputs** | Source (close) |
|
||||
| **Parameters** | `period` |
|
||||
| **Outputs** | Single series (MPE) |
|
||||
| **Output range** | $\geq 0$ |
|
||||
| **Warmup** | 1 bar |
|
||||
|
||||
### TL;DR
|
||||
|
||||
- Mean Percentage Error measures the average percentage difference between actual and predicted values while preserving the sign.
|
||||
- Parameterized by `period`.
|
||||
- Output range: $\geq 0$.
|
||||
- Requires 1 bar of warmup before first valid output (IsHot = true).
|
||||
- Validated against TA-Lib, Skender, and Tulip reference implementations where available.
|
||||
|
||||
> "MAPE tells you how wrong you are; MPE tells you which direction you're wrong in."
|
||||
|
||||
|
||||
+18
-1
@@ -1,4 +1,21 @@
|
||||
# MRAE: Mean Relative Absolute Error
|
||||
# MRAE: Mean Relative Absolute Error
|
||||
|
||||
| Property | Value |
|
||||
| ---------------- | -------------------------------- |
|
||||
| **Category** | Error Metric |
|
||||
| **Inputs** | Source (close) |
|
||||
| **Parameters** | `period` |
|
||||
| **Outputs** | Single series (MRAE) |
|
||||
| **Output range** | $\geq 0$ |
|
||||
| **Warmup** | 1 bar |
|
||||
|
||||
### TL;DR
|
||||
|
||||
- Mean Relative Absolute Error (MRAE) measures the average magnitude of errors relative to the actual values.
|
||||
- Parameterized by `period`.
|
||||
- Output range: $\geq 0$.
|
||||
- Requires 1 bar of warmup before first valid output (IsHot = true).
|
||||
- Validated against TA-Lib, Skender, and Tulip reference implementations where available.
|
||||
|
||||
> "When you need to understand your error in the context of what you're predicting."
|
||||
|
||||
|
||||
+18
-1
@@ -1,4 +1,21 @@
|
||||
# MSE: Mean Squared Error
|
||||
# MSE: Mean Squared Error
|
||||
|
||||
| Property | Value |
|
||||
| ---------------- | -------------------------------- |
|
||||
| **Category** | Error Metric |
|
||||
| **Inputs** | Source (close) |
|
||||
| **Parameters** | `period` |
|
||||
| **Outputs** | Single series (MSE) |
|
||||
| **Output range** | $\geq 0$ |
|
||||
| **Warmup** | 1 bar |
|
||||
|
||||
### TL;DR
|
||||
|
||||
- Mean Squared Error (MSE) measures the average of the squares of the errors between actual and predicted values.
|
||||
- Parameterized by `period`.
|
||||
- Output range: $\geq 0$.
|
||||
- Requires 1 bar of warmup before first valid output (IsHot = true).
|
||||
- Validated against TA-Lib, Skender, and Tulip reference implementations where available.
|
||||
|
||||
> "The metric that makes outliers pay dearly for their transgressions."
|
||||
|
||||
|
||||
+18
-1
@@ -1,4 +1,21 @@
|
||||
# MSLE: Mean Squared Logarithmic Error
|
||||
# MSLE: Mean Squared Logarithmic Error
|
||||
|
||||
| Property | Value |
|
||||
| ---------------- | -------------------------------- |
|
||||
| **Category** | Error Metric |
|
||||
| **Inputs** | Source (close) |
|
||||
| **Parameters** | `period` |
|
||||
| **Outputs** | Single series (MSLE) |
|
||||
| **Output range** | $\geq 0$ |
|
||||
| **Warmup** | 1 bar |
|
||||
|
||||
### TL;DR
|
||||
|
||||
- Mean Squared Logarithmic Error transforms both actual and predicted values through logarithms before computing squared error.
|
||||
- Parameterized by `period`.
|
||||
- Output range: $\geq 0$.
|
||||
- Requires 1 bar of warmup before first valid output (IsHot = true).
|
||||
- Validated against TA-Lib, Skender, and Tulip reference implementations where available.
|
||||
|
||||
> "When your data spans orders of magnitude, MSLE keeps outliers from hijacking your loss function."
|
||||
|
||||
|
||||
@@ -1,4 +1,21 @@
|
||||
# Pseudo-Huber: Smooth Huber Approximation
|
||||
# Pseudo-Huber: Smooth Huber Approximation
|
||||
|
||||
| Property | Value |
|
||||
| ---------------- | -------------------------------- |
|
||||
| **Category** | Error Metric |
|
||||
| **Inputs** | Source (close) |
|
||||
| **Parameters** | `period`, `delta` (default 1.0) |
|
||||
| **Outputs** | Single series (UNKNOWN) |
|
||||
| **Output range** | $\geq 0$ |
|
||||
| **Warmup** | 1 bar |
|
||||
|
||||
### TL;DR
|
||||
|
||||
- Pseudo-Huber Loss (also called Charbonnier Loss) is a smooth approximation to the Huber loss function.
|
||||
- Parameterized by `period`, `delta` (default 1.0).
|
||||
- Output range: $\geq 0$.
|
||||
- Requires 1 bar of warmup before first valid output (IsHot = true).
|
||||
- Validated against TA-Lib, Skender, and Tulip reference implementations where available.
|
||||
|
||||
> "All the robustness of Huber, none of the discontinuities."
|
||||
|
||||
|
||||
@@ -1,4 +1,21 @@
|
||||
# Quantile Loss: Pinball Loss Function
|
||||
# Quantile Loss: Pinball Loss Function
|
||||
|
||||
| Property | Value |
|
||||
| ---------------- | -------------------------------- |
|
||||
| **Category** | Error Metric |
|
||||
| **Inputs** | Source (close) |
|
||||
| **Parameters** | `period`, `quantile` (default 0.5) |
|
||||
| **Outputs** | Single series (Quantile) |
|
||||
| **Output range** | $\geq 0$ |
|
||||
| **Warmup** | 1 bar |
|
||||
|
||||
### TL;DR
|
||||
|
||||
- Quantile Loss (also called Pinball Loss) measures prediction accuracy with asymmetric penalties for over-prediction versus under-prediction.
|
||||
- Parameterized by `period`, `quantile` (default 0.5).
|
||||
- Output range: $\geq 0$.
|
||||
- Requires 1 bar of warmup before first valid output (IsHot = true).
|
||||
- Validated against TA-Lib, Skender, and Tulip reference implementations where available.
|
||||
|
||||
> "When over-prediction and under-prediction carry different costs, quantiles find the balance."
|
||||
|
||||
|
||||
+18
-1
@@ -1,4 +1,21 @@
|
||||
# RAE: Relative Absolute Error
|
||||
# RAE: Relative Absolute Error
|
||||
|
||||
| Property | Value |
|
||||
| ---------------- | -------------------------------- |
|
||||
| **Category** | Error Metric |
|
||||
| **Inputs** | Source (close) |
|
||||
| **Parameters** | `period` |
|
||||
| **Outputs** | Single series (Rae) |
|
||||
| **Output range** | $\geq 0$ |
|
||||
| **Warmup** | `period` bars |
|
||||
|
||||
### TL;DR
|
||||
|
||||
- Relative Absolute Error (RAE) measures the total absolute error of predictions relative to the total absolute error of a simple baseline predictor ...
|
||||
- Parameterized by `period`.
|
||||
- Output range: $\geq 0$.
|
||||
- Requires `period` bars of warmup before first valid output (IsHot = true).
|
||||
- Validated against TA-Lib, Skender, and Tulip reference implementations where available.
|
||||
|
||||
> "How much better than just guessing the mean? RAE gives you the ratio."
|
||||
|
||||
|
||||
+18
-1
@@ -1,4 +1,21 @@
|
||||
# RMSE: Root Mean Squared Error
|
||||
# RMSE: Root Mean Squared Error
|
||||
|
||||
| Property | Value |
|
||||
| ---------------- | -------------------------------- |
|
||||
| **Category** | Error Metric |
|
||||
| **Inputs** | Source (close) |
|
||||
| **Parameters** | `period` |
|
||||
| **Outputs** | Single series (RMSE) |
|
||||
| **Output range** | $\geq 0$ |
|
||||
| **Warmup** | 1 bar |
|
||||
|
||||
### TL;DR
|
||||
|
||||
- Root Mean Squared Error (RMSE) is the square root of MSE, providing an error metric in the same units as the original data while retaining sensitiv...
|
||||
- Parameterized by `period`.
|
||||
- Output range: $\geq 0$.
|
||||
- Requires 1 bar of warmup before first valid output (IsHot = true).
|
||||
- Validated against TA-Lib, Skender, and Tulip reference implementations where available.
|
||||
|
||||
> "MSE's more interpretable sibling that speaks the language of your data."
|
||||
|
||||
|
||||
@@ -1,4 +1,21 @@
|
||||
# RMSLE: Root Mean Squared Logarithmic Error
|
||||
# RMSLE: Root Mean Squared Logarithmic Error
|
||||
|
||||
| Property | Value |
|
||||
| ---------------- | -------------------------------- |
|
||||
| **Category** | Error Metric |
|
||||
| **Inputs** | Source (close) |
|
||||
| **Parameters** | `period` |
|
||||
| **Outputs** | Single series (RMSLE) |
|
||||
| **Output range** | $\geq 0$ |
|
||||
| **Warmup** | 1 bar |
|
||||
|
||||
### TL;DR
|
||||
|
||||
- Root Mean Squared Logarithmic Error is the square root of MSLE, providing an error metric in log-scale units.
|
||||
- Parameterized by `period`.
|
||||
- Output range: $\geq 0$.
|
||||
- Requires 1 bar of warmup before first valid output (IsHot = true).
|
||||
- Validated against TA-Lib, Skender, and Tulip reference implementations where available.
|
||||
|
||||
> "RMSLE: because sometimes your errors need to be measured in decades, not dollars."
|
||||
|
||||
|
||||
+18
-1
@@ -1,4 +1,21 @@
|
||||
# RSE: Relative Squared Error
|
||||
# RSE: Relative Squared Error
|
||||
|
||||
| Property | Value |
|
||||
| ---------------- | -------------------------------- |
|
||||
| **Category** | Error Metric |
|
||||
| **Inputs** | Source (close) |
|
||||
| **Parameters** | `period` |
|
||||
| **Outputs** | Single series (Rse) |
|
||||
| **Output range** | $\geq 0$ |
|
||||
| **Warmup** | `period` bars |
|
||||
|
||||
### TL;DR
|
||||
|
||||
- Relative Squared Error (RSE) measures the total squared error of predictions relative to the total squared error of a simple baseline predictor tha...
|
||||
- Parameterized by `period`.
|
||||
- Output range: $\geq 0$.
|
||||
- Requires `period` bars of warmup before first valid output (IsHot = true).
|
||||
- Validated against TA-Lib, Skender, and Tulip reference implementations where available.
|
||||
|
||||
> "The squared error version of RAE. RSE and R² are two sides of the same coin: R² = 1 - RSE."
|
||||
|
||||
|
||||
@@ -1,4 +1,21 @@
|
||||
# R²: Coefficient of Determination
|
||||
# R²: Coefficient of Determination
|
||||
|
||||
| Property | Value |
|
||||
| ---------------- | -------------------------------- |
|
||||
| **Category** | Error Metric |
|
||||
| **Inputs** | Source (close) |
|
||||
| **Parameters** | `period` |
|
||||
| **Outputs** | Single series (R) |
|
||||
| **Output range** | $\geq 0$ |
|
||||
| **Warmup** | `period` bars |
|
||||
|
||||
### TL;DR
|
||||
|
||||
- The Coefficient of Determination (R²) measures the proportion of variance in the actual values that is predictable from the predicted values.
|
||||
- Parameterized by `period`.
|
||||
- Output range: $\geq 0$.
|
||||
- Requires `period` bars of warmup before first valid output (IsHot = true).
|
||||
- Validated against TA-Lib, Skender, and Tulip reference implementations where available.
|
||||
|
||||
> "R² tells you how much of the variance in actual values is explained by your predictions. It's the statistician's favorite metric for good reason."
|
||||
|
||||
|
||||
@@ -1,4 +1,21 @@
|
||||
# SMAPE: Symmetric Mean Absolute Percentage Error
|
||||
# SMAPE: Symmetric Mean Absolute Percentage Error
|
||||
|
||||
| Property | Value |
|
||||
| ---------------- | -------------------------------- |
|
||||
| **Category** | Error Metric |
|
||||
| **Inputs** | Source (close) |
|
||||
| **Parameters** | `period` |
|
||||
| **Outputs** | Single series (SMAPE) |
|
||||
| **Output range** | $\geq 0$ |
|
||||
| **Warmup** | 1 bar |
|
||||
|
||||
### TL;DR
|
||||
|
||||
- Symmetric Mean Absolute Percentage Error addresses a fundamental asymmetry in MAPE: the fact that over-predictions and under-predictions of the sam...
|
||||
- Parameterized by `period`.
|
||||
- Output range: $\geq 0$.
|
||||
- Requires 1 bar of warmup before first valid output (IsHot = true).
|
||||
- Validated against TA-Lib, Skender, and Tulip reference implementations where available.
|
||||
|
||||
> "MAPE punishes based on who's right; SMAPE punishes based on how different they are."
|
||||
|
||||
|
||||
@@ -1,4 +1,21 @@
|
||||
# Theil's U: Theil's U Statistic
|
||||
# Theil's U: Theil's U Statistic
|
||||
|
||||
| Property | Value |
|
||||
| ---------------- | -------------------------------- |
|
||||
| **Category** | Error Metric |
|
||||
| **Inputs** | Source (close) |
|
||||
| **Parameters** | `period` |
|
||||
| **Outputs** | Single series (TheilU) |
|
||||
| **Output range** | $\geq 0$ |
|
||||
| **Warmup** | `period` bars |
|
||||
|
||||
### TL;DR
|
||||
|
||||
- Theil's U Statistic measures forecast accuracy relative to a naive no-change forecast.
|
||||
- Parameterized by `period`.
|
||||
- Output range: $\geq 0$.
|
||||
- Requires `period` bars of warmup before first valid output (IsHot = true).
|
||||
- Validated against TA-Lib, Skender, and Tulip reference implementations where available.
|
||||
|
||||
> "The forecast that matters is the one that beats a naive guess."
|
||||
|
||||
|
||||
@@ -1,4 +1,21 @@
|
||||
# Tukey's Biweight: Robust Loss Function
|
||||
# Tukey's Biweight: Robust Loss Function
|
||||
|
||||
| Property | Value |
|
||||
| ---------------- | -------------------------------- |
|
||||
| **Category** | Error Metric |
|
||||
| **Inputs** | Source (close) |
|
||||
| **Parameters** | `period`, `c` (default DefaultC) |
|
||||
| **Outputs** | Single series (UNKNOWN) |
|
||||
| **Output range** | $\geq 0$ |
|
||||
| **Warmup** | 1 bar |
|
||||
|
||||
### TL;DR
|
||||
|
||||
- Tukey's Biweight (also called Bisquare) is a redescending M-estimator that completely ignores errors beyond a threshold.
|
||||
- Parameterized by `period`, `c` (default defaultc).
|
||||
- Output range: $\geq 0$.
|
||||
- Requires 1 bar of warmup before first valid output (IsHot = true).
|
||||
- Validated against TA-Lib, Skender, and Tulip reference implementations where available.
|
||||
|
||||
> "When outliers need to be silenced, not just quieted."
|
||||
|
||||
|
||||
@@ -1,4 +1,21 @@
|
||||
# WMAPE: Weighted Mean Absolute Percentage Error
|
||||
# WMAPE: Weighted Mean Absolute Percentage Error
|
||||
|
||||
| Property | Value |
|
||||
| ---------------- | -------------------------------- |
|
||||
| **Category** | Error Metric |
|
||||
| **Inputs** | Source (close) |
|
||||
| **Parameters** | `period` |
|
||||
| **Outputs** | Single series (Wmape) |
|
||||
| **Output range** | $\geq 0$ |
|
||||
| **Warmup** | `period` bars |
|
||||
|
||||
### TL;DR
|
||||
|
||||
- Weighted Mean Absolute Percentage Error (WMAPE) adjusts MAPE by weighting each error by the magnitude of the actual value.
|
||||
- Parameterized by `period`.
|
||||
- Output range: $\geq 0$.
|
||||
- Requires `period` bars of warmup before first valid output (IsHot = true).
|
||||
- Validated against TA-Lib, Skender, and Tulip reference implementations where available.
|
||||
|
||||
> "When not all errors are created equal, weight them by what matters."
|
||||
|
||||
|
||||
@@ -1,5 +1,22 @@
|
||||
# WRMSE: Weighted Root Mean Squared Error
|
||||
|
||||
| Property | Value |
|
||||
| ---------------- | -------------------------------- |
|
||||
| **Category** | Error Metric |
|
||||
| **Inputs** | Source (close) |
|
||||
| **Parameters** | `period` |
|
||||
| **Outputs** | Single series (Wrmse) |
|
||||
| **Output range** | $\geq 0$ |
|
||||
| **Warmup** | `period` bars |
|
||||
|
||||
### TL;DR
|
||||
|
||||
- WRMSE extends the classic RMSE by incorporating weights for each observation, enabling analysts to emphasize critical data points such as recent ob...
|
||||
- Parameterized by `period`.
|
||||
- Output range: $\geq 0$.
|
||||
- Requires `period` bars of warmup before first valid output (IsHot = true).
|
||||
- Validated against TA-Lib, Skender, and Tulip reference implementations where available.
|
||||
|
||||
> "Not all errors are created equal—WRMSE lets you decide which ones matter most."
|
||||
|
||||
WRMSE extends the classic RMSE by incorporating weights for each observation, enabling analysts to emphasize critical data points such as recent observations, high-volume periods, or specific market regimes. When all weights are equal, WRMSE reduces exactly to RMSE, making it a strict generalization. This implementation uses dual RingBuffers for O(1) streaming updates with periodic resync to manage floating-point drift.
|
||||
@@ -169,4 +186,4 @@ WRMSE is validated by:
|
||||
|
||||
- Aitken, A.C. (1936). "On Least Squares and Linear Combinations of Observations." *Proceedings of the Royal Society of Edinburgh*.
|
||||
- Gauss, C.F. (1809). *Theoria Motus Corporum Coelestium*. (Foundation of least squares theory)
|
||||
- Greene, W.H. (2012). *Econometric Analysis*. 7th ed. Chapter 9: Generalized Least Squares.
|
||||
- Greene, W.H. (2012). *Econometric Analysis*. 7th ed. Chapter 9: Generalized Least Squares.
|
||||
|
||||
Reference in New Issue
Block a user