Permission denied when pandas dataframe to tempfile csv

后端 未结 6 2089

I\'m trying to store a pandas dataframe to a tempfile in csv format (in windows), but am being hit by:

[Errno 13] Permission denied: \'C:\\Users\\Username\\AppData\\Loca

6条回答
  •  借酒劲吻你
    2021-02-20 02:43

    I encountered the same error message and the issue was resolved after adding "/df.csv" to file_path.

    df.to_csv('C:/Users/../df.csv', index = False)
    

提交回复
热议问题