शुरू करेंमुफ़्त में शुरू करें

Create a folium location from the urban centroid

In order to construct a folium map of the Urban Residents neighborhood, you need to build a coordinate pair location that is formatted for folium.

यह अभ्यास पाठ्यक्रम का हिस्सा है

Visualizing Geospatial Data in Python

पाठ्यक्रम देखें

अभ्यास निर्देश

  • Print the head of urban_polygon.
  • Store the first occurrence of center as urban_center and print urban_center. This has been done for you.
  • Create an array from urban_center that reverses the order of longitude and latitude. Call this urban_location.
  • Print urban_location. This has been done for you.

इंटरैक्टिव व्यावहारिक अभ्यास

इस अभ्यास को इस नमूना कोड को पूरा करके आज़माएँ।

# Print the head of the urban_polygon
print(urban_polygon.____())

# Create urban_center from the urban_polygon center
urban_center = ____.____[0]

# Print urban_center
print(urban_center)

# Create array for folium called urban_location
urban_location = [urban_center.____, urban_center.____]

# Print urban_location
print(urban_location)
कोड संपादित करें और चलाएँ