단일 영역 (Single Areas)
1. x좌표 2, y범위 1 ~ 7
2. x좌표 4, y범위 4 ~ -1
3. x좌표 6, y범위 5 ~ -3
1번 범위에서 2번 3의 선을 이어서 사이에 있는 영역을 표현합니다
p = figure(plot_width=400, plot_height=400)
p.varea(x=[2, 4, 6], #vertical
y1=[1, 4, 5],
y2=[7, -1, -3])
show(p)
스택 영역 (Stacked Areas)
y1의 값 위에 y2의 값이 스택처럼 쌓인것을 확인할 수 있습니다
source = ColumnDataSource(data=dict(
x=np.arange(3),
y1=[1, 3, 7],
y2=[2, 3, 6])
)
p = figure(plot_width=400, plot_height=400)
p.varea_stack(['y1', 'y2'], x='x', color=("royalblue", "lightblue"), source=source)
show(p)
'bokeh' 카테고리의 다른 글
[bokeh] 계란형 (Ovals) (0) | 2020.10.05 |
---|---|
[bokeh] 패치, 폴리곤 (Patch, Polygons) (0) | 2020.10.05 |
[bokeh] 막대, 사각형, 육각 타일 (0) | 2020.10.04 |
[bokeh] 라인 플롯 (Line Plots) (0) | 2020.10.04 |
[bokeh] 산점도(Scatter Plots) (0) | 2020.10.03 |