@@ -209,6 +209,7 @@ def plot_scalar(step, var, field=None, axis=None, **extra):
209209 axis .set_axis_off ()
210210 else :
211211 axis .set_aspect (conf .plot .ratio / axis .get_data_ratio ())
212+
212213 axis .set_adjustable ('box' )
213214 axis .set_xlim (xmin , xmax )
214215 axis .set_ylim (ymin , ymax )
@@ -290,7 +291,7 @@ def cmd():
290291 for step in sdat .walk .filter (snap = True ):
291292 for vfig in lovs :
292293 fig , axes = plt .subplots (ncols = len (vfig ), squeeze = False ,
293- figsize = (12 * len (vfig ), 9 ))
294+ figsize = (9 * len (vfig ), 6 ))
294295 for axis , var in zip (axes [0 ], vfig ):
295296 if var [0 ] not in step .fields :
296297 print ("'{}' field on snap {} not found" .format (var [0 ],
@@ -305,6 +306,11 @@ def cmd():
305306 plot_iso (axis , step , var [1 ])
306307 elif valid_field_var (var [1 ] + '1' ):
307308 plot_vec (axis , step , var [1 ])
309+ if conf .field .timelabel :
310+ time , unit = sdat .scale (step .timeinfo ['t' ], 's' )
311+ time = misc .scilabel (time )
312+ axes [0 , 0 ].text (0.02 , 1.02 , '$t={}$ {}' .format (time , unit ),
313+ transform = axes [0 , 0 ].transAxes )
308314 oname = '_' .join (chain .from_iterable (vfig ))
309315 plt .tight_layout (w_pad = 3 )
310316 misc .saveplot (fig , oname , step .isnap )
0 commit comments