Thank you! These links really helped me. Although I didn't succeed in parsing ensembl format annotaion file (I'm confused about which part is feature and which is tag), I finally got job done by downloading Genbank format annotation file, and wrote a BioPerl script for this.It's much easier~~
Hi there~ Now I got batch of gene IDs,and downloaded the annotation flat files from Ensembl (same specie ,of course). I wanna extract the description (briefly introduction for gene function) in the annotation file for each one of the IDs. Could anyone suggest a Perl module to do this job? Or other soft suit will be fine. I appreciate for your help!
2 answers
There is no single Ensembl format, that's possibly why your search didn't return something usable (you did a search on search.cpan.org for perl modules, didn't you ;).
You probably meant:
- EMBL format, then: Bio::SeqIO::embl
- or Genbank: Bio::SeqIO::genbank
- also GFF is common: Bio::FeatureIO::gff
nice it help,but which an ensembl format file are you referring to??
Maybe you want to consider using the Ensembl Perl API to get all the information you want for a gene, given a gene stable ID. Not only you won't have any trouble with formats, but you would be able to get much more (cross-references, GO annotations, location, etc).
Here are a few lines of code on how to do this:
[?]
You can easily extract other information in addition to the description.
Log in to answer this question.
I guess BioPerl would do the job.
The key question here is what exactly do you mean by "annotation flat files?" For doing things like extracting a couple of fields from a text file, just use "cut" instead of writing a script.
I know BioPerl, and did lots of search at CPAN~