Displaying 5 results from an estimated 5 matches for "sspl".
Did you mean:
ssl
2024 Jul 16
2
Automatic Knot selection in Piecewise linear splines
...earth()
to get more:
## Can we do knot-selection for simple (x,y) splines? === Yes, via earth() {using MARS}!
x <- (0:800)/8
f <- function(x) 7 * sin(pi/8*x) * abs((x-50)/20)^1.25 - (x-40)*(12-x)/64
curve(f(x), 0, 100, n = 1000, col=2, lwd=2)
set.seed(11)
y <- f(x) + 10*rnorm(x)
m.sspl <- smooth.spline(x,y) # base line "standard smoother"
require(earth)
fm1 <- earth(x, y) # default settings
summary(fm1, style = "pmax") #-- got 10 knots (x = 44 "used twice") below
## Call: earth(x=x, y=y)
## y =
## 175.9612
## - 10.6744 * pmax(0, x...
2024 Jul 26
1
Automatic Knot selection in Piecewise linear splines
...for simple (x,y) splines? === Yes, via earth() {using MARS}!
>
> x <- (0:800)/8
>
> f <- function(x) 7 * sin(pi/8*x) * abs((x-50)/20)^1.25 - (x-40)*(12-x)/64
> curve(f(x), 0, 100, n = 1000, col=2, lwd=2)
>
> set.seed(11)
> y <- f(x) + 10*rnorm(x)
>
> m.sspl <- smooth.spline(x,y) # base line "standard smoother"
>
> require(earth)
> fm1 <- earth(x, y) # default settings
> summary(fm1, style = "pmax") #-- got 10 knots (x = 44 "used twice") below
> ## Call: earth(x=x, y=y)
>
> ## y =
> ## 17...
2024 Jul 09
1
Automatic Knot selection in Piecewise linear splines
How can I do automatic knot selection while fitting piecewise linear
splines to two variables x and y? Which package to use to do it simply? I
also want to visualize the splines (and the scatter plot) with a graph.
Anupam
[[alternative HTML version deleted]]
2004 Nov 08
1
how lambda is computed in smoot.spline given _df_
Hi,
I posted some days ago a question concerning the computation of lambda in the smooth.spline function (which I repreat at the bottom of the mail) given _df_ .
Unfortunately the documentation is not clear to me. Maybee someone can help to answer in my view the basic question:
If the penalized log likelihood is L = (y - f)' W (y - f) + lambda c' Sigma c
how the _lambda_ in the above
2009 Apr 28
1
kernlab - custom kernel
hi,
I am using R's "kernlab" package, exactly i am doing classification using
ksvm(.) and predict.ksvm(.).I want use of custom kernel. I am getting some
error.
# Following R code works (with promotergene dataset):
library("kernlab")
s <- function(x, y) {
sum((x*y)^1.25)
}
class(s) <- "kernel"
data("promotergene")
gene <- ksvm(Class ~ .,