English 中文(简体)
Bokeh - Setting Ranges
  • 时间:2024-12-22

Bokeh - Setting Ranges


Previous Page Next Page  

Numeric ranges of data axes of a plot are automatically set by Bokeh taking into consideration the dataset under process. However, sometimes you may want to define the range of values on x and y axis exppcitly. This is done by assigning x_range and y_range properties to a figure() function.

These ranges are defined with the help of range1d() function.

Example


xrange = range1d(0,10)

To use this range object as x_range property, use the below code −


fig = figure(x,y,x_range = xrange)
Advertisements