An embedded and charset-unspecified text was scrubbed... Name: not available URL: <https://stat.ethz.ch/pipermail/r-sig-geo/attachments/20101004/82b8ced0/attachment.pl>
nugget in variogram
2 messages · Arantzazu Blanco Bernardeau, Edzer Pebesma
Because you do not pass an (initial) nugget value to function vgm(), you are fitting an exponential model without a nugget. Without a nugget model, the nugget is (implicitly) zero. Compare:
vgm(1, "Exp", 300)
model psill range 1 Exp 1 300
vgm(1, "Exp", 300, 1)
model psill range 1 Nug 1 0 2 Exp 1 300 You are also wrong if you think that you now fix (as of: not fit) parameters in the fit.variogram step; for this you have to pass parameters fit.ranges and/or fit.sills; e.g. to fit the nugget but fix the partial sill, pass fit.sills = c(TRUE,FALSE), to fix the nugget but fit the partial sill, pass fit.sill=c(FALSE, TRUE).
On 10/04/2010 11:07 AM, Arantzazu Blanco Bernardeau wrote:
Hello
I am really glad of your answer, but for me it does not work as I would like
So, my data are called cc (is a subset of a bigger spatialdataframe) and the variogram would be
varcc=variogram(pf1_3atm~1,cc, width=500,cutoff=10000)
Then I fix the sill and the range of the variogram
inisill=var(cc at data$pf1_3atm,na.rm=T)
iniran=var$dist[varcc$gamma>0.9*inisill][1]
varcc.fit=fit.variogram(varcc,vgm(psill=inisill, "Exp", iniran)) # I can not fix the nugget because the output gives errors ("Singular model")
plot(varcc,varcc.fit)
varcc[1,"gamma"] this would be the nugget (where the model cuts the axis)
[1] 11.97 The problem in the indicator you suggest is: varcc.fit$psill[1] / sum(varcc.fit$psill)= 1, because varcc.fit$psill[1] = sum(varcc.fit$psill) as the output of varcc.fit gives: varcc.fit model psill range 1 Exp 41.46455 1297.040 I have tried (don't know if it is correct):
varcc[1,"gamma"]/sum(varcc.fit$psill)
[1] 0.2886803 (and this would mean that the spatial correlation is weak because we have a relative big nugget effect) Can this be done? Thanks a lot again for your attention.
Date: Thu, 30 Sep 2010 18:39:22 +0200 From: edzer.pebesma at uni-muenster.de To: r-sig-geo at stat.math.ethz.ch Subject: Re: [R-sig-Geo] nugget in variogram On 09/30/2010 04:13 PM, Arantzazu Blanco Bernardeau wrote:
Hello everybody I am new on geostatistics so maybe my question is trivial or is already answered (I can not find the solution in the thread list). I have a variogram where I did not fix the nugget, because doing it was giving "singular models". I would like to know the nugget ratio of my variograms but I don't know how to get then the nugget value. So I did look in the output of variogram and did take the minimum value of gamma. Is this correct?
Well, it's not the usual way, where you would fit a model: library(gstat) data(meuse) coordinates(meuse) = ~x+y v = variogram(log(zinc)~1, meuse) v.m = fit.variogram(v, vgm(1, "Sph", 500, 1)) v[1, "gamma"] # your estimator: plot(v, v.m) v.m$psill[1] / sum(v.m$psill) # the usual estimator: Only when you have plenty of measurements at very short distances apart, I can imagine you would use the sample variogram (v) value.
Thanks very much for your attention. [[alternative HTML version deleted]]
_______________________________________________ R-sig-Geo mailing list R-sig-Geo at stat.math.ethz.ch https://stat.ethz.ch/mailman/listinfo/r-sig-geo
-- Edzer Pebesma Institute for Geoinformatics (ifgi), University of M?nster Weseler Stra?e 253, 48151 M?nster, Germany. Phone: +49 251 8333081, Fax: +49 251 8339763 http://ifgi.uni-muenster.de http://www.52north.org/geostatistics e.pebesma at wwu.de
_______________________________________________ R-sig-Geo mailing list R-sig-Geo at stat.math.ethz.ch https://stat.ethz.ch/mailman/listinfo/r-sig-geo
Edzer Pebesma Institute for Geoinformatics (ifgi), University of M?nster Weseler Stra?e 253, 48151 M?nster, Germany. Phone: +49 251 8333081, Fax: +49 251 8339763 http://ifgi.uni-muenster.de http://www.52north.org/geostatistics e.pebesma at wwu.de