Learn R Programming

AMIAS (version 1.0.1)

plot.AMIAS.1d: plot observe data with fitted value for AMIAS model

Description

Similar to other plot methods, this functions plot fitted lines with the given sequence from a fitted "AMIAS.1d" object.

Usage

# S3 method for AMIAS.1d
plot(x, s=length(x$df), betatype="l", betacolor="blue", betalwd=2, ...)

Arguments

x

A list with class attribute 'AMIAS.1d'.

s

If the AMIAS object contain a T sequence to select adatively, the s-th model would be plot, default is the selected model.

betatype

Character indicating the type of plotting; actually any of the types as in plot.default.

betacolor

Color of the fitted line.

betalwd

Wide of the fitted line.

Other arguments,see plot.default for details.

See Also

AMIAS plot.default lines.default.

Examples

Run this code
# NOT RUN {
  library(AMIAS)

  set.seed(12580)
  n <- 100
  sigma <- 0.3
  y0 <- rep(0,n)
  y0[10:15] <- 2
  y0[40:60] <- -1
  y0[80:82] <- 4
  y <- y0 + sigma*rnorm(n)
  y[80:82] <- y0[80:82] + sigma*rnorm(3)
  object <- AMIAS(y, h=1, outer_itermax=5)
  plot(object)
# }

Run the code above in your browser using DataLab