When you've exhausted every last mote of flavor from a piece of gum, you have two options. You can be a polite, productive member of society, wrap your gooey garbage in a small piece of paper, and throw it in a trash can. Or you can be a jerk and toss it on the ground (or under a desk, on a wall, etc.). Most of us have probably played both roles.

Here in New York, decades of the second choice — laziness, discourtesy — are on display anywhere you walk. Most every stretch of sidewalk is heavily speckled with dark black spots, each one representing a cast aside piece of gum mashed into the pavement by the slow but sure stampede of pedestrian traffic.

If you've forgotten this unsightly feature of the New York sidewalk, here are photos at three prominent locations in the city. Even elegant Gramercy Park isn't immune from Gotham's messiness pandemic (although it looks a lot better than Grand Central!):

Grand Central; Union Square; Gramercy Park

At first it seems almost impossible, and a little embarrassing, that so much discarded gum could exist in this city. How can a piece of gum not only be littered, but possess the persistence to stay stuck to the sidewalk and not ride elsewhere on some sorry soul's sole?

Let's try to actually simulate years of passersby on a piece of pavement, since an appreciation for the endless drumbeat of time and volume can often normalize feats of accumulation that had at first seemed unlikely. So even if we assign a one-in-a-million chance to a pedestrian tossing her gum on the sidewalk, five years' worth of walkers turns blank pavement at a popular location into its familiar dalmated state:

More precisely, the propagating dots in the above GIF, assigned a random position and radius upon conception, represent five years of 200,000 weekly pedestrians crossing a plane with a 0.000001 probability of leaving a stain. In total, the 260 simulated weeks yielded 54 gumspots; in an additional hundred runs of the same experiment, 95 simulations netted at least forty. And although our trial location may be digital fiction, it is realistic: dozens of commercial districts in this city host this much — or more — regular foot traffic.

More interesting than the ubiquity of gum stains in this city is the distribution. Not every square foot of concrete wears an equal appearance. Some have fresh, unblemished faces; others suffer from a heavily spotted complexion. Where are there imbalances? And why? Those follow-up questions can probably be solved in that order.

And so: we count spots. The first challenge is picking our sample. In an ever-changing cityscape, it's important to build in a semblance of continuity into our experiment. It'd be best to find a long stretch of sidewalk and observe our gumspots rise and fall with the gradual and continuous variation in the underlying neighborhoods. Something like an avenue.

Park Avenue is too long for a single identity

For decades, Park Avenue has served as a metonym for old money. Even as other areas of the city have bloomed more affluent, a 2014 study listed Lenox Hill and Carnegie Hill as the first and fourth richest neighborhoods in Manhattan, as measured by mean household income. Park Avenue crosses through both, a centuries-old cable of elevated wealth.

That reputation will be addressed by counting gum spots down the entire boulevard. But so will the other identities of Park Avenue, which runs all the way up to 132nd street before being absorbed by the East River as the borough tapers to the north; and all the way down to 17th Street, morphing from residential to commercial along the way before being rechristened Union Square East.

In the spirit of statistics (and with respect to the statistician's time), we shouldn't examine every inch of Park Avenue but rather a (hopefully) representative sample. In particular, systematic sampling, which instructs us to select every kth element from a population, is a good fit for our analysis, since the sidewalk is parceled out into mostly consistent, manageable pieces, called flags or slabs.

Each is approximately five feet by five feet. Usually three or four columns of flags comprise the full width of a block. One runs along the curb and is the home to pretty things, like trees, and not so pretty things, like dog shit. Its opposite runs along the side of a building and serves as the boundary between public and private property. In the middle are one or two vertical lengths that we will pluck for our sampling.

Most blocks are divided into columns, which can be used for sampling

Before we get into the numbers, let's acknowledge the imperfection of the data (and, by association, the difficulty in gathering it). Flags of pavement are not all the same size. Some are as small as nine square feet. Some have giant cracks running through them. Some fancy ones are patterned with a diagonal lattice. This means that some gumspot totals will be taken from smaller areas, and blocks will have different sized samples.

Worse, the pavement is made out of different materials that can make identifying a gumstain nearly impossible in some scenarios. Unpigmented pavement is a breeze — the blackened dots starkly contrast their smooth, pale canvas. But some material, called aggregate, is a mix of concrete and pebbles with the explicit purpose of "camouflag[ing] dirt and gum in high-traffic areas," as noted by nyc.gov's write-up on their materials. A lot of good that does us! Check out these three snaps of different flags:

Easy → Hard → Very Hard

The keys to overcoming these challenges are diligence and hope. Diligence in that we must standardize the collection of data by decreeing that stains must be of a threshold size and darkness to even be considered gumspots; and hope in that we'll pray to find patterns stark enough that they couldn't be explained by the random mistakes of our brave observer. That is, a study this problematic can be saved by discrepancies of great enough magnitude to bowl over the probable incidence of error in data-collecting.

Which is exactly what happened. Let's take a look at the gumspot totals from 17th Street all the way up to 130th:

The light blue line represents the raw average number of spots per flag block-by-block along the horizontal axis. You can gather the major trends from this line, but also included is a "smoothed" version, which averages each block with its two neighbors to the north and south (to make five blocks in total). This approximating function leaves our model less exposed to rapid, radical shifts in the data and the distracting spikes they create graphically.

You realize a few things when counting gum spots for five miles, beyond the sneaking possibility that you're slowly going crazy. The last flags on each block usually have more spots than the rest of the block, as their position on the corner bears traffic in two directions. Indeed the first data point for each block, or the one consistently closest to the corner, had on average a full spot more than the rest of the block (normalized to the mean of each block, the corners had an average gumspot z-score of +0.3).

Many more patterns went unmeasured but not unnoticed. Trash cans, newspaper boxes, and bus stops all attract gum. Bumpier surfaces, such as those of aggregate concrete, seemed more effective at repelling gum. Whether that's because gum sticks less easily to them, is easier to scrape off, or is just harder to see is unclear.

A larger, more important discovery was that commercial districts, roughly defined as blocks south of 6oth Street or north of 120th Street, are much more heavily spotted (12.0 spots per flag) than residential (7.6). The trend is intuitive: blocks with storefronts produce more waste, receive more foot traffic, and serve people less incentivized to be neat than they might be at home.

The problem is that all this commercial filth obscures subtler trends. The rising gum tide in business zones is itself a notable finding, but it drowns some of the more interesting discrepancies in spot totals. Case in point: 28th Street and Park Avenue is a vastly different intersection from a geographical and socioeconomic stance than the one at 124th Street and Park Avenue. But both are popular commercial locations that collect gum at a rate of about forty spots per flag, preventing us from seeing some of those differences manifest in the sidewalk.

Let's focus on the residential stretch of Park Avenue then, which conveniently lies more or less entirely between 60th Street and 120th Street. The most localized data for per capita income that the US Census Bureau publishes is for "block groups," which, in New York, typically span a few blocks in each direction and account for several thousand inhabitants. Thus, we can overlay a pretty precise per capita income graph on our plot and see how it corresponds with the gumspotting data:

This confirms a suspicion you might have had since the beginning of this post: nice neighborhoods, like those aforementioned clusters of extreme wealth in the Upper East Side, have fewer gum stains on their streets. Poorer neighborhoods, like the ones north of 96th Street, are heavily gummed. There are even microtrends within the snobby areas. 70th Street sees a $100,000 hike in per capita income along with a downtick in gumspots; the spotless haven between 93rd and 94th Streets is mirrored by a local peak of $166,621.

By ditching geographic sequence and simply plotting blocks as gumspots versus per capita income, we can more easily see their relationship:

The two have a correlation coefficient of -0.78, which scores as a strong, negative linear relationship. The trendline overlaid on the graph has a slope of -0.0000465, which means that on average every additional gumspot comes with about a $20,000 drop in per capita income.

Looking at these graphs, it'd be easy to condemn the impoverished as messier or ruder than the wealthy elite that live south of 96th Street. And maybe it's true that someone worth four figures is more likely to toss their gum on the sidewalk than someone worth seven.

But there are more factors at play here. Remember that many people beyond the immediate residents use these blocks and contribute to their appearance. It's likely that there's some broken-windows style cycle in play whereby people are more likely to toss their gum on streets that are already heavily spotted. Moreover, a block surveilled by a few uniformed doorman is a riskier place to commit peccadillos of this variety. Plus wealthy professionals who only see the inside of a black car between their apartment and their office never even have the opportunity to walk their neighborhood and generate gumspots.

Ultimately, though, the differences probably lie not in the rate that gum is dropped but in the rate that it's cleaned up. Even though the sidewalk is public property, its maintenance falls upon owners of the abutting buildings. Rich property owners in Lenox Hill with an image to upkeep and wealthy residents to impress will pay professional cleaners thousands of dollars to power-scrub their streets on a regular basis. Property owners in East Harlem, perhaps bereft of both the inclination to wash their pavement and the necessary funds, are less likely to do so.

These guys probably make a lot of visits to Lenox Hill.

So keep your eye out for gumspots next time you're walking through the city. Because even though your parents probably said to keep your head up when walking around, now and then there are lessons to be learned by looking down.

Thanks for reading the inaugural perplex.city blogpost! New posts will come out every Thursday. All scripts and data used for this post can be found at https://github.com/PerplexCity/Gumspotting. Questions? Want to write a post? Email [email protected]