Microsoft Word - ds2500_lab_geo.docx
DS 2501: Intermediate Programming with Data / Lab Practicum
Prof. Rachlin
Northeastern University
Where are the trees?
The attached program trees.py reads the trees.geojson file containing the geographical coordinates of
over 200,000 trees in the Boston city limits and plots them on a map. For this lab I would like you to
extend the program by also plotting the location of hospitals and colleges. The geojson data has been
provided.
a) Add markers for colleges and hospitals. For trees, it was sufficient to fill in a single pixel in the
1000x1000 numpy a
ay. For colleges and hospitals to show up on the map you will want to fill in
a square a
ay of pixels in and around the desired location. (I would try a 5x5 square). For
example, instead of just setting i,j to 1 you might want to try setting i-2…i+2, j-2…j+2 all to some
specific value to make the “position” show up more clearly. Choose a distinctive value (color) for
colleges and hospitals.
) Pinpoint Northeastern University on your map and answer the following question: How well are
trees on the Northeastern campus in Boston represented in the tree dataset? Include a triple-
quoted comment in your updated code.
Submit your new program: boston_yourname.py (.ipynb ok too) and your visualization.