def _create_range_tool(data, min_time, max_time, plot_range, width, height, time_column: str=None):
    'Create plot bar to act as as range selector.'
    ext_min = (min_time - ((max_time - min_time) * 0.15))
    ext_max = (max_time + ((max_time - min_time) * 0.15))
    plot_height = max(120, int((height * 0.2)))
    rng_select = figure(x_range=(ext_min, ext_max), title='Range Selector', plot_height=plot_height, plot_width=width, x_axis_type='datetime', y_axis_type=None, tools='', toolbar_location=None)
    help_str = ('Drag the middle or edges of the selection box to change ' + 'the range in the main chart')
    rng_select.add_layout(Title(text=help_str, align='right', text_font_size='10px'), 'below')
    rng_select.xaxis[0].formatter = _get_tick_formatter()
    if isinstance(data, dict):
        for (_, series_def) in data.items():
            rng_select.circle(x=series_def['time_column'], y='y_index', color=series_def['color'], source=series_def['source'])
    elif isinstance(data, pd.DataFrame):
        rng_select.circle(x=time_column, y='y_index', color='blue', source=ColumnDataSource(data))
    range_tool = RangeTool(x_range=plot_range)
    range_tool.overlay.fill_color = 'navy'
    range_tool.overlay.fill_alpha = 0.2
    rng_select.ygrid.grid_line_color = None
    rng_select.add_tools(range_tool)
    rng_select.toolbar.active_multi = range_tool
    return rng_select
Create plot bar to act as as range selector.
def _create_range_tool(data, min_time, max_time, plot_range, width, height, time_column: str=None):
    
    ext_min = (min_time - ((max_time - min_time) * 0.15))
    ext_max = (max_time + ((max_time - min_time) * 0.15))
    plot_height = max(120, int((height * 0.2)))
    rng_select = figure(x_range=(ext_min, ext_max), title='Range Selector', plot_height=plot_height, plot_width=width, x_axis_type='datetime', y_axis_type=None, tools=, toolbar_location=None)
    help_str = ('Drag the middle or edges of the selection box to change ' + 'the range in the main chart')
    rng_select.add_layout(Title(text=help_str, align='right', text_font_size='10px'), 'below')
    rng_select.xaxis[0].formatter = _get_tick_formatter()
    if isinstance(data, dict):
        for (_, series_def) in data.items():
            rng_select.circle(x=series_def['time_column'], y='y_index', color=series_def['color'], source=series_def['source'])
    elif isinstance(data, pd.DataFrame):
        rng_select.circle(x=time_column, y='y_index', color='blue', source=ColumnDataSource(data))
    range_tool = RangeTool(x_range=plot_range)
    range_tool.overlay.fill_color = 'navy'
    range_tool.overlay.fill_alpha = 0.2
    rng_select.ygrid.grid_line_color = None
    rng_select.add_tools(range_tool)
    rng_select.toolbar.active_multi = range_tool
    return rng_select