Skip to main content
Ctrl+K

eegprep

  • User Guide
  • Examples
  • Functions
  • FAQ
  • References
    • Contributing to EEGPrep
    • Development Setup
    • Releasing
    • Changelog
  • GitHub
  • User Guide
  • Examples
  • Functions
  • FAQ
  • References
  • Contributing to EEGPrep
  • Development Setup
  • Releasing
  • Changelog
  • GitHub

Section Navigation

  • Core and Session
  • GUI and Console
  • Data Loading and Saving
  • BIDS
  • Preprocessing and Artifacts
  • Epoching and Selection
  • ICA and Components
    • ICL_feature_extractor
    • ICADefaults
    • compvar
    • eeg_amica
    • eeg_autocorr
    • eeg_autocorr_fftw
    • eeg_autocorr_welch
    • eeg_getica
    • eeg_icalabelstat
    • eeg_icflag
    • eeg_picard
    • eeg_pv
    • eeg_pvaf
    • eeg_rpsd
    • eeg_runica
    • icaact
    • icadefs
    • icaproj
    • icavar
    • iclabel
    • optimal_kmeans
    • picard
    • posact
    • promax
    • robust_kmeans
    • spher
    • runamica
    • runica
    • runica_ml2
    • runica_mlb
    • runicalowmem
    • runpca
    • runpca2
    • varimax
    • varsort
    • zica
  • Filtering and Signal Processing
  • Time-Frequency
  • Plotting and Topography
  • Numerical Utilities
  • Statistics
  • STUDY Workflows
  • Interactive Pop Workflows
  • Extension SDK and Registry
  • Functions
  • ICA and Components
  • optimal_kmeans

optimal_kmeans#

optimal_kmeans(clustdata, clusnum, *, random_state=0)#

Run k-means for a range and choose the best silhouette score.

Parameters:
  • clustdata (Any)

  • clusnum (int | list[int] | tuple[int, int])

  • random_state (int)

Return type:

tuple[ndarray, ndarray, ndarray, ndarray]

previous

iclabel

next

picard

On this page
  • optimal_kmeans()

© Copyright 2024-2026, EEGPrep contributors.

Created using Sphinx 9.1.0.