Skip to content

Instantly share code, notes, and snippets.

@domitry
Created May 7, 2014 13:14
Show Gist options
  • Save domitry/0c2bd2997bc94b4e6f2a to your computer and use it in GitHub Desktop.
Save domitry/0c2bd2997bc94b4e6f2a to your computer and use it in GitHub Desktop.
require 'sciruby'
df = SciRuby::Dataframe.new(address.json)
# change data
db = SciRuby::DataBase.connect(address_to_server)
db.push('table_name', df)
heatmap = BioPlot::HeatMap.new(table:db.table_name, x:'index', y:'Y')
scatter = SciPlot::Scatter.new(table:db.table_name, x:'X', y:'Y')
stage = SciPlot::Stage.new()
stage.add(heatmap)
stage.add(scatter)
stage.render() # -> render on IRuby
stage.publish # -> generate static html (with Ajax)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment