def make_plot(source, xname, yname, line_color, xdr=None, ydr=None):
 if (xdr is None):
  xdr = DataRange1d()
 if (ydr is None):
  ydr = DataRange1d()
 plot = Plot(x_range=xdr, y_range=ydr, min_border=50)
 plot.add_layout(LinearAxis(), 'below')
 plot.add_layout(LinearAxis(), 'left')
 plot.add_glyph(source, Line(x=xname, y=yname, line_color=line_color))
 plot.add_tools(PanTool(), WheelZoomTool())
 return plot

def make_plot ( source , xname , yname , line_color , xdr = None , ydr = None ) : if ( xdr is None ) : xdr = DataRange1d ( ) if ( ydr is None ) : ydr = DataRange1d ( ) plot = Plot ( x_range = xdr , y_range = ydr , min_border = 50 ) plot . add_layout ( LinearAxis ( ) , 'below' ) plot . add_layout ( LinearAxis ( ) , 'left' ) plot . add_glyph ( source , Line ( x = xname , y = yname , line_color = line_color ) ) plot . add_tools ( PanTool ( ) , WheelZoomTool ( ) ) return plot
returns a tuple ; the former can be added to a gridplot .