You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Using converters kwarg to get the data how I like will fix my problem, but we may want to update the docs to let users know true/false user defined values will not work in conjugation with providing the boolean type.
The text was updated successfully, but these errors were encountered:
Confirmed. I'd like to read a column containing t, f & `` as a nullable boolean. dtype={'column_name':'boolean'} does not respect `true_values=['t']`.
I've also tried using a converter to replace t with True and f with False, but read_csv ignores dtype parameters where a converter is used, so the column is read as an object series, rather than a nullable boolean.
For now, my workaround is to pass true_values=['t'] (and the equivalent for 'f') to read_csv, and chain astype({'column_name':'boolean'}).
Hi friends,
Not sure if this is working as intended, but it appears you cannot use both dtype and true_values or false_values kwargs when reading csv.
Using converters kwarg to get the data how I like will fix my problem, but we may want to update the docs to let users know true/false user defined values will not work in conjugation with providing the boolean type.
The text was updated successfully, but these errors were encountered: