import pandas as pd
from io import StringIO
csv_one = """\
one;two;three
1;2;3;
4;5;6;
"""
df1 = pd.read_csv(StringIO(csv), sep=";")
This data looks as:
one two three
1 2 3 NaN
4 5 6 NaN
The desired result is:
one two three
1 2 3
4 5 6
I could manually edit the csv, but I don't really want to have to do that if possible.
In R the function read_delim can manage this with something along the lines of read_delim( <path>, ";", escape_double = FALSE, trim_ws = TRUE)