SWITRS: On What Days Do Motorcycles Crash?
A few months ago I wrote a post in which I explored when car accidents happen in California. This time I’m going to go through the same analysis but restrict myself to looking at accidents involving motorcycles. Motorcycle accidents are the original reason I tracked down the SWITRS data: my father rode motorcycles for years (he only recently stopped) and we wanted to better understand what sort of risks that brought.
I expected the accident trend for motorcycles to match the one I found when looking at cars. There I found that commute accidents accounted for the majority of accidents, and so holidays and weekends that most people have off result in fewer accidents. Motorcycles, we will see, do not follow this pattern.
One thing before we get started: the number of riders on a given day (or more accurately, the number of miles ridden by them) has the most impact on the number of crashes. If there are more riders, there are going to be more crashes. From now on I’ll treat the two numbers as equivalent, even though there are some confounding factors, like weather, which would change the ratio of accidents to number of riders on the road; I hope to look at these other factors in a later post.
As per usual, the Jupyter notebook used to perform this analysis can be found here (rendered on Github).
I selected accidents involving motorcycles from the SQLite database (discussed previously) with the following query:
This gave me 193,336 data points (accidents) to examine spanning 2001 through 2015. Just as before, accidents from 2016 are rejected because there is not yet complete data for the year.
Accidents per Week
For cars, I found that there was a decrease in accidents starting in 2008 as people stopped driving to work during the Great Recession. Apart from that, I found that the week-to-week rate changed relatively little, with holidays providing the largest increases and decreases. When I looked at just motorcycles, I expected to see a similar pattern. However, the trends (plotted below) are completely different.
There are far fewer accidents because there are far fewer motorcycles; there are about 27 million vehicles in California, but of those only 770,000 are motorcycles. There is also a strong seasonal effect—even in sunny California, motorcycle ridership drops drastically in the winter! And unlike for cars, there is not a large decrease due to the recession. Finally, there is an overall upward trend in the number of motorcycle accidents.
Commute accidents account for the majority of car accidents. However, this does not appear to be the case for motorcycles, because the numbers were relatively unchanged by the Great Recession; people kept riding at the same levels when out of work.
For car accidents, the days with the most accidents and least accidents were holidays. The largest number of accidents were on holidays where people went to work and then out afterwards, like Halloween. Motorcycle accidents do not follow that pattern. Instead, the holidays show quite disparate results: some holidays dip, some spike, others show almost no deviation from a normal day.
The summer holidays do not stand out; only Memorial Day is readily visible. Winter holidays, by contrast, show both peaks and valleys. I would interpret this as due to the seasonal weather:
- In summer, any day is a good day to ride.
- In the winter, the weather keeps riders off the road, except when a holiday gives them the extra motivation they need.
One final outlier to address: the sharp peak at the end of February is leap day. The peak not an error, but is a statistical artifact. The mean for all other days is calculated with
n = 15, but only
n = 3 for leap day.
Day of the Week
Car accidents happen less during the weekend, when people aren’t commuting.
For motorcycles the weekends are prime riding times, and so the number of accidents increases. If we think of weekends as a kind of mini-holiday, they provide a way to look at the same seasonal holiday phenomenon discussed above. Winter holidays showed high variance, so I would expect to see some weekends with high winter ridership, and some with low ridership. Summer holidays had low variance, so I expect to see similar ridership on all summer weekends.
The violin plots below show the distribution of accidents by day of the week over the 15 year period. They are divided into two seasons: summer (May–October) and winter (November–April).
There is lower ridership in winter over all (top row), as indicated by the central dotted line indicating average number of accidents. And we can see an increase on weekends; but during the winter, that weekend increase is small as compared with summer (bottom row). The winter distributions are more elongated than those from summer, meaning that on some days there are many riders, and on others there are almost none, just as we expected. Summer weekends, by contrast, have consistently high ridership.
We can conclude that weekend rider behavior does seem to track seasonal holiday riding behavior. And like the trends for holidays, the weekend results could be due to weather.
Motorcycle accidents do not follow the same trends as for cars. Motorcyclists continue riding even when they do not have a job to commute to. Seasons have a large effect on the number of riders out on the road. Motorcycle ridership has variance for winter holidays and weekends when the weather may turn against them. There are many more ways to explore motorcycle accidents—time of day, type of motorcycle, vehicle at fault—but those will have to wait for another day.
Update: Edited post for brevity, clarity, and correctness; see this git diff and this git diff.