You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
<em>This function has comparable performance to <ahref="#plotlyreact"><code>Plotly.react</code></a> and is faster than redrawing the whole plot with <ahref="#plotlynewplot"><code>Plotly.newPlot</code></a>.</em><br/><br/>
306
306
307
-
This allows you to add <b>new</b> traces to an existing <code>graphDiv</code> at any location in its data array.
307
+
This allows you to add <b>new</b> traces to an existing <code>graphDiv</code> at any location in its <ahref='#retrieving-data-layout'>data array</a>. Every <code>graphDiv</code> object has a <code>data</code> component which is an array of JSON blobs that each describe one trace. The full list of trace types can be found <ahref="{{ BASE_URL }}/javascript/reference/">in the Full Reference</a>.
<em>This function has comparable performance to <ahref="#plotlyreact"><code>Plotly.react</code></a> and is faster than redrawing the whole plot with <ahref="#plotlynewplot"><code>Plotly.newPlot</code></a>.</em><br/><br/>
340
341
This allows you to reorder traces in an existing <code>graphDiv</code>. This will change the ordering of the layering and the legend.
341
342
343
+
All traces defined in <code>graphDiv</code> are ordered in an array. They are drawn one by one from first to last. Each time a new layer or trace is drawn to the canvas the new trace is drawn directly over the current canvas, replacing the colors of the traces and background. This algorithm to image stacking/drawing is known as the <ahref='https://www.youtube.com/watch?v=oMgOR3PxmDU'>Painter's Algorithm</a>. As its name implies the Painter's Algorithm is typically the manner in which a painter paints a landscape, starting from objects with the most perspective depth and progressively moving forward and layering over the background objects.
Plots emit events prefixed with <code>plotly_</code> when clicked or hovered over, and event handlers can be bound to events using the <code>on</code> method that is exposed by the plot div object. For more information and examples of how to use Plotly events see: <ahref="https://plot.ly/javascript/plotlyjs-events/">https://plot.ly/javascript/plotlyjs-events/</a>.
0 commit comments