[ensembl-dev] fetch all within species paralogous genes

shaohua fan shaohua.fan at uni-konstanz.de
Tue Apr 17 16:19:02 BST 2012


Dear Matthieu,

Thanks for the reply! I will try the scripts you sent to me. 

Shaohua  
On Apr 17, 2012, at 3:17 PM, Matthieu Muffato wrote:

> Dear Shaohua
> 
> The most efficient way is probably to use the fetch_all_by_MethodLinkSpeciesSet_orthology_type() method from the HomologyAdaptor
> 
> You first have to create a MethodLinkSpeciesSet object
> my $mlss_adaptor = $reg->get_adaptor("Multi", "compara", "MethodLinkSpeciesSet");
> my $mlss = $mlss_adaptor->fetch_by_method_link_type_registry_aliases("ENSEMBL_PARALOGUES", ["human"]);
> This object describes which kind of data you want, and on which species
> 
> Then, you can retrieve the homologies:
> my $homology_adaptor = $reg->get_adaptor("Multi", "compara", "Homology");
> my $all_paralogues = $homology_adaptor->fetch_all_by_MethodLinkSpeciesSet_orthology_type($mlss, "within_species_paralog");
> 
> This method can be extended to orthologues and to pairs of species. It is the fastest when it comes to fetch big sets of homologues
> 
> Hope this helps,
> Matthieu
> 
> On 17/04/12 10:45, shaohua fan wrote:
>> Dear all,
>> 
>> As a newbie of Ensembl compara API, I want to ask whether there is a way to fetch all the within species paralogous genes of one specified genome by using the compara API? I have searched the former emails and Ensembl website and only found the solution for the single gene in the tutorial of compara API.
>> 
>> Thanks a lot!
>> 
>> shaohua

-----------------------------------------------------------------------------------
Shaohua Fan, Ph.D student.
Professor Axel Meyer's Lab
Department of Biology (Fach M617)
University of Konstanz
Universitaetsstrasse 10
D-78457 Konstanz
Germany

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://mail.ensembl.org/pipermail/dev_ensembl.org/attachments/20120417/65a52b68/attachment.html>


More information about the Dev mailing list