SymmetricMAPEMetric<T>
Models & Types · AiDotNet.Evaluation.Metrics.Regression
Computes Symmetric Mean Absolute Percentage Error (sMAPE) for regression.
Implements: IRegressionMetric<T>
For Beginners
Unlike MAPE, sMAPE treats over-predictions and under-predictions symmetrically:
- Bounded between 0% and 200%
- Symmetric: equal penalty for over and under predictions
- Handles zero values better than MAPE
Note: This is the regression version, not time-series specific.
How It Works
sMAPE = (100/N) * Σ |y - ŷ| / ((|y| + |ŷ|) / 2)
Constructors
| Constructor | Summary |
|---|---|
SymmetricMAPEMetric() |
Properties
| Property | Summary |
|---|---|
MetricDirection Direction { get; } |
|
T MaxValue { get; } |
|
T MinValue { get; } |
|
bool RequiresProbabilities { get; } |
|
bool SupportsMultiClass { get; } |
|
string Category { get; } |
|
string Description { get; } |
|
string Name { get; } |
Methods
| Method | Summary |
|---|---|
MetricWithCI<T> ComputeWithCI(ReadOnlySpan<T> predictions, ReadOnlySpan<T> actuals, ConfidenceIntervalMethod ciMethod, double confidenceLevel, int bootstrapSamples, int? randomSeed) |
|
T Compute(ReadOnlySpan<T> predictions, ReadOnlySpan<T> actuals) |