コード例 #1
0
# specify custom marker for outliers
box_plot6 = BoxPlot(df,
                    label='cyl',
                    values='mpg',
                    marker='cross',
                    title="label='cyl', values='mpg', marker='cross'")

# color whisker by cylinder
box_plot7 = BoxPlot(df,
                    label='cyl',
                    values='mpg',
                    whisker_color='cyl',
                    title="label='cyl', values='mpg', whisker_color='cyl'")

# remove outliers
box_plot8 = BoxPlot(
    df,
    label='cyl',
    values='mpg',
    outliers=False,
    title="label='cyl', values='mpg', outliers=False, tooltips=True",
    tooltips=True)
box_plot8.title_text_font_size = '11pt'

output_file("boxplot_multi.html", title="boxplot_multi.py example")

show(
    vplot(hplot(box_plot, box_plot2), hplot(box_plot3, box_plot4),
          hplot(box_plot5, box_plot6), hplot(box_plot7, box_plot8)))
コード例 #2
0
ファイル: boxplot_multi.py プロジェクト: 280185386/bokeh
                    title="label='cyl' color='blue'",
                    color='blue')

# color by one dimension and label by two dimensions
box_plot5 = BoxPlot(df, label=['cyl', 'origin'], values='mpg',
                    title="label=['cyl', 'origin'] color='cyl'",
                    color='cyl')

# specify custom marker for outliers
box_plot6 = BoxPlot(df, label='cyl', values='mpg', marker='cross',
                    title="label='cyl', values='mpg', marker='cross'")

# color whisker by cylinder
box_plot7 = BoxPlot(df, label='cyl', values='mpg', whisker_color='cyl',
                    title="label='cyl', values='mpg', whisker_color='cyl'")

# remove outliers
box_plot8 = BoxPlot(df, label='cyl', values='mpg', outliers=False,
                    title="label='cyl', values='mpg', outliers=False, tooltips=True",
                    tooltips=True)
box_plot8.title_text_font_size = '11pt'

output_file("boxplot_multi.html", title="boxplot_multi.py example")

show(vplot(
    hplot(box_plot, box_plot2),
    hplot(box_plot3, box_plot4),
    hplot(box_plot5, box_plot6),
    hplot(box_plot7, box_plot8)
) )