Specify a longitudinal k-means (KML) method
lcMethodKML(
response,
time = getOption("latrend.time"),
id = getOption("latrend.id"),
nClusters = 2,
...
)
The name of the response variable.
The name of the time variable.
The name of the trajectory identifier variable.
The number of clusters to estimate.
Arguments passed to kml::parALGO and kml::kml. The following external arguments are ignored: object, nbClusters, parAlgo, toPlot, saveFreq
Other lcMethod implementations:
lcMethod-class
,
lcMethodAKMedoids
,
lcMethodCrimCV
,
lcMethodCustom
,
lcMethodDtwclust
,
lcMethodFunFEM
,
lcMethodGCKM
,
lcMethodLMKM
,
lcMethodLcmmGBTM
,
lcMethodLcmmGMM
,
lcMethodLongclust
,
lcMethodMclustLLPA
,
lcMethodMixAK_GLMM
,
lcMethodMixtoolsGMM
,
lcMethodMixtoolsNPRM
,
lcMethodRandom
,
lcMethodStratify
,
lcMethodTwoStep
# NOT RUN {
library(kml)
data(latrendData)
method <- lcMethodKML("Y", id = "Id", time = "Time", nClusters = 3)
model <- latrend(method, latrendData)
# }
Run the code above in your browser using DataLab