Learn R Programming

stream (version 1.0-3)

DSC_TwoStage: TwoStage Clustering Process

Description

Combines a micro and a macro clustering algorithm into a single process.

Usage

DSC_TwoStage(micro, macro)

Arguments

micro
Clustering algorithm for online stage (DSC_micro)
macro
Clustering algorithm for offline stage (DSC_macro)

Value

  • An object of class DSC_TwoStage (subclass of DSC, DSC_Macro).

Details

cluster() runs the micro-clustering stage and if centers/weights are requested the reclustering is automatically performed.

See Also

DSC, DSC_Macro

Examples

Run this code
dsd <- DSD_Gaussians(k=3)

# Create a clustering process that uses a window for the online stage and
# k-means for the offline stage (reclustering)
dsc <- DSC_TwoStage(
  micro=DSC_Window(horizon=100), 
  macro=DSC_Kmeans(k=3)
  ) 
dsc
  
cluster(dsc, dsd, 200) 
dsc
plot(dsc, dsd, type="both")  
evaluate(dsc, dsd, assign="macro")

Run the code above in your browser using DataLab