Skip Navigation
National Institute of Environmental Health SciencesNational Institutes of Health
Increase text size Decrease text size Print this page

Genetic Algorithm Method for Optimizing a Position Weight Matrix

Position weight matricies (PWM) are simple models commonly used in motif finding algorithms to identify short functional elements, such as cis-regulatory motifs, on genes. When few expermentially verified motifs are available, estimation of the PWM may be poor. Genetic Algorithm Method for Optimizing a Position Weight Matrix (GAPWM) implements a simple method to improve a poorly estimated PWM using chromatin immunoprecipitation (ChIP) data.

This program was developed by Leping Li of the National Institutes of Environmental Health Sciences, Research Triangle Park, North Carolina 27709.


This work is made available under the GPL v2.


Download the source code for the distribution of GAPWM along with usage documentation and examples (  View Information About ZIP Files (8.2MB)


In the main directory of the distribution, type
make install

By default, the configure program will direct the executable files to /usr/local/bin which, in most cases, requires the user to "su" to root prior to the "make install" step. The target directory for the executable file can be overridden by specifying the --prefix option during the configure phase. For example,

./configure --prefix=/home/gapwm_user

will direct the executables into /home/gapwm_user/bin directory.

The configure application accepts several arguments to tailor the build and installation process. Please see the INSTALL file contained in the root directory of the distribution for further details.

The source code and package were developed using Fedora. Although the intent was to make the code portable to most U*IX variants, you may encounter minor build issues on other platforms. Feedback regarding any difficulties you may experience will be very helpful in improving the distribution package.

Contact for this tool: Leping Li

Back to top Back to top Department of Health & Human Services National Institutes of Health
This page URL:
NIEHS website:
Email the Web Manager at
Last Reviewed: August 11, 2008