title: factories and unique numbers in a pandas dataframe
body: <p>I have a dataframe that looks like:</p>
  
  <pre><code>import pandas as pd
  import random
  
  d={'ID':["x1", "x2", "x1"],
  'CUSIP':['a', 'b', "#NULL"],
  'ISIN':["#NULL", "#NULL", 'I']}
  
  df=pd.DataFrame(data=d)
  df
  </code></pre>
  
  <p>I am trying to replace all the '#NULL' with a unique number suffix. So, the output table will look something like:</p>
  
  <pre><code>import pandas as pd
  import random
  
  d={'ID':["x1", "x2", "x1"],
  'CUSIP':['a', 'b', "#NULL_1"],
  'ISIN':["#NULL_2", "#NULL_3", 'I']}
  
  df=pd.DataFrame(data=d)
  df
  </code></pre>