forked from justinbois/bootcamp
-
Notifications
You must be signed in to change notification settings - Fork 0
/
lesson23-24.py
44 lines (36 loc) · 1.05 KB
/
lesson23-24.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
# I am Justin Bois and this is my Python Header
import numpy as np
import scipy.stats
# This is how we import the module of Matplotlib we'll be using
import matplotlib.pyplot as plt
import seaborn as sns
rc={'lines.linewidth': 2, 'axes.labelsize': 18,
'axes.titlesize': 18}
sns.set(rc=rc)
data_txt = np.loadtxt('data/collins_switch.csv',
delimiter=',', skiprows=2)
# # Slice out iptg and gfp
iptg = data_txt[:,0]
gfp = data_txt[:,1]
sem = data_txt[:,2]
#
# # Plot ipgt vs gfp
# plt.semilogx(iptg, gfp, linestyle='none', marker='.',
# markersize=20)
# plt.xlabel('IPTG (mM)')
# plt.ylabel('Normalized GFP')
# plt.title('IPTG Titration - semilog X')
# plt.ylim(-0.02, 1.02)
# plt.xlim(8e-4, 15)
# plt.show()
# # Plot ipgt vs gfp
# plt.errorbar(iptg, gfp, yerr=sem, linestyle='none',
# marker='.', markersize=20)
# plt.xlabel('IPTG (mM)')
# plt.ylabel('Normalized GFP')
# plt.title('IPTG Titration - semilog X w/ ErrorBars')
# plt.ylim(-0.02, 1.02)
# plt.xlim(8e-4, 15)
# plt.xscale('log')
# plt.show()
# Practice exercise 3