KalmanFilter: Kalman Filter

View source: R/KalmanFilter.R

KalmanFilterR Documentation

Kalman Filter

Description

Kalman filtering is also sometimes called “linear quadratic estimation”

Usage

KalmanFilter(Datavector,DLMobject,PlotIt=TRUE,Short=FALSE)

Arguments

Datavector

[1:n], the univariate data set to be analyzed

DLMobject

Optional, basically a list with scalar Parameters as defined by dlm::dlm, FF, V, GG, W, m0, C0 can be set, details for Parameter estimation in [Petris, 2010] or in the dlmMLE function of dlm package.

PlotIt

Default: FALSE, TRUE: Evaluates output of function versus input by plots, works only if Datavector given

Short

If PlotIt=TRUE: short or extensive plotting

Details

"All filters share a common goal: to let something pass through while something else does not. An example that many people can relate to is a coffee filter. This coffee filter will allow the liquid to pass through, while leaving the solid coffee grounds behind. You can also think about a low-pass filter, which lets low frequencies pass through while attenuating high frequencies. A Kalman filter also acts as a filter, but its operation is a bit more complex and harder to understand. A Kalman filter takes in information which is known to have some error, uncertainty, or noise. The goal of the filter is to take in this imperfect information, sort out the useful parts of interest, and to reduce the uncertainty or noise."[Rhudy et al., 2017]

"A Karman Filter can be seen as a Hidden Markov Model based on Gaussian Mixtures" [Ultsch, 2018].

Value

List with

FilteredData

[1:n], Filtered Datavector such that noise and uncertainty are reduced.

FULL

output of dlmFilter of dlm package

ParametersDLM

DLMobject used in dlmFilter

Note

If DLMobject not given the parameters FF, V, GG, W are set to 1 and the mean 'm0' and standard deviation 'C0' are estimated robustly.

Author(s)

Michael Thrun

References

[Rhudy et al., 2017] Matthew B. Rhudy, Roger A. Salguero and Keaton Holappa: A KALMAN FILTERING TUTORIAL FOR UNDERGRADUATE STUDENTS, International Journal of Computer Science & Engineering Survey (IJCSES) Vol.8, No.1, February, 2017.

[Petris, 2010] Petris, Giovanni: An R Package for Dynamic Linear Models, Journal of Statistical Software,Vol. 36(12), 2010.

[Ultsch, 2018] personal correspondance.

Examples


KalmanFilter(Datavector,PlotIt=TRUE,Short=FALSE)


Mthrun/TSAT documentation built on Feb. 5, 2024, 11:15 p.m.