[SOLVED] Kriging: mean and CV is NA

Any question regarding the Interpolation method using Kriging

[SOLVED] Kriging: mean and CV is NA

Postby carolang » Mon Feb 22, 2016 2:40 pm

Hello,
I have participated in the course of geostatistics and I am recently using the package and running an example code for estimation biomass, my problen is when I run the follow line:

### Kriged mean
global.mk=global(db.c1, model = vg.fit, uc=c("1"), polygon = db.poly,
calcul = "krige", flag.polin=T, flag.wgt=T, ivar = 1)
cat("Kriged.mean= ",round(global.mk$zest,2),"; CV.geo= ",round(global.mk$cv,3),"\n")

Results show me an error in the mean and CV giving a value of NA, I have checked the data, the function, etc. and I don´t find answer for this problem.
Another question is: Does The package RGeostats have some constraints on number of samples to estimate the kriging mean and variances as do EVA software???

Any suggestions I will appreciate so much,
carolang
 
Posts: 5
Joined: Mon Feb 22, 2016 2:09 pm

Re: Kriging: mean and CV is NA

Postby Didier Renard » Mon Feb 22, 2016 9:17 pm

Hello

I checked that the procedure gives a correct result. There must be a slight problem in the input.
Please check the contents of:
- db.c1: check that the data (the Z-locator variable) is correctly defined. Does it contain any NA value. Are the coordinates all defined
- Could db.c1 contain samples located at the same location (duplicates)
- Could the polygon be mis-located (so as no data point sits within the polygon).

Sorry but this are the only tracks that I can figure out. Otherwise send us the data (db.c1, vg.fit and db.poly).
For this you can run db.write(db.c1) or poly.write(poly.data) and model.write(vg.fit). These commands will create ASCII files that you can simply send by mail.

Cheers
Didier Renard
 
Posts: 337
Joined: Thu Sep 20, 2012 4:22 pm

Re: Kriging: mean and CV is NA

Postby carolang » Tue Feb 23, 2016 12:54 pm

Didier Hi, Nice to hear from you!!
Well I checked all the answers and you were right!! I had duplicated coords, maybe it could be good make a function in RGeostats to identify these points, or Message that say "duplicated coords".....

Cheers,
carolang
 
Posts: 5
Joined: Mon Feb 22, 2016 2:09 pm

Re: Kriging: mean and CV is NA

Postby Fabien Ors » Wed Feb 24, 2016 9:07 am

Hello

This function exists already :-)
Please, have look here :
http://rgeostats.free.fr/html/duplicate.html

Cheers,
Fabien Ors
Administrateur du site
 
Posts: 226
Joined: Thu Sep 20, 2012 1:07 pm


Return to Kriging

Who is online

Users browsing this forum: No registered users and 2 guests

cron