title: Is there any faster way to delete all white space/tabs of a dataframe in pandas?
body: <p>What is the optimal way to remove all the spaces from a pandas data frame?
  In SO I have found some suggestions as:</p>
  
  <pre><code>df = df.replace({'\s': ''}, regex=True)
  </code></pre>
  
  <p>or</p>
  
  <pre><code>df.replace({'\n': '&lt;br&gt;'}, regex=True)
  </code></pre>
  
  <p>But since my data is too large, is taking too much time to compute.
  for a small fraction of my dataset is taking 2mins. And my full dataset is (1Tb)</p>
  
  <p>Is there any way to improve this? Parallelize? Better function? or just use another language?</p>