|
Essential Wavelets for Statistical Applications and Data Analysis R.T. Ogden, University of South Carolina 0-8176-3864-4 * 1996 * $40.00 * Hardcover * 285 pages * 40 Illustrations |
Fig7.7 <- function(n = 128)
{
# postscript(file = "Fig7.7.ps", height = 6.5, width = 6.5, horiz = F)
par(mfrow = c(2, 2), mar = c(1.5, 1.5, 1.5, 0.5), mgp = c(5, 0.4, 0))
rs <- c(57, 14, 55, 51, 30, 0, 53, 44, 34, 53, 49, 2)
.Random.seed <- rs
y1 <- rnorm(n)
y2 <- arima.sim(n, model = list(ar = 0.5))
y3 <- arima.sim(n, model = list(ar = -0.5))
y4 <- arima.sim(n, model = list(ar = c(0, 0, 0, 0, 0, 0, 0, 0, 0, 0,
0, 0.5)))
omega <- ((0:(n/2)) * 2 * pi)/n
p1 <- spec.pgram(y1)
p2 <- spec.pgram(y2)
p3 <- spec.pgram(y3)
p4 <- spec.pgram(y4)
plot(omega, 10^(p1$spec/10), type = "l")
mtext("White noise", side = 3, line = 0.1)
plot(omega, 10^(p2$spec/10), type = "l")
mtext("AR(1), r = 0.5", side = 3, line = 0.1)
plot(omega, 10^(p3$spec/10), type = "l")
mtext("AR(1), r = -0.5", side = 3, line = 0.1)
plot(omega, 10^(p4$spec/10), type = "l")
mtext("Seasonal time series", side = 3, line = 0.1)
# graphics.off()
NULL
}