Hi
Have you looked at Bioperl (www.bioperl.org)? It is goldmine of tools for bioinformatics tasks.
Correct me if I'm wrong but do not the Swiss-Prot and UniProt have the same dataformat? You should therefore be able to use something like:
$stream = Bio::SeqIO->new(-file => $filename, -format => 'swiss');
while ( my $seq = $stream->next_seq() ) { # do something with $seq, like print "Sequence ",$seq->id,"\n"; }
where $filename contains the name of your flatfile.
Then you can just use DBI to insert each sequence to database.
Best regards, Gretar Mar
SG Edwards wrote:
Hi,
I am writing a perl program that will extract data from a UniProt (this is a protein database!) flatfile so that I can automatically put data into my PostgreSQL database. I am taking out name, protein ID number, references etc from the file.
Does anyone know if there is a script available to do this already?
Many thanks,
Stephen
-- To unsubscribe, e-mail: [EMAIL PROTECTED] For additional commands, e-mail: [EMAIL PROTECTED] <http://learn.perl.org/> <http://learn.perl.org/first-response>