title: How to recode values of a character column in a dataframe?
body: <p>Beginner Question: What is a simple way to rename a variable observation in a dataframe column?</p>
  <p>I have dataframe &quot;Stuff&quot; with a column of categorical data called &quot;Age&quot; where one of the data variables is called &quot;Age80+&quot;. I've learned that R does not like &quot;+&quot; in a name,</p>
  <p>e.g. Age80+ &lt;-    brings up an error</p>
  <p>In column &quot;Age&quot; there are 7 other variable numbers, e.g. &quot;Age18_30&quot; so I cannot manually change the observation names efficiently.</p>
  <p>I have looked but I haven't found a simple way to rename all &quot;Age80+&quot; to &quot;Age80plus&quot; without bringing in complicated packages like &quot;stringer&quot; or &quot;dplyr&quot;. The dataframe has 100's of &quot;Age80+&quot; observations.</p>
  <p>Thank you</p>
  <p>I have tried</p>
  <pre><code>Stuff$Age&lt;- gsub(&quot;Age80+&quot;, &quot;Age80plus&quot;, Stuff$Age)
  </code></pre>
  <p>But that changes &quot;Age80+&quot; to &quot;Age80plus+&quot; not &quot;Age80plus&quot;</p>
  <p>The change leaves the &quot;+&quot;</p>