[R-sig-Geo] Positive Definite Covariance Matrix for Grid Sampled Data
Edzer J. Pebesma
e.pebesma at geo.uu.nl
Tue Sep 11 20:30:24 CEST 2007
Keith,
indeed kriging usually fails when one or more point pairs have zero
distance. One solution in terms of distances would be to shift these
points a bit, such that no zero distances occur anymore. In terms of the
covariances, the solution would be to lower the corresponding
off-diagonal entries with a small amount.
If you have measurements with a known measurement error variance, it may
make sense to use this variance as the amount to subtract from all
off-diagonal elements of the covariance matrix.
Hope this helps,
--
Edzer
Keith Dunnigan wrote:
> Hello all,
>
>
>
> First I would like to apologize if this question is inappropriate for
> this list. I am new here, I found this list doing a web search and it
> seemed like the members here would have knowledge in this area. If
> there are more appropriate lists of forums for this question, I would
> appreciate that information.
>
>
>
> I do the majority of my work as a biostatistician in the
> pharmaceutical industry, so I am new to this area. I am working on a
> couple of small projects in this area though. I have consulted a couple
> of basic texts ("Introduction to Geostatistics" by Kitanidis, and "An
> Introduction to Applied Geostatistics" by Isaaks & Srivastava).
>
>
>
> The gist of what I have gathered from my reading is that standard
> practice is not to use the actual covariance matrix calculated from the
> data. This is because this matrix may in general not be positive
> definite. Instead standard practice seems to be to pick from one of
> several standard covariance models, which are guaranteed to be positive
> definite. After fitting the most appropriate model then, one generates
> the covariance matrix from this model and the distance matrix. The
> resulting matrix should be positive definite.
>
>
>
> The only problem is, I am not finding that to be true. For instance,
> when I apply the exponential model to my distance matrix and calculate
> the eigenvalues, I find that some of them are negative. Very, very
> small, but negative (For example -1.2 x 10exp-13). I applied a couple
> of models and found this to be true. Could someone help me with this?
>
>
>
> This is a small data set. I have a distance matrix that is 20 by 20.
> The exponential model I have used has range parameter R = 14 and sigma
> squared parameter 86.618. Letting the distance be x, the exponential
> model then is c(x) = sigmasq * exp( ((-3)*x)/R .
>
>
>
> My distance matrix is such that most of the covariances have very
> small values (effectively zero), except for the first couple of
> distances. That may be the trouble, what do geo folks usually do in
> situations such as this? I have copied the distance matrix below in the
> case any of you wants to take a look at this.
>
>
>
> 0 162 232 246 474 0 162 232 246 474 0 162 232 246
> 474 0 162 232 246 474
>
> 162 0 70 84 312 162 0 70 84 312 162 0 70 84 312 162
> 0 70 84 312
>
> 232 70 0 14 242 232 70 0 14 242 232 70 0 14 242 232
> 70 0 14 242
>
> 246 84 14 0 228 246 84 14 0 228 246 84 14 0 228 246
> 84 14 0 228
>
> 474 312 242 228 0 474 312 242 228 0 474 312 242 228 0 474
> 312 242 228 0
>
> 0 162 232 246 474 0 162 232 246 474 0 162 232 246 474 0
> 162 232 246 474
>
> 162 0 70 84 312 162 0 70 84 312 162 0 70 84 312 162
> 0 70 84 312
>
> 232 70 0 14 242 232 70 0 14 242 232 70 0 14 242 232
> 70 0 14 242
>
> 246 84 14 0 228 246 84 14 0 228 246 84 14 0 228 246
> 84 14 0 228
>
> 474 312 242 228 0 474 312 242 228 0 474 312 242 228 0 474
> 312 242 228 0
>
> 0 162 232 246 474 0 162 232 246 474 0 162 232 246 474 0
> 162 232 246 474
>
> 162 0 70 84 312 162 0 70 84 312 162 0 70 84 312 162
> 0 70 84 312
>
> 232 70 0 14 242 232 70 0 14 242 232 70 0 14 242 232
> 70 0 14 242
>
> 246 84 14 0 228 246 84 14 0 228 246 84 14 0 228 246
> 84 14 0 228
>
> 474 312 242 228 0 474 312 242 228 0 474 312 242 228 0 474
> 312 242 228 0
>
> 0 162 232 246 474 0 162 232 246 474 0 162 232 246 474 0
> 162 232 246 474
>
> 162 0 70 84 312 162 0 70 84 312 162 0 70 84 312 162
> 0 70 84 312
>
> 232 70 0 14 242 232 70 0 14 242 232 70 0 14 242 232
> 70 0 14 242
>
> 246 84 14 0 228 246 84 14 0 228 246 84 14 0 228 246
> 84 14 0 228
>
> 474 312 242 228 0 474 312 242 228 0 474 312 242 228 0 474
> 312 242 228 0
>
>
>
> Thanks in advance for any help you can provide! Warmest Regards,
>
>
>
> Keith Dunnigan
>
> Statking Consulting
>
> Cincinnati Ohio
>
>
>
>
> [[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
>
More information about the R-sig-Geo
mailing list