[Bioperl-l] Bio::Tools::Run::Alignment::Clustalw. Alignment d oesn't print out in CGI.

Davis, Sean (NIH/NHGRI) sdavis2 at mail.nih.gov
Sat May 29 19:52:08 EDT 2004


 I'm not an expert, but you might check the server error log.  It may be
that the user under which the CGI is running does not have privileges for
executing clustalw or writing necessary temp files.  

-----Original Message-----
From: Tariq Shafi
To: bioperl-l at portal.open-bio.org
Sent: 5/29/2004 11:25 AM
Subject: [Bioperl-l] Bio::Tools::Run::Alignment::Clustalw. Alignment doesn't
print out in CGI.

Hello all

Got a major problem using BioPerl and can't figure out the solution!

I am trying to make an alignment in Clustalw and print out the results
to a 
CGI page, with no luck.

When I print out to the console it prints out, but it doesn't work in
the 
web page.

Here is the code:

# Filename: DoAlignment.pl

#!/usr/bin/perl

use CGI qw(:standard);
use Bio::Seq;
use Bio::SeqIO;
use Bio::Tools::Run::Alignment::Clustalw;

$query = new CGI;

print $query->header;

# The dbh connection works fine. (I have changed the names here for 
security)
$dbh = DBI->connect('dbi:mysql:dbname=db;host=host.domain.;port=9999',
'me', 
'my password') or die("connection not made:\n");


for ($i = 1; $i < 4; $i++)

{
     $seq = Bio::Seq->new(-seq => 'ATCGT',
                                     -desc => 'Sample sequence',
                                     -id => 'something' . $i,
                                     -accession_number => 'GB_ID'
                                     -moltype=>'dna');

     print $seq->seq(), br();
     print $seq->id(), br();
     push @sequences, $seq;
}

# Prints out '3' to web page, which is fine
print scalar @sequences, br();

@params = ('ktuple'=>2, 'matrix' => 'BLOSUM');
$aligner = Bio::Tools::Run::Alignment::Clustalw->new(@params);

# This prints out to web page
print "Here!", br();

$alignment = $aligner->align(\@sequences);

#This does NOT print out to web page
print "Here again!", br();

On the web page, this executable script types the following:

ATCGT
something1
ATCGT
something2
ATCGT
something3
3
Here!


But there is no ClustalW alignment printed out and not even the 'Here 
Again!' after the Clustalw operation. Everything works fine when I test 
./DoAlignment.pl on the console.

Many thanks for your help in advance

Tariq

_________________________________________________________________
Use MSN Messenger to send music and pics to your friends 
http://www.msn.co.uk/messenger

_______________________________________________
Bioperl-l mailing list
Bioperl-l at portal.open-bio.org
http://portal.open-bio.org/mailman/listinfo/bioperl-l


More information about the Bioperl-l mailing list