Okriging(dataset, vario, step, maxdist, border.sw=FALSE, border.poly="none")
plotkriged(dataset, kriged, outpdf="dataset-kriged.pdf", border.sw=FALSE, border.poly="none")
scan.map.ras(filename)
make.variogram(nugget=0, sill = 1000, range = 1000)
Function plotkriged produces two maps in a pdf file: 1) a raster image of the kriged values, superimposed on a contour map, and a plot of the original point pattern (measured points). 2) is the variance of the kriging error over the domain. The function scan.map.ras is based on reading a file with format similar to GeoEAS and using image and contour commands applied to the transpose. When scanning, we take into account that the first row is the southernmost row and the last row is the northernmost row. Each row goes from west to east. The input file contains values of one variable z, a header with a title, then number of columns and rows for the grid. Then it specifies the cell size. Then the file specifies the number of variables in the file, and labels for the measurements. After that, we have a stream of values. In general, we can have more than one variable and therefore each record can have more than one number.
Function make.variogram directly forces a model with selected parameter values.
ppp
, plot plot
, plot plot
, sgeostat point
, pair
, krige
,xyz.ok <- Okriging(xyz, xyz.vsph, step=0.1, maxdist=0.25)
plotkriged(xyz, xyz.ok,outpdf="lab12/xyz-kriged.pdf")
test.ras <- scan.map.ras("lab12/grid30x30.txt")
xyz.vsph <- make.variogram(nugget=0, sill=160, range=0.1)
Run the code above in your browser using DataLab