<head>
  <script src="https://cdn.plot.ly/plotly-latest.min.js"></script>
</head>
<body>
  <div id="graph"></div>
</body>
function rand() {
  return Math.random();
}

Plotly.plot('graph', [{
  y: [1,2,3].map(rand),
  mode: 'lines+markers', 
  marker: {color: 'pink', size: 8},
  line: {width: 4}
}, {
  y: [1,2].map(rand),
  mode: 'lines+markers',
  marker: {color: 'gray', size:8},
  line: {width: 4}
}]);

var cnt = 0;
var interval = setInterval(function() {
  Plotly.extendTraces('graph', {
    y: [[rand()], [rand()]]
  }, [0, 1])

  cnt = cnt+1;
  if(cnt === 100) clearInterval(interval);
}, 500);

External CSS

This Pen doesn't use any external CSS resources.

External JavaScript

This Pen doesn't use any external JavaScript resources.