Skip to content

Instantly share code, notes, and snippets.

@brantfaircloth
Created July 2, 2011 18:13
Show Gist options
  • Save brantfaircloth/1061484 to your computer and use it in GitHub Desktop.
Save brantfaircloth/1061484 to your computer and use it in GitHub Desktop.
Easily get coverage from velvet assemblies
  • assemble data and output an AMOS file (-amos_file yes)

  • download and build http://sourceforge.net/projects/amos/

  • convert the afg file output by velvet to a bnk file

     ~/src/amos-3.0.0/src/Bank/bank-transact -m my.afg -b my.bnk -c
    
  • get short-version, depth-of-coverage output

     ~/src/amos-3.0.0/src/Validation/analyze-read-depth my.bnk -d
    
  • if you need coverage across specific contigs, you can get a "map" of node number (velvet) to IID (amos) by outputting data as follows:

     ~/src/amos-3.0.0/src/Utils/cvgStat -b my.bnk > my.cvg
    
  • then parse that file to match iid to node number. after parsing pass the IID data (here named *.iid) to analyze-read-depth for the contigs in which you are interested

     ~/src/amos-3.0.0/src/Validation/analyze-read-depth my.bnk -d -I my.iid
    
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment