-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathread_models_bapsg.py
More file actions
64 lines (55 loc) · 2.04 KB
/
read_models_bapsg.py
File metadata and controls
64 lines (55 loc) · 2.04 KB
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
63
import matplotlib.pyplot as pl
import numpy as np
import pandas as pd
from collections import OrderedDict
df = pd.read_csv('bastar-psg_rotmix.txt',sep='\t',engine='python').T
cey = df[0].values
sr = df[1].values
df20 = pd.read_csv('monash_3m_007.txt',skiprows=[0,1,2,3],sep='\s+',engine='python')
z11 = df20['[X/H]'].values[22]
y11 = df20['[X/H]'].values[35]
ce11 = df20['[X/H]'].values[54]
cey11 = ce11 - y11
sr11 = 720.
df21 = pd.read_csv('monash_3m_014.txt',skiprows=[0,1,2,3],sep='\s+',engine='python')
z12 = df21['[X/H]'].values[22]
y12 = df21['[X/H]'].values[35]
ce12 = df21['[X/H]'].values[54]
cey12 = ce12 - y12
sr12 = 230.
df22 = pd.read_csv('monash_3m_03.txt',skiprows=[0,1,2,3],sep='\s+',engine='python')
z13 = df22['[X/H]'].values[22]
y13 = df22['[X/H]'].values[35]
ce13 = df22['[X/H]'].values[54]
cey13 = ce13 - y13
sr13 = -145.
CeY3 = np.array([cey11,cey12,cey13])
Sr3 = np.array([sr11,sr12,sr13])
params = {'text.usetex': True,
'xtick.direction': 'in',
'ytick.direction': 'in',
'axes.linewidth' : 5,
'xtick.major.size': 20,
'ytick.major.size': 20,
'xtick.labelsize': 30,
'ytick.labelsize': 30,
'ytick.major.pad': 5,
'ytick.major.width': 3,
'xtick.major.pad': 5,
'xtick.major.width': 3}
pl.rcParams.update(params)
pl.tick_params(axis='both', pad=5)
fig = pl.figure(29) # Figure object
ax = fig.add_subplot(1,1,1)
#pl.fill([-0.5,-0.4,-0.4,-0.5], [-200,-200,0,0], 'gray', alpha=0.5)
#pl.fill([-0.5,-0.22,-0.22,-0.5], [-200,-200,0,0], 'gray', alpha=0.5)
pl.axhline(y=0,linewidth=5, color='k')
pl.axvline(x=0,linewidth=5, color='k')
pl.plot(cey,sr,marker='s',c='tab:green',lw=4,markersize=12.,ls='-',label='This work')
pl.plot(CeY3,Sr3,marker='o',c='tab:blue',lw=4,markersize=12.,ls='-',label='Monash')
handles, labels = pl.gca().get_legend_handles_labels()
by_label = OrderedDict(zip(labels, handles))
pl.legend(by_label.values(), by_label.keys(),prop={'size':25})
pl.xlabel('$[Ce/Y]$', fontsize=40)
pl.ylabel('$\delta({^{88}}Sr/{^{86}}Sr)$', fontsize=40)
pl.show()