all_LTG = [LTGlon,LTGlat];%combine the lat/lon LTG data into one matrix
j=4;%k clusters selected from kpickplot
[LTGidx2,LTGC2,LTGsum2,LTGD2] = kmeans(all_LTG,j,'replicates',10,'display','final');
ptsymb = {'bs','r^','md','go','c+','y*','k.'}; %assign symbols and colors for different clusters
for i=1:j LTGclust = find(LTGidx2==i); plot(all_LTG(LTGclust,1),all_LTG(LTGclust,2),ptsymb{i}); hold on end
plot(LTGC2(:,1),LTGC2(:,2),'ko');
plot(LTGC2(:,1),LTGC2(:,2),'kx');
hold off
title('LTG: Cluster Plot')
xlabel('Longitude º ')
ylabel('Latitude º ')
xlim([-35 55]);
ylim([-40 40]);
