comp.lang.idl-pvwave archive
Messages from Usenet group comp.lang.idl-pvwave, compiled by Paulo Penteado

Home » Public Forums » archive » K mean clustering
Show: Today's Messages :: Show Polls :: Message Navigator
E-mail to friend 
Return to the default flat view Create a new topic Submit Reply
K mean clustering [message #94159] Wed, 08 February 2017 14:39
smnadoum is currently offline  smnadoum
Messages: 24
Registered: June 2016
Junior Member
Hi,


I was wondering if I could get some help on k means clustering in a time series analysis from 2000 to 2012.

I have 4 different datasets (green, yellow, blue and brown) that I want to calculate k mean clustering for. My data is organized in a time series from 2000 to 2012. Each dataset is consisted of three sites:
green_1, green_2, green_3.. same thing for the other colors

I want to calculate k means for all of the data and then output and plot the results of each data set in one plot, so that each plot will represent three sites e.g. green_plot: kmeans for green_1, green_2, green_3.



pro km_clustering, green, yellow, brown, brown


n= 13 ;; number of variables is 13 (years)-13 for yellow, 13 for green and 13 for brown
green_1= *filepath ;define the path of all the data
green_2= *filepath ;define the path of all the data
green_3= *filepath ;define the path of all the data



array = [[green_1], [green_2], [green_3]]

weights = CLUST_WTS(array, N_CLUSTERS = 3) ;;compute cluster weights.

result = CLUSTER(array, weights, N_CLUSTERS = 3) ;compute classification


how can add a loop here to run through all of my files (3 yellows, 3 greens, 3 browns, and 3 blues)?


Thank you for your help/time in advance,
[Message index]
 
Read Message
Previous Topic: Why doesn't PERROR make any sense in MPFIT?
Next Topic: IDL installation in mac OS X 10.11

-=] Back to Top [=-
[ Syndicate this forum (XML) ] [ RSS ] [ PDF ]

Current Time: Wed Oct 08 16:02:05 PDT 2025

Total time taken to generate the page: 0.00182 seconds