-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathplots.py
62 lines (25 loc) · 787 Bytes
/
plots.py
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
import matplotlib.pyplot as plt
import numpy as np
class Plot():
def __init__(self):
pass
def basicPlot(self, df, x, y):
plt.plot(df[x], df[y])
self.show()
# Plots a nice looking plot that
# is far better to look at
def coolPlot(self, df, x, y, title):
# fig = plt.figure()
# ax = fig.add_subplot(111)
# ax.plot(df[x], df[y])
# plt.xlabel(x)
# plt.ylabel(y)
# plt.title(title)
# plt.xticks(np.arange(0, len(df[y]), step=len(df[y]) // 4))
# for axis in ['top', 'right']:
# ax.spines[axis].set_visible(False)
# ax.yaxis.tick_left()
# ax.xaxis.tick_bottom()
self.show()
def show(self):
plt.show()