bokeh.models.grids

A guide renderer for displaying grid lines on Bokeh plots.

class Grid(**kwargs)[source]

Bases: bokeh.models.renderers.GuideRenderer

Display horizontal or vertical grid lines at locations given by a supplied Ticker.

band_fill_alpha

property type: Percent

The fill alpha of alternating bands between Grid lines.

band_fill_color

property type: Color

The fill color of alternating bands between Grid lines.

band_hatch_alpha

property type: Percent

The hatch alpha of alternating bands between Grid lines.

band_hatch_color

property type: Color

The hatch color of alternating bands between Grid lines.

band_hatch_extra

property type: Dict ( String , Instance ( Texture ) )

The hatch extra of alternating bands between Grid lines.

band_hatch_pattern

property type: String

The hatch pattern of alternating bands between Grid lines.

band_hatch_scale

property type: Size

The hatch scale of alternating bands between Grid lines.

band_hatch_weight

property type: Size

The hatch weight of alternating bands between Grid lines.

bounds

property type: Either ( Auto , Tuple ( Float , Float ) )

Bounds for the rendered grid lines. By default, a grid will look for a corresponding axis to ask for bounds. If one cannot be found, the grid will span the entire visible range.

dimension

property type: Int

Which dimension the Axis Grid lines will intersect. The x-axis is dimension 0 (vertical Grid lines) and the y-axis is dimension 1 (horizontal Grid lines).

grid_line_alpha

property type: Percent

The line alpha of the Grid lines.

grid_line_cap

property type: Enum ( LineCap )

The line cap of the Grid lines.

grid_line_color

property type: Color

The line color of the Grid lines.

grid_line_dash

property type: DashPattern

The line dash of the Grid lines.

grid_line_dash_offset

property type: Int

The line dash offset of the Grid lines.

grid_line_join

property type: Enum ( LineJoin )

The line join of the Grid lines.

grid_line_width

property type: Float

The line width of the Grid lines.

minor_grid_line_alpha

property type: Percent

The line alpha of the minor Grid lines.

minor_grid_line_cap

property type: Enum ( LineCap )

The line cap of the minor Grid lines.

minor_grid_line_color

property type: Color

The line color of the minor Grid lines.

minor_grid_line_dash

property type: DashPattern

The line dash of the minor Grid lines.

minor_grid_line_dash_offset

property type: Int

The line dash offset of the minor Grid lines.

minor_grid_line_join

property type: Enum ( LineJoin )

The line join of the minor Grid lines.

minor_grid_line_width

property type: Float

The line width of the minor Grid lines.

ticker

property type: Instance ( Ticker )

The Ticker to use for computing locations for the Grid lines.

x_range_name

property type: String

A particular (named) x-range to use for computing screen locations when rendering a grid on the plot. If unset, use the default x-range.

y_range_name

property type: String

A particular (named) y-range to use for computing screen locations when rendering a grid on the plot. If unset, use the default y-range.

JSON Prototype
{
  "band_fill_alpha": 0,
  "band_fill_color": null,
  "band_hatch_alpha": 1.0,
  "band_hatch_color": "black",
  "band_hatch_extra": {},
  "band_hatch_pattern": null,
  "band_hatch_scale": 12.0,
  "band_hatch_weight": 1.0,
  "bounds": "auto",
  "dimension": 0,
  "grid_line_alpha": 1.0,
  "grid_line_cap": "butt",
  "grid_line_color": "#e5e5e5",
  "grid_line_dash": [],
  "grid_line_dash_offset": 0,
  "grid_line_join": "bevel",
  "grid_line_width": 1,
  "id": "12407",
  "js_event_callbacks": {},
  "js_property_callbacks": {},
  "level": "underlay",
  "minor_grid_line_alpha": 1.0,
  "minor_grid_line_cap": "butt",
  "minor_grid_line_color": null,
  "minor_grid_line_dash": [],
  "minor_grid_line_dash_offset": 0,
  "minor_grid_line_join": "bevel",
  "minor_grid_line_width": 1,
  "name": null,
  "subscribed_events": [],
  "tags": [],
  "ticker": null,
  "visible": true,
  "x_range_name": "default",
  "y_range_name": "default"
}