You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I'm having trouble with my dataset (wind speeds in Netherlands).
var krigingData = [{"x":5.183333333333334,"y":52.1,"t":7},{"x":5.883333333333333,"y":52.06666666666667,"t":6},{"x":4.716666666666667,"y":53,"t":9}];
var t = krigingData.map(function(d){ return d.t; });
var x = krigingData.map(function(d){ return d.x; });
var y = krigingData.map(function(d){ return d.y; });
var model = "exponential";
var alpha = 100, beta = 1;
var variogram = kriging.train(t, x, y, model, alpha, beta);
Using var krigingData = [{"x":5.883333333333333,"y":52.06666666666667,"t":6},{"x":4.716666666666667,"y":53,"t":9},{"x":6.583333333333333,"y":53.13333333333333,"t":7}]; it does work, so it seems something in my dataset is bothering the algorithm, though I can't see what.
BTW the full dataset I want to plot is, which is wind speed in m/s on 2013/12/23 at 12:00 local time.
Hello,
Yes I agree, this rewrite is an improvement! I'm still working on fixing up some of the bugs, but that error you're getting is from calling the cholesky decomposition function with a non-positive definite matrix. Should be solved by increasing the variance for the noise process, I'll try to address this issue in the README.
This problem was actually one of the motivating reasons for adding these adjustable parameters to this new version of the code. Especially with these small sample sizes, since I'm using least squares, a lot of the times you're dealing with these non-positive definite matrices that can only be inverted after some penalization.
Maybe we should throw a descriptive error if this happens?
Also is it possible to auto adjust the parameters so the inversion can be done? I dont understand the exact math involved here...
Hi!
Great to see your progress, the API improved ++!
I'm having trouble with my dataset (wind speeds in Netherlands).
This fails as it produces
NaN
values in theC
matrix on line https://github.com/oeo4b/kriging.js/blob/master/kriging.js#L234.The
NaN
values originate from line https://github.com/oeo4b/kriging.js/blob/master/kriging.js#L67, becausep[i]
turned negative there.Using
var krigingData = [{"x":5.883333333333333,"y":52.06666666666667,"t":6},{"x":4.716666666666667,"y":53,"t":9},{"x":6.583333333333333,"y":53.13333333333333,"t":7}];
it does work, so it seems something in my dataset is bothering the algorithm, though I can't see what.BTW the full dataset I want to plot is, which is wind speed in m/s on 2013/12/23 at 12:00 local time.
The text was updated successfully, but these errors were encountered: