Learn R Programming

ClustVarLV (version 1.4.1)

get_partition: To get the clusters of variables.

Description

This function returns the group's membership for the p variables. The output can be a vector p x 1 of integers between 1 and K, or a binary matrix of size p x n.

Usage

get_partition(resclv, K = NULL, type = "vector")

Arguments

resclv
: result of CLV(), CLV_kmeans() or LCLV()
K
: the number of groups chosen (already defined if CLV_kmeans is used)
type
: presented in the form of a "vector" (by default) or a "matrix"

Value

partition
the group's membership for the variables)

Examples

Run this code
data(apples_sh)
resclvX <- CLV(X = apples_sh$senso, method = "directional", sX = TRUE)
parti4G<-get_partition(resclvX, K = 4)

Run the code above in your browser using DataLab