Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

plot.fm

Plot fitted model components for a functional model


Description

When class(x)[1] = ftsm, plot showing the principal components in the top row of plots and the coefficients in the bottom row of plots.

When class(x)[1] = fm, plot showing the predictor scores in the top row of plots and the response loadings in the bottom row of plots.

Usage

## S3 method for class 'fm'
plot(x, order, xlab1 = x$y$xname, ylab1 = "Principal component", 
 xlab2 = "Time", ylab2 = "Coefficient", mean.lab = "Mean", 
  level.lab = "Level", main.title = "Main effects", interaction.title 
   = "Interaction", basiscol = 1, coeffcol = 1, outlier.col = 2, 
    outlier.pch = 19, outlier.cex = 0.5, ...)

Arguments

x

Output from ftsm or fplsr.

order

Number of principal components to plot. Default is all principal components in a model.

xlab1

x-axis label for principal components.

xlab2

x-axis label for coefficient time series.

ylab1

y-axis label for principal components.

ylab2

y-axis label for coefficient time series.

mean.lab

Label for mean component.

level.lab

Label for level component.

main.title

Title for main effects.

interaction.title

Title for interaction terms.

basiscol

Colors for principal components if plot.type = "components".

coeffcol

Colors for time series coefficients if plot.type = "components".

outlier.col

Colors for outlying years.

outlier.pch

Plotting character for outlying years.

outlier.cex

Size of plotting character for outlying years.

...

Plotting parameters.

Value

Function produces a plot.

Author(s)

Rob J Hyndman

References

R. J. Hyndman and M. S. Ullah (2007) "Robust forecasting of mortality and fertility rates: A functional data approach", Computational Statistics \& Data Analysis, 51(10), 4942-4956.

R. J. Hyndman and H. Booth (2008) "Stochastic population forecasts using functional data models for mortality, fertility and migration", International Journal of Forecasting, 24(3), 323-342.

R. J. Hyndman and H. L. Shang (2009) "Forecasting functional time series (with discussion)", Journal of the Korean Statistical Society, 38(3), 199-221.

See Also

Examples

plot(x = ftsm(y = ElNino_ERSST_region_1and2))

ftsa

Functional Time Series Analysis

v6.0
GPL-3
Authors
Rob Hyndman [aut] (<https://orcid.org/0000-0002-2140-5352>), Han Lin Shang [aut, cre, cph] (<https://orcid.org/0000-0003-1769-6430>)
Initial release
2020-11-29

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.