Packages and Data

Number of Breaks Per Mile by Material

This graph is made from workorder data collected by the Ashland, WI Public Works Department from 2004-2019. This past Winter, I worked as an intern for the public works department plotting water main breaks in GIS. I exported the data from GIS into a .csv file to create my graphs. The data include information about pipe material, pipe diameter, installation date, break date, etc. The American Waterworks Association has set a standard of 25 breaks/year/100 miles (.25 breaks per mile) of pipe as a way for public works departments to manage their assets. For Ashland, the standard is 14.75 breaks per year for our 59 miles of pipe (also .25 breaks per mile). Anything above this number indicates pipe replacement is necessary, so knowing which pipe material is producing the highest number of breaks allows the public works department to shift their focus to the problem areas. In essence, the question that I am trying to answer is: Which pipe materials are above the maximum number of recommended breaks per mile?

#R> # A tibble: 7 x 3
#R>   Material                   freq    KUB
#R>   <fct>                     <int>  <dbl>
#R> 1 Unknown                      16 0.286 
#R> 2 Cast Iron                   122 2.18  
#R> 3 Copper                        1 0.0179
#R> 4 Ductile Iron                 26 0.464 
#R> 5 High Density Polyethylene     1 0.0179
#R> 6 Lead                          1 0.0179
#R> 7 Polyvinyl Chloride            2 0.0357

The data show that cast iron pipes break much more than every other type of pipe material, and both cast iron and ductile iron pipes exceed the recommened number of breaks per mile. Therefore, efforts should focus on replacing pipes with these material types first. I chose to use a bar plot because the values on the x-axis are discrete. The colors I chose are colorblind friendly.

Number of Breaks by Decade of Installation

This graph seperates the number of broken pipes per year by the decade that the pipes were installed.This allows public works managers to identify the age of pipes that are the most in need of replacement.

The data show that the pipes that have been breaking the most between 2004-2019 were installed in the 1880s and 1890s.This makes sense as these are the oldest pipes, and these old cast iron pipes are the most abundant type of pipe that Ashland has. I chose to facet by decade to highlight the age of the pipes. It is important to note that the data for some of these years are incomplete, so the number of breaks in some years will be much lower than others, which makes the graphs look a bit wonky, but real life data are not always pretty.