You are here: Symbol Reference > StatTimeSerAnalysis Namespace > Functions > StatTimeSerAnalysis.TripleExpSmooth Function
Stats Master VCL
ContentsIndex
Example

Generate 24 random values representing 4 quarters x 6 years = 24, perform smoothing and read Alpha,Beta,Gamma + MSE.

Uses MtxExpr,StatTimeSerAnalysis, Math387;
procedure Example;
var Data,S,b,L: Vector;
    Alpha,Beta,Gamma,MSE: double;
begin
  Data.Size(24,false);
  Data.RandGauss;
  // smooth data, initial alpha = 0.1, beta=0.1, gamma = 0.3
  Alpha := 0.1;
  Beta := 0.1;
  Gamma := 0.3;
  // Period = 4
  MSE := TripleExpSmooth(Data,S,b,L,Alpha,Beta,Gamma,4);
  // results: MSE and MLE estimate for Alpha,Beta,Gamma
end;
#include "MtxExpr.hpp"
#include "Math387.hpp"
#include "StatTimeSerAnalysis.hpp"
void __fastcall Example();
{
  sVector Data,S,b,L;
  Data.Size(24,false);
  Data.RandGauss();
  // smooth data, initial alpha = 0.1, beta=0.1, gamma = 0.3
  double alpha = 0.1;
  double beta = 0.1;
  double gamma = 0.3;
  // Period = 4
  double MSE = TripleExpSmooth(Data,S, b, L, alpha,beta,gamma,4);
  // results: MSE and MLE estimate for Alpha,Beta,Gamma
}
Copyright (c) 1999-2025 by Dew Research. All rights reserved.