@@ -105,8 +105,8 @@ def scatter(x,y, plotdata=True, fig=None, ax=None, makefigax=True,
105105 )
106106 if plotdata :
107107 if percentiles :
108- ax .plot (outs ['xmid' ], outs ['perc16 ' ], linecolor + '-.' , linewidth = linewidth )
109- ax .plot (outs ['xmid' ], outs ['perc84 ' ], linecolor + '-.' , linewidth = linewidth )
108+ ax .plot (outs ['xmid' ], outs ['bins16 ' ], linecolor + '-.' , linewidth = linewidth )
109+ ax .plot (outs ['xmid' ], outs ['bins84 ' ], linecolor + '-.' , linewidth = linewidth )
110110 ax .plot (outs ['xmid' ], outs ['avg_y' ], linewidth = linewidth , color = linecolor , label = binlabel )
111111 return outs
112112 else :
@@ -126,7 +126,7 @@ def error(x,y, plotdata=True, fig=None, ax=None, makefigax=True,
126126 #for plt.plot
127127 linecolor = 'r' ,linewidth = 3 ,
128128 #for set_aesthetics
129- xlabel = '' , ylabel = '' , aspect = 'equal ' ,
129+ xlabel = '' , ylabel = '' , aspect = 'auto ' ,
130130 xlim = [], ylim = []):
131131 fig , ax = figure_check (fig = fig , ax = ax , makefigax = makefigax )
132132 if plotdata :
@@ -150,8 +150,8 @@ def error(x,y, plotdata=True, fig=None, ax=None, makefigax=True,
150150 size_y_bin = size_y_bin , counting_thresh = counting_thresh , percentiles = percentiles ,)
151151 if plotdata :
152152 if percentiles :
153- ax .plot (outs ['xmid' ], outs ['perc16 ' ], linecolor + '-.' , linewidth = linewidth )
154- ax .plot (outs ['xmid' ], outs ['perc84 ' ], linecolor + '-.' , linewidth = linewidth )
153+ ax .plot (outs ['xmid' ], outs ['bins16 ' ], linecolor + '-.' , linewidth = linewidth )
154+ ax .plot (outs ['xmid' ], outs ['bins84 ' ], linecolor + '-.' , linewidth = linewidth )
155155 ax .plot (outs ['xmid' ], outs ['avg_y' ], linewidth = linewidth , color = linecolor , label = binlabel )
156156 return outs
157157 else :
@@ -208,7 +208,7 @@ def plot2dhist(x,y,
208208 ylabel = '' ,
209209 lim = False ,
210210 setplotlims = False ,
211- aspect = 'equal ' ):
211+ aspect = 'auto ' ):
212212 if type (x )!= np .array :
213213 x = np .copy (np .array (x ))
214214 if type (y )!= np .array :
@@ -255,7 +255,7 @@ def plot2dhist(x,y,
255255 if data :
256256
257257 ax .imshow ((hist .transpose ())** dens_scale , cmap = 'gray_r' ,extent = extent ,origin = 'lower' ,
258- aspect = 'auto' ,alpha = 0.9 )
258+ aspect = aspect ,alpha = 0.9 )
259259 if bin_y :
260260 if size_y_bin != 0 :
261261 nbins = int ( (xlim [1 ]- xlim [0 ])/ size_y_bin )
@@ -317,7 +317,7 @@ def plot2dhist(x,y,
317317 else :
318318 mn , mx = np .nanmin (ccode_avgs ), np .nanmax (ccode_avgs )
319319 im = ax .imshow ((ccode_avgs .transpose ()), cmap = cmap ,extent = extent ,origin = 'lower' ,
320- aspect = 'auto' ,alpha = 0.9 , vmin = mn , vmax = mx )#, norm=colors.PowerNorm(gamma=1/2))
320+ aspect = aspect ,alpha = 0.9 , vmin = mn , vmax = mx )#, norm=colors.PowerNorm(gamma=1/2))
321321 if show_cbar :
322322 cbar = fig .colorbar (im , ax = ax )
323323 cbar .set_label (ccodename , fontsize = 20 )
0 commit comments