You cannot select more than 25 topics Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.

20 lines
412 B
Python

#!/usr/bin/env python
import matplotlib.pylab as plt
import csv
x_values = []
y_values = []
y_err = []
with open('data.txt') as FILE:
data = csv.reader(FILE, delimiter='\t')
for row in data:
x_values.append(float(row[4]))
y_values.append(float(row[0]))
y_err.append(float(row[1]))
print(x_values)
plt.errorbar(x_values,y_values,yerr=y_err)
plt.savefig('plot.png')