df_sample['prediction']=prediction ## Now let's save it to the proper submission.csv file. It is important to set index parameter to "False", ## otherwise our row index would be included in the output file. I would't recommend it. df_sample.to_csv('submission.csv', index=False)
Preview:
downloadDownload PNG
downloadDownload JPEG
downloadDownload SVG
Tip: You can change the style, width & colours of the snippet with the inspect tool before clicking Download!
Click to optimize width for Twitter