Issue
I am trying to load a .csv file lying on my desktop using pandas on jupyter notebook and getting the following error:
What's the problem with the code? The same method works on windows. (I'm using ubuntu 16.04 LTS)
Solution
Try passing encoding='utf-8'
argument in your read_csv
function, like this:
data = pd.read_csv('file_name.csv', encoding='utf-8')
Hope this helps.
Answered By - Rishabh Agrahari
0 comments:
Post a Comment
Note: Only a member of this blog may post a comment.