title: Problem with 'mutate()' input 'data' in ANOVA (rstatix)
body: <p>This is driving me crazy. I am using anova_test from rstatix and it's telling me that my columns aren't there when they clearly are.</p>
  <p>This is what my dataframe looks like:</p>
  <pre><code>ID = c(1, 1, 1, 1, 1, 1, 2, 2, 2, 2, 2, 2, 3, 3, 3, 3, 3, 3) 
  Form = c(&quot;A&quot;, &quot;A&quot;, &quot;A&quot;, &quot;B&quot;, &quot;B&quot;, &quot;B&quot;, &quot;A&quot;, &quot;A&quot;, &quot;A&quot;, &quot;B&quot;, &quot;B&quot;, &quot;B&quot;, &quot;A&quot;, &quot;A&quot;, &quot;A&quot;, &quot;B&quot;, &quot;B&quot;, &quot;B&quot;)
  Pen = c(&quot;Red&quot;, &quot;Blue&quot;, &quot;Green&quot;, &quot;Red&quot;, &quot;Blue&quot;, &quot;Green&quot;, &quot;Red&quot;, &quot;Blue&quot;, &quot;Green&quot;,&quot;Red&quot;, &quot;Blue&quot;, &quot;Green&quot;,&quot;Red&quot;, &quot;Blue&quot;, &quot;Green&quot;,&quot;Red&quot;, &quot;Blue&quot;, &quot;Green&quot;)
  Time = c(20, 4, 6, 2, 76, 3, 86, 35, 74, 94, 14, 35, 63, 12, 15, 73, 87, 33)
  df &lt;- data.frame(ID, Form, Pen, Time)
  </code></pre>
  <p>ID, Form, Pen are factors, Time is numeric. So each subject completed forms A and B with Red, Blue, and Green pens, and I measured how long each took in completing the form.</p>
  <p>This is a fake dataset that I've purposefully come up with to ask this question. In reality, this dataframe is derived from a larger dataset with several more variables. Each variable has a lot more observation (so not just one datapoint for subject 1 &amp; Form A &amp; Red Pen, as in this example, but multiple), so I've summarized to get mean Time.</p>
  <pre><code>df &lt;- original.df %&gt;% dplyr::select(ID, Form, Pen, Time)
  df &lt;- df %&gt;% dplyr::group_by(ID, Form, Pen) %&gt;% dplyr::summarise(Time = mean(Time))
  df &lt;- df %&gt;% convert_as_factor(ID, Form, Pen)
  df$Time &lt;- as.numeric(df$Time)
  </code></pre>
  <p>I wanted to test the main and interactive effects, so I'm doing a 2 by 3 repeated measures ANOVA (a two way ANOVA, because Form and Pen are two independent variables).</p>
  <pre><code>aov &lt;- rstatix::anova_test(data = df, dv = Time, wid = ID, within = c(Form, Pen))
  </code></pre>
  <p>and I KEEP getting this error:</p>
  <pre><code>Error: Problem with `mutate()` input `data`.
  x Can't subset columns that don't exist.
  x Columns `ID` and `Form` don't exist.
  ℹ Input `data` is `map(.data$data, .f, ...)`.
  </code></pre>
  <p>WHY?! Any help would be greatly appreciated. I've been searching solutions for HOURS and I'm getting pretty frustrated.</p>