#!/usr/bin/perl -w ###################################################################################################################################### # fugue_filter.pl ###################################################################################################################################### # # Written by Osvaldo Graña, January 2001 # # This program filters data from "Fugue profile lib search" to use it under THREADLIZE # ("http://www.cnb.uam.es/~pazos/threadlize" Pazos, Rost & Valencia (1999) Bioinformatics 15(12):1062-1063) # # # HOW TO USE IT: # # Once you get your results within an email from fugue server (read in the web page what options you have to # check in the fugue cgi), save the email content in a ".txt" file (for example "1aaf.txt") and filter it # as follows: # # fugue_filter.pl 1aaf.txt > results # # "results" will contain filtered data, it can be used as an input for THREADLIZE: # # threadlize results & # # # LICENSE TERMS: # # This program is free licensed for academic and non-profit users. Private users, please, contact Osvaldo Graña (osvaldog@cnb.uam.es). # # Please, do not modify the code. # # This program is distributed in the hope that it will be useful, but WITHOUT ANY WARRANTY. # # # # Osvaldo Graña # Protein Design Group (CNB-CSIC) # Campus Universidad Autonoma. # Cantoblanco. 28049 Madrid. # Tlf: +34-91-5854570. Fax: +34-91-5854506. # osvaldog@cnb.uam.es # http://www.pdg.cnb.uam.es/ # # ###################################################################################################################################### use strict; my ( @in, @linea, @score, $dimension, $i, $j, $actual, $copiar, $target, @secuencia_target, @pdbcode, @secuencia_structure, $aux, @prov_target, @prov_model, $copiar2, $long, $contador, $aux2, $espacios ); open (FUGUE,$ARGV[0]) || die "fugue_pilter.pl: Cannot open $ARGV[0]\n\n"; @in=; close FUGUE; @score=(); $dimension=@in; $copiar=0; @secuencia_target=(); for ($i=0;$i<$dimension;$i++) { if (($in[$i]=~ />P1/) && ($in[$i+1]=~ /sequence/)) { $copiar=1; $i=$i+2; } if ($copiar==1) { $_=$in[$i]; $_=~ s/\-|\*| //g; $_=uc($_); push @secuencia_target,$_; if ((defined $in[$i+1]) && ($in[$i+1]=~ /^\n/)) { last; } } } $copiar=0; for ($i=0;$i<$dimension;$i++) { if ($copiar==1) { push @score,$in[$i]; if ((defined $in[$i+1]) && ($in[$i+1]=~ /^\n/)) { last; } } if ($in[$i]=~ /\*\*\*\*\*\*/) { push @score,$in[$i-1]; $i++; $copiar=1; } } print"3D-PSSM\n\n"; foreach (@secuencia_target) { print"Conf: "; chomp; $espacios=""; for ($i=0;$iP1/); push @secuencia_structure,"#\n"; $i=$i+2; do { $aux=$in[$i]; $aux=~ s/\-/\./g; $aux=~ s/\*//g; $aux=uc($aux); push @secuencia_target,$aux; $i++; } until ($in[$i]=~ /^\n/); push @secuencia_target,"#\n"; } } for ($i=0;$i<@pdbcode;$i++) { $_=$pdbcode[$i]; for ($j=0;$j=@secuencia_structure) { last; } } }