@@ -1880,27 +1880,27 @@ def plotHistory(self,m,xaxis='model_number',y1='star_mass',y2=None,show=True,
1880
1880
1881
1881
def plotKip (self ,m ,show = True ,reloadHistory = False ,xaxis = 'num' ,ax = None ,xrng = [None ,None ],mix = None ,show_mix = True ,
1882
1882
cmin = None ,cmax = None ,burnMap = [mpl .cm .Purples_r ,mpl .cm .hot_r ],fig = None ,yrng = None ,ylabel = None ,
1883
- show_mass_loc = False ,show_mix_labels = True ,mix_alpha = 1.0 ,step = 1 ,y2 = None ,title = None ,y2rng = None ):
1883
+ show_mass_loc = False ,show_mix_labels = True ,mix_alpha = 1.0 ,step = 1 ,y2 = None ,title = None ,y2rng = None , zone_frac = 1.0 ):
1884
1884
1885
1885
self .plotKip3 (m ,plot_type = 'history' ,xaxis = 'model_number' ,show = show ,
1886
1886
reloadHistory = reloadHistory ,ax = ax ,mod_min = xrng [0 ],mod_max = xrng [1 ],show_mix = show_mix ,mix = mix ,
1887
1887
cmin = cmin ,cmax = cmax ,cmap = burnMap ,fig = fig ,yrng = yrng ,ylabel = ylabel ,
1888
1888
show_mass_loc = show_mass_loc ,show_mix_labels = show_mix_labels ,mix_alpha = mix_alpha ,
1889
- xstep = step ,y2 = y2 ,title = title ,y2rng = y2rng )
1889
+ xstep = step ,y2 = y2 ,title = title ,y2rng = y2rng , zone_frac = zone_frac )
1890
1890
1891
1891
def plotKip2 (self ,m ,show = True ,reloadHistory = False ,xaxis = 'num' ,ageZero = 0.0 ,ax = None ,xrng = [None ,None ],mix = None ,
1892
1892
cmin = None ,cmax = None ,burnMap = [mpl .cm .Purples_r ,mpl .cm .hot_r ],fig = None ,yrng = None ,
1893
1893
show_mix = True ,show_burn = True ,
1894
1894
show_mass_loc = False ,show_mix_labels = True ,mix_alpha = 1.0 ,step = 1 ,max_mass = 99999.0 ,age_collapse = False ,age_log = True ,age_reverse = False ,
1895
- mod_out = None ,xlabel = None ,title = None ,colorbar = True ,burn = True ,end_time = None ,ylabel = None ,age_zero = None ,y2 = None ,y2rng = None ):
1895
+ mod_out = None ,xlabel = None ,title = None ,colorbar = True ,burn = True ,end_time = None ,ylabel = None ,age_zero = None ,y2 = None ,y2rng = None , zone_frac = 1.0 ):
1896
1896
1897
1897
self .plotKip3 (m ,plot_type = 'history' ,xaxis = 'star_age' ,show = show ,
1898
1898
reloadHistory = reloadHistory ,ax = ax ,mod_min = xrng [0 ],mod_max = xrng [1 ],show_mix = show_mix ,mix = mix ,
1899
1899
cmin = cmin ,cmax = cmax ,cmap = burnMap ,fig = fig ,yrng = yrng ,
1900
1900
show_mass_loc = show_mass_loc ,show_mix_labels = show_mix_labels ,mix_alpha = mix_alpha ,
1901
1901
xstep = step ,y2 = y2 ,title = title ,y2rng = y2rng ,colorbar = colorbar ,ylabel = ylabel ,
1902
1902
age_zero = age_zero ,age_lookback = age_collapse ,age_log = age_log ,age_reverse = age_reverse ,
1903
- mod_index = mod_out ,xlabel = xlabel ,show_burn = burn ,end_time = end_time )
1903
+ mod_index = mod_out ,xlabel = xlabel ,show_burn = burn ,end_time = end_time , zone_frac = zone_frac )
1904
1904
1905
1905
1906
1906
#Will replace plotKip and plotKip2 when finished
@@ -1913,7 +1913,7 @@ def plotKip3(self,m,plot_type='history',xaxis='model_number',yaxis='mass',zaxis=
1913
1913
cmin = None ,cmax = None ,cmap = [mpl .cm .Purples_r ,mpl .cm .hot_r ],colorbar = True ,cbar_label = None ,
1914
1914
show_mass_loc = False ,show_mix_labels = True ,mix_alpha = 1.0 ,
1915
1915
age_lookback = False ,age_log = True ,age_reverse = False ,age_units = 'years' ,end_time = None ,age_zero = None ,
1916
- y2 = None ,y2rng = None ,mod_index = None ,zlog = False ):
1916
+ y2 = None ,y2rng = None ,mod_index = None ,zlog = False , zone_frac = 1.0 ):
1917
1917
1918
1918
if fig == None :
1919
1919
fig = plt .figure (figsize = (12 ,12 ))
@@ -1962,7 +1962,7 @@ def plotKip3(self,m,plot_type='history',xaxis='model_number',yaxis='mass',zaxis=
1962
1962
mix_data = []
1963
1963
1964
1964
#Number of zones to plot
1965
- num_zones = np .max (m .hist .num_zones )
1965
+ num_zones = np .max (m .hist .num_zones ) * 1.0 / zone_frac
1966
1966
1967
1967
if plot_type == 'history' :
1968
1968
if xaxis == 'model_number' :
0 commit comments