Wednesday, June 15, 2011

Champion Combination Success Data [June 1 - June 15]

For some time I didn't post Combo Success Ratio since we have 15 days since the last update I thought that that could be enough time and data to make a list top 25 champion combinations that where most successful. So here we go.

I present to you a list of most successful champion combinations since the last patch (Oriana release).

100,000+ games and a more then a million champion games data was narrowed to summoners that hold 1200+ Elo on any ranking ladder and only data from 5v5 games was considered with at least 80 games played by a combo., resulting in TOP 25 list.

Notes:

In most of the combinations its easy to see why it would be fun to have it on the enemy team. If I remember correctly Sona / Karthus combo is not a new one in such list Karthus can deal plenty Area of Effect (AoE) damage and in combination with Sona's Ultimate enemy can't move away resulting in GG.

Rumble / Taric or Janna : Rumble is more popular on EU server with his persistent damage and good support is hard to do much against. Apparently Rumble nerf didn't to prevent hes enemy's HP bar from going down.

Warwick / Nunu: Imagining what this combo can do I smiled - they are perfect for each other (no homo). I mean... how can you deal with tanky DPS that can heal and scary tank that can send you to Alaska in your shorts..? Oh yeah he can heal to... did I mentioned that Nunu's Blood Boil can also make D in DPS so much more PS? This is one reactive combo that leaves me feeling exited and depressed in the same time.

(click the column title to sort)

Top 25 Champ. Combo. Success - 5v5 - US and EU - 1200+ Elo

Champ1 Champ2 Avg. Elo Games Win %
Sona Karthus 1418 86 74
Taric Rumble 1491 135 71
Rumble Janna 1469 141 68
Warwick Nunu 1491 181 65
Sona Gangplank 1380 171 64
Poppy Evelynn 1357 105 64
Warwick Soraka 1470 602 63
Xin Zhao Sona 1382 355 63
Vladimir Rumble 1403 283 63
Soraka Gangplank 1397 214 63
Swain Sona 1409 136 63
Janna Blitzcrank 1397 115 63
Kassadin Evelynn 1357 108 63
Poppy Janna 1418 90 63
Fiddlesticks Annie 1404 85 63
Taric Anivia 1447 83 63
Xin Zhao Nocturne 1367 234 62
Rumble Annie 1426 218 62
Soraka Shaco 1420 148 62
Rumble Malzahar 1397 147 62
Twisted Fate Fiddlesticks 1363 110 62
Morgana Evelynn 1379 103 62
Nasus Kennen 1363 102 62
Rumble Nidalee 1403 93 62
Singed Nasus 1334 93 62

Sunday, June 12, 2011

Connecting SQL to Stata (integrating SQL commads with statistical analysis scripts)

For few days now I had a pleasure to work with a statistical analysis tool called Stata. Among other tools such as SPSS and SAS it used extensively in business world and scientific community. SPSS is more user friendly version of statistical software that provides same functionality as Stata and SAS being in the league of its own.

Common problem both Stata and SPSS share is a lack of SQL input support. The only support is really unpractical ODBC driver that is not that convenient to use. I got a feeling that it is more of a work around the a solution to the SQL input support. As a response to a need in connecting statistical software to a SQLite database (db I use to store and reshape all the data) I had to write a software the acts like a filter between Stata "*.do" files and Stata.

In essence I just added a command to a Stata do file that is able to open SQLite database and runs SQL statement data from witch will be imported into Stata. To do that I wrote a small program that is registered to interpret "*.so" files and find additional database commands, execute SQL statement and pass the date to a Stata that will continue interpreting the rest of the file containing Stata commands.

Essentially this is what the file looks like:

db=P:\Games\League of Legends\DBgen2\lolbw.db
[[
SELECT name, elo as Elo, SUM(win) AS Wins, SUM(loss) AS Losses,
 SUM(win)+SUM(loss) as Total, 100.0*SUM(win)/(SUM(win)+SUM(loss)) AS "Win %", 
 avg(dmg) as "Dmg Given", avg(dmgtaken) as "Dmg Taken", avg(gold) as Gold,  
 avg(cs) as CS, avg(kill) as Kills, avg(asist) as Assists, avg(death) as Deaths
FROM "match" m
WHERE 1=1
 --AND elo>=1200
 --AND elo<=1400
 --AND substr(id,3,1)=='r'
 --AND substr(map,-2,1)=='5'
 --AND server='EU'
 --AND datetime(date) > datetime('2011-05-24 03:00:00')--  patch 118
 --AND datetime(date) > datetime('2011-06-01 14:00:00')-- patch 119 oriana
GROUP BY name
HAVING Total>20
ORDER BY "Win %" DESC,Wins DESC

]]

set more off
#delimit ;

twoway 
(scatter kills win, sort mcolor (green) msize(large) msymbol(circle_hollow)) 
(scatter assists win, sort mcolor(blue) msize(medium) msymbol(circle_hollow)) 
(scatter deaths win, sort mcolor(red) msize(small) msymbol(circle_hollow)) 
(lowess kills win, noweight lcolor(green)) 
(lowess assists win, noweight lcolor(blue)) 
(lowess deaths win, noweight lcolor(red))
;



As you can see first part of the script connects to SQLite database and runs SQL statement resulting in the data that will later be processed by the rest of the Stata script file resulting in a graph.


EDIT 11-02-2011:

Zip file that contains:

- dosoSQLiteStata.exe
- Source code
- Template "install so extension (template).reg"
- Sample *.SO file

To use just drag and drop created *.so file on the "dosoSQLiteStata.exe"
OR
For registering *.so extension you need to edit .reg file and specify proper path.

http://www.mediafire.com/?ysfkjsxqvb26bu0
(Let me know if I need to upload it again)

Wednesday, June 8, 2011

LoL Champion Success Data - Since Orianna's B-Day [June 01-08]

Hello summoners,

Another week passed (and a bit more) since Orianna's Birthday. This week we will have two tables to look at. One table will look at the data in Elo range 1200-1400 and another 1400+.

So, how is Orianna doing in her first week? Lets see... Most popular champ... Well indeed... #40 1200-1400 Elo and #43 1400+ Ok, all the baddies, stop playng new champ now! (If your wondering why Orianna is spelled Oriana (one N) its because Riot code name for Orianna is Oriana... lol)

Least popular champ. Heimer: (my main since I started playing). Followed by Karma and Sivir (Nothing new).
Interesting: Sivir and Heimer have highest Avarage CS. I Guess ppl @ 1300 Elo don't like farming.


(click the column title to sort)

5v5 - US and EU - 1200 to 1400 Elo

Champ Avg Player Elo Wins Losses Total Win % Dmg Given Dmg Taken Gold CS
Sona 1294 777 501 1278 60 54960 19422 8416 62
Janna 1304 625 422 1047 59 52326 16500 8099 56
Mordekaiser 1291 1477 1063 2540 58 131402 19161 10914 149
Soraka 1305 784 601 1385 56 33173 16767 7395 42
Xin Zhao 1295 1725 1372 3097 55 108971 26047 9866 90
Amumu 1297 1511 1198 2709 55 94590 24787 9431 61
Nocturne 1293 1136 917 2053 55 144915 26138 10839 92
Evelynn 1294 922 731 1653 55 59815 20931 8975 54
Fiddlesticks 1289 410 324 734 55 86935 24968 9090 65
Galio 1291 361 289 650 55 104157 23168 9610 125
Annie 1298 1233 1049 2282 54 94949 18385 10164 118
Malzahar 1294 989 811 1800 54 113858 19003 10959 155
Brand 1295 734 625 1359 54 108297 18550 10113 121
Rammus 1292 712 583 1295 54 71469 25706 8804 63
Rumble 1293 594 494 1088 54 89301 23969 9848 99
Ashe 1297 2037 1780 3817 53 110388 17388 10436 130
Vladimir 1297 1616 1431 3047 53 121536 27124 10651 142
Warwick 1300 1213 1053 2266 53 106760 34103 9513 62
Taric 1300 473 415 888 53 40751 25699 7853 51
Urgot 1297 345 296 641 53 88734 18915 9581 110
Twisted Fate 1295 1363 1209 2572 52 116419 20643 10639 130
Caitlyn 1293 1310 1174 2484 52 133189 18435 10540 149
Gangplank 1293 889 798 1687 52 112548 25658 12295 127
Nasus 1291 757 683 1440 52 110419 31371 10282 132
Karthus 1296 427 386 813 52 131518 20637 11465 148
Anivia 1293 400 369 769 52 114892 21957 10309 136
Trundle 1296 386 355 741 52 119151 30997 9807 66
Cassiopeia 1292 276 254 530 52 104828 19087 10087 122
Singed 1296 1001 926 1927 51 101002 32203 9786 121
Jarvan IV 1302 953 910 1863 51 89595 24852 10459 105
Irelia 1295 939 880 1819 51 90992 27820 10506 120
Jax 1289 908 867 1775 51 96793 26566 9819 100
Nunu 1299 855 819 1674 51 91989 31489 9091 62
Tryndamere 1290 745 709 1454 51 140375 32830 10966 117
Zilean 1299 293 279 572 51 71888 17950 8291 87
Blitzcrank 1297 1525 1473 2998 50 71174 24435 8712 81
Alistar 1296 1112 1083 2195 50 60337 29023 8636 73
Katarina 1286 873 839 1712 50 98753 22604 10254 104
Miss Fortune 1299 622 622 1244 50 120407 20073 10507 147
Maokai 1296 457 445 902 50 93198 27621 9447 107
Kennen 1298 445 439 884 50 95435 21067 9684 118
Karma 1296 241 237 478 50 90373 20255 9279 108
Heimerdinger 1290 221 215 436 50 132538 17731 10193 151
Oriana 1297 3312 3359 6671 49 104696 17882 9729 122
Kog'Maw 1290 730 740 1470 49 114334 20533 10346 119
Master Yi 1291 687 695 1382 49 146954 25196 10818 119
Poppy 1295 539 545 1084 49 71985 23278 9997 78
Malphite 1289 994 1042 2036 48 71900 21505 9040 85
Cho'Gath 1294 761 824 1585 48 101383 29494 9927 128
Corki 1300 717 761 1478 48 123792 19645 10587 153
Ezreal 1299 614 665 1279 48 113006 19511 10347 128
Morgana 1291 561 604 1165 48 90972 22277 9219 114
Vayne 1296 1344 1477 2821 47 91084 20476 9937 111
Teemo 1291 1099 1192 2291 47 99349 19202 10001 119
Renekton 1296 698 764 1462 47 99579 29784 9666 114
Nidalee 1297 665 735 1400 47 89546 22836 8998 104
Shaco 1290 655 727 1382 47 105890 21243 9796 70
Ryze 1294 447 497 944 47 83050 20663 9302 99
Udyr 1295 417 454 871 47 114279 25594 9324 65
Sion 1290 399 444 843 47 91943 22635 9140 105
Dr. Mundo 1293 388 426 814 47 82168 30958 8847 97
Lee Sin 1298 1303 1529 2832 46 100041 23805 9355 85
Swain 1295 1169 1324 2493 46 89557 29223 9516 105
Shen 1299 826 964 1790 46 50381 26574 8415 78
Lux 1290 778 887 1665 46 99867 15025 9516 108
Garen 1291 718 829 1547 46 74743 28259 9310 92
Gragas 1302 265 302 567 46 103632 26121 9565 119
Twitch 1295 244 280 524 46 85812 19639 10078 94
Kayle 1290 234 267 501 46 63614 23019 8261 82
Sivir 1293 225 262 487 46 138280 21878 10618 161
Veigar 1291 482 576 1058 45 99104 17846 10311 123
Akali 1296 819 1026 1845 44 86474 25297 9781 100
Kassadin 1298 535 666 1201 44 76780 20641 9255 89
Olaf 1294 400 502 902 44 118628 32111 9451 76
Pantheon 1293 375 482 857 43 90286 23197 9932 99
LeBlanc 1292 355 527 882 40 64878 18151 9126 79
Tristana 1293 302 448 750 40 111399 20811 10094 137

5v5 - US and EU - 1400+ Elo

Champ Avg Player Elo Wins Losses Total Win % Dmg Given Dmg Taken Gold CS
Evelynn 1518 437 273 710 61 62518 20582 9008 53
Vladimir 1520 903 604 1507 59 129336 27291 10916 161
Mordekaiser 1500 473 320 793 59 135510 17635 10984 166
Amumu 1521 868 626 1494 58 101453 23995 9593 53
Warwick 1537 838 593 1431 58 100563 33488 9407 70
Janna 1529 462 327 789 58 37052 15371 7965 41
Rumble 1527 375 264 639 58 94429 23301 10094 116
Fiddlesticks 1532 184 130 314 58 94930 25888 9048 61
Soraka 1534 615 447 1062 57 23391 15047 7309 29
Katarina 1490 264 194 458 57 104692 22957 10779 120
Cassiopeia 1537 116 86 202 57 102759 17805 9873 131
Ashe 1518 1031 810 1841 56 115268 16974 10708 147
Twisted Fate 1528 839 642 1481 56 129310 19461 11117 151
Xin Zhao 1500 723 561 1284 56 113940 25733 9755 84
Irelia 1524 619 474 1093 56 98754 28171 11129 145
Nocturne 1516 540 418 958 56 146259 25456 10549 81
Malzahar 1526 462 356 818 56 118248 18543 11020 166
Heimerdinger 1502 93 71 164 56 139729 18755 10725 158
Sona 1520 355 287 642 55 45653 18102 8255 53
Maokai 1515 203 163 366 55 100374 26584 9944 121
Caitlyn 1523 666 558 1224 54 135998 17894 10668 165
Singed 1511 438 373 811 54 102766 30723 9941 134
Jax 1520 400 340 740 54 97974 25490 9852 112
Taric 1541 320 271 591 54 35506 24290 7964 44
Zilean 1511 165 137 302 54 69626 17712 8673 86
Corki 1539 575 492 1067 53 129922 19243 10953 168
Nunu 1526 456 404 860 53 91342 29432 9015 53
Miss Fortune 1534 407 358 765 53 125639 19741 10842 167
Gangplank 1506 356 305 661 53 120546 27251 13121 148
Nidalee 1507 343 295 638 53 101174 25083 9545 126
Brand 1527 295 259 554 53 114155 18614 10518 139
Twitch 1524 110 97 207 53 88656 19497 10381 98
Galio 1496 109 96 205 53 107667 22525 9677 137
Jarvan IV 1525 652 585 1237 52 93669 24765 10951 120
Annie 1538 607 558 1165 52 100616 18033 10315 138
Alistar 1515 527 485 1012 52 60501 26751 8660 73
Teemo 1499 389 358 747 52 105862 19325 10329 135
Garen 1504 280 256 536 52 75656 25356 9458 102
Poppy 1521 249 229 478 52 73049 23512 10603 87
Karthus 1518 190 172 362 52 136486 20575 11485 164
Urgot 1531 170 152 322 52 94493 17703 9829 126
Kayle 1515 105 94 199 52 67744 23223 8918 96
Oriana 1512 1466 1391 2857 51 108266 17911 9980 133
Malphite 1484 289 270 559 51 74746 20573 9319 95
Nasus 1492 275 261 536 51 110525 31081 10504 144
Anivia 1520 227 210 437 51 117371 20806 10251 148
Trundle 1530 224 209 433 51 117762 28721 9382 63
Rammus 1502 214 203 417 51 77722 24242 8791 53
Kennen 1503 210 195 405 51 101021 19739 10025 138
Vayne 1517 678 660 1338 50 96967 20516 10322 130
Udyr 1519 194 188 382 50 122592 25278 9514 67
Olaf 1518 185 185 370 50 134631 32305 10006 71
Pantheon 1500 165 161 326 50 99765 23707 10845 118
Gragas 1531 141 139 280 50 109577 23916 9879 140
Swain 1521 503 515 1018 49 91751 29189 9673 118
Lux 1490 244 246 490 49 100629 14726 9773 115
Morgana 1498 185 192 377 49 93025 22794 9511 122
Veigar 1511 184 190 374 49 103014 17178 10670 138
Lee Sin 1527 734 775 1509 48 113712 24263 9661 83
Blitzcrank 1507 611 660 1271 48 66381 23137 8505 78
Shaco 1517 331 349 680 48 122456 21381 10086 72
Master Yi 1509 310 324 634 48 162838 26262 11096 110
Kog'Maw 1501 265 284 549 48 114545 19567 10250 130
Renekton 1508 262 275 537 48 107413 30923 10370 134
Tryndamere 1503 228 242 470 48 152941 35479 11299 119
Ryze 1490 186 199 385 48 80810 19537 9184 108
Karma 1517 107 113 220 48 86228 18954 9240 107
Akali 1509 347 380 727 47 90345 24842 9980 116
Ezreal 1516 301 328 629 47 124004 20400 10753 146
Cho'Gath 1512 299 325 624 47 107576 29090 10392 142
Kassadin 1507 247 271 518 47 84469 20751 9775 109
Sion 1506 128 139 267 47 107268 21442 9828 130
Shen 1493 323 401 724 44 51901 25409 8550 89
LeBlanc 1519 117 153 270 43 71126 18270 9659 93
Tristana 1527 190 254 444 42 114920 20735 10390 149
Sivir 1509 73 97 170 42 144742 21338 10890 175
Dr. Mundo 1502 89 128 217 41 83455 29922 8784 107

Wednesday, May 25, 2011

Data mining method for League of Legends Stats

I have a lot of people asking me how I get my data for game statistics I am posting reports on. Hopefully this post answers most of the questions.

Skip this paragraph if you know how google works. As you know google and other search engines use applications capped crawlers that aimlessly scout the internet and download everything they can find usefully and store it for the search engine application to process. The data is then indexed by indexing applications and stored into a specialized database. When you search using a keyword google goes into the database and gets what you might be looking for.

How I get data is similar. Instead of indexing and looking for data aimlessly my tool indexes very specific pages and knows exactly what its looking for making it very efficient. Efficiency saves my computer as well as web server resources.

Where do I get data from?
Anywhere there is valuable data. Currently only lolbase and riot ranking ladders are indexed. Unfortunately riotstats.com is still under heavy development and has bugs and issues as well as missing a lot of valuable statistics.

I would recommend using JaxUploader from riotstats.com just because its uploading data to BOTH lolbase and riotstats.

Got more questions? Let me know.


Data scope and random factor

After looking at the data and some graphs I realized that there is substantial random variable that can decide a game. In order to get a crisp data large data sample is crucial. This especially is true for x2 champ combo.

I might release individual champ success ratio every few days while x2 champ combo every week or two. Effectively that will average data hopefully enough to remove most of the random factor and expose the interesting trends.

LoL Champion Combo Success Data [May 20-24]

Table below is sortable (click column title)

Here is table of Champ Success Ratios for both US and EU server in period between May 20-24, 2011. Keep in mind while looking at "Avg Player Elo" that since all Elo data coming from Riot Ranked ladders, players that are lower then 1200 Elo are represented by an Elo of 0 (zero).

There are 2,850 possible 2 champion combinations using 76 champs. These are 25 most successful.

With next set of data would be interesting to see how patch influenced the combos.


Champ1 Champ2 Avg Player Elo Wins Losses 1000*wins/losses Win %
Maokai Anivia 238.0 47 19 2473 71
Rumble Fiddlesticks 207.0 61 29 2103 67
Twitch Rumble 289.0 43 21 2047 67
Sona Karthus 324.0 69 34 2029 66
Singed Brand 309.0 112 62 1806 64
Warwick Soraka 394.0 227 129 1759 63
Zilean Nocturne 343.0 73 42 1738 63
Sona Evelynn 207.0 116 67 1731 63
Heimerdinger Caitlyn 258.0 129 75 1720 63
Soraka Rumble 406.0 94 55 1709 63
Kassadin Heimerdinger 130.0 41 24 1708 63
Irelia Fiddlesticks 337.0 73 44 1659 62
Rumble Rammus 325.0 176 107 1644 62
Sona Corki 372.0 64 39 1641 62
Vladimir Janna 431.0 263 162 1623 61
Swain Rumble 305.0 60 37 1621 61
Urgot Malphite 398.0 50 31 1612 61
Mordekaiser Evelynn 307.0 256 159 1610 61
Mordekaiser Maokai 214.0 80 50 1600 61
Shen Rumble 347.0 145 91 1593 61
Soraka Poppy 494.0 43 27 1592 61
Sona Malzahar 367.0 155 99 1565 61
Udyr Sona 292.0 72 46 1565 61
Vayne Soraka 411.0 343 225 1524 60
Soraka Lee Sin 465.0 59 39 1512 60

LoL Champion Success Data for May 20-24

This data is coming from lolbase.net and is generated from game logs uploaded to lolbase within past few days. There is also new data available: "Average Player Elo". Keep in mind while looking at "Avg Player Elo" that since all Elo data coming from Riot Ranked ladders, players that are lower then 1200 Elo are represented by an Elo of 0 (zero).

CLICK ON COLUMN TITLE TO SORT
Champ Avg Player Elo Wins Losses 1000*wins/losses Win %
Rumble 318.3 2001 1433 1396 58
Sona 285.0 1893 1370 1381 58
Soraka 402.6 1643 1261 1302 56
Janna 320.5 2087 1661 1256 55
Karthus 270.8 1084 873 1241 55
Amumu 345.3 3304 2723 1213 54
Mordekaiser 293.1 3397 2846 1193 54
Brand 279.4 2000 1761 1135 53
Malzahar 330.5 2464 2112 1166 53
Nocturne 286.2 2165 1910 1133 53
Vladimir 333.2 4083 3540 1153 53
Anivia 316.5 1077 973 1106 52
Evelynn 282.1 2383 2147 1109 52
Galio 300.3 421 379 1110 52
Irelia 394.6 2006 1799 1115 52
Singed 343.6 1677 1503 1115 52
Taric 382.2 798 720 1108 52
Twisted Fate 339.9 2691 2459 1094 52
Alistar 302.9 5313 5008 1060 51
Blitzcrank 354.1 1468 1376 1066 51
Caitlyn 289.2 2304 2173 1060 51
Fiddlesticks 198.4 1291 1197 1078 51
Heimerdinger 185.7 2054 1927 1065 51
Katarina 215.8 2645 2487 1063 51
Malphite 280.5 1734 1620 1070 51
Nunu 272.0 1913 1810 1056 51
Rammus 196.5 3467 3331 1040 51
Urgot 347.2 773 732 1056 51
Zilean 316.2 1080 1037 1041 51
Ashe 276.0 4695 4529 1036 50
Cassiopeia 288.1 869 863 1006 50
Corki 455.7 777 777 1000 50
Kennen 219.0 1872 1802 1038 50
Nasus 281.5 1538 1516 1014 50
Warwick 245.4 4534 4385 1033 50
Xin Zhao 219.3 7352 7101 1035 50
Annie 259.0 1680 1711 981 49
Gangplank 318.9 1561 1610 969 49
Jax 267.8 2773 2850 972 49
Lee Sin 404.4 1235 1257 982 49
Maokai 295.3 911 915 995 49
Miss Fortune 218.1 3703 3760 984 49
Poppy 286.3 1223 1257 972 49
Teemo 198.6 2997 3003 998 49
Trundle 398.6 713 727 980 49
Tryndamere 191.6 2542 2563 991 49
Jarvan IV 276.8 4364 4597 949 48
Kog'Maw 231.8 576 609 945 48
Swain 335.5 980 1060 924 48
Twitch 227.7 792 857 924 48
Vayne 287.5 6021 6513 924 48
Garen 271.6 1753 1948 899 47
Master Yi 176.3 2476 2724 908 47
Morgana 246.1 1186 1331 891 47
Renekton 341.7 1049 1142 918 47
Udyr 315.3 958 1077 889 47
Kassadin 341.9 902 1023 881 46
Lux 260.9 2124 2450 866 46
Nidalee 342.3 1482 1687 878 46
Ryze 268.6 1523 1766 862 46
Shaco 308.0 1707 1948 876 46
Shen 357.2 1908 2176 876 46
Sion 296.3 1065 1241 858 46
Cho'Gath 292.6 1349 1610 837 45
Dr. Mundo 224.5 1237 1476 838 45
Ezreal 352.2 1306 1573 830 45
Gragas 347.3 496 594 835 45
Kayle 300.2 668 812 822 45
Pantheon 253.1 1030 1218 845 45
Karma 342.2 482 608 792 44
Sivir 176.2 909 1139 798 44
Akali 252.8 1914 2466 776 43
LeBlanc 269.0 1080 1379 783 43
Olaf 299.7 1003 1281 782 43
Veigar 181.6 2743 3514 780 43
Tristana 231.2 882 1202 733 42
As you can see Rumble did really well I can't wait to see how well he will do after t nerf or the latest patch. Right after Rumble as always underrated support :)