Hello, I have been trying to learn how to perform an ANOVA for a data table. I know how to do this in Excel, and I understand that using Excel for this situation is much more straightforward than doing it in Python. However, I am trying to learn more about performing statistical analysis tests in Python.

Here is the data table that I am working with:

Please let me know if it is possible and teach me or guide me through how I can perform this in Python.

Thank you.

It’s probably easiest to run this kind of script in Jupyter (an interactive Python shell with a web-interface that supports nice rendering of tables and makes plotting a bit easier).

This is included in an Anaconda Navigator install.

Then install for instance scipy (SciPy - Installation)(<- also has general doc about various install methods, like pip and conda and how to get those).

After the installs, you can start a Jupyter Notebook either from the Navigator or by running in a command shell (with an active conda base environment):

```
jupyter notebook
```

Then have a look at: scipy.stats.f_oneway — SciPy v1.11.2 Manual

That doc provides a worked-out example. Since you are already familiar with the stats, I assume you won’t have trouble following along.

An alternative package you could use is: ANOVA - statsmodels 0.14.0

That doc also shows a work-out example (in a Jupyter notebook), but the docs seems rather succinct…

1 Like

Yes, I am currently using Jupyter Notebook, and thank you. I will look into those packages.