-
Notifications
You must be signed in to change notification settings - Fork 8
Open
Description
Hello!
Thank you for the hard work on this package, it is incredibly exhaustive and useful.
One thing I am struggling with is fitting a thin plate spline with knots that are not at the sample locations. Here is an example that slightly modifies an example given in the manual:
library(fields)
data(ozone2)
y16<- ozone2$y[16,]
# there are some missing values -- remove them
good<- !is.na( y16)
y<- y16[good]
x<- ozone2$lon.lat[ good,]
#
# the knots can be arbitrary but just for fun find them with a space
# filling design. Here we select 50 from the full set of 147 points
#
xknots<- cover.design( x, 50, num.nn= 75)$design # select 50 knot points
Tps(x,y, knots=xknots)
I receive the error
Error in eigen(A + B, symmetric = TRUE) :
infinite or missing values in 'x'
I am able to fit a thin plate spline using knots not at the sample locations using some code I have written, but I would like to take advantage of this package to fit the lambda parameter. I have been using this publication for my own code so far:
Any insight on why this error is showing up would be helpful.
Metadata
Metadata
Assignees
Labels
No labels