rStats.js v1.3.0
    Preparing search index...

    Function pwrT2nTest

    • Power of a two-sample t test with unequal sample sizes, or a sample size, the effect size or the significance level for a given power. Equivalent to pwr::pwr.t2n.test() in R.

      Parameters

      Returns PwrT2nTestResult

      pwrT2nTest({ n1: 20, n2: 30, d: 0.5 }).power; // 0.39656999440895696
      pwrT2nTest({ n1: 50, d: 0.5, power: 0.8 }).n2; // 87.70891347276086