https://github.com/cran/fields
Tip revision: beb6c9118b4f355fc630943f00274a7df8714fe1 authored by Doug Nychka on 26 April 2007, 00:00:00 UTC
version 3.5
version 3.5
Tip revision: beb6c91
Tps.r
"Tps" <-
function (x, Y, m = NULL, p = NULL, scale.type = "range",
...)
{
x <- as.matrix(x)
d <- ncol(x)
if (is.null(p)) {
if (is.null(m)) {
m <- max(c(2, ceiling(d/2 + 0.1)))
}
p <- (2 * m - d)
if (p <= 0) {
stop(" m is too small you must have 2*m -d >0")
}
}
if (!is.null(list(...)$lambda)) stop(
"Tps does not currently support the fixed lambda option.
See help(Tps) for details")
Tpscall <- match.call()
Tpscall$cov.function <- "Thin plate spline radial basis functions (Rad.cov) "
Krig(x, Y, cov.function = Rad.cov, m = m,
scale.type = scale.type, outputcall = Tpscall, p = p,
...)
}