Skip to contents

Formula: c_i = argmin ||y_i - B c||^2 per curve, then Lloyd k-means on the coefficient vectors

Usage

Fdaclust(Y, K = 2, basis = NULL, iters = 25)

Arguments

Y

See Usage.

K

See Usage.

basis

See Usage.

iters

See Usage.

Value

List with labels, centers, coef, wss, K, n.

References

Abraham, Cornillon, Matzner-Lober and Molinari (2003), Unsupervised curve clustering using B-splines, Scandinavian Journal of Statistics 30(3):581-595. The two-stage form implemented here – fit B-spline coefficients per curve, then k-means on the coefficient vectors – is as the method is described in the functional-clustering review literature (arXiv:1803.00276).

Examples

V <- c(1, 2, 3, 4, 5, 6, 7, 8)
Fdaclust(V)
#> $labels
#> [1] 0 0 0 0 1 1 1 1
#> 
#> $centers
#>      [,1]
#> [1,]  2.5
#> [2,]  6.5
#> 
#> $coef
#>      [,1]
#> [1,]    1
#> [2,]    2
#> [3,]    3
#> [4,]    4
#> [5,]    5
#> [6,]    6
#> [7,]    7
#> [8,]    8
#> 
#> $wss
#> [1] 10
#> 
#> $K
#> [1] 2
#> 
#> $n
#> [1] 8
#> 
#> $method
#> [1] "Functional clustering (k-means on B-spline coefficients)"
#> 
#> attr(,"class")
#> [1] "morie_rich_result" "list"