Posts

Showing posts with the label Bayesian Modeling

Which Game is the Scariest? Alien: Isolation, Dead Space, Dead Space 2, or Silent Hill 2? An R Halloween Analysis!

Image
I wanted to get into the halloween spirit by doing some kind of horror themed analytics post. The idea of combining R, data analytics, and the macabre isn't as straightforward as some may think (yes, that was a joke). While I don't care for horror movies, for some reason, I enjoy survival horror video games. Not playing them, of course. I'm far too squeamish for that. I usually watch youtube videos of other people playing them to spare myself a panic attack. I'm the kind of guy who would start playing the game and once the atmosphere became intense, I would just go, "NOPE", turn off the game and walk away. Of the survival horror games I've seen, the Dead Space franchise is up there. I also love the Alien franchise, though that franchise has suffered from a number of awful releases (including movies). Alien: Isolation is a gem, whose intense atmosphere makes every footstep nerve-racking. Lastly, I wanted to include another game that I haven't see

Simple Bayesian Model (T-test) in R using either WinBUGs or JAGS.

Image
WinBUGs and JAGS (Just Another Gibbs Sampler) are convenient and effective tools for estimating bayesian models for your data. Both use an openBUGs style syntax, although they do have their differences (e.g. censored data, or matrix operations). Even more convenient is that there are packages that allow you to pass BUGs syntax, call the Gibbs sampler, and pull the MCMC chain(s) back all within R. For me, the choice of whether to use WinBUGS, or JAGS (or openBUGs for that matter) is more a question of what OS you are running. WinBUGs is a Windows application and JAGS runs on OSX. I've never attempted to run these on Linux, so if anyone knows, feel free to provide that in the comments. If you need to obtain WinBUGS or JAGS, click on the hyperlinks to download them. The data I'm using comes from the 2010 US Census Data. It contains the median age for men and women per "place". In census language, "place" typically refers to cities or towns. Some cleaning