Kalman Filter

Describing Kalman Filter

  • The Kalman Filter is an iterative mathematical algorithm, not a model
  • A Kalman filter is an optimal estimator that infers parameters of interest from indirect, inaccurate, and uncertain observations
  • It is recursive, so new measurements can be processed as they arrive
  • If we assume ϵX\epsilon|X is Gaussian, then the Kalman filter minimizes the MSE of the estimated parameters
  • The Kalman filter is a powerful algorithm to use for nowcasting
  • Nowcasting refers to forecasting without having current predictor values on hand
  • Therefore, we would need to estimate our predictor values

Use-Cases of the Kalman Filter

  • It provides good results in practice due to optimality and structure
  • It's a convenient form for online, real-time processing
  • It's easy to formulate and implement given a basic understanding
  • Measurement equations don't need to be inverted

What is a Filter?

  • A filter refers to the process filtering out the noise when we're trying to find some best parameter estimate from noisy data
  • A Kalman filter cleans up the data measurements to try to account for the noise
  • It also projects these measurements onto the estimated state

Defining the Kalman Filter Algorithm

  • The Kalman filter can be defined as the following:
yi=Hxi+ϵiy_{i} = Hx_{i} + \epsilon_{i} where xi=Axi1+ϕi\text{where } x_{i} = Ax_{i-1} + \phi_{i}
  • We can see that there are two parts of the algorithm:

    1. The update portion of the algorithm, which is the following component:
    xi=Axi1+ϕix_{i} = Ax_{i-1} + \phi_{i}
    • Where xix_{i} is our hidden variable and represents our estimated predictor variable (i.e. current predicted value of xx)
    • Where xi1x_{i-1} represents the previous predicted value of xx
    • Where AA represents the state transition matrix

      • These could be made up of the beta coefficients for a linear regression model, or the autoregressive coefficients in an AR (or ARIMA) model, etc.
    • Where ϕi\phi_{i} represents the error term for xix_{i}
    • The prediction portion of the algorithm, which is the following component:
    yi=Hxi+ϵiy_{i} = Hx_{i} + \epsilon_{i}
    • Where yiy_{i} represents our estimated response variable (i.e. current predicted value of yy)
    • Where xix_{i} refers to our hidden variable and represents our estimated precitor variable
    • Where HH represents the state transition matrix

      • These could be made up of the beta coefficients for a linear regression model, or the autoregressive coefficients in an AR (or ARIMA) model, etc.
    • Where ϵi\epsilon_{i} represents the error term for yiy_{i}

Advantages of the Kalman Filter

  • The Kalman filter is predictive and adaptive, since it looks forward with an estimate of the covariance and mean of the time series of one step into the future
  • The Kalman filter does not require stationary data (neural networks usually do)
  • It has a smooth representation of the series, while not requiring knowledge of the future
  • A potential disadvantage of the Kalman filter is that it typically assumes linearity

References

Previous

MCMC Methods