MATH590: Data clustering

1Centroid methods

Import data corresponding to gait

In[2]:=

SetDirectory["/home/student/courses/MATH590/SETdata"];

c=Import["coefs.data","Table"]; {nSteps,nd}=Dimensions[c]

{298,2}

In[3]:=

c[[1;;4,1;;2]]

( -0.31621 -4.52238 -5.62919 -2.08116 0.50384 -1.45805 0.340489 -2.78363 )

In[4]:=

options = {

CriterionFunction->"StandardDeviation",

DistanceFunction->EuclideanDistance,

Method->"NeighborhoodContraction"

};

cGroups=FindClusters[c,options];

cGroupsPlot = ListPlot[cGroups];

Export["cClusters1.png",cGroupsPlot];

Length[cGroups]

5

In[5]:=

Figure 1. Classification of steps into clusters