Skip to content
Plotly templates

Physics — Distance–Time Graph

Constant speed, a pause, then the return journey.

Template previewPlotly
Rendering…

Make it your own.

{
  "data": [
    {"type":"scatter","mode":"lines","name":"distance","line":{"color":"#2563eb","width":3},
     "x":[0,2,4,6,8,10,12],
     "y":[0,20,40,40,40,20,0]}
  ],
  "layout": {"title":"Distance-time graph","xaxis":{"title":"time (s)"},"yaxis":{"title":"distance (m)"}}
}