RFoptions(seed=0) ## *ANY* simulation will have the random seed 0; set
## RFoptions(seed=NA) to make them all random again
#Example 1
x <- if (interactive()) 0:1000 else 0:10
model <- RMgauss(scale=50)
z <- RFsimulate(RPschlather(model), x)
plot(z)
y <- if (interactive()) 0:100 else 0:10
cov <- RFcov(model, y)
ecf <- RFcov(RMschlather(model), y)
matplot(y, cbind(cov, ecf), type="l")
# Example 2
x <- if (interactive()) 0:1000 else 0:10
model <- RMschlather(model)
z <- RFsimulate(RPschlather(model), x)
plot(z)
y <- if (interactive()) 0:100 else 0:10
cov <- RFcov(model, y)
ecf <- RFcov(RMschlather(model), y)
matplot(y, cbind(cov, ecf), type="l")
FinalizeExample()
Run the code above in your browser using DataLab