Welcome, guest | Sign In | My Account | Store | Cart

Notice! PyPM is being replaced with the ActiveState Platform, which enhances PyPM’s build and deploy capabilities. Create your free Platform account to download ActivePython or customize Python with the packages you require and get automatic updates.

Download
ActivePython
INSTALL>
pypm install nwalign

How to install nwalign

  1. Download and install ActivePython
  2. Open Command Prompt
  3. Type pypm install nwalign
 Python 2.7Python 3.2Python 3.3
Windows (32-bit)
0.3.1 Failed View build log
Windows (64-bit)
0.3.1 Failed View build log
Mac OS X (10.5+)
0.3.1 Available View build log
Linux (32-bit)
0.3.1 Available View build log
Linux (64-bit)
0.3.1 Available View build log
 
Author
License
BSD
Dependencies
Imports
Lastest release
version 0.3.1 on Jan 5th, 2011

This module provides a python module and a command-line interface to do global- sequence alignment using the Needleman-Wunsch algorithm. It uses cython and numpy for speed.

Command-Line Usage

the nwalign executable is installed to the PATH by setuptools

$ nwalign alphabet alpet

System Message: ERROR/3 (<string>, line 19)

Inconsistent literal block quoting.

alphabet alp---et

specify an alignment scoring matrix

$ nwalign --matrix /usr/share/ncbi/data/BLOSUM62 EEAEE EEEEG

System Message: ERROR/3 (<string>, line 26)

Inconsistent literal block quoting.

EEAEE- EE-EEG

with specified penalties

$ nwalign --gap_open -10 --gap_extend -4 --match 12 ASDFF ASFF

System Message: ERROR/3 (<string>, line 33)

Inconsistent literal block quoting.

ASDFF AS-FF

Python Usage

Alignment
>>> import nwalign as nw
>>> nw.global_align("CEELECANTH", "PELICAN", matrix='PAM250')

System Message: ERROR/3 (<string>, line 45)

Inconsistent literal block quoting.

('CEELE-CANTH', '-PEL-ICAN--')

# with a specified penalty for open and extend. >>> nw.global_align("CEELECANTH", "PELICAN", gap_open=-10, gap_extend=-4, matrix='PAM250') ('CEELECANTH', '-PELICAN--')

the matrix is specified as the full path to an scoring matrix as is distributed with the NCBI toolset.

Scoring

get the score of an alignment. (the first 2 args are from an alignment and must have the same length.

>>> nw.score_alignment('CEELECANTH', '-PELICAN--', gap_open=-5,

System Message: ERROR/3 (<string>, line 62)

Inconsistent literal block quoting.

... gap_extend=-2, matrix='PAM250') 11

>>> nw.score_alignment('CEELE-CANTH', '-PEL-ICAN--', gap_open=-5,
...                     gap_extend=-2, matrix='PAM250')
6

Subscribe to package updates

Last updated Jan 5th, 2011

Download Stats

Last month:5

What does the lock icon mean?

Builds marked with a lock icon are only available via PyPM to users with a current ActivePython Business Edition subscription.

Need custom builds or support?

ActivePython Enterprise Edition guarantees priority access to technical support, indemnification, expert consulting and quality-assured language builds.

Plan on re-distributing ActivePython?

Get re-distribution rights and eliminate legal risks with ActivePython OEM Edition.