Data Intro

I have been playing Call of Duty since the second game in the series. I was about 7 years old when my friends, brothers, and I would play the split screen campaign and battle eachother in local multiplayer. Now, just over 15 years and $1000 later(had to buy original black ops 3 times cuz someone knocked over my 360), I still enjoy playing this series with my friends online. CoD has come an extremely long way since I first started playing, considering it was almost strictly a World War II game back in the day, and I am curious to see how the weapons in the newest release, Cold War, can perform.

The Cold War weapons data being analyzed was scraped from a webpage. This webpage was put together by a fellow CoD lover. Fortunately, this person made my life easier, they went into the game and copied down all the weapon stats into a spreadsheet that I was able to scrape. So shout out to this person.

This data frame includes all the base weapon and base weapon stats. Each time a player increases their weapon level, they unlock attatchments that improve weapon performance. Any player is allowed to have up to 5 attachments on their weapon, unless they are using the primary gunfighter wildcard which allows 8 attachments on the primary weapon. Some of these attachments include : muzzle, barrel, optic, stock, front grip, rear grip, and underbarrel. This allows the players of the CoD community to make over 40,000 possible weapon combinations! However, we will just be looking at base weapon stats, that is, a weapon with zero attachments.

Below are tables showing the data, data dictionary, and summary statistics. It is important to note that this is an exploratory analysis. I am not answering one hypothesis of “what is the best weapon?”, rather I want to compare how the weapons differ between classes and how the classes differ between weapons.

weapon Damage DPS Time To Kill Shots To Kill Effective Range RPM Mag Size ADS Reload Speed Muzzle Velocity Vert. Recoil Hor. Recoil Hipfire Accuracy gun_type
X1911 50 333.3 300.0 3 19.05 400 8 225 1.8 200 231 120.0 6.5 p
Magnum 75 214.0 351.0 2 15.24 171 6 225 6.3 300 200 200.0 6.5 p
Diamatti 30 360.0 366.0 5 21.59 1111 15 225 1.7 250 168 120.0 7.0 p
Hauer 77 159 175.0 0.0 1 5.72 66 5 250 4.5 850 750 150.0 8.0 sg
Gallo 118 417.0 283.0 2 5.72 212 7 250 6.0 850 450 250.0 8.0 sg
Pelington 703 110 99.0 1100.0 2 127.00 54 5 550 5.1 500 550 250.0 18.0 sr
LW3 110 86.0 1300.0 2 127.00 47 5 650 3.0 550 550 350.0 18.0 sr
M82 110 330.0 333.0 2 127.00 180 5 700 3.0 525 1040 300.0 18.0 sr
Type 63 68 370.0 367.0 3 50.80 327 25 350 2.5 625 390 -180.0 8.5 tr
M16 50 450.0 132.0 3 25.40 909 30 350 2.7 725 390 -80.0 8.5 tr
Aug 51 714.0 152.0 3 38.10 857 30 350 2.7 775 420 166.5 8.5 tr
DMR 14 58 349.0 332.0 3 50.80 361 20 325 2.5 700 351 270.0 8.5 tr
Stoner 63 42 505.4 249.0 4 50.80 722 75 625 6.0 675 270 200.0 7.0 lmg
RPD 38 413.0 276.0 4 50.80 652 75 600 7.0 475 351 100.0 7.0 lmg
M60 50 431.0 232.0 3 50.80 517 75 650 7.4 600 350 500.0 7.0 lmg
MP5 32 457.0 280.0 5 15.24 857 30 275 2.6 250 252 208.0 7.0 smg
Milano 42 403.2 312.5 4 12.70 576 32 250 2.2 225 322 225.0 6.5 smg
AK74u 38 441.4 258.0 4 7.62 697 30 300 2.4 500 288 224.0 7.0 smg
KSP 45 50 450.0 166.0 3 11.43 722 30 275 2.4 200 200 -300.0 7.0 smg
Bullfrog 34 425.0 320.0 5 19.05 750 50 275 2.8 250 180 127.5 7.5 smg
XM4 30 361.0 333.0 5 45.72 722 30 300 2.6 550 360 30.0 7.5 ar
AK47 38 380.0 300.0 4 38.10 600 30 300 2.6 490 405 -84.0 7.5 ar
Krig 6 35 380.3 368.0 5 50.80 652 30 300 2.4 625 276 -32.0 7.5 ar
QBZ 83 32 363.2 353.0 5 45.72 681 30 283 2.5 625 350 -85.0 8.0 ar
FFAR 1 28 424.2 330.0 6 38.10 909 25 300 2.1 625 330 40.0 7.5 ar
Data Dictionary
variable definition
Weapon name of the gun
Damage amount of health one bullet from the gun takes away when it hits another player
DPS Damage per second. This shows the quantity of damage a gun can do in a time period.
Time to Kill How fast this weapon would kill an enemy in milliseconds.
Shots to Kill The number of shots it takes a weapon to kill an enemy.
Effective Range A measure in meters, of a distance a weapon should perform its best at.
RPM Fire rate. This displays how many bullets this weapon can shoot in one minute.
Mag Size The amount of bullets a weapon is able to shoot before a reload or a new clip.
ADS Aim down sight. A measure of time in milliseconds of how long it takes to aim the weapon.
Reload Speed A measure of time in seconds of how long it takes to change magazines with a new one.
Muzzle Velocity A measure of speed a bullet travels out of the barrel of the weapon.
Vert. Recoil Vertical Recoil. A measure of how much the weapon misses its intended target up or down.
Hor. Recoil Horizontal Recoil. A measure of how much the weapon misses its intended target left or right.
Hipfire Accuracy A measure of how many bullets will hit its intened target when not aiming down sights.
gun_type Puts each weapon into a class. ‘p’ = pistols, ‘sg’ = shotguns, ‘sr’ = sniper rifles, ‘tr’ = tactical rifles, ‘lmg’ = light machine guns, ‘smg’ = sub machine guns, ’ar = assault rifles
Summary Stats
min_reload_speed max_range max_mag min_time_to_kill max_shot_to_kill avg_damage
1.7 127 75 0 6 59.12

DESCRIPTIVE ANALYSIS COLD WAR WEAPONS:

As you can see from the charts, all weapon categories are best at something. Sure, shot guns and sniper rifles are at the top if we’re talking damage per shot. But these weapons are only good for that one enemy at a time. More often than not, playing online CoD will have you running into multiple enemies at once. This is why it’s important to look at the damage per second. Now we can see that lmgs, ars, trs, and smgs are the superior classes. Dividing the classes even further, we get into reload speed, effective range, and aim down sight time. These variables are crucial when deciding a weapon for competetive play. If you’re looking for a weapon that is faster reload speed, smaller magazines, and lower range, then you are going to want a sub machine gun. If you just want to increase that range a little bit while maintaining similar reload times and mag size, then an assault rifle is what you want. Finally, if you want to increase the range even further and play with a burst or semiautomatic rifle, then the tactical rifle is your choice of class. If you want to play from an extreme distance or play close by using attachemnts that improve ads, then a sniper is the best. If you decide you want to do something different like idk be an asshole, then you can pick between light machine guns or shot guns or both. :p

Lets bring in some of our own data. I scraped this data set from cod trackers website. I got the weapon stats from my friends and I’s gameplay. Some of the game modes that were played: team deathmatch, kill confirmed, domination, hardpoint, and search and destroy. Data manipulating was necessary to get some of the variables I wanted to look at. For the most part, the variables are self-explanatory but some of the variables that are important, not easily understood, or were created by me are in the data dictionary right below the snippet of the data set.
All Weapons Slice
Weapon player class Kills K.D.Ratio Deaths Deaths.During.Use Damage Headshots HS. Matches.Played Assists Hits Shots Accuracy Kills.min Kills.match Damage.min dps Damage.match avg_life seconds_played mins_played score_min
AK-47 leo ar 1675 1.39 453 1208 313349 286 0.8 1266 507 9506 37900 25.1 2.12 1.32 396.14 6.6014073 247.51 104.000 47467 791.1166667 243.76936
XM4 leo ar 1489 1.09 379 1366 287686 336 0.8 1285 429 10450 40559 25.8 1.68 1.16 324.34 5.4021482 223.88 140.000 53254 887.5666667 191.92924
Pelington 703 leo sr 708 1.28 276 551 120090 331 14.1 1187 47 851 2352 36.2 1.09 0.60 185.32 3.0876228 101.17 140.000 38894 648.2333333 112.84517
Krig 6 leo ar 206 1.04 271 199 41805 37 0.7 119 82 1446 5597 25.8 2.19 1.73 444.73 7.3367848 351.30 21.030 5698 94.9666667 260.09126
M16 leo tr 162 1.12 229 144 31326 33 1.2 176 49 787 2633 29.9 1.64 0.92 316.42 5.2710752 177.99 25.950 5943 99.0500000 188.28874
Gallo SA12 leo sg 139 1.03 75 135 22890 8 0.3 154 17 273 2304 11.8 4.63 0.90 763.00 12.3930698 148.64 24.630 1847 30.7833333 479.15539
MP5 leo smg 88 0.68 652 129 16820 8 0.2 89 32 771 3769 20.5 1.47 0.99 280.33 4.6541229 188.99 5.540 3614 60.2333333 172.66187
Milano 821 leo smg 83 1.11 84 75 16091 2 0.1 151 26 570 1706 33.4 2.37 0.55 459.74 7.4668213 106.56 25.650 2155 35.9166667 267.28538
Hauer 77 leo sg 8 0.50 79 16 1735 0 0.0 11 2 83 472 17.6 2.67 0.73 578.33 7.7455357 157.73 2.840 224 3.7333333 241.07143
AK-74u leo smg 7 0.39 200 18 1339 0 0.0 0 3 50 247 20.2 1.40 7.00 267.80 4.3615635 1339.00 1.540 307 5.1166667 166.12378
1911 leo p 6 0.86 28 7 684 1 1.0 48 0 13 101 12.9 6.00 0.12 684.00 5.8461538 14.25 4.180 117 1.9500000 307.69231
M60 leo lmg 3 1.00 5 3 511 0 0.0 16 0 11 75 14.7 3.00 0.19 511.00 5.2142857 31.94 19.600 98 1.6333333 183.67347
Diamatti leo p 3 0.75 4 4 780 1 1.6 4 0 26 63 41.3 3.00 0.75 780.00 11.6417910 195.00 16.750 67 1.1166667 268.65672
FFAR 1 leo ar 2 2.00 84 1 276 1 3.3 4 0 10 30 33.3 2.00 0.50 276.00 9.5172414 69.00 0.350 29 0.4833333 413.79310
QBZ-83 leo ar 2 2.00 81 1 514 0 0.0 36 2 76 554 13.7 0.15 0.06 39.54 0.6353523 14.28 9.990 809 13.4833333 22.24969
DMR 14 leo tr 2 2.00 25 0 300 1 9.1 8 0 6 11 54.5 2.00 0.25 300.00 6.5217391 37.50 1.840 46 0.7666667 260.86957
LW3 - Tundra leo sr 1 1.00 184 1 150 1 50.0 0 0 2 2 100.0 1.00 1.00 150.00 16.6666667 150.00 0.050 9 0.1500000 666.66667
M82 leo sr 1 0.50 32 2 150 0 0.0 8 0 0 2 0.0 1.00 0.12 150.00 2.1126761 18.75 2.220 71 1.1833333 84.50704
RPD leo lmg 1 0.50 44 2 203 0 0.0 8 0 4 18 22.2 1.00 0.12 203.00 5.6388889 25.38 0.819 36 0.6000000 166.66667
KSP 45 leo smg 0 0.00 52 2 123 0 0.0 31 0 4 357 1.1 0.00 0.00 17.57 0.2679739 3.97 8.830 459 7.6500000 0.00000
AUG leo tr 0 0.00 94 0 0 0 0.0 0 0 0 0 0.0 0.00 0.00 0.00 0.0000000 0.00 0.010 1 0.0166667 0.00000
All Weapons Dictionary
variable_aw definition_aw
player name of the player
K.D.Ratio amount of kills divided by deaths.during.use
Deaths The number of times a player has been killed by that weapon
HS. Headshot percentage. The amount of headshots divided by total shots
avg_life The average time of any life with that weapon before you get killed
mins_played Time played in minutes
score_min Quantity of score per minute played. Kills = 100 points, assists = 50 points

DESCRIPTIVE ANALYSIS OUR WEAPONS:

These charts above show some interesting information comparing all of our gameplay. This data also makes an argument for the best player. That player is me.

Data Comparison:

Base Stats
weapon Damage DPS Time To Kill Shots To Kill Effective Range RPM Mag Size ADS Reload Speed Muzzle Velocity Vert. Recoil Hor. Recoil Hipfire Accuracy gun_type
Pelington 703 110 99.0 1100 2 127.00 54 5 550 5.1 500 550 250 18 sr
AK74u 38 441.4 258 4 7.62 697 30 300 2.4 500 288 224 7 smg
Performance
Weapon player class Kills K.D.Ratio Deaths Deaths.During.Use Damage Headshots HS. Matches.Played Assists Hits Shots Accuracy Kills.min Kills.match Damage.min dps Damage.match avg_life seconds_played mins_played score_min
Pelington 703 leo sr 708 1.28 276 551 120090 331 14.1 1187 47 851 2352 36.2 1.09 0.60 185.32 3.087623 101.17 140.00 38894 648.2333333 112.84517
AK-74u leo smg 7 0.39 200 18 1339 0 0.0 0 3 50 247 20.2 1.40 7.00 267.80 4.361563 1339.00 1.54 307 5.1166667 166.12378
Pelington 703 mitch sr 30 0.52 299 58 5602 14 8.4 12 2 54 167 32.3 0.77 2.50 143.64 2.387894 466.83 7.85 2346 39.1000000 79.28389
AK-74u mitch smg 1 1.00 506 0 150 0 0.0 0 0 1 0 1.0 1.00 1.00 150.00 75.000000 150.00 0.00 2 0.0333333 3000.00000
AK-74u justin smg 2135 1.17 395 1819 374299 136 0.3 944 484 12779 42617 30.0 2.61 2.26 457.02 7.616992 396.50 124.00 49140 819.0000000 290.23199
Pelington 703 justin sr 3 1.50 88 2 613 0 0.0 12 1 6 14 42.9 0.60 0.25 122.60 1.952229 51.08 3.57 314 5.2333333 66.87898
AK-74u pat smg 985 1.10 578 892 173293 113 0.6 249 254 6076 20318 29.9 4.25 3.96 746.95 12.415317 695.96 24.15 13958 232.6333333 478.00544
Pelington 703 pat sr 598 0.99 257 606 94553 168 9.3 272 44 788 1815 43.4 2.24 2.20 354.13 5.900343 347.62 62.00 16025 267.0833333 232.13729
AK-74u owen smg 1755 1.12 1285 1573 312376 261 0.8 431 411 9793 31428 31.2 4.01 4.07 713.19 11.879221 724.77 20.46 26296 438.2666667 447.33039
Pelington 703 owen sr 50 0.50 428 100 9412 16 7.7 61 11 74 208 35.6 1.32 0.82 247.68 4.111839 154.30 5.35 2289 38.1500000 145.47837

Here we can see how a sniper and a sub machine gun can perform at weapon level 0. We can also see how we have performed with these weapons as the guns have leveled up.

Predictions

Part of what makes a good Call of Duty player is a positive K/D. For the average player, maintaining a K/D just above 1 is a challenge in itself. This means on a match by match basis, I am killing more times than I am getting killed. Pro players are another beast. These types of players have no problem maintaining K/D’s above a 2 and even higher. Objective time, communication, and game awareness are just some other factors that attribute to how good a player is. Looking at this bunch of variables can be overwhelming, so for now, we will see what variables can predict a positive K/D.

The variables I am going to be looking at are: headshots, headshot percentage, accuracy, average life, and score per minute. I expect these to attribute to a positive K/D over other variables. If we look at average life, we would think that the longer a person is alive means the longer they are not dying. So, we can only assume that they will be getting at least one kill if their average life is high in quantity of seconds. If this variable is not significant, then we can look at score per minute to see if, when they are alive, this player is actually producing kills and assists. Further, the amount of headshots, headshot percentage, and accuracy are important in predicting a K/D because how is a player supposed to have more kills than deaths if they cannot hit their shots. I am curious to see how significant these variables are in predicting a 1.0 K/D.

Heres a graph to see if there was a correlation between average life and a positive K/D ratio. To make the data more balanced, I filtered out to weapons that had at least 100 matches played. The results show that there is not a correlation.

This is interesting and shows some correlation. Generally, if the accuracy is above 30% the K/D is mostly above a 1, which is what I expected.

Now lets look at a true linear model.

## 
## Call:
## lm(formula = K.D.Ratio ~ Headshots + HS. + Accuracy + avg_life + 
##     score_min, data = all_weapons1)
## 
## Residuals:
##      Min       1Q   Median       3Q      Max 
## -0.26456 -0.10044 -0.01560  0.08478  0.34231 
## 
## Coefficients:
##              Estimate Std. Error t value Pr(>|t|)    
## (Intercept) 7.528e-01  1.818e-01   4.142 0.000199 ***
## Headshots   3.502e-04  3.078e-04   1.138 0.262679    
## HS.         7.173e-03  1.019e-02   0.704 0.486095    
## Accuracy    2.289e-03  5.228e-03   0.438 0.664053    
## avg_life    8.744e-05  7.996e-04   0.109 0.913528    
## score_min   5.022e-04  2.171e-04   2.313 0.026566 *  
## ---
## Signif. codes:  0 '***' 0.001 '**' 0.01 '*' 0.05 '.' 0.1 ' ' 1
## 
## Residual standard error: 0.149 on 36 degrees of freedom
## Multiple R-squared:  0.1816, Adjusted R-squared:  0.06798 
## F-statistic: 1.598 on 5 and 36 DF,  p-value: 0.1856

The result was surprising. The only variable that is somewhat significant is the score per minute. I can believe this because this variable does show the most impact this player had in a game. The higher the score per minute, the more kills and assists this player is producing in a small time frame. And the more kills in a small time frame could mean equal or less deaths.

THE END

Is there a best weapon? This is really up for you to decide. Each class has its ups and downs. Each weapon is unique from the next one in its class. But remember, Call of Duty online is team play, which means that a combination of weapons and classes is what’s going to be best when trying to win.