code: def summary(args):
      
      from jcvi.utils.table import write_csv
  
      p = OptionParser(summary.__doc__)
      opts, args = p.parse_args(args)
  
      if len(args) != 1:
          sys.exit(p.print_help())
  
      agpfile, = args
      header = "Chromosome #_Distinct #_Components #_Scaffolds " \
               "Scaff_N50 Scaff_L50 Length".split()
  
      agp = AGP(agpfile)
      data = list(agp.summary_all())
      write_csv(header, data, sep=" ")
docs: %prog summary agpfile
  
      print a table of scaffold statistics, number of BACs, no of scaffolds,
      scaffold N50, scaffold L50, actual sequence, PSMOL NNNs, PSMOL-length, % of
      PSMOL sequenced.