def plot_raw(self, xmin=None, xmax=None): V = self.Vps t = self.td if xmin and xmax: interval = np.where((xmin < t) & (t < xmax)) t = t[interval] V = V[interval] my_plot(t, V, '.', color='blue')
def plot_dump_from_file(self,filepath,style=None,fignum=1,pretty=True,**kwargs): """Plots dump file corresponding to a particular dump file path""" dumpdict = cdio.read_from_dump(filepath) # read in dump dictionary from file cadddump = cddump.CADDDataDump(dumpdict) # initialize cadddump object objs = self.objects_to_plot() # figure out objects to plot (atoms, elements, etc.), based on simtype cadddump.gen_all_plot(objs,style=style) # generate plot objects for these attributes fig = myplot.my_plot(cadddump,fignum=fignum) # plot them! if pretty: myplot.pretty_figure(fig,aspect=1,ticksize=None,**kwargs) return fig
def plot_dump_from_file(self, filepath, style=None, fignum=1, pretty=True, **kwargs): """Plots dump file corresponding to a particular dump file path""" dumpdict = cdio.read_from_dump( filepath) # read in dump dictionary from file cadddump = cddump.CADDDataDump(dumpdict) # initialize cadddump object objs = self.objects_to_plot( ) # figure out objects to plot (atoms, elements, etc.), based on simtype cadddump.gen_all_plot( objs, style=style) # generate plot objects for these attributes fig = myplot.my_plot(cadddump, fignum=fignum) # plot them! if pretty: myplot.pretty_figure(fig, aspect=1, ticksize=None, **kwargs) return fig
def my_quick_plot(data,style=None,fignum=1,**kwargs): plotdata = LinePlotData.from_dataset(data,style) fig = myplot.my_plot(plotdata,fignum=fignum) myplot.pretty_figure(fig,**kwargs)