def _plot(self, region=None, cax=None):
self._new_region(region)
bin_coords = [(x.start - 1) for x in self.sr]
ds = self.da_sub[self.init_row]
self.line, = self.ax.plot(bin_coords, ds)
if not self.is_symmetric:
self.current_cutoff = (self.ax.get_ylim()[1] - self.ax.get_ylim()[0]) / 2 + self.ax.get_ylim()[0]
else:
self.current_cutoff = self.ax.get_ylim()[1]/ 2
self.ax.axhline(0.0, linestyle='dashed', color='grey')
self.cutoff_line = self.ax.axhline(self.current_cutoff, color='r')
if self.is_symmetric:
self.cutoff_line_mirror = self.ax.axhline(-1*self.current_cutoff, color='r')
self.ax.set_ylim((np.nanmin(ds), np.nanmax(ds)))
评论列表
文章目录