[英]Two-way Repeated Measures ANOVA in Spyder-TypeError: list indices must be integers or slices, not numpy.float64
[英]Two-way repeated measures ANOVA python function
提前感謝您的任何答案。 我想在 python 中進行 2 路重復測量方差分析,其中一個 IV 有 5 個級別,其他 4 個級別,一個 DV。 我試過在 scipy 文檔和一些在線博客中環顧四周,但似乎找不到任何東西。
您可以使用直接與 Pandas DataFrame 一起使用的Pinouin包(我是其創建者)中的 rm_anova 函數,例如:
import pingouin as pg
# Compute the 2-way repeated measures ANOVA. This will return a dataframe.
pg.rm_anova(dv='dv', within=['iv1', 'iv2'], subject='id', data=df)
# Optional post-hoc tests
pg.pairwise_ttests(dv='dv', within=['iv1', 'iv2'], subject='id', data=df)
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.