Skip to content
Plotly templates

Power Analysis Curves

Power as a function of sample size at three effect sizes.

Template previewPlotly
Rendering…

Make it your own.

{
  "data": [
    { "type":"scatter","mode":"lines","name":"Cohen's d = 0.2 (small)",
      "x":[20,40,60,80,100,150,200,300,400,500,750,1000],
      "y":[0.15,0.22,0.30,0.38,0.45,0.59,0.70,0.84,0.92,0.96,0.99,1.0],
      "line":{"color":"#94a3b8","width":2.5} },
    { "type":"scatter","mode":"lines","name":"d = 0.5 (medium)",
      "x":[20,40,60,80,100,150,200,300,400,500,750,1000],
      "y":[0.34,0.60,0.77,0.87,0.93,0.99,1.0,1.0,1.0,1.0,1.0,1.0],
      "line":{"color":"#3666ff","width":2.5} },
    { "type":"scatter","mode":"lines","name":"d = 0.8 (large)",
      "x":[20,40,60,80,100,150,200,300,400,500,750,1000],
      "y":[0.70,0.94,0.99,1.0,1.0,1.0,1.0,1.0,1.0,1.0,1.0,1.0],
      "line":{"color":"#16a34a","width":2.5} },
    { "type":"scatter","mode":"lines","name":"Power = 0.80",
      "x":[20,1000],"y":[0.8,0.8],"line":{"color":"#dc2626","dash":"dash"} }
  ],
  "layout":{
    "title":"Power curves (two-sided t-test, α = 0.05)",
    "xaxis":{"title":"Sample size per group","type":"log"},
    "yaxis":{"title":"Power (1 − β)","range":[0,1.05]}
  }
}