Hextile movie ratings

In [1]:
import numpy as np
import pandas as pd
import holoviews as hv
hv.extension('matplotlib')
%output fig='svg' size=200

Define data

In [2]:
import sqlite3
from bokeh.sampledata import movies_data

# Load data
conn = sqlite3.connect(movies_data.movie_path)
movies = pd.read_sql('SELECT userRating, imdbRating FROM omdb, tomatoes WHERE omdb.ID = tomatoes.ID', conn)

# Declare element
hextiles = hv.HexTiles(movies, [('userRating', 'Tomato User Rating'), ('imdbRating', 'IMDb Rating')], [])

Plot data

In [3]:
hextiles.options(min_count=0) * hv.Bivariate(hextiles)
Out[3]:

Download this notebook from GitHub (right-click to download).