Halo 5 February Season Ranks

Inspired by a post on the Halo subreddit showing player rankings in different multiplayer playlists in Halo 5 I decided to do something similar. I used the Halo 5 API R package I wrote a few months ago got to work collecting as much data as I could from users.

The public API has several limiting factors. First is that there's no easy way to simply get a large list of users currently playing Halo. Microsoft doesn't make public player activity numbers public so having easy access to this would probably be against their intention. To get around this I looked at my recent game history, and took all the names of the players of my opponents. Then looked at all their recent game histories. Quickly I was able to get a list of a little over 17,000 unique names that played at least some form of matchmaking.

The second limiting factor is that Microsoft only allows 1 request per second. This isn't really a huge hurdle as I just left it running overnight to gather the data. It would be nicer if there was a faster option though.

Anyways here are some results from the Team Arena, Slayer, and SWAT playlists. Keep in mind that when this data was gathered it had only been about 10 days since the February season went live. I'll try to do something like this again at the end of the month to see if there are any major changes.

Team Arena:



From what I've heard of 343i's Halo ranking system a near normal curve like this is to be expected. With gold and platinum ranks containing the majority of players. There are some spikes at tier 1 of each rank. This is due to the fact that in Halo 5 you cannot rank down out of a division until the next season. So if players are improperly placed into diamond or go on a hot streak and make it into diamond, they'll just end up sitting at diamond 1 most of the season. With how quick the seasons in Halo are (historically slightly over a month for pre-season and January) I don't think this is that bad of an issue, as it does relieve a little bit of 'ladder anxiety' from the matchmaking knowing that you won't rank out of a division if you go on a losing streak.

Another interesting thing is the large percentage of players currently in onyx. I think this is likely due to my small-ish sample size of just over 7000 players for Team Arena, and because it's still early in the season. As the season goes on the more casual players will finish their placement matches and the relative amount of onyx players will probably decrease.

I've also included a boxplot showing win rates of players in the different ranks. Nothing really surprising; as players rank increases so does their win rate. Though from my understanding the matchmaking system should try and give players a close to 50% win rate, so again, perhaps this will even out as the season progresses.

Slayer:



Nothing too different in the slayer playlist other than it seems skewed towards higher ranks. I'm actually a little lost as to why this is. My best guess is that players who play Slayer might be more competitive than those that play Team Arena and combined with it being early in the season it's likely to produce these results. But again, I don't really know for sure. Maybe you have some suggestions?

SWAT:



Compared with the other two playlist there is hardly anybody in SWAT above platinum. From what I've heard 343i have done some tuning for ranks in SWAT which is probably why it looks so different than the others.

Well I hope you enjoyed these. Comments and suggestions on what other kinds of data from Halo 5 might be interesting are definitely welcome. What I really want to do is make some heatmaps (still) but 343i seems like they do not want to make the necessary data to do this available. Maybe soon... hopefully.

Tags:


Halo 5 API: Profile Viewer



Instead of playing Halo, I've been having fun with 343's public Halo 5 API. There's a remarkable amount of information that you are able to pull from them; I'm quite surprised.

This is my first time doing anything like this so, since I'm already familiar with it, I used R and Shiny to throw together a little dashboard to let you view basic arena statistics. I might add more functionality but probably nothing serious unless it gets crazy popular for some reason. More importantly, to go along with the Shiny app, I'm working on a nice R package to allow others easy access to 343's generous amount of game data. Hopefully I'll be able to finish it up with a couple weeks and get it uploaded to CRAN or github at the very least.

I was really hoping I could do a heatmap of where most deaths occur in each level. Kind of like was Bungie did for Halo 2. Unfortunately I didn't see any of that data available through the API but maybe in the future.

Check out the Shiny app and code to come!

R package to access the API is now up on my github!

Tags:


I2C and the ADXL345 on Raspberry Pi

Still mucking around with the Raspberry Pi, I wanted to dip my toes into using the I2C bus to interface with sensors. The sensor I'm going to use to demonstrate here is the ADXL345 accelerometer from Analog Devices. It actually supports I2C or SPI but the RPi only allows 1 SPI device so I wanted to use I2C instead.

To enable I2C on the Raspberry Pi I followed this tutorial.

Hooking up the sensor is simple enough. Power (3.3v), ground, and the two I2C connections: SDA (data) and SCL (clock). However in addition to these 4 connections the sensor needs 2 additional connections. The pin labeled CS goes to power (3.3v) and the pin labeled SDO goes to ground. This is needed to put the sensor into I2C mode instead of SPI.



Now comes the fun part, interfacing with the sensor. For this we will refer to data sheet available here. Looking at the register chart, there are a few things we need to set up before we can actually get data from the sensor.

First we enable i2c; set the address of the sensor, the ADXL345 has address 0x53; and set the clock divider, 2500 gives use a clock frequency of 100kHz which is standard for I2C.

Next we need to write to the POWER_CTL register located at 0x2D. We write 0x08 to it which enables the measurment mode on the ADXL345. Disabling the measurment bit would put the sensor into standby mode. Standby mode powers up the sensor but won't take measurements. This would be useful in a situation where power conservation was an issue.

Finally we must tell the sensor what type of data we want. Writing 0x0B to the DATA_FORMAT register located at 0x31 means we want to use the full resolution of 13-bits with a g range of +/-16g. There are several different ranges to choose from (2, 4, 8, 16) but choosing anything else limits the number of bits to 10 instead of 13. And more bits is always better.

Check out the register descriptions in the data sheet and you will get a much better understanding of what I just described above.

Now that all the initialization is out of the way it's time to actually get from readings from the sensor. The readings are stored in 6 bytes starting at 0x32. There are 2 bytes for each axis. It looks something like this:
DATAX0 - DATAX1 - DATAY0 - DATAY1 - DATAZ0 - DATAZ1
Where DATAx0 has the least significant bits and DATAx1 has the most significant bits. It's important to do a single read of all the registers to minimize any change in the data that might happen between reads.

So combine the bytes and we've got a result from the sensor. Since we're using full resolution mode we will get a range of -4096 to 4095 for each axis and dividing the result by 256 gives the G value. If the sensor is lying flat on a table it should read 1G in the z-axis due to gravity.

And that's pretty much it. Now you can interface with I2C devices from your Raspberry Pi! I wrote a simple program with will flash an LED whenever there is more than a G in either X-axis direction that I hope illustrates what I've explained here.

http://notez.ca/downloads/accel.c
(I've since stopped paying for a server so the file is no longer available. Email me if you are interested to see the code)

Tags:


Raspberry Pi Online Weather Station



I've recently been given a Raspberry Pi and have been trying to come up with a good idea about what to do with it. I eventually decided on a Raspberry Pi powered weather station.

The idea is use the experience building the weather station to expand my knowledge in programming, electronics, meteorology, and data collection.

So far all I have is a small temperature sensor set up that takes a reading every 5 minutes. I'm looking to soon add an anemometer (wind speed sensor), and precipitation sensor. The readings from the Raspberry Pi are uploaded to my database where I use R Shiny to pull the data and present it on a webpage. With more data shiny makes it super easy to come up with interesting statistics and graphs.

Shiny app:
http://cluoma.shinyapps.io/ShinyTest

Raspberry Pi Code:
http://notez.ca/downloads/temperature.zip
(I've since stopped paying for my own server so both links will no longer work. If you interested in the code for either please email me)

Tags:


Notez - A Dumb Notes App



I decided to brush up on my SQL so I've started a simple little notes app that I call 'Notez'. Once I get the web version running the way I want my idea is to make a native iPhone app to access the same database. This way you'll be able to do neat things like add alarms and notifications to notes to remind you about things.

It's very simple right now and I have no way for users to create accounts so you can login with email 'public' and no password to try it and see what others have written.

http://notez.ca
(I've since stopped paying for my own server so the link is now dead.)

Tags: