def plot_isoratios(self,xiso,yiso,fign=<NUM_LIT:1>,spec=None,deltax=True,deltay=True,logx=False,logy=False,<EOL>title=None,legend=None,legloc='<STR_LIT>',errbar=True,dcycle=<NUM_LIT>,addiso=None,<EOL>co_toggle='<STR_LIT:c>',cust_toggle=None,shift=<NUM_LIT:0>,weighting=None,zoneselect=None,iniabufile='<STR_LIT>',<EOL>plt_sparse=<NUM_LIT:1>,plt_symb='<STR_LIT:o>',plt_col='<STR_LIT:k>',plt_lt='<STR_LIT:->',plt_lw=<NUM_LIT:1.>,alpha_dum=<NUM_LIT:1.>,plt_massrange=False,plt_show=True,<EOL>figsave=False):
from . import utils as u<EOL>if len(iniabufile.split('<STR_LIT:/>')) == <NUM_LIT:1> :   <EOL><INDENT>scriptpathtmp = __file__<EOL>if len(scriptpathtmp.split('<STR_LIT:/>')) == <NUM_LIT:1>:   <EOL><INDENT>scriptpathtmp = os.path.abspath('<STR_LIT:.>') + '<STR_LIT>'   <EOL><DEDENT>svnpathtmp = '<STR_LIT:/>'<EOL>for i in range(len(scriptpathtmp.split('<STR_LIT:/>'))-<NUM_LIT:3>):   <EOL><INDENT>if scriptpathtmp.split('<STR_LIT:/>')[i] != '<STR_LIT>':<EOL><INDENT>svnpathtmp += scriptpathtmp.split('<STR_LIT:/>')[i] + '<STR_LIT:/>'<EOL><DEDENT><DEDENT>iniabufile = svnpathtmp + '<STR_LIT>' + iniabufile   <EOL><DEDENT>inut = u.iniabu(iniabufile)<EOL>try:<EOL><INDENT>xrat_solsys = inut.isoratio_init(xiso)<EOL><DEDENT>except KeyError:   <EOL><INDENT>xrat_solsys = <NUM_LIT:0.><EOL><DEDENT>try:<EOL><INDENT>yrat_solsys = inut.isoratio_init(yiso)<EOL><DEDENT>except KeyError:<EOL><INDENT>yrat_solsys = <NUM_LIT:0.><EOL><DEDENT>xrat_solsys *= (old_div(float(xiso[<NUM_LIT:1>].split('<STR_LIT:->')[<NUM_LIT:1>]), float(xiso[<NUM_LIT:0>].split('<STR_LIT:->')[<NUM_LIT:1>])))<EOL>yrat_solsys *= (old_div(float(yiso[<NUM_LIT:1>].split('<STR_LIT:->')[<NUM_LIT:1>]), float(yiso[<NUM_LIT:0>].split('<STR_LIT:->')[<NUM_LIT:1>])))<EOL>xdataerr = None<EOL>ydataerr = None<EOL>if self._classTest() == '<STR_LIT>':<EOL><INDENT>if spec==None:<EOL><INDENT>spec = str(eval(input('<STR_LIT>'<EOL>'<STR_LIT>')))<EOL><DEDENT>if spec == '<STR_LIT>':<EOL><INDENT>print('<STR_LIT>')<EOL>tp_pos, co_return = self._tp_finder(dcycle)<EOL>tp_pos_tmp = []<EOL>co_return_tmp  = []<EOL>tp_pos_tmp.append(<NUM_LIT:1>)<EOL>co_return_tmp.append(co_return[<NUM_LIT:0>])<EOL>for i in range(len(tp_pos)):<EOL><INDENT>tp_pos_tmp.append(tp_pos[i])<EOL>co_return_tmp.append(co_return[i])<EOL><DEDENT>tp_pos = tp_pos_tmp<EOL>co_return = co_return_tmp<EOL>iso_alldata = self.get(tp_pos,[xiso[<NUM_LIT:0>],xiso[<NUM_LIT:1>],yiso[<NUM_LIT:0>],yiso[<NUM_LIT:1>]])<EOL>xrat = np.zeros(len(iso_alldata))<EOL>yrat = np.zeros(len(iso_alldata))<EOL>for i in range(len(iso_alldata)):<EOL><INDENT>xrat[i] = old_div(iso_alldata[i][<NUM_LIT:0>], iso_alldata[i][<NUM_LIT:1>])<EOL>yrat[i] = old_div(iso_alldata[i][<NUM_LIT:2>], iso_alldata[i][<NUM_LIT:3>])<EOL><DEDENT>for i in range(len(xrat)):<EOL><INDENT>xrat[i] *= old_div(float(xiso[<NUM_LIT:1>].split('<STR_LIT:->')[<NUM_LIT:1>]), float(xiso[<NUM_LIT:0>].split('<STR_LIT:->')[<NUM_LIT:1>]))<EOL>yrat[i] *= old_div(float(yiso[<NUM_LIT:1>].split('<STR_LIT:->')[<NUM_LIT:1>]), float(yiso[<NUM_LIT:0>].split('<STR_LIT:->')[<NUM_LIT:1>]))<EOL><DEDENT>if deltax:<EOL><INDENT>xrat = (old_div(xrat,xrat_solsys) -<NUM_LIT:1.>) * <NUM_LIT><EOL><DEDENT>if deltay:<EOL><INDENT>yrat = (old_div(yrat,yrat_solsys) -<NUM_LIT:1.>) * <NUM_LIT><EOL><DEDENT>xdata_o = []<EOL>ydata_o = []<EOL>xdata_c = []<EOL>ydata_c = []<EOL>for i in range(len(co_return)):<EOL><INDENT>if co_return[i] <= <NUM_LIT:1.>:<EOL><INDENT>xdata_o.append(xrat[i])<EOL>ydata_o.append(yrat[i])<EOL><DEDENT>else:<EOL><INDENT>xdata_c.append(xrat[i])<EOL>ydata_c.append(yrat[i])<EOL><DEDENT><DEDENT>if xdata_o != [] and xdata_c != []:<EOL><INDENT>xdata_o.append(xdata_c[<NUM_LIT:0>])<EOL>ydata_o.append(ydata_c[<NUM_LIT:0>])<EOL><DEDENT>style_o = [plt_symb + '<STR_LIT>', plt_col, '<STR_LIT>', '<STR_LIT:4>', '<STR_LIT:2>',None]<EOL>style_c = [plt_symb + plt_lt,  plt_col, plt_col, '<STR_LIT>', '<STR_LIT:1>', legend]<EOL>xdata = []<EOL>ydata = []<EOL>style = []<EOL>if xdata_o != []:<EOL><INDENT>xdata.append(xdata_o)<EOL>ydata.append(ydata_o)<EOL>style.append(style_o)<EOL><DEDENT>if xdata_c != []:<EOL><INDENT>xdata.append(xdata_c)<EOL>ydata.append(ydata_c)<EOL>style.append(style_c)<EOL><DEDENT><DEDENT>elif spec == '<STR_LIT>':<EOL><INDENT>print('<STR_LIT>')<EOL>co_toggle = co_toggle.lower()<EOL>isotope_list = [xiso[<NUM_LIT:0>],xiso[<NUM_LIT:1>],yiso[<NUM_LIT:0>],yiso[<NUM_LIT:1>]]<EOL>cyc_no = self.se.cycles[len(self.se.cycles)-<NUM_LIT:1>-shift]<EOL>mco_data = self.get(cyc_no,['<STR_LIT>','<STR_LIT>','<STR_LIT>','<STR_LIT>','<STR_LIT>','<STR_LIT>',xiso[<NUM_LIT:0>],xiso[<NUM_LIT:1>],yiso[<NUM_LIT:0>],yiso[<NUM_LIT:1>]])<EOL>mass = mco_data[<NUM_LIT:0>]<EOL>if cust_toggle == None:<EOL><INDENT>c_elem = mco_data[<NUM_LIT:1>]+mco_data[<NUM_LIT:2>]<EOL>o_elem = mco_data[<NUM_LIT:3>]+mco_data[<NUM_LIT:4>]+mco_data[<NUM_LIT:5>]<EOL>co_ratio = c_elem / o_elem * (old_div(<NUM_LIT>, <NUM_LIT>))<EOL>co_comp_val = <NUM_LIT:1.><EOL><DEDENT>else:<EOL><INDENT>co_data1 = self.get(cyc_no,cust_toggle[<NUM_LIT:0>])<EOL>co_data2 = self.get(cyc_no,cust_toggle[<NUM_LIT:1>])<EOL>for i in range(len(co_data1)):<EOL><INDENT>if i == <NUM_LIT:0>:<EOL><INDENT>c_elem = co_data1[i]<EOL><DEDENT>else:<EOL><INDENT>c_elem += co_data1[i]<EOL><DEDENT><DEDENT>for i in range(len(co_data2)):<EOL><INDENT>if i == <NUM_LIT:0>:<EOL><INDENT>o_elem = co_data2[i]<EOL><DEDENT>else:<EOL><INDENT>o_elem += co_data2[i]<EOL><DEDENT><DEDENT>massn1 = <NUM_LIT:0.><EOL>for i in range(len(co_data1)):<EOL><INDENT>massn1 += sum(co_data1[i]) * float(cust_toggle[<NUM_LIT:0>][i].split('<STR_LIT:->')[<NUM_LIT:1>])<EOL><DEDENT>massn1 /= sum(c_elem)<EOL>massn2 = <NUM_LIT:0.><EOL>for i in range(len(co_data2)):<EOL><INDENT>massn2 += sum(co_data2[i]) * float(cust_toggle[<NUM_LIT:1>][i].split('<STR_LIT:->')[<NUM_LIT:1>])<EOL><DEDENT>massn2 /= sum(o_elem)<EOL>co_ratio = c_elem / o_elem * (old_div(massn2, massn1))   <EOL>co_comp_val = float(cust_toggle[<NUM_LIT:2>])<EOL><DEDENT>isotope_profile = []<EOL>for i in range(<NUM_LIT:6>,<NUM_LIT:10>):   <EOL><INDENT>isotope_profile.append(mco_data[i])<EOL><DEDENT>if addiso != None:<EOL><INDENT>if type(addiso[<NUM_LIT:0>] == list):   <EOL><INDENT>for i in range(len(addiso)):<EOL><INDENT>for j in range(<NUM_LIT:4>):<EOL><INDENT>if isotope_list[j] == addiso[i][<NUM_LIT:0>]:<EOL><INDENT>multiplicator_addiso = <NUM_LIT:1.><EOL>try:<EOL><INDENT>multiplicator_addiso = float(addiso[i][<NUM_LIT:1>])<EOL>starter = <NUM_LIT:2><EOL><DEDENT>except ValueError:<EOL><INDENT>starter = <NUM_LIT:1><EOL><DEDENT>for k in range(starter,len(addiso[i])):<EOL><INDENT>isotope_profile[j] += array(self.get(cyc_no,addiso[i][k])) * multiplicator_addiso<EOL><DEDENT><DEDENT><DEDENT><DEDENT><DEDENT>else:<EOL><INDENT>for j in range(<NUM_LIT:4>):<EOL><INDENT>if isotope_list[j] == addiso[<NUM_LIT:0>]:<EOL><INDENT>multiplicator_addiso = <NUM_LIT:1.><EOL>try:<EOL><INDENT>multiplicator_addiso = float(addiso[<NUM_LIT:1>])<EOL>starter = <NUM_LIT:2><EOL><DEDENT>except ValueError:<EOL><INDENT>starter = <NUM_LIT:1><EOL><DEDENT>for k in range(starter,len(addiso)):<EOL><INDENT>isotope_profile[j] += array(self.get(cyc_no,addiso[k])) * multiplicator_addiso<EOL><DEDENT><DEDENT><DEDENT><DEDENT><DEDENT>crich = []   <EOL>dumb = True<EOL>if cust_toggle != None:<EOL><INDENT>for i in range(len(co_ratio)):<EOL><INDENT>if dumb:<EOL><INDENT>if co_ratio[i] >= co_comp_val:<EOL><INDENT>crich.append(i)<EOL>dumb = False<EOL>continue<EOL><DEDENT><DEDENT>else:<EOL><INDENT>if co_ratio[i] < co_comp_val:<EOL><INDENT>crich.append(i)<EOL>dumb = True<EOL><DEDENT><DEDENT><DEDENT><DEDENT>elif co_toggle != '<STR_LIT:a>':<EOL><INDENT>for i in range(len(co_ratio)):<EOL><INDENT>if co_toggle == '<STR_LIT:c>':   <EOL><INDENT>if dumb:<EOL><INDENT>if co_ratio[i] >= <NUM_LIT:1>:<EOL><INDENT>crich.append(i)<EOL>dumb = False<EOL>continue<EOL><DEDENT><DEDENT>else:<EOL><INDENT>if co_ratio[i] < <NUM_LIT:1>:<EOL><INDENT>crich.append(i)<EOL>dumb = True<EOL><DEDENT><DEDENT><DEDENT>elif co_toggle == '<STR_LIT:o>':   <EOL><INDENT>if dumb:<EOL><INDENT>if co_ratio[i] <= <NUM_LIT:1>:<EOL><INDENT>crich.append(i)<EOL>dumb = False<EOL>continue<EOL><DEDENT><DEDENT>else:<EOL><INDENT>if co_ratio[i] > <NUM_LIT:1>:<EOL><INDENT>crich.append(i)<EOL>dumb = True<EOL><DEDENT><DEDENT><DEDENT>else:<EOL><INDENT>print('<STR_LIT>')<EOL>return None<EOL><DEDENT><DEDENT><DEDENT>else:   <EOL><INDENT>print('<STR_LIT>')<EOL>crich.append(<NUM_LIT:0>)<EOL>crich.append(len(co_toggle))<EOL><DEDENT>if len(crich)%<NUM_LIT:2> == <NUM_LIT:1>:<EOL><INDENT>crich.append(len(co_ratio)-<NUM_LIT:1>)<EOL><DEDENT>if len(crich) == <NUM_LIT:0>:<EOL><INDENT>print('<STR_LIT>')<EOL>return None<EOL><DEDENT>isotope_profile = array(isotope_profile).transpose()<EOL>if co_toggle != '<STR_LIT:a>':<EOL><INDENT>if cust_toggle != None:<EOL><INDENT>print('<STR_LIT>')<EOL><DEDENT>elif co_toggle == '<STR_LIT:c>':<EOL><INDENT>print('<STR_LIT>')<EOL><DEDENT>elif co_toggle == '<STR_LIT:o>':<EOL><INDENT>print('<STR_LIT>')<EOL><DEDENT>mass_tmp = zeros((len(crich)))<EOL>for i in range(len(crich)):<EOL><INDENT>mass_tmp[i] = mass[crich[i]]<EOL><DEDENT>j = <NUM_LIT:1><EOL>for i in range(old_div(len(crich),<NUM_LIT:2>)):<EOL><INDENT>print('<STR_LIT>' + str(j) + '<STR_LIT>' + str(mass_tmp[<NUM_LIT:2>*i]) + '<STR_LIT>' + str(mass_tmp[<NUM_LIT:2>*i+<NUM_LIT:1>]))<EOL>j += <NUM_LIT:1><EOL><DEDENT>print('<STR_LIT:\n>')<EOL>if zoneselect == '<STR_LIT:all>':<EOL><INDENT>usr_zones = <NUM_LIT:0><EOL><DEDENT>elif zoneselect == '<STR_LIT>':<EOL><INDENT>usr_zones = [j-<NUM_LIT:1>]<EOL><DEDENT>else:<EOL><INDENT>usr_zones = eval(input('<STR_LIT>'))<EOL><DEDENT>crich_dumb = crich<EOL>if usr_zones == <NUM_LIT:0>:<EOL><INDENT>print('<STR_LIT>')<EOL><DEDENT>elif type(usr_zones) == int:   <EOL><INDENT>tmp = int(usr_zones)-<NUM_LIT:1><EOL>crich = crich_dumb[<NUM_LIT:2>*tmp:<NUM_LIT:2>*tmp+<NUM_LIT:2>]<EOL><DEDENT>else:<EOL><INDENT>crich = []<EOL>for i in range(len(usr_zones)):<EOL><INDENT>tmp = int(usr_zones[i])-<NUM_LIT:1><EOL>crich.append(crich_dumb[<NUM_LIT:2>*tmp])<EOL>crich.append(crich_dumb[<NUM_LIT:2>*tmp + <NUM_LIT:1>])<EOL><DEDENT><DEDENT><DEDENT>if weighting == None:<EOL><INDENT>isos_to_use = []<EOL>for i in range(old_div(len(crich),<NUM_LIT:2>)):<EOL><INDENT>isos_dumb = []<EOL>n = crich[<NUM_LIT:2>*i]<EOL>while n <= crich[<NUM_LIT:2>*i+<NUM_LIT:1>]:<EOL><INDENT>isos_dumb.append(isotope_profile[n])<EOL>n += <NUM_LIT:1><EOL><DEDENT>isos_to_use.append(array(isos_dumb))<EOL><DEDENT><DEDENT>elif weighting.lower() == '<STR_LIT>' or weighting.lower() == '<STR_LIT>':<EOL><INDENT>isotope_profile_cweight = zeros((old_div(len(crich),<NUM_LIT:2>),<NUM_LIT:4>))<EOL>mass_tot = []<EOL>for i in range(len(isotope_profile_cweight)):   <EOL><INDENT>if crich[<NUM_LIT:2>*i] == <NUM_LIT:0>:<EOL><INDENT>print('<STR_LIT>')<EOL><DEDENT>else:<EOL><INDENT>dumb = crich[<NUM_LIT:2>*i + <NUM_LIT:1>]<EOL>j = crich[<NUM_LIT:2>*i]<EOL>mass_tmp = <NUM_LIT:0><EOL>while j <= dumb:<EOL><INDENT>mass_shell = mass[j] - mass[j-<NUM_LIT:1>]<EOL>mass_tmp += mass_shell<EOL>for k in range(<NUM_LIT:4>):<EOL><INDENT>isotope_profile_cweight[i][k] += isotope_profile[j][k]*mass_shell<EOL><DEDENT>j += <NUM_LIT:1><EOL><DEDENT>mass_tot.append(mass_tmp)<EOL><DEDENT><DEDENT>for i in range(len(isotope_profile_cweight)):<EOL><INDENT>for j in range(<NUM_LIT:4>):<EOL><INDENT>isotope_profile_cweight[i][j] /= mass_tot[i]<EOL><DEDENT><DEDENT>isos_to_use = [array(isotope_profile_cweight)]<EOL><DEDENT>elif weighting.lower() == '<STR_LIT:all>':   <EOL><INDENT>isos_tmp = zeros((<NUM_LIT:1>, len(isotope_profile[<NUM_LIT:0>])))<EOL>for i in range(len(isotope_profile)-<NUM_LIT:1>):   <EOL><INDENT>for j in range(len(isos_tmp[<NUM_LIT:0>])):<EOL><INDENT>mass_shell = mass[i+<NUM_LIT:1>] - mass[i]<EOL>isos_tmp[<NUM_LIT:0>][j] += isotope_profile[i][j]*mass_shell<EOL><DEDENT><DEDENT>isos_tmp /= sum(mass)<EOL>isos_to_use = [isos_tmp]<EOL><DEDENT>for i in range(len(isos_to_use)):<EOL><INDENT>for j in range(len(isos_to_use[i])):<EOL><INDENT>for k in range(len(isos_to_use[i][j])):<EOL><INDENT>isos_to_use[i][j][k] /= float(isotope_list[k].split('<STR_LIT:->')[<NUM_LIT:1>])<EOL><DEDENT><DEDENT><DEDENT>ratiox = []<EOL>ratioy = []<EOL>for i in range(len(isos_to_use)):<EOL><INDENT>ratiox_dumb = []<EOL>ratioy_dumb = []<EOL>for j in range(len(isos_to_use[i])):<EOL><INDENT>ratiox_dumb.append(old_div(isos_to_use[i][j][<NUM_LIT:0>], isos_to_use[i][j][<NUM_LIT:1>]))<EOL>ratioy_dumb.append(old_div(isos_to_use[i][j][<NUM_LIT:2>], isos_to_use[i][j][<NUM_LIT:3>]))<EOL><DEDENT>ratiox.append(array(ratiox_dumb))<EOL>ratioy.append(array(ratioy_dumb))<EOL><DEDENT>ratiox = array(ratiox)<EOL>ratioy = array(ratioy)<EOL>for i in range(len(ratiox)):<EOL><INDENT>for j in range(len(ratiox[i])):<EOL><INDENT>ratiox[i][j] *= (old_div(float(xiso[<NUM_LIT:1>].split('<STR_LIT:->')[<NUM_LIT:1>]), float(xiso[<NUM_LIT:0>].split('<STR_LIT:->')[<NUM_LIT:1>])))<EOL>ratioy[i][j] *= (old_div(float(yiso[<NUM_LIT:1>].split('<STR_LIT:->')[<NUM_LIT:1>]), float(yiso[<NUM_LIT:0>].split('<STR_LIT:->')[<NUM_LIT:1>])))<EOL><DEDENT><DEDENT>if deltax:<EOL><INDENT>ratiox_tmp = []<EOL>for i in range(len(ratiox)):<EOL><INDENT>ratiox_tmp_tmp = []<EOL>for j in range(len(ratiox[i])):<EOL><INDENT>ratiox_tmp_tmp.append((old_div(ratiox[i][j], xrat_solsys) - <NUM_LIT:1.>) * <NUM_LIT>)<EOL><DEDENT>ratiox_tmp.append(ratiox_tmp_tmp)<EOL><DEDENT>ratiox = array(ratiox_tmp)<EOL><DEDENT>if deltay:<EOL><INDENT>ratioy_tmp = []<EOL>for i in range(len(ratioy)):<EOL><INDENT>ratioy_tmp_tmp = []<EOL>for j in range(len(ratioy[i])):<EOL><INDENT>ratioy_tmp_tmp.append((old_div(ratioy[i][j], yrat_solsys) - <NUM_LIT:1.>) * <NUM_LIT>)<EOL><DEDENT>ratioy_tmp.append(ratioy_tmp_tmp)<EOL><DEDENT>ratioy = array(ratioy_tmp)<EOL><DEDENT>plt_massrange_lst = []<EOL>if plt_massrange==True:   <EOL><INDENT>for i in range(len(ratiox)):<EOL><INDENT>plt_massrange_lst.append([ratiox[i][<NUM_LIT:0>], ratioy[i][<NUM_LIT:0>], mass[crich[<NUM_LIT:2>*i]]])<EOL>plt_massrange_lst.append([ratiox[i][len(ratiox[i])-<NUM_LIT:1>], ratioy[i][len(ratioy[i])-<NUM_LIT:1>], mass[crich[<NUM_LIT:2>*i+<NUM_LIT:1>]]])   <EOL><DEDENT><DEDENT>elif plt_massrange != False:<EOL><INDENT>for plt_mr_val in plt_massrange:<EOL><INDENT>mrng_i = <NUM_LIT:0><EOL>while plt_mr_val > mass[mrng_i] and mrng_i < len(mass):<EOL><INDENT>mrng_i += <NUM_LIT:1><EOL><DEDENT>if mrng_i > <NUM_LIT:0>:<EOL><INDENT>mrng_i -= <NUM_LIT:1><EOL><DEDENT>mratx = old_div(isotope_profile[mrng_i][<NUM_LIT:0>],isotope_profile[mrng_i][<NUM_LIT:1>])<EOL>mraty = old_div(isotope_profile[mrng_i][<NUM_LIT:2>],isotope_profile[mrng_i][<NUM_LIT:3>])<EOL>if deltax:<EOL><INDENT>mratx = (old_div(mratx, ratiox_solsys) - <NUM_LIT:1.>) * <NUM_LIT><EOL><DEDENT>if deltay:<EOL><INDENT>mraty = (old_div(mraty, ratioy_solsys) - <NUM_LIT:1.>) * <NUM_LIT><EOL><DEDENT>plt_massrange_lst.append([mratx,mraty,mass[mrng_i]])<EOL><DEDENT><DEDENT>xdata = ratiox<EOL>ydata = ratioy<EOL>style_tmp0= [plt_symb + plt_lt,  plt_col, plt_col, '<STR_LIT>', '<STR_LIT:1>', legend]<EOL>style_tmp = [plt_symb + plt_lt,  plt_col, plt_col, '<STR_LIT>', '<STR_LIT:1>', None]<EOL>style = []<EOL>for i in range(len(xdata)):<EOL><INDENT>if i == <NUM_LIT:0>:<EOL><INDENT>style.append(style_tmp0)<EOL><DEDENT>else:<EOL><INDENT>style.append(style_tmp)<EOL><DEDENT><DEDENT><DEDENT>else:<EOL><INDENT>print('<STR_LIT>')<EOL>return None<EOL><DEDENT><DEDENT>if self._classTest() == '<STR_LIT>':<EOL><INDENT>print('<STR_LIT>')<EOL>xdata,xdataerr,ydata,ydataerr,style = self.plot_ratio_return(xiso,yiso,deltax,deltay)<EOL>legend=True<EOL>plt_sparse=<NUM_LIT:1>   <EOL>plt_lw = <NUM_LIT:0.><EOL><DEDENT>params = {'<STR_LIT>':  <NUM_LIT:20>,<EOL>'<STR_LIT>':   <NUM_LIT>,<EOL>'<STR_LIT>': <NUM_LIT>,<EOL>'<STR_LIT>': <NUM_LIT>,<EOL>'<STR_LIT>': <NUM_LIT>}<EOL>pl.rcParams.update(params)<EOL>pl.figure(fign)<EOL>for i in range(len(xdata)):<EOL><INDENT>if errbar:<EOL><INDENT>if xdataerr != None or ydataerr != None:<EOL><INDENT>pl.errorbar(xdata[i],ydata[i],xerr=xdataerr[i],yerr=ydataerr[i],marker=style[i][<NUM_LIT:0>],<EOL>color=style[i][<NUM_LIT:1>],linestyle='<STR_LIT>',lw=<NUM_LIT:2>,markevery=plt_sparse,alpha=alpha_dum)<EOL><DEDENT><DEDENT>pl.plot(xdata[i],ydata[i],style[i][<NUM_LIT:0>],c=style[i][<NUM_LIT:1>],mfc=style[i][<NUM_LIT:2>],ms=float(style[i][<NUM_LIT:3>]),<EOL>mew=float(style[i][<NUM_LIT:4>]),label=style[i][<NUM_LIT:5>],markevery=plt_sparse,linewidth=plt_lw,alpha=alpha_dum)<EOL><DEDENT>if plt_massrange != False:<EOL><INDENT>for mrng_ind in range(len(plt_massrange_lst)):<EOL><INDENT>pl.text(plt_massrange_lst[mrng_ind][<NUM_LIT:0>], plt_massrange_lst[mrng_ind][<NUM_LIT:1>],<EOL>str(round(plt_massrange_lst[mrng_ind][<NUM_LIT:2>], <NUM_LIT:2>)), ha='<STR_LIT:right>', va='<STR_LIT>', color=plt_col,fontsize=<NUM_LIT>)<EOL><DEDENT><DEDENT>if logx and logy == False:<EOL><INDENT>pl.semilogx()<EOL><DEDENT>elif logx == False and logy:<EOL><INDENT>pl.semilogy()<EOL><DEDENT>elif logx and logy:<EOL><INDENT>pl.loglog()<EOL><DEDENT>if legend != None and legloc != None:<EOL><INDENT>pl.legend(loc=legloc)<EOL><DEDENT>if title != None:<EOL><INDENT>pl.title(title)<EOL><DEDENT>if deltax:<EOL><INDENT>pl.xlabel('<STR_LIT>' + xiso[<NUM_LIT:0>].split('<STR_LIT:->')[<NUM_LIT:1>] + '<STR_LIT>' +xiso[<NUM_LIT:0>].split('<STR_LIT:->')[<NUM_LIT:0>] + '<STR_LIT>' + xiso[<NUM_LIT:1>].split('<STR_LIT:->')[<NUM_LIT:1>] + '<STR_LIT>' +xiso[<NUM_LIT:1>].split('<STR_LIT:->')[<NUM_LIT:0>] + '<STR_LIT:)>' )<EOL><DEDENT>else:<EOL><INDENT>pl.xlabel('<STR_LIT>' + xiso[<NUM_LIT:0>].split('<STR_LIT:->')[<NUM_LIT:1>] + '<STR_LIT>' +xiso[<NUM_LIT:0>].split('<STR_LIT:->')[<NUM_LIT:0>] + '<STR_LIT>' + xiso[<NUM_LIT:1>].split('<STR_LIT:->')[<NUM_LIT:1>] + '<STR_LIT>' +xiso[<NUM_LIT:1>].split('<STR_LIT:->')[<NUM_LIT:0>])<EOL><DEDENT>if deltay:<EOL><INDENT>pl.ylabel('<STR_LIT>' + yiso[<NUM_LIT:0>].split('<STR_LIT:->')[<NUM_LIT:1>] + '<STR_LIT>' +yiso[<NUM_LIT:0>].split('<STR_LIT:->')[<NUM_LIT:0>] + '<STR_LIT>' + yiso[<NUM_LIT:1>].split('<STR_LIT:->')[<NUM_LIT:1>] + '<STR_LIT>' +yiso[<NUM_LIT:1>].split('<STR_LIT:->')[<NUM_LIT:0>] + '<STR_LIT:)>' )<EOL><DEDENT>else:<EOL><INDENT>pl.ylabel('<STR_LIT>' + yiso[<NUM_LIT:0>].split('<STR_LIT:->')[<NUM_LIT:1>] + '<STR_LIT>' +yiso[<NUM_LIT:0>].split('<STR_LIT:->')[<NUM_LIT:0>] + '<STR_LIT>' + yiso[<NUM_LIT:1>].split('<STR_LIT:->')[<NUM_LIT:1>] + '<STR_LIT>' +yiso[<NUM_LIT:1>].split('<STR_LIT:->')[<NUM_LIT:0>])<EOL><DEDENT>print(xrat_solsys, yrat_solsys)<EOL>if deltay:<EOL><INDENT>pl.axhline(<NUM_LIT:0>,color='<STR_LIT:k>')<EOL><DEDENT>else:<EOL><INDENT>pl.axhline(yrat_solsys,color='<STR_LIT:k>')<EOL><DEDENT>if deltax:<EOL><INDENT>pl.axvline(<NUM_LIT:0>,color='<STR_LIT:k>')<EOL><DEDENT>else:<EOL><INDENT>pl.axvline(xrat_solsys,color='<STR_LIT:k>')<EOL><DEDENT>pl.gcf().subplots_adjust(bottom=<NUM_LIT>)<EOL>pl.gcf().subplots_adjust(left=<NUM_LIT>)<EOL>if figsave != False:<EOL><INDENT>pl.savefig(figsave)<EOL><DEDENT>if plt_show:<EOL><INDENT>pl.show()<EOL><DEDENT>
This is the new routine to plot isotopic ratios for ALL input. rt, June 2014

Parameters:
-----------
xiso : np.array
    x data to plot. This can be an array or a list of arrays, depending on who calls the routine
yiso : np.array
    y data to plot. This can be an array or a list of arrays, depending on who calls the routine
fign : integer, optional
    Figure number
spec : string, optional
    What specifications do you want to do when coming from nugridse models. Choose 'surf' for
    surface models or 'exp' for explosions (out files)
deltax : boolean, optional
    X axis in delta values?
deltay : boolean, optional
    Y axis in delta values?
logx : boolean, optional
    Logarithmic x axis?
logy : boolean, optional
    Logarithmic y axis?
title : string, optional
    Title for your plot
legend : string, optional
    Legend for your model / grains. For grains the legend is automatically taken from the
    grain class
legloc : string / integer, optional
    Location of the legend, use matplotlib standard. Use None to not plot legend if plotted
    by default, e.g., from grain class routine.
errbar : boolean, optional
    Error bars on grain data?
dcycle : integer, optional
    Difference between cycles to take for thermal pulse searching, if searching is
    deactivated, dcycle describes how often cycles are sampled.  The default is 500.
addiso : list, optional
    For explosive models. Add an isotope.  Format ['C-12', 0.5 ,'N-12'] to add N12
    to C12 and multiply it with a factor of 0.5.  Multiple isotopes can be added, the
    factor is optional and does not have to be given.  Isotopes can be added to other
    isotopes as well, i.e., [['C-12', 'N-12'], ['C-13', 'N-13']].  The default None.
    Notice that while addiso = [['N-14','O-14'],['N-14',fractionation,'C-14']]
    works, other options like addiso = [['N-14','O-14',fractionation,'C-14']] or
    addiso = [['N-14',1,'O-14',fractionation,'C-14']] are not working and give Typerror.
    CAREFUL, that for the option addiso = [['N-14',fractionation,'C-14','O-14']] there is
    no error message, but the fractionation is applied to both O14 and C14!
co_toggle : string, optional
    For explosive models, choose what shells you want to look for! Select 'c' for
    selecting zones with C/O >= 1.  Select 'o' for C/O <= 1.  If 'a' takes the
    whole star.  The defalut is 'c'. See cust_toggle (below) for an alternative!
cust_toggle : list, optional
    This option is like co_toggle (and overwrites it when chosen) but lets you choose
    your own comparison. For example you want to find zones that have a 10 fold
    overabundance of Ti-46 and Ti-47 over O-16 and Zr-96, you can choose here
    [['Ti-46','Ti-47'],['O-16','Zr-96'],100.] Assuming the first list is is x, the
    second list y, and the comparator number is f, the statement only plots shells
    in which the condition x/y>f is fulfilled. x and y are number sums of the chosen
    isotopes, f has to be given as a float. This is only for explosive shells. Please
    note, if this toggle is NOT None, then co_toggle is overwritten!
shift : integer, optional
    For explosive models, how much do you want to shift the models back from the
    last cycle? By default (0) the last cycle is taken.
weighting : string, optional
    For explosive models. If None then, plot every profile separately.  If 'zone'
    then, average each zone.  If 'all' then average all selected zones.  The
    default is None.
zoneselect: string, optional
    For explosive models. Select if you want to plot 'all' zones or outer most zone.
    Arguments are 'all' and 'top', respectively. Default is None, then the user is
    asked to provide this information during the routine as input.
iniabufile : string, optional
    Initial abundance file. Use absolute path for your file or filename to choose a
    given file in USEEPP. Attention: You need a standard tree checked out from SVN
plt_sparse : integer, optional
    Every how many datapoints is the plot done? Not used for some routines!
plt_symb : string, optional
    Symbol for the plot. In case of grains, this is handled automatically.
plt_col : string / float, optional
    Color for plotted curve. In case of grains, this is handled automatically.
plt_lt : string, optional
    line type for plot.
plt_lw : float, optional
    Line width for plot.
alpha_dum : trasparency to apply to grains data, in case of many data are plotted.
    This may be allpied also for theoretical curves.
plt_massrange : boolean, optional
    For explosive models. Plot mass of shell with first and last datapoint of
    each zone.  If list given, label those zones.  The default is False.
plt_show : boolean, optional
    Do you want to show the plot or not?
figsave : string, optional
    Give path and filename here, if you want to save the figure.