Lakens / TOSTER

TOST equivalence test and power functions
35 stars 18 forks source link

powerTOSTpaired.raw not incorporating sdif #26

Closed debruine closed 6 years ago

debruine commented 6 years ago

powerTOSTpaired.raw gives the same bounds regardless of sdif (and the same results as powerTOSTpaired).

e.g., the following give the same bounds (± .17)

powerTOSTpaired.raw( alpha = 0.05, sdif = 100, N = 290, statistical_power = 0.8 ) powerTOSTpaired.raw( alpha = 0.05, sdif = 1, N = 290, statistical_power = 0.8 ) powerTOSTpaired( alpha = 0.05, N = 290, statistical_power = 0.8 )

Lakens commented 6 years ago

Thanks for letting me know. This bug is now fixed. Output is now:

powerTOSTpaired.raw( alpha = 0.05, sdif = 100, N = 290, statistical_power = 0.8 ) The equivalence bounds to achieve 80 % power with N = 290 are -17.18 and 17.18 . [1] -17.18444 17.18444 powerTOSTpaired.raw( alpha = 0.05, sdif = 1, N = 290, statistical_power = 0.8 ) The equivalence bounds to achieve 80 % power with N = 290 are -0.17 and 0.17 . [1] -0.1718444 0.1718444 powerTOSTpaired( alpha = 0.05, N = 290, statistical_power = 0.8 ) The equivalence bounds to achieve 80 % power with N = 290 are -0.17 and 0.17 . [1] -0.1718444 0.1718444