AMA_step_size {cvxclustr} | R Documentation |
AMA_step_size
computes a step size based on the better of two bounds derived by Anderson
and Morely.
AMA_step_size(w, n)
w |
vector of weights |
n |
number of points to cluster |
data(mammals) X <- as.matrix(mammals[,-1]) X <- t(scale(X,center=TRUE,scale=FALSE)) n <- ncol(X) ## Pick some weights and a sequence of regularization parameters. k <- 5 phi <- 0.5 w <- kernel_weights(X,phi) w <- knn_weights(w,k,n) AMA_step_size(w,n)