Oct-28-2020, 03:09 PM
Hi,
I am trying to use folium and pandas and I ran the following script under ubuntu 18 with python3 under geany :
Thanks for your help
I am trying to use folium and pandas and I ran the following script under ubuntu 18 with python3 under geany :
#! python3 # coding: utf-8 ''' https://www.pluralsight.com/guides/map-visualizations-in-python-using-folium ''' import os.path, sys import folium import pandas racine = '/mnt/0ea0b27f-3be6-4d2c-b157-a62559e56142/' fich_csv = 'python3/prog/gpx/csvfile' franchises = pandas.read_csv(racine+fich_csv) print("--", franchises) #view the dataset franchises.head() center = [-0.023559, 37.9061928] map_kenya = folium.Map(location=center, zoom_start=8) #display map map_kenya for index, franchise in franchises.iterrows(): location = [franchise['latitude'], franchise['longitude']] folium.Marker(location, popup = f'Name:{franchise["store"]}\n Revenue($):{franchise["revenue"]}').add_to(map_kenya) #display the map map_kenyaMy problem : nothing is displayed.
Thanks for your help