Skip to content

mamatsunami/runkit-plotly

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

runkit-plotly

Tool module to easily embed plotly charts in a runkit notebook.

See working example

const wrapPlotly = require('runkit-plotly');

var makeChart = wrapPlotly((data, elem, Plotly) => {
    var trace = {
        x: data.x,
        y: data.y,
        mode: 'lines',
        type: 'scatter'
    };

    var data = [trace];

    Plotly.newPlot(elem, data);
});

makeChart(
    {
        x: [2, 3, 4, 5],
        y: [16, 5, 11, 9]
    },
    {
        width: 700,
        height: 500
    }
); 

About

wrapper to easily embed plotly charts in runkit

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published