Bokeh 简明教程
Bokeh - Basic Concepts
Bokeh 包提供了两个接口,使用这些接口可以执行各种绘图操作。
Bokeh package offers two interfaces using which various plotting operations can be performed.
bokeh.models
此模块是一个低级接口。它为应用程序开发人员在开发可视化效果时提供了极大的灵活性。Bokeh 图形会导致一个对象,其中包含场景的可视和数据方面,而 BokehJS 库使用该对象。构成 Bokeh 场景图的低级对象称为模型。
This module is a low level interface. It provides great deal of flexibility to the application developer in developing visualizations. A Bokeh plot results in an object containing visual and data aspects of a scene which is used by BokehJS library. The low-level objects that comprise a Bokeh scene graph are called Models.
bokeh.plotting
这是一个更高级别的界面,具有用于组合视觉图形的功能。此模块包含 Figure 类的定义。它实际上是 bokeh.models 模块中定义的图表类的子类。
This is a higher level interface that has functionality for composing visual glyphs. This module contains definition of Figure class. It actually is a subclass of plot class defined in bokeh.models module.
Figure 类简化了图表创建。它包含各种方法来绘制不同的矢量化图形图形。图形是 Bokeh 图形的基础块,例如线、圆、矩形和其他形状。
Figure class simplifies plot creation. It contains various methods to draw different vectorized graphical glyphs. Glyphs are the building blocks of Bokeh plot such as lines, circles, rectangles, and other shapes.