title: How do I apply a function with multiple inputs into a data frame using apply?
body: <p>I am trying to convert a cell from a date range (Jan 1- Dec 31, 2021) to just the year with a created function right. I am getting an invalid syntax. Please help</p>
  <pre><code>def right (s, amount):
      return s[-amount:]
  
  df[&quot;Campaign&quot;].apply(right(df[&quot;Campaign&quot;], 4), index = 1)
  print(df)
  </code></pre>