Skip to content

Instantly share code, notes, and snippets.

@freeman-lab
Created February 16, 2016 00:07
Show Gist options
  • Save freeman-lab/c12685ec09ebf4c25cfa to your computer and use it in GitHub Desktop.
Save freeman-lab/c12685ec09ebf4c25cfa to your computer and use it in GitHub Desktop.
using lightning scatter in js without the server
var scatter = require('lightning-scatter')
var el = document.body.appendChild(document.createElement('div'))
var viz = new scatter(el, {points: [[Math.random(), Math.random()], [Math.random(), Math.random()]]})
setInterval(function () {
viz.appendData({points: [[Math.random(), Math.random()], [Math.random(), Math.random()]]})
}, 50)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment