How do I open a tab delimited text file in pandas so that I can then use it for exploratory data analysis?
<p>I have a tab delimited file with data about some movies. Some movie titles are enclosed in a double quote. How can I read the file into a pandas dataframe and how can I remove the double quote from the movie titles?  </p>

<p>I know how to do it in R and I know how to remove the double quotes. However, is there an equivalent function in pandas to do that? But most importantly how do I load it into a pandas dataframe?</p>

<p>You can use <code>read_table</code> as its <code>quotechar</code> parameter is set to <code>'"'</code> by default and will so remove the double quotes.</p>

<pre><code>import pandas as pd
from io import StringIO

the_data = """
A   B   C   D
ABC 2016-6-9 0:00   95  "foo foo"
ABC 2016-6-10 0:00  0   "bar bar"
"""
df = pd.read_table(StringIO(the_data))
print(df)

#      A               B   C        D
# 0  ABC   2016-6-9 0:00  95  foo foo
# 1  ABC  2016-6-10 0:00   0  bar bar
</code></pre>

python pandas