title: How to display bokeh legends with scatter plots using a dataframe?
body: <p>I have the following plot:</p>
  
  <pre><code>import pandas as pd
  from bokeh.plotting import ColumnDataSource, figure, output_file, show
  from bokeh.models import HoverTool
  
  output_file("scatter.html")
  df = pd.read_csv('/Users/jz/07_isolate_selection.csv')
  hash = {}
  
  c = ('aliceblue', 'antiquewhite', 'aqua', 'aquamarine', 'azure', 'beige', 'bisque', 'black', 
      'blanchedalmond', 'blue', 'blueviolet', 'brown', 'burlywood', 'cadetblue', 'chartreuse', 
      'chocolate', 'coral', 'cornflowerblue', 'cornsilk', 'crimson', 'cyan', 'darkblue', 'darkcyan', 
      'darkgoldenrod', 'darkgray', 'darkgreen', 'darkgrey', 'darkkhaki', 'darkmagenta', 'darkolivegreen', 
      'darkorange', 'darkorchid', 'darkred', 'darksalmon', 'darkseagreen', 'darkslateblue', 'darkslategray', 
      'darkslategrey', 'darkturquoise', 'darkviolet', 'deeppink', 'deepskyblue', 'dimgray', 'dimgrey', 'dodgerblue', 
      'firebrick', 'floralwhite', 'forestgreen', 'fuchsia', 'gainsboro', 'ghostwhite', 'gold', 'goldenrod', 
      'gray', 'green', 'greenyellow', 'grey', 'honeydew', 'hotpink', 'indianred', 'indigo', 'ivory', 'khaki', 
      'lavender', 'lavenderblush', 'lawngreen', 'lemonchiffon', 'lightblue', 'lightcoral', 'lightcyan', 
      'lightgoldenrodyellow', 'lightgray', 'lightgreen', 'lightgrey', 'lightpink', 'lightsalmon', 'lightseagreen', 
      'lightskyblue', 'lightslategray', 'lightslategrey', 'lightsteelblue', 'lightyellow', 'lime', 'limegreen', 
      'linen', 'magenta', 'maroon', 'mediumaquamarine', 'mediumblue', 'mediumorchid', 'mediumpurple', 'mediumseagreen', 
      'mediumslateblue', 'mediumspringgreen', 'mediumturquoise', 'mediumvioletred', 'midnightblue', 'mintcream', 'mistyrose', 
      'moccasin', 'navajowhite', 'navy', 'oldlace', 'olive', 'olivedrab', 'orange', 'orangered', 'orchid', 'palegoldenrod', 
      'palegreen', 'paleturquoise', 'palevioletred', 'papayawhip', 'peachpuff', 'peru', 'pink', 'plum', 'powderblue', 
      'purple', 'red', 'rosybrown', 'royalblue', 'saddlebrown', 'salmon', 'sandybrown', 'seagreen', 'seashell', 'sienna', 
      'silver', 'skyblue', 'slateblue', 'slategray', 'slategrey', 'snow', 'springgreen', 'steelblue', 'tan', 'teal', 
      'thistle', 'tomato', 'turquoise', 'violet', 'wheat', 'white', 'whitesmoke', 'yellow', 'yellowgreen');
  
  
  #loop through and assign colors:
  counter = 0
  for a in df.material.unique():
      hash[a] = c[counter]
      counter += 1
  
  # generate colors:
  
  colors = [hash[code] for code in df.material]
  df['color'] = colors
  
  
  source = ColumnDataSource(df)
  TOOLS="pan,wheel_zoom,box_zoom,reset,hover"
  p = figure(title="Hoverful Scatter", tools=TOOLS)
  p.circle('peak.count', 'purity.score', radius=.66, source=source,
            fill_color=colors, fill_alpha=0.6, line_color=None)
  
  hover = p.select(dict(type=HoverTool))[0]
  hover.tooltips = [
      ("material", "@material")
  ]
  
  show(p)
  </code></pre>
  
  <p>How can I display a legend which corresponds to the groups defined in df.material column? The color coding works below, where I group the circles by the df.material, but I would also like to display a legend so that you know that 'aliceblue' corresponds with 'FOO' and 'olive' corresponds with 'BAR' as an example.</p>
  
  <p>Thanks!</p>