code: def make_plot(mapper, palette):
      cmap = mapper("x", palette=palette, low=1, high=1000)
      axis_type = mapper.__name__.split("_")[0]  # linear or log
  
      p = figure(
          x_range=(1, 1000),
          title=f"{palette} with {mapper.__name__}",
          toolbar_location=None,
          tools="",
          x_axis_type=axis_type,
      )
  
      r = p.scatter("x", "y", alpha=0.8, source=source, color=cmap)
  
      color_bar = r.construct_color_bar(
          padding=0, ticker=p.xaxis.ticker, formatter=p.xaxis.formatter
      )
      p.add_layout(color_bar, "below")
  
      return p
  
imports: import numpy
  from bokeh.layouts import column, gridplot
  from bokeh.models import ColumnDataSource
  from bokeh.plotting import figure, show
  from bokeh.transform import linear_cmap, log_cmap
label_desc: Use image node_id 1 for calling a global function with example usage: make_plot(mapper, palette) and returns: p