Traitement-signal-plantes/Py-Script/courbe.py

36 lines
688 B
Python

#! /usr/bin/env python3
# -*- coding: UTF-8 -*-
import numpy as np
import matplotlib.pyplot as plt
import csv
tab = np.zeros([1,9])
with open('../RawDataFiles/RawData667.csv', newline='') as csvfile:
reader = csv.reader(csvfile, quoting=csv.QUOTE_NONNUMERIC)
for row in reader:
t = np.zeros([1,9])
t[0] = row
tab = np.append(tab ,t , axis = 0)
#print(tab)
"""
x = tab[:,0]
y = tab[:,1]
print(x)
print("y = " + str(y))
"""
def printFig(axe_x , axe_y , title = "new plot" , xlabel = "axe x" , ylabel = "axe y"):
plt.plot(axe_x , axe_y)
plt.xlabel(xlabel)
plt.ylabel(ylabel)
plt.title(title)
plt.show()
return 0
#printFig(x,y)