Biowulf at the NIH
RSS Feed
Spanner on Biowulf

Spanner is a c++ program for the detection of Structural Variation events from whole genome sequenced read pair data. It uses aligned read information in bam format and was developed in conjunction with the Mosaik alignment program


Programs Location


The spanner executable can be easily added to your path by using the modules commands as in the example below:

biowulf% module load spanner

Submitting a Single Batch Job

1. Create a script file similar to the one below

# This file is called spanner.bat
#PBS -N Spanner
#PBS -m be
#PBS -k oe

module load spanner

cd /data/user/somewhereWithInputfile

3. Submit the script using the 'qsub' command on Biowulf.

qsub -l nodes=1 spanner.bat

Submitting a Swarm of Jobs

Using the 'swarm' utility, one can submit many jobs to the cluster to run concurrently.

Set up a swarm command file (eg /data/username/cmdfile). Here is a sample file:

module load spanner; spanner -i file1 -Z -M mask1.file -t      
module load spanner; spanner -i file2 -Z -M mask2.file -t      
module load spanner; spanner -i file3 -Z -M mask3.file -t      
module load spanner; spanner -i file4 -Z -M mask4.file -t      

Submit this swarm with:

swarm -f cmdfile

By default, each line of the commands above will be executed on 1 processor core of a node and can use 1GB of memory. If each spanner command requires more than 1 GB of memory, you should specify the memory require for each spanner command (i.e. each line of the swarm command file above) by using the -g flag:

biowulf> $ swarm -g 10 -f cmdfile

For more information regarding running swarm, see swarm.html


Running an Interactive Job

User may need to run jobs interactively sometimes. Such jobs should not be run on the Biowulf login node. Instead allocate an interactive node as described below, and run the interactive job there. For example:

biowulf% qsub -I -l nodes=1 
qsub: waiting for job 2236960.biobos to start 
qsub: job 2236960.biobos ready
[user@p4]$ module load spanner

[user@p4]$ cd /data/user/somewhereWithInputfile 
[user@p4]$ spanner -t -Z 1 -u -M mask.file
[user@p4] exit 
qsub: job 2236960.biobos completed 

[user@biowulf ~]$ 

User can add a node property in the qsub command to request a specific kind of interactive node. For example, if you need a node with 8gb of memory to run job interactively, do this:

biowulf% qsub -I -l nodes=1:g8

Documentation - Spanner website


   spanner  [-Z ] [-S ] [-M ] [-w ] [-Q ]
            [-d ] [-t] [-a ] [-b] [-s] [-u ] [-c
            ] [-i ] [-x ] [-f ] [-p ]
            [-o ] [-R ] [--] [--version] [-h]


   -Z ,  --Zmode 
     bam access mode (1=ZAtag, 2=SortedByReadName) 

   -S ,  --specialtag 
     prefix of element names in special reference

   -M ,  --MASKFILE 
     Event masking file

   -w ,  --fragtailwindow 
     p-value for frag window cut

   -Q ,  --qmin 
     minimum mapping q value

   -d ,  --debug 
     debug: interval>0, RD<0

   -t,  --text
     ascii text output

   -a ,  --anchorfile 
     name of anchor info file

   -b,  --build
     build span files

   -s,  --scan
     scan fragment length only

   -u ,  --uniquify 
     duplicate fragment removal

   -c ,  --contigs 
     regexp for allowed contigs

   -i ,  --infile 
     specify pre-built input files

   -x ,  --maxfrag 
     maximum number of fragments

   -f ,  --fragHist 
     name of fragment length histogram file

   -p ,  --prefix 
     output prefix

   -o ,  --outdir 
     name of SV output area

   -R ,  --rcp 
     name of parameter file

   --,  --ignore_rest
     Ignores the rest of the labeled arguments following this flag.

     Displays version information and exits.

   -h,  --help
     Displays usage information and exits.