Seasonal Virgin River Narrows Discharge

This April I’m visiting Zion National Park, one of North America’s most interesting locations to explore geologic formations. One such venue in the park is an iconic hike referred to as The Narrows: The Narrows in Zion National Park It’s surely even more sensational in person. Unfortunately, there’s a catch: the Virgin River, a Colorado river tributary that shaped the distinct rock walls of The Narrows, has seasonal water level changes that can force hikers to trek waist deep in the river or close the route entirely.

Wisconsin State Hex Grid - Mapping 2016 Presidential Results

NEAT PACKAGE ALERT! My 1st R package! Automatically turn geospatial polygons like states into regular/hexagonal grids #rstats #ggplot2 — J Bailey (@iammrbailey) October 31, 2017 I’ve been thinking about implementing something like this for a while - got excited by this tweet I thought I would do some exploring and write out a post over the weekend. Creating a county-level hex grid of Wisconsin makes for a perfect supplment to my earlier post about mapping the 2016 Wisconsin presidential results.

Makeover Monday: WSJ Measles Vaccination Chart

Last week I wrote a post about recreating the WSJ measles vaccination chart as an animated cartogram - you can check out the full write-up of the development here: It was featured on DataCamp across all their social media platforms - pretty neat! A comment from one of the readers (which disqus seems to have overwritten as I was re-initializing my site) read as so: Your measles chart is a beautiful piece of work!

Animated Line Chart from Condition of Education 2017 Data Release

Animation seen here! New from #COE2017: 21% of students reported being bullied at school in 2015, a ↓ from the 28% reported in 2005. — NCES (@EdNCES) May 3, 2017 Full image: COE 2017 Bullying Line Graph Animation Interested in learning more? Hire me to consult on your next project, follow me on twitter, leave a comment, or contact me via email. All inquiries welcome!

Reproducing the WSJ Measles Vaccination Chart Using R

Mastering Animation in R Recently I’ve been working on creating gif animations for social media: New from #COE2017: 21% of students reported being bullied at school in 2015, a ↓ from the 28% reported in 2005. — NCES (@EdNCES) May 3, 2017 It’s pretty addicting! And not as complicated as it appears. Let’s walk through the creation of a gif using R. Wall Street Journal Measles Vaccination Chart One of the more compelling data visualizations produced in recent years is the following representation of measles incidence from 1928 to 2003 produced by the Wall Street Journal graphics team:

Mapping Wisconsin Presidential Election Results

“Your home state did us no favors…” As a Wisconsinite transplanted into the highest density of left-leaning voters in the country (District of Columbia) I’ve heard from several friends over the weeks in the aftermath of the US presidential election that voters in my home state should shoulder responsibility for contributing to Donald Trump winning an electoral majority. The “winner-take-all” basis in which electoral votes are allocated means the margin of victory in each state is null - extra votes don’t matter - which contributes to an outcome in which a winning candidate can have fewer total votes than another nominee.

NBA Draft Odds Plot

Original Source I was scrolling twitter and noticed this tweet from David Sparks - Director of Basketball Analytics for the Boston Celtics: With thanks to @hadleywickham, @hrbrmstr, and @ColorBrewer. #rstats — David Sparks (@dsparks) April 22, 2016 With his obligatory shoutouts to Hadley Wickham and BoB Rudis, I felt compelled to reproduce the plot in RStudio and get some ggplot2 code out there open-sourcing his work. Package Dependencies and Data Powered by RMarkdown, knitr, and Jekyll

This is an R Markdown document. Markdown is a simple formatting syntax for authoring HTML, PDF, and MS Word documents. For more details on using R Markdown see Spend a few months documenting code scripts in RStudio and you’ll have surely seen those introductory lines numerous times. This is also a R code script. And a markdown document. And an HTML page. All of which are generated within one .

sabr - R package

The sabr package connects the Lahman SQL Database with functions used in calculating offensive performance in the MLB, namely wOBA. Created by Tom Tango and popularized in The Book: Playing the Percentages in Baseball, wOBA uses yearly MLB performance to weigh offensive measures relative to league value. This package offers the following capabilities: Retrieves the most up-to-date wOBA measures from 1871-2015 Queries yearly and career offensive performance from the Lahman SQL database Calculates a player’s seasonal wOBA performance Installation: Download the latest development version from github:

Visualizing Video Games Throughout History

Call of Duty :: Frank Underwood // Frogger :: George Costanza // Shinobi :: Wu-Tang Clan // Super Nintendo & Sega Genesis :: ??? Video games have long infiltrated popular culture. This article will attempt to explain that reach. Inspired by FiveThirtyEight's great article "Designing the Best Board Game on the Planet", I set out to extend this methodology to video games. The focus of 538's research related to a robust data set pulled from BoardGameGeek, an exhaustive collection of board games contributed by it's passionate users.

Kris Bryant Performance Projection

A dynamic rCharts visualization displaying performance projections for Kris Bryant based on his 10 most similar career MiLB comparable players. Read more at You can change the y-axis parameters by selecting the performance measure you’d like to visualize. Additionally, hover over the points to see player details, and select players in the legend to show or remove their data from the graph. Year Age LevEq G PA AB R H X2B X3B HR RBI SB CS BB SO BA OBP SLG OPS Count 2015 23 3 130 548 489 76 138 32 5 24 83 9 4 47 105 0.

Working with Minor League Similarity Scores

There are some people who see baseball players that way-each one is unique, absolutely not interchangeable with another. I don't deny the validity of that approach-but if you take that tack, then you can't turn around and argue that your player should be in the Hall of Fame because his numbers are just as good as this other player's. "Similarity" is a complex concept, and two players who are not statistically similar may be profoundly similar in some other way.

Let's Make a Minor League Baseball Database!

Baseball is a game of numbers, some more accessible than others. Rates, averages, linear weights, aging curves, and WAR are only a few of the myriad statistics influencing decision makers in MLB franchises. An endless amount of data is accessible to the average fan at many sites, most notably the Lahman Baseball Database, which is the most robust catalog of MLB player statistics available to the public. One area of relatively limited accessibility to the average fan is statistics for Minor League players.