Plot the time series.
333875
def plot(self, label=None, colour='g', style='-'): # pragma: no cover
        ''''''
        pylab = LazyImport.pylab()
        pylab.plot(self.dates, self.values, '%s%s' % (colour, style), label=label)
        if label is not None:
            pylab.legend()
        pylab.show()
23885
def plot(self, f, lfilter=None,**kargs):
        """"""

        return plt.plot([ f(i) for i in self.res if not lfilter or lfilter(i) ], **kargs)
373630
def seriesshape(self):
        """"""
        seriesshape = [len(hydpy.pub.timegrids.init)]
        seriesshape.extend(self.shape)
        return tuple(seriesshape)
962006
def plot_nb(self,xdata,ydata=[],logScale=False):
        ''''''
        self.plot(xdata,ydata,logScale)
161042
def plot_fit(self, **kwargs):
        

        import matplotlib.pyplot as plt
        import seaborn as sns

        figsize = kwargs.get('figsize',(10,7))
        plt.figure(figsize=figsize)
        date_index = self.index[self.ar:self.data.shape[0]]
        mu, Y = self._model(self.latent_variables.get_z_values())
        plt.plot(date_index,Y,label='Data')
        plt.plot(date_index,mu,label='Filter',c='black')
        plt.title(self.data_name)
        plt.legend(loc=2)   
        plt.show()
333184
def _plot(self):
        """"""
        for serie in self.series[::-1 if self.stack_from_top else 1]:
            self.bar(serie)
        for serie in self.secondary_series[::-1 if self.stack_from_top else 1]:
            self.bar(serie, True)
1178753
def prevPlot(self):
        """"""
        if self.stacker.currentIndex() > 0:
            self.stacker.setCurrentIndex(self.stacker.currentIndex()-1)
441877
def util_granulate_time_series(time_series, scale):
    
    n = len(time_series)
    b = int(np.fix(n / scale))
    temp = np.reshape(time_series[0:b*scale], (b, scale))
    cts = np.mean(temp, axis = 1)
    return cts
1099601
def plot(self, intervals=None, new_fig=True):
        """"""

        import pylab as p

        if new_fig:
            p.figure()

        #step 1: plot histogram
        p.plot(self.x, self.y, ls='-', c='b', lw='1.5')

        #step 2: plot peaks
        first_peak = None
        last_peak = None
        if self.peaks:
            first_peak = min(self.peaks["peaks"][0])
            last_peak = max(self.peaks["peaks"][0])
            p.plot(self.peaks["peaks"][0], self.peaks["peaks"][1], 'rD', ms=10)
            p.plot(self.peaks["valleys"][0], self.peaks["valleys"][1], 'yD', ms=5)

        #Intervals
        if intervals is not None:
            #spacing = 0.02*max(self.y)
            for interval in intervals:
                if first_peak is not None:
                    if interval <= first_peak or interval >= last_peak:
                        continue
                p.axvline(x=interval, ls='-.', c='g', lw='1.5')
                if interval-1200 >= min(self.x):
                    p.axvline(x=interval-1200, ls=':', c='b', lw='0.5')
                if interval+1200 <= max(self.x):
                    p.axvline(x=interval+1200, ls=':', c='b', lw='0.5')
                if interval+2400 <= max(self.x):
                    p.axvline(x=interval+2400, ls='-.', c='r', lw='0.5')
                #spacing *= -1

        #p.title("Tonic-aligned complete-range pitch histogram")
        #p.xlabel("Pitch value (Cents)")
        #p.ylabel("Normalized frequency of occurence")
        p.show()
396881
def plot(self):
    
    plt.ion()
    plt.show()
    x = numpy.linspace(0, 15, 100)
    y = numpy.zeros(x.shape)
    y = self.excite(y, x)
    plt.plot(x, y)
    plt.xlabel('Input')
    plt.ylabel('Persistence')
    plt.title('Sigmoid Activation Function')
258799
def plotline(plt, alpha, taus, style,label=""):
    
    y = [pow(tt, alpha) for tt in taus]
    plt.loglog(taus, y, style,label=label)
793039
def plot_target_trajectory(targets_x, targets_y, targets_z, ax):
    """"""
    ax.scatter(targets_x, targets_y, targets_z)
787109
def timeseries(datasets):
    """"""
    expanded_ds = []
    for ds in datasets:
        tmp = ds.expand_dims("time")
        tmp.coords["time"] = pd.DatetimeIndex([ds.attrs["start_time"]])
        expanded_ds.append(tmp)

    res = xr.concat(expanded_ds, dim="time")
    res.attrs = combine_metadata(*[x.attrs for x in expanded_ds])
    return res
72269
def trend(self, **kwargs):
        ''''''
        return DataFrame({ name: series.trend(**kwargs) \
            for name, series in self.groups.iteritems() })
973747
def plot(self, ax=None, **kwargs):
        
        ax, fig, plt = get_ax_fig_plt(ax)

        yy = [len(v) for v in self.values]
        ax.plot(self.binvals, yy, **kwargs)

        return fig
1096516
def plot_stateseries(
            self, names: Optional[Iterable[str]] = None,
            average: bool = False, **kwargs: Any) \
            -> None:
        
        self.__plot(self.model.sequences.states, names, average, kwargs)
1107568
def plot_fit(self,**kwargs):
        
        import matplotlib.pyplot as plt
        import seaborn as sns

        figsize = kwargs.get('figsize',(10,7))

        if self.latent_variables.estimated is False:
            raise Exception("No latent variables estimated!")
        else:
            date_index = self.index[self.lags:self.data[0].shape[0]]
            mu, Y = self._model(self.latent_variables.get_z_values())
            for series in range(0,Y.shape[0]):
                plt.figure(figsize=figsize)
                plt.plot(date_index,Y[series],label='Data ' + str(series))
                plt.plot(date_index,mu[series],label='Filter' + str(series),c='black')  
                plt.title(self.data_name[series])
                plt.legend(loc=2)   
            plt.show()