title: How to use different colour to plot in folium map?
body: <p>So i have many csv files each one of them has three columns.</p>
  <ol>
  <li>latitude</li>
  <li>longitude</li>
  <li>distance</li>
  </ol>
  <p>for example:
  car1.csv</p>
  <pre><code>lat     long      total_dist
  23.33   73.32.       0
  23.45.  73.34.       10
  23.64.  73.53.       16 ---&gt; #cumulative sum as car1 travels
  #similarly there it for car2,car3,car4 etc
  </code></pre>
  <p>so i concatenated these csv file into one data frame to plot map</p>
  <pre><code>import pandas as pd
  import folium
  from pathlib import Path
  import glob
  
  path = r'C:/Users/Desktop/Sample/car_new' # use your path
  all_files = glob.glob(path + &quot;/*.csv&quot;)
  
  li = []
  
  for filename in all_files:
      df = pd.read_csv(filename, index_col=None, header=0)
      li.append(df)
  
  car_locations = pd.concat(li, axis=0, ignore_index=True)
  
  
  car_locations = car_locations[[&quot;Latitude&quot;, &quot;Longitude&quot;,]]
  
  
  
  map = folium.Map(location=[car_locations.Latitude.mean(), car_locations.Longitude.mean()], zoom_start=14, control_scale=True, tiles='Stamen Terrain')
  
  folium.PolyLine(car_locations, color=&quot;red&quot;, weight=2.5, opacity=0.5).add_to(map)
  
  
  map
  </code></pre>
  <p>i want set conditions like this</p>
  <pre><code>if(total_dist &gt; 120):
  #plot green line on map
  else:
  #plot red line
  </code></pre>
  <p>This is how it should look i have posted a link to the image.
  <a href="https://imgur.com/a/07rxQ9l" rel="nofollow noreferrer">https://imgur.com/a/07rxQ9l</a></p>