code: def plot(args):
      
      from jcvi.graphics.base import savefig
  
      p = OptionParser(plot.__doc__)
      opts, args, iopts = p.set_image_options(args, figsize="8x7", format="png")
  
      if len(args) != 3:
          sys.exit(not p.print_help())
  
      workdir, sample_key, chrs = args
      chrs = chrs.split(",")
      hmm = CopyNumberHMM(workdir=workdir)
      hmm.plot(sample_key, chrs=chrs)
  
      image_name = sample_key + "_cn." + iopts.format
      savefig(image_name, dpi=iopts.dpi, iopts=iopts)
docs: %prog plot workdir sample chr1,chr2
  
      Plot some chromosomes for visual proof. Separate multiple chromosomes with
      comma. Must contain folder workdir/sample-cn/.