CSV file dont open with code - Printable Version +- Python Forum (https://python-forum.io) +-- Forum: Python Coding (https://python-forum.io/forum-7.html) +--- Forum: Data Science (https://python-forum.io/forum-44.html) +--- Thread: CSV file dont open with code (/thread-14240.html) |
CSV file dont open with code - ayaz786amd - Nov-21-2018 i have put the following code in python shell and it working fine but not opening in pycharm import pandas as pd import numpy as np df = pd.read_csv('C:\Program Files\PycharmProjects\code examples\StatementImportTemplate.csv') df.head()its showing just in output: "C:\Program Files\python.exe" "C:/Program Files/PycharmProjects/code examples/code practice.py" Process finished with exit code 0 csv file has two columns one has date other has numbers RE: CSV file dont open with code - gontajones - Nov-21-2018 Are you running this as a file ('python "code practice.py"'), right? Your code is fine. Try to use print(df.head()) to output head() content in your console (prompt).
RE: CSV file dont open with code - ayaz786amd - Nov-21-2018 thanks its working |