Created
November 12, 2022 11:57
-
-
Save loreno-heer/caee38e51a14cc1079b5dc09a3cbffcf to your computer and use it in GitHub Desktop.
Reading a Excel file with pandas and plotting it with matplotlib. May need to install dependencies (pip install pandas, pip install matplotlib, pip install openpyxl)
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import pandas as pd | |
import matplotlib.pyplot as plt | |
# import matplotlib.dates | |
data = pd.read_excel("test.xlsx") | |
N = list(data['n']) | |
P = list(data['P']) | |
plt.figure() | |
plt.plot(N,P) | |
plt.show() |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment