code: def test_two_factors_repeated_measures_anova():
      """
      Testing two factors repeated measures anova
      Results reproduces R `ezANOVA` function from library ez
      """
      df = AnovaRM(
          data.iloc[:48, :], "DV", "id", within=["A", "B"]
      ).fit()
      a = [
          [1, 7, 40.14159, 3.905263e-04],
          [2, 14, 29.21739, 1.007549e-05],
          [2, 14, 17.10545, 1.741322e-04],
      ]
      assert_array_almost_equal(
          df.anova_table.iloc[:, [1, 2, 0, 3]].values, a, decimal=5
      )
  
file_path: statsmodels/statsmodels/stats/tests/test_anova_rm.py
imports: from statsmodels.compat.pandas import assert_frame_equal
  from numpy.testing import assert_array_almost_equal, assert_equal, assert_raises
  import pandas
  from statsmodels.stats.anova import AnovaRM
label_desc: Use image node_id 2 for calling a global function with example usage: test_two_factors_repeated_measures_anova() without return types