作者 LiloHuang (相見不如懷念) 看板 Perl
標題 支持Perl on Google App Engine 幫忙投票
時間 Mon Jun 9 21:51:29 2008
───────────────────────────────────────
最近火紅的 Google App Engine 已經開放申請了
philip 發表在 痞客邦 留言(0) 人氣(191)
Name:
CutPeptide.pl
Description:
將
ensemble的 peptide sequences (fasta files),個別輸出成單筆sequence
Source Code:
#!/usr/bin/perl
##############
# Edit by Philippe
# 05.14.08
##############
# input FASTA files
open(IN, "/home/philippe/CutPeptide/Homo_sapiens.NCBI36.49.pep.all.fas");
while ($line = )
{
chomp($line);
# regular expression, match >
if ($line =~ /^>(.*)/)
{
$ENSP = $1;
print "$ENSP\n";
# output FASTA files
open (OUT, "+>/home/philippe/CutPeptide/pep_all_fasta/$ENSP.fas");
print OUT ">$ENSP\n";
}
else
{
print OUT "$line\n";
}
}
close IN;
close OUT;
philip 發表在 痞客邦 留言(0) 人氣(76)
這篇程式碼真的太有趣了,大家可以跑跑看!
#!usr/bin/perl
# "To be or not to be, that's a question!"
open DNA, $AGRV[0] || die "Die!!";
While(<DNA>){
$_Saint=0; $_Alive=0; $_Hell=0;
While(<DNA>){
$_Saint=1;
break;
}
While(<DNA>){
While(<
While(<
While(<
While(<
While(<
While(<DNA>){
$_Alive=1;
break;}>)
{break;}>)
{break;}>)
{break;}>)
{break;}>)
{break;}
break;
}
While(<DNA>){
While(<
While(<
While(<
While(<
While(<
While(<DNA>){
$_Hell=1;
}>)
{ ;}>)
{ ;}>)
{ ;}>)
{ ;}>)
{ ;}
break;
}
}
close DNA;
#2Bor^2B,that's a question!
philip 發表在 痞客邦 留言(0) 人氣(164)