title: How to deal with TypeError: must be str, not float
body: <p>I am trying to run this</p>
  
  <pre><code> pa['pattern'] = pa['AccessType']  + pa.groupby(['AccessedBy'])['AccessType'].shift(1)
  </code></pre>
  
  <p>but it's throwing </p>
  
  <pre><code>  TypeError: must be str, not float
  </code></pre>
  
  <p>But </p>
  
  <pre><code>AccessedBy                 object
  AccessType                 object
  </code></pre>
  
  <p>It was running fine when I last run it few days back. what am I missing ?</p>