nodes: 0, module; 1, function_definition; 2, function_name:plot; 3, parameters; 4, block; 5, identifier:self; 6, identifier:x; 7, default_parameter; 8, default_parameter; 9, default_parameter; 10, expression_statement; 11, expression_statement; 12, if_statement; 13, expression_statement; 14, expression_statement; 15, expression_statement; 16, expression_statement; 17, if_statement; 18, if_statement; 19, expression_statement; 20, expression_statement; 21, expression_statement; 22, if_statement; 23, expression_statement; 24, if_statement; 25, expression_statement; 26, if_statement; 27, expression_statement; 28, expression_statement; 29, expression_statement; 30, identifier:row_order; 31, None; 32, identifier:imshow_kwargs; 33, None; 34, identifier:strip; 35, True; 36, comment:"""
          Plot the scaled ChIP-seq data.
  
          :param x: X-axis to use (e.g, for TSS +/- 1kb with 100 bins, this would
              be `np.linspace(-1000, 1000, 100)`)
          :param row_order: Array-like object containing row order -- typically
              the result of an `np.argsort` call.
          :param strip: Include axes along the left side with points that can be
              clicked to spawn a minibrowser for that feature.
          """; 37, assignment; 38, comparison_operator:row_order is None; 39, block; 40, assignment; 41, assignment; 42, assignment; 43, assignment; 44, identifier:imshow_kwargs; 45, block; 46, comparison_operator:'cmap' not in _imshow_kwargs; 47, block; 48, assignment; 49, call; 50, call; 51, identifier:strip_ax; 52, block; 53, call; 54, identifier:strip_ax; 55, block; 56, call; 57, attribute; 58, block; 59, else_clause; 60, call; 61, assignment; 62, assignment; 63, identifier:nrows; 64, subscript; 65, identifier:row_order; 66, None; 67, expression_statement; 68, identifier:extent; 69, tuple; 70, identifier:axes_info; 71, call; 72, pattern_list; 73, identifier:axes_info; 74, identifier:_imshow_kwargs; 75, call; 76, expression_statement; 77, string; 78, identifier:_imshow_kwargs; 79, expression_statement; 80, identifier:mappable; 81, call; 82, attribute; 83, argument_list; 84, attribute; 85, argument_list; 86, expression_statement; 87, expression_statement; 88, expression_statement; 89, attribute; 90, argument_list; 91, expression_statement; 92, expression_statement; 93, attribute; 94, argument_list; 95, identifier:self; 96, identifier:db; 97, expression_statement; 98, block; 99, attribute; 100, argument_list; 101, attribute; 102, identifier:fig; 103, attribute; 104, dictionary; 105, attribute; 106, integer:0; 107, assignment; 108, call; 109, call; 110, integer:0; 111, identifier:nrows; 112, attribute; 113, argument_list; 114, identifier:fig; 115, identifier:matrix_ax; 116, identifier:line_ax; 117, identifier:strip_ax; 118, identifier:cbar_ax; 119, identifier:dict; 120, argument_list; 121, call; 122, string_content:cmap; 123, assignment; 124, attribute; 125, argument_list; 126, identifier:plt; 127, identifier:colorbar; 128, identifier:mappable; 129, identifier:cbar_ax; 130, identifier:line_ax; 131, identifier:plot; 132, identifier:x; 133, call; 134, assignment; 135, assignment; 136, assignment; 137, identifier:matrix_ax; 138, identifier:axis; 139, string; 140, call; 141, call; 142, attribute; 143, identifier:set_visible; 144, False; 145, assignment; 146, expression_statement; 147, attribute; 148, identifier:mpl_connect; 149, string; 150, attribute; 151, identifier:self; 152, identifier:fig; 153, identifier:self; 154, identifier:axes; 155, pair; 156, pair; 157, pair; 158, pair; 159, attribute; 160, identifier:shape; 161, identifier:row_order; 162, call; 163, identifier:min; 164, argument_list; 165, identifier:max; 166, argument_list; 167, attribute; 168, identifier:matrix_and_line_shell; 169, keyword_argument; 170, keyword_argument; 171, keyword_argument; 172, keyword_argument; 173, attribute; 174, argument_list; 175, subscript; 176, call; 177, identifier:matrix_ax; 178, identifier:imshow; 179, subscript; 180, dictionary_splat; 181, attribute; 182, argument_list; 183, pattern_list; 184, call; 185, attribute; 186, attribute; 187, attribute; 188, identifier:row_order; 189, string_content:tight; 190, attribute; 191, argument_list; 192, attribute; 193, argument_list; 194, identifier:matrix_ax; 195, identifier:xaxis; 196, attribute; 197, call; 198, assignment; 199, identifier:fig; 200, identifier:canvas; 201, string_content:pick_event; 202, identifier:self; 203, identifier:callback; 204, string; 205, identifier:matrix_ax; 206, string; 207, identifier:strip_ax; 208, string; 209, identifier:line_ax; 210, string; 211, identifier:cbar_ax; 212, identifier:self; 213, identifier:diffed_array; 214, attribute; 215, argument_list; 216, identifier:x; 217, identifier:x; 218, identifier:metaseq; 219, identifier:plotutils; 220, identifier:strip; 221, identifier:strip; 222, identifier:aspect; 223, string; 224, identifier:extent; 225, identifier:extent; 226, identifier:interpolation; 227, string; 228, identifier:_imshow_kwargs; 229, identifier:update; 230, identifier:imshow_kwargs; 231, identifier:_imshow_kwargs; 232, string; 233, attribute; 234, argument_list; 235, attribute; 236, identifier:row_order; 237, identifier:_imshow_kwargs; 238, attribute; 239, identifier:mean; 240, keyword_argument; 241, identifier:line; 242, attribute; 243, argument_list; 244, identifier:line; 245, identifier:features; 246, identifier:self; 247, identifier:features; 248, identifier:line; 249, identifier:ind; 250, attribute; 251, identifier:set_visible; 252, False; 253, attribute; 254, identifier:set_visible; 255, False; 256, identifier:self; 257, identifier:minibrowser; 258, identifier:GeneChipseqMiniBrowser; 259, argument_list; 260, attribute; 261, call; 262, string_content:matrix_ax; 263, string_content:strip_ax; 264, string_content:line_ax; 265, string_content:cbar_ax; 266, identifier:np; 267, identifier:arange; 268, identifier:nrows; 269, string_content:auto; 270, string_content:nearest; 271, string_content:cmap; 272, attribute; 273, identifier:smart_colormap; 274, call; 275, call; 276, identifier:self; 277, identifier:diffed_array; 278, identifier:self; 279, identifier:diffed_array; 280, identifier:axis; 281, integer:0; 282, identifier:strip_ax; 283, identifier:plot; 284, call; 285, binary_operator:np.arange(nrows) + 0.5; 286, dictionary_splat; 287, identifier:strip_ax; 288, identifier:xaxis; 289, identifier:matrix_ax; 290, identifier:yaxis; 291, list; 292, keyword_argument; 293, keyword_argument; 294, keyword_argument; 295, identifier:self; 296, identifier:minibrowser; 297, identifier:SignalChipseqMiniBrowser; 298, argument_list; 299, identifier:metaseq; 300, identifier:colormap_adjust; 301, attribute; 302, argument_list; 303, attribute; 304, argument_list; 305, attribute; 306, argument_list; 307, call; 308, float:0.5; 309, attribute; 310, attribute; 311, attribute; 312, identifier:db; 313, attribute; 314, identifier:plotting_kwargs; 315, attribute; 316, identifier:local_coverage_kwargs; 317, attribute; 318, list; 319, keyword_argument; 320, keyword_argument; 321, attribute; 322, identifier:min; 323, attribute; 324, identifier:max; 325, identifier:np; 326, identifier:zeros; 327, tuple; 328, attribute; 329, argument_list; 330, identifier:self; 331, identifier:_strip_kwargs; 332, identifier:self; 333, identifier:ip; 334, identifier:self; 335, identifier:control; 336, identifier:self; 337, identifier:db; 338, identifier:self; 339, identifier:browser_plotting_kwargs; 340, identifier:self; 341, identifier:browser_local_coverage_kwargs; 342, attribute; 343, attribute; 344, identifier:plotting_kwargs; 345, attribute; 346, identifier:local_coverage_kwargs; 347, attribute; 348, identifier:self; 349, identifier:diffed_array; 350, identifier:self; 351, identifier:diffed_array; 352, identifier:nrows; 353, identifier:np; 354, identifier:arange; 355, identifier:nrows; 356, identifier:self; 357, identifier:ip; 358, identifier:self; 359, identifier:control; 360, identifier:self; 361, identifier:browser_plotting_kwargs; 362, identifier:self; 363, identifier:browser_local_coverage_kwargs
code: def plot(self, x, row_order=None, imshow_kwargs=None, strip=True):
          """
          Plot the scaled ChIP-seq data.
  
          :param x: X-axis to use (e.g, for TSS +/- 1kb with 100 bins, this would
              be `np.linspace(-1000, 1000, 100)`)
          :param row_order: Array-like object containing row order -- typically
              the result of an `np.argsort` call.
          :param strip: Include axes along the left side with points that can be
              clicked to spawn a minibrowser for that feature.
          """
          nrows = self.diffed_array.shape[0]
          if row_order is None:
              row_order = np.arange(nrows)
          extent = (min(x), max(x), 0, nrows)
          axes_info = metaseq.plotutils.matrix_and_line_shell(strip=strip)
          fig, matrix_ax, line_ax, strip_ax, cbar_ax = axes_info
          _imshow_kwargs = dict(
              aspect='auto', extent=extent, interpolation='nearest')
          if imshow_kwargs:
              _imshow_kwargs.update(imshow_kwargs)
  
          if 'cmap' not in _imshow_kwargs:
              _imshow_kwargs['cmap'] = metaseq.colormap_adjust.smart_colormap(
                  self.diffed_array.min(),
                  self.diffed_array.max()
              )
          mappable = matrix_ax.imshow(
              self.diffed_array[row_order],
              **_imshow_kwargs)
          plt.colorbar(mappable, cbar_ax)
          line_ax.plot(x, self.diffed_array.mean(axis=0))
          if strip_ax:
              line, = strip_ax.plot(np.zeros((nrows,)), np.arange(nrows) + 0.5,
                                    **self._strip_kwargs)
              line.features = self.features
              line.ind = row_order
  
          matrix_ax.axis('tight')
          if strip_ax:
              strip_ax.xaxis.set_visible(False)
              matrix_ax.yaxis.set_visible(False)
  
          matrix_ax.xaxis.set_visible(False)
  
          if self.db:
              self.minibrowser = GeneChipseqMiniBrowser(
                  [self.ip, self.control],
                  db=self.db,
                  plotting_kwargs=self.browser_plotting_kwargs,
                  local_coverage_kwargs=self.browser_local_coverage_kwargs)
          else:
              self.minibrowser = SignalChipseqMiniBrowser(
                  [self.ip, self.control],
                  plotting_kwargs=self.browser_plotting_kwargs,
                  local_coverage_kwargs=self.browser_local_coverage_kwargs)
  
          fig.canvas.mpl_connect('pick_event', self.callback)
  
          self.fig = fig
          self.axes = {
              'matrix_ax': matrix_ax,
              'strip_ax': strip_ax,
              'line_ax': line_ax,
              'cbar_ax': cbar_ax
          }