plot_fitted function

SSFA plot

SSFA plot

This function allows to plot the data and the fitted values obtained by SSFA model.

plot_fitted(x, y, object, xlab, ylab, main, ...)

Arguments

  • x: the x coordinates of points in the plot.
  • y: the y coordinates of points in the plot.
  • object: an object of class ssfa.
  • xlab: a title for the x axis.
  • ylab: a title for the y axis.
  • main: an overall title for the plot.
  • ...: arguments to be passed to methods, such as graphical parameters (see par ).

See Also

plot

Examples

library(ssfa) data(SSFA_example_data) data(Italian_W) #### SFA and SSFA comparison sfa <- ssfa(log_y ~ log_x, data = SSFA_example_data, data_w=Italian_W, form = "production", par_rho=FALSE) ssfa <- ssfa(log_y ~ log_x, data = SSFA_example_data, data_w=Italian_W, form = "production", par_rho=TRUE) sfa_fitted <- fitted.ssfa(sfa) plot_fitted(SSFA_example_data$log_x, SSFA_example_data$log_y, ssfa) lines(sort(SSFA_example_data$log_x), sfa_fitted[order(SSFA_example_data$log_x)],col="red")
  • Maintainer: Elisa Fusco
  • License: GPL-3
  • Last published: 2023-08-28

Useful links