Learn R Programming

RandomFields (version 3.0.10)

Specific: Methods that are specific to certain covariance models

Description

This model defines that the (Gaussian) random field should be modelled by a particular method that is specific to the given covariance model.

These is a very advanced model of RandomFields.

Usage

RPspecific(phi, loggauss)

Arguments

phi
object of class RMmodel; specifies the covariance model to be simulated.
loggauss
optional parameters; same meaning as for RPgauss.

Value

  • RPspecific returns an object of class RMmodel

Details

RPspecific is used for specific algorithms or specific features for simulating certain covariance functions
    % i.W. alle Modele mit struct und do Funktion
  • RMplus
{ RMplus is able to simulate separately the fields given by its summands. This is necessary, e.g., when a RMtrend is involved. } RMS{ Then the sqrt(var) is multiplied onto the Gaussian random fields after the field has been simulated. Hence, when var is random, then, for each realisation of the Gaussian field (for n>1 in RFsimulate) a new realisation of var is used. Further, new coordinates are created where the old coordinates have been devided by the scale and/or multiplied with the Aniso matrix or a projection has been performed.

RPspecific(RMS()) is called internally when the user wants to simulate Anisotropic fields with isotropic methods, e.g. RPtbm. } RMmppplus{ } RMtrend{ }

References

  • Schlather, M. (1999)An introduction to positive definite functions and to unconditional simulation of random fields.Technical report ST 99-10, Dept. of Maths and Statistics, Lancaster University.

See Also

RP, RPcoins, RPhyperplane, RPspectral, RPtbm.

Examples

Run this code
RFoptions(seed=0)
## example for implicite use
model <- RMgauss(var=10, s=10) + RMnugget(var=0.1)
plot(model)
plot(RFsimulate(model=model, 0:10, 0:10, grid=TRUE, n=4))
## The following function shows the internal structure of the model.
## In particular, it can be seen that RPspecific is applied to RMplus.
str(RFgetModelInfo(level=0, which="keys"))

## example for explicite used
model <- RPspecific(RMS(var=unif(min=0, max=10), RMgauss()))
n <- if (interactive()) 6 else 1
k <- if (interactive()) 10 else 1
x <- seq(0,10,0.02)
RFoptions(seed=NA)
for (i in 1:k) {
  readline(paste("Simulation no.", i, ": press return", sep=""))
  plot(RFsimulate(model, x=x, n=n), ylim=c(-5,5))
}

RFoptions(seed=NA)

Run the code above in your browser using DataLab