Where to Spot New York Hipster: A Preliminary Gentrification Analysis

Melinda Martinus
Data Mining the City
3 min readOct 20, 2017

My project aims to spatially visualize hipster trend in New York. People often say that neighborhood such as Williamsburg, Greenpoint, Astoria, East Village, and so forth are representations of hipster area. Such assumption inspires me to do this project.

Hipster can be spatially visualized! I scrapped ‘hipster stuff’ location such as #coldbrew, #avocadotoast, #bikramyoga, #coworkingspace, #kombucha, #usedbookstore, #vintageclothingstore, #vinylstore ‘organically’ (manually) from google map and geocoded those data. Google map gave me 461 data in total for those hipster stuffs (coldbrew=36, avocado toast=105, bikram yoga=32, kombucha=3, vintage clothing store=75, coworking space=63, vinyl store=33, used bookstore=119).

Please find the coding method below.

Method

import spatialpixel.mapping.slippymapper as slippymapper
import csv
import spatialpixel.data.geojson as geojson

def setup():
size(900, 900, P2D)

global nyc, zoom
zoom=12
nyc=slippymapper.SlippyMapper (40.721182, -73.930587, zoom, "carto-light", width, height)

with open ('hipster stuffs.csv') as f:
reader = csv.reader(f)
header = reader.next()

for row in reader:
try:
latitude = float(row[2])
longitude = float(row[3])
hipsterstuff = row[0]

if hipsterstuff == "Coldbrew":
nyc.addMarker(latitude, longitude,marker({'text':row[0],'R':247,'G':239,'B':67}))
if hipsterstuff == "Avotoast":
nyc.addMarker(latitude, longitude,marker({'text':row[0],'R':0,'G':200,'B':0}))
if hipsterstuff == "Bikram Yoga":
nyc.addMarker(latitude, longitude,marker({'text':row[0],'R':247,'G':12,'B':28}))
if hipsterstuff == "Kombucha":
nyc.addMarker(latitude, longitude,marker({'text':row[0],'R':200,'G':242,'B':80}))
if hipsterstuff == "Vintage Clothing":
nyc.addMarker(latitude, longitude,marker({'text':row[0],'R':247,'G':12,'B':142}))
if hipsterstuff == "Coworking Space":
nyc.addMarker(latitude, longitude,marker({'text':row[0],'R':242,'G':125,'B':29}))
if hipsterstuff == "Vinyl Store":
nyc.addMarker(latitude, longitude,marker({'text':row[0],'R':247,'G':37,'B':5}))
if hipsterstuff == "Used Bookstore":
nyc.addMarker(latitude, longitude,marker({'text':row[0],'R':185,'G':206,'B':188}))
except:
pass
print hipsterstuff

def ntacode(geojsonFeature):
return geojsonFeature['properties']['ntacode']

neighborhoods= geojson.SlippyLayer('Neighborhood Tabulation Areas.geojson', styler=ntacode)
nyc.addLayer(neighborhoods)
nyc.render()

def draw():
background(255)
nyc.draw()

class marker(slippymapper.DataMarker):
def drawMarker(self, x, y, marker):
txt = self.data['text']
marker.fill(self.data['R'],self.data['G'],self.data['B'])
marker.ellipse(x, y, 7, 7)
# making the marker interactive. When you hover the market you get the text
if dist(x, y, mouseX, mouseY) < 5:
# setting the marker text as the tweets text and its position and color
marker.fill(0,0,0) #textcolor
marker.text(txt, 5+x,y)

def mouseClicked():
global nyc, zoom
lon = nyc.xToLon(mouseX)
lat = nyc.yToLat(mouseY)

# making zoom in
if mouseButton == LEFT:
zoom += 1
# defining maximum zoom in
if zoom > 18:
zoom = 18
# making zoom out
elif mouseButton == RIGHT:
zoom -= 1
# defining maximum zoom out
if zoom < 1:
zoom = 1


nyc.setCenter(lat, lon)
nyc.setZoom(zoom)
nyc.render()

A Case Study: Bushwick Gentrification

Bushwick is known as one of the rapidly gentrified neighborhoods in New York City. It’s probably true! The streetviews I retreived using this method seem to depict that those dots are located in residential area not commercial area. The issue of displacement would be real if the number of hipster things keep growing in that area in the future.

For further analysis, I would like to correlate my hipster stuffs data with minority population, median income, and median rent to validate my hypothesis that hipster phenomenon is deleterious for society.

--

--