[R-sig-Geo] 2 questions about likfit in geoR

Ruben Roa RRoa at fisheries.gov.fk
Wed Oct 19 18:43:26 CEST 2005


> -----Original Message-----
> From:	r-sig-geo-bounces at stat.math.ethz.ch [SMTP:r-sig-geo-bounces at stat.math.ethz.ch] On Behalf Of liyun ma
> Sent:	Wednesday, October 19, 2005 2:45 PM
> To:	r-sig-geo at stat.math.ethz.ch
> Subject:	[R-sig-Geo] 2 questions about likfit in geoR
> 
> Dear all,
> 
> I have two questions about using the likfit function in geoR.
> One is about the trend estimation. The likfit function estimates the mean 
> parameters and the covariance parameters at the same time. Is there any way 
> to specify the trend function to be a fixed number? For example let mean be 
> zero?
> 
> The second question is the function gives beta.var,  which is the estimated 
> variance  for the mean
> parameter beta. Can we also get the estimated variance for the covariance 
> parameters kappa, sigma^2 and phi?
> 
> Thanks a lot!
> 
> Lauren Ma
> 
--------------
Hi Lauren, 
First, you have to pass the argument Hessian=TRUE in likfit
Then to see the Hessian, you can use:
yourlikfitobject$info.minimisation.function
The Hessian will be the last item. By inverting the Hessian you will have the observed
covariance matrix. The observed variances will be in the main diagonal. In the Hessian the order
of parameters is as follows: phi, ratio of sigma^2 over tau^2, kappa, and lambda (the 
latter when you have included the Box-Cox parameter, recommended).
In my experience (always with lambda<>1) the parameter beta is underestimated. I have 
compared it with what you get after predictions (with mean(krige.object$predict); this should 
be similar to, though not identical with beta) and with the simple sample mean of the original data and 
beta has always been much smaller. I contacted the author of geoR (Paulo Ribeiro Jr) and he said that 
he would check the code. To get beta in the original units you have to back-transform it (assuming
lambda is <>1) usign the BCtransform function.
I hope this helps.
Ruben




More information about the R-sig-Geo mailing list