Changes

Jump to navigation Jump to search

Matplotlib DPL94 R1rho R2eff

651 bytes added, 19:01, 13 March 2014
x_w_eff = []
x_theta = []
x_disp_point = []
y = []
R1 = cdp.myspin.ri_data['R1']
R1_rho = cdp.myspin.r2eff[dic_key]
print(dic_key.split("_"))
 
# Get disp_point, the Spin-lock field strength
x_disp_point.append(float(dic_key.split("_")[-1]))
# Get w_eff
R1rho_R2eff = (R1_rho - R1*cos(theta)*cos(theta)) / (sin(theta) * sin(theta))
y.append(R1rho_R2eff)
 
print x_disp_point
# Modify data
plt.ylim([0,16])
plt.title("%s \n %s as function of %s"%(spin_inte,ylabel, xlabel))
#plt.savefig("matplotlib_%s_%s_w_eff.png"%(spin_inte_rep, plotlabel) )
# Plot R1rho_R2eff as function of w_eff
plt.ylim([0,16])
plt.title("%s \n %s as function of %s"%(spin_inte,ylabel, xlabel))
#plt.savefig("matplotlib_%s_%s_theta.png"%(spin_inte_rep, plotlabel) ) # Plot R1rho_R2eff as function of disp_point, the Spin-lock field strengthplt.figure()plotlabel = 'R1rho_R2eff'plt.plot(x_disp_point, y, 'o', label='R1rho_R2eff')xlabel = 'Spin-lock field strength [Hz]'plt.xlabel(xlabel)ylabel = 'R1rho_R2eff [rad.s^-1]'plt.ylabel(ylabel)plt.legend(loc='best')plt.grid(True)#plt.ylim([0,16])plt.title("%s \n %s as function of %s"%(spin_inte,ylabel, xlabel))plt.savefig("matplotlib_%s_%s_disp.png"%(spin_inte_rep, plotlabel) )  
plt.show()
</source>
Trusted, Bureaucrats
1,382

edits

Navigation menu