variogramModel: create or update variogram model

Description Usage Arguments Value Author(s) See Also Examples

Description

This gives an easier interface to the parameters of the variogram model

Usage

1
2
3
4
5
6
7
8
9
rtopVariogramModel(model = "Ex1", sill = NULL, range = NULL, 
    exp = NULL, nugget = NULL, exp0 = NULL,
    observations = NULL, formulaString = obs~1) 
## S3 method for class 'rtop'
updateRtopVariogram(object, ...)
## S3 method for class 'rtopVariogramModel'
updateRtopVariogram(object, action = "mult", ..., 
              checkVario = FALSE, 
sampleVariogram = NULL, observations = NULL) 

Arguments

model

variogram model, currently "Ex1" is the only implemented, see Skoien et al (2006)

sill

sill of variogram

range

range of variogram

exp

the exponent of the fractal part of the variogram, see Skoien et al (2006)

exp0

gives the angle of the first part of the variogram in a log-log plot (weibull type), should be between 0 and 2. See Skoien et al (2006)

nugget

nugget of point variogram

formulaString

formula that defines the dependent variable as a linear model of independent variables, see e.g. createRtopObject for more details.

object

either: object of class rtop (see rtop-package), or an rtopVariogramModel.

action

character variable defining whether the new parameters should be add(-ed), mult(-iplied) or replace the former parameters. Leaving the parameters equal to NULL will cause no change.

checkVario

logical, will issue a call tocheckVario if TRUE

sampleVariogram

a sample variogram of the data

observations

a set of observations

...

parameters to lower level functions

Value

The function helps creating and updating the parameters of the variogram, by using common names and simple update methods. This is mainly for manual fitting of the variogram. The automatic call to checkVario makes it easier to visualize the effect of the changes to the variogram

Author(s)

Jon Olav Skoien

See Also

rtop-package

Examples

 1
 2
 3
 4
 5
 6
 7
 8
 9
10
11
12
13
14
## Not run: 
library(rgdal)
rpath = system.file("extdata",package="rtop")
observations = readOGR(rpath,"observations")
# Create a column with the specific runoff:
observations$obs = observations$QSUMMER_OB/observations$AREASQKM
predictionLocations = readOGR(rpath,"predictionLocations")
rtopObj = createRtopObject(observations,predictionLocations)
 # Fit a variogram (function also creates it)
rtopObj = rtopFitVariogram(rtopObj)
rtopObj = updateRtopVariogram(rtopObj, exp = 1.5, action = "mult", 
              checkVario = TRUE)

## End(Not run)

rtop documentation built on May 2, 2019, 6:48 p.m.