Difference between revisions of "BioPerl"

From HPC users
Jump to navigationJump to search
Line 5: Line 5:
== Installed version ==
== Installed version ==


The currently installed version is 1.7.0.
These versions are installed and and currently available ...
 
... on envirnoment ''hpc-uniol-env'':
'''BioPerl/1.7.0'''
... on environment ''hpc-env/6.4'':
'''BioPerl/1.7.2'''-foss-2017b-Perl-5.26.0


== Using BioPerl ==
== Using BioPerl ==

Revision as of 13:06, 28 June 2019

Introduction

BioPerl is a collection of Perl modules that facilitate the development of Perl scripts for bioinformatics applications. It has played an integral role in the Human Genome Project.

Installed version

These versions are installed and and currently available ...

... on envirnoment hpc-uniol-env:

BioPerl/1.7.0

... on environment hpc-env/6.4:

BioPerl/1.7.2-foss-2017b-Perl-5.26.0

Using BioPerl

If you want to use BioPerl on the cluster, you will have to load its corresponding module first. You can do that with the command:

module load BioPerl

After that BioPerl is loaded and operational.

Using BioPerl on the cluster

If you want to run jobs on the cluster, you will have to create a jobscript which needs to be submitted to SLURM.

An example jobscript for BioPerl could look like this:

#!/bin/bash 

#SBATCH --ntasks=1
#SBATCH --mem=2G
#SBATCH --time=0-2:00  
#SBATCH --job-name=BIOPERL-TEST
#SBATCH --output=bioperl-test.%j.out        
#SBATCH --error=bioperl-test.%j.err   

module load BioPerl
perl seqio.pl

If you want to run this example, please create a file with the bioperl-test.job containing the code above. You will also need to create a file called "seqio.pl" with the following content:

#!/bin/perl -w

use Bio::Seq; use Bio::SeqIO; 

$seq_obj = Bio::Seq->new(-seq=>"aaaatgggggggggggccccgtt",
                         -display_id => "#12345",
                         -desc => "example 1",
                         -alphabet => "dna" ); 

$seqio_obj = Bio::SeqIO->new(-file => '>sequence.fasta',
                             -format => 'fasta' ); 

$seqio_obj->write_seq($seq_obj);

If you created both files you can submit your job with the following command:

sbatch -p carl.p bioperl-test.job

After job has finished (takes about 10-20 seconds), you will find three new files in the directory you started the job from:

  • sequence.fasta
  • bioperl-test.JOBID.err
  • bioperl-test.JOBID.out

If the file "sequence.fasta" contains this:

>#12345 example 1
aaaatgggggggggggccccgtt

everything went fine and you can start to create your own scripts.

Documentation

The full documentation can be found here.