Skip to content

Instantly share code, notes, and snippets.

@sbassi
Created May 18, 2020 03:43
Show Gist options
  • Star 0 You must be signed in to star a gist
  • Fork 0 You must be signed in to fork a gist
  • Save sbassi/a662e2b1ded0d1f452bf8b99545244d2 to your computer and use it in GitHub Desktop.
Save sbassi/a662e2b1ded0d1f452bf8b99545244d2 to your computer and use it in GitHub Desktop.
import numpy as np
from pandas import read_csv
import holoviews as hv
from holoviews import opts
hv.extension('bokeh')
DATA_FILE = 'samples/GSM188012.CEL'
dtype = {'x': int, 'y': int, 'lux': float}
ds = read_csv(DATA_FILE, sep='\t', dtype=dtype)
heatmap = hv.HeatMap(ds).aggregate(function=np.mean)
heatmap.opts(opts.HeatMap(tools=['hover'], colorbar=True, width=1200, height=1200, toolbar='above'))
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment