Article
Easy Sample Size Calculation for 2-way ANOVA
Search Medline for
Authors
Published: | September 6, 2024 |
---|
Outline
Text
Introduction: When an experimenter wants to ascertain that a treatment has a larger effect in one setting (e.g., a knock-out genotype) compared to another setting (e.g., wildtype genotype) an F-test for interaction in a 2-way ANOVA might be a suitable statistical analysis. To plan the sample size for such an experiment the effect size (f), a dimensionless and abstract quantity, is needed. But (f) ultimately depends on the expected mean values and the residual variance in the different experimental groups of the 2-way ANOVA. However, to the best of our knowledge, there is currently no easy to use freely available software to do this planning for 2-way ANOVA starting from the expected cell means.
Methods: Shiny [1] is an R add-on package that allows the creation of interactive web applications directly from R code, enabling data exploration, visualization, and analysis.We used Shiny to design a web-application that facilitates sample size planning for 2-way ANOVA for experimenters and clinicians, starting from the expected mean values for the different experimental groups of the ANOVA.
Results: We have developed an easy to use web-application called sscn for sample size estimation in 2-way ANOVA. The user interface of our web-application comprises visual elements that guide the users through inputting crucial data for their experimental design. Key inputs include the expected mean values per group corresponding to all combinations of involved factors. For instance, in case of a 2x2 design, e.g., two factors with two levels per factor, there would be four unique combinations. Users can specify the number of factors and their respective levels, which are then presented in a structured table format. This feature enables users to verify the correctness of their inputs regarding the combinations of levels. The expected residual variance within each experimental group needs to be set and the users specify which effect (main effect or interaction) is of interest. Moreover, the users can fine-tune parameters such as desired power 1-β and the requested significance level α.
Finally, the resulting sample size is calculated and shown. The web-application called sscn is freely accessible at https://tu-dresden.de/med/mf/imb/service/tools.
Discussion: Our web-application makes sample size calculation for 2-way ANOVA more tangible for clinicians and experimenters that are not statistical experts. We have made efforts to validate our web-application against other established sample size software (G*Power [2], nQuery [3]). In fact, our tool supports any ANOVA model, including ANOVAs of higher order with more than two factors but also 1-way ANOVA and t-tests as special case. This way, we hope to offer a one-stop solution for clinicians and experimenters.
Conclusion: We present our user-friendly tool sscn to plan sample size for 2-way ANOVA experiments. The tool is freely accessible at https://tu-dresden.de/med/mf/imb/service/tools.
The authors declare that they have no competing interests.
The authors declare that an ethics committee vote is not required.
References
- 1.
- Shiny [Internet]. [cited 2024 Apr 30]. Available from: https://shiny.posit.co/
- 2.
- Faul F. G*Power [Internet]. Heinrich-Heine-Universität Düsseldorf; [cited 2024 Apr 30]. Available from: https://www.psychologie.hhu.de/arbeitsgruppen/allgemeine-psychologie-und-arbeitspsychologie/gpower
- 3.
- nQuery. Platform for optimizing trial design [Internet]. Statsols.com; [cited 2024 Apr 30]. Available from: https://www.statsols.com/nquery