Reader small image

You're reading from  Hands-On Data Visualization with Bokeh

Product typeBook
Published inJun 2018
Reading LevelIntermediate
PublisherPackt
ISBN-139781789135404
Edition1st Edition
Languages
Tools
Right arrow
Author (1)
Kevin Jolly
Kevin Jolly
author image
Kevin Jolly

Kevin Jolly is a formally educated data scientist with a master's degree in data science from the prestigious King's College London. Kevin works as a statistical analyst with a digital healthcare start-up, Connido Limited, in London, where he is primarily involved in leading the data science projects that the company undertakes. He has built machine learning pipelines for small and big data, with a focus on scaling such pipelines into production for the products that the company has built. Kevin is also the author of a book titled Hands-On Data Visualization with Bokeh, published by Packt. He is the editor-in-chief of Linear, a weekly online publication on data science software and products.
Read more about Kevin Jolly

Right arrow

Creating multiple plots in a row and column

We might see a situation in which we would like to compare the two scatter plots horizontally, but would like the time series plot to be stacked here with the scatter plots, but all within the embrace of the same layout.

Such a combination of horizontal and vertical layouts is called a nested layout.

We can construct a nested layout by using the code shown here:

#Import the required packages

from bokeh.layouts import column, row
from bokeh.io import output_file, show

#Construct the nested layout

nested_layout = column(row(plot1,plot2), plot3)

#Output the plot

output_file('nested.html')

show(nested_layout)

This results in a plot as illustrated here:

Plots 1, 2, and 3 in a nested layout

In the previous code, we used the row function to combine Plot 1 and Plot 2 in a horizontal row and then used the column function on the horizontal...

lock icon
The rest of the page is locked
Previous PageNext Page
You have been reading a chapter from
Hands-On Data Visualization with Bokeh
Published in: Jun 2018Publisher: PacktISBN-13: 9781789135404

Author (1)

author image
Kevin Jolly

Kevin Jolly is a formally educated data scientist with a master's degree in data science from the prestigious King's College London. Kevin works as a statistical analyst with a digital healthcare start-up, Connido Limited, in London, where he is primarily involved in leading the data science projects that the company undertakes. He has built machine learning pipelines for small and big data, with a focus on scaling such pipelines into production for the products that the company has built. Kevin is also the author of a book titled Hands-On Data Visualization with Bokeh, published by Packt. He is the editor-in-chief of Linear, a weekly online publication on data science software and products.
Read more about Kevin Jolly