I am working on loading a sample csv file using koalas. What I see is a weird behavior.
The file has a blank column area_code
which looks like this. As you can see, it is a blank column. All the rows for this column have blank.
When I read the file as df = ks.read_csv('zipcodes.csv')
, I get the following output, which means that the column has nulls, as expected, all good.
When I read the file as df = ks.read_csv('zipcodes.csv', dtype = str)
, I get the following output, which means that the column doesn't have any nulls.
After a closer look, it seems that the dtype = str
is causing this column to be loaded with a string value = None
Any reason why would this happen. Any help is appreciated. Thanks in advance.
Bhupesh C