title: Pandas: convert object to str
body: <p>I have the following dataframe:</p>
  <pre><code>    R_fighter       B_fighter           win_by                  last_round  Referee         date            Winner
  0   Adrian Yanez    Gustavo Lopez       KO/TKO                  3           Chris Tognoni   March 20, 2021  Adrian Yanez
  1   Trevin Giles    Roman Dolidze       Decision - Unanimous    3           Herb Dean       March 20, 2021  Trevin Giles
  2   Tai Tuivasa     Harry Hunsucker     KO/TKO                  1           Herb Dean       March 20, 2021  Tai Tuivasa
  3   Cheyanne Buys   Montserrat Conejo   Decision - Unanimous    3           Mark Smith      March 20, 2021  Montserrat Conejo
  4   Marion Reneau   Macy Chiasson       Decision - Unanimous    3           Mark Smith      March 20, 2021  Macy Chiasson
  </code></pre>
  <p>I'm trying to convert the type of the column <strong>win_by</strong> from <code>object</code> to <code>str</code>. <br>
  I use <code>.astype()</code> as suggested here <a href="https://stackoverflow.com/questions/33957720/how-to-convert-column-with-dtype-as-object-to-string-in-pandas-dataframe">How to convert column with dtype as object to string in Pandas Dataframe</a>: <br></p>
  <pre><code>UFC_db['win_by'] = UFC_db['win_by'].astype('|S')
  </code></pre>
  <p>but nothing changed:</p>
  <pre><code>&lt;class 'pandas.core.frame.DataFrame'&gt;
  RangeIndex: 6012 entries, 0 to 6011
  Data columns (total 7 columns):
   #   Column      Non-Null Count  Dtype 
  ---  ------      --------------  ----- 
   0   R_fighter   6012 non-null   object
   1   B_fighter   6012 non-null   object
   2   win_by      6012 non-null   object
   3   last_round  6012 non-null   object
   4   Referee     6012 non-null   object
   5   date        6012 non-null   object
   6   Winner      6012 non-null   object
  dtypes: object(7)
  memory usage: 328.9+ KB
  </code></pre>
  <p>I also tried</p>
  <pre><code>UFC_db['win_by'] = UFC_db['win_by'].astype('str')
  
  UFC_db['win_by'] = UFC_db['win_by'].astype(str)
  </code></pre>
  <p>and</p>
  <pre><code>UFC_db['win_by'] = UFC_db['win_by'].astype('str',errors =&quot;ignore&quot;)
  </code></pre>
  <p>as suggested here <a href="https://stackoverflow.com/questions/52240694/python-pandas-column-type-casting-with-astype-is-not-working">Python - pandas column type casting with &quot;astype&quot; is not working</a></p>
  <p>but still nothing changed</p>