% Top Players in Cody
% time vector is: time1748
% data vector is: data1748
t = time1748;
d = data1748;
v = [];
for i = 1:length(t)
for j = 1:(size(d,2)/2)
v(end+1,:) = [t(i) d(i,[2*j-1 2*j])];
end
end
playerTable = { ...
2722350,'@bmtran';
2789428,'Richard Zapor';
470811,'Venu Lolla';
734801,'Binbin Qi';
2391181,'Aurelien Queffurust';
504719,'Amitava Biswas';
1379371,'Alfonso Nieto-Castanon';
1189631,'Ben Petschel';
2747253,'Mark';
3334064,'Freddy';
2943139,'Bart Vandewoestyne';
404847,'Christopher';
33802,'James';
1861624,'Grzegorz Knor';
649595,'Alan Chalker';
2623746,'Prateep Mukherjee';
1841757,'the cyclist';
496166,'Tim';
891763,'Yuval Cohen';
3263429,'Nikolai';
2282513,'Raphael Cautain';
3291011,'S L';
413337,'Martijn';
744956,'Vincent';
1962870,'Amro';
2333895,'Tomasz';
3529521,'Matt Eicholtz';
415894,'David Young';
1917002,'yuval tr';
3372125,'K';
2334019,'Fel';
599720,'Matt Baran';
1063408,'Peter Wittenberg';
2210440,'Franck Dernoncourt';
2654876,'Bart';
3413081,'Stefan';
2373420,'Chendra';
1967755,'blaat';
3290269,'James Kristoff';
2689605,'Sangeeta';
1011447,'Tobias';
1702345,'Bert';
1904570,'David Hruska';
2372892,'eric landiech';
1538946,'proecsm';
1449599,'Denis Koch';
17831,'Nicholas Howe';
1326470,'Sven';
2049607,'Kuifeng';
1448465,'Dirk Engel';
343082,'Jean-Marie SAINTHILLIER';
869884,'Khaled Hamed';
2255311,'José Ramón Menzinger';
870409,'Claudio Gelmi';
3354683,'Yaroslav';
};
nameHash = java.util.Hashtable;
for i = 1:size(playerTable,1)
nameHash.put(playerTable{i,1},playerTable{i,2});
end
profids = d(end,1:2:end);
leaderNameList = {};
hold all
for i = 1:length(profids)
ix = v(:,2)==profids(i);
t1 = v(ix,1);
d1 = v(ix,3);
plot(t1,d1)
name = nameHash.get(profids(i));
if isempty(name)
name = 'UNKNOWN';
end
leaderNameList{end+1} = name;
end
hold off
datetick
legend(leaderNameList,'Location','EastOutside')
set(gcf,'Color','white')
data points
Created 06 Jul 2012 by Ned Gulley
96 views (30 days)
This trend is associated in this plot (though may not be used.)
10 comments
very nice plot!
Ned,
Is is correctly updated ? I mean I see that for example the trend of Mark is not updated anymore (he is currently 11th) , we should see the other Cody player James instead.
Thanks for pointing out the problem Aurelien! I meant to cycle through the current leaders, but instead I was cycling through the top ten when I started gathering data. Should be fixed now.
cool! It looks like very nice now with the legend.
Your plit is broken , maybe it comes (like me) from the bug of 14 Sep 2012 06:07:17 . Trendy has returned NaN .
Thanks for the reminder...
It wasn't the NaN. My code looks up each players name based on their profile ID, and my name table didn't yet include Khaled, because he has made such a meteoric rise. Should be a little more robust now.
Ah ok , you mean that if one Cody player is not in your playerTable , the Trendy will fail.
Right. That's what WAS happening, but it shouldn't have that problem anymore.
Badges, introduced in mid-November, provided a big one-time jump in the scores.
... and the recent rescoring of solutions to eliminate the feval trick has provided a small drop in the score for some of use :-)