<div dir="ltr">Thanks!</div><br><div class="gmail_quote"><div dir="ltr" class="gmail_attr">On Thu, 18 Jul 2019 at 13:38, Anja Thormann <<a href="mailto:anja@ebi.ac.uk">anja@ebi.ac.uk</a>> wrote:<br></div><blockquote class="gmail_quote" style="margin:0px 0px 0px 0.8ex;border-left:1px solid rgb(204,204,204);padding-left:1ex"><div style="overflow-wrap: break-word;"><div>Hi Ramiro,</div><div><br></div><div>we provide LD calculations for species for which we have sufficient amount of genotype data. Our script expects at least 40 samples per population for LD calculation. At the moment we have enough genotype data for human, goat and sheep.</div><div><br></div><div>You can query our population endpoint for your species of interest  with the filter variable set to LD in order to find out for which populations LD can be calculated: For example for human: </div><div><a href="https://rest.ensembl.org/info/variation/populations/homo_sapiens?filter=LD;content-type=application/json" target="_blank">https://rest.ensembl.org/info/variation/populations/homo_sapiens?filter=LD;content-type=application/json</a></div><div><br></div><div>We will provide better exception handling for the cases you have listed in your examples.</div><div><br></div><div>Thank you,</div><div>Anja</div><div><br><blockquote type="cite"><div>On 18 Jul 2019, at 12:04, Ramiro Magno <<a href="mailto:ramiro.magno@gmail.com" target="_blank">ramiro.magno@gmail.com</a>> wrote:</div><br class="gmail-m_6828473094815871867Apple-interchange-newline"><div><div dir="ltr">Hi<div><br></div><div>What should I expect when using this endpoint with other species than human:</div><div><br></div><div><a href="http://rest.ensembl.org/documentation/info/ld_region_get" target="_blank">http://rest.ensembl.org/documentation/info/ld_region_get</a><br></div><div><br></div><div>The returned errors do not seem to be consistent. Some expose internal errors even. I was expecting some error more specifically related to the invalid parameter.</div><div><br></div><div>Here's some examples:</div><div><br></div><div><b>Example 1</b></div><div><br></div><div><font face="courier new, monospace">* Endpoint:       <a href="https://rest.ensembl.org/ld/gorilla/rs1042779/1000GENOMES:phase_3:CEU?window_size=50;d_prime=0;r2=0" target="_blank">https://rest.ensembl.org/ld/gorilla/rs1042779/1000GENOMES:phase_3:CEU?window_size=50;d_prime=0;r2=0</a><br>* Status code:    400<br>* Error message: "Can't call method "max_snp_distance" on an undefined value at /nfs/public/release/ensweb/live/rest/www_97/ensembl-rest/lib/EnsEMBL/REST/Model/LDFeatureContainer.pm line 50.</font><br></div><div><br></div><div><b>Example 2</b></div><div><br></div><div><font face="courier new, monospace">* Endpoint:       <a href="https://rest.ensembl.org/ld/gorilla/region/1:1..10000/1000GENOMES:phase_3:CEU?d_prime=0;r2=0" target="_blank">https://rest.ensembl.org/ld/gorilla/region/1:1..10000/1000GENOMES:phase_3:CEU?d_prime=0;r2=0</a><br>* Status code:    400<br>* Error message: "Can't call method "db" on an undefined value at /nfs/public/release/ensweb/live/rest/www_97/ensembl-rest/lib/EnsEMBL/REST/Model/LDFeatureContainer.pm line 92.</font><br></div><div><br></div><div><b>Example 3</b></div><div><br></div><div><font face="courier new, monospace">* Endpoint: <a href="https://rest.ensembl.org/ld/fly/region/1:1..10000/1000GENOMES:phase_3:CEU?d_prime=0;r2=0" target="_blank">https://rest.ensembl.org/ld/fly/region/1:1..10000/1000GENOMES:phase_3:CEU?d_prime=0;r2=0</a></font></div><div><font face="courier new, monospace">* Status code: 500</font></div><div><font face="courier new, monospace">* Error message:  Error: lexical error: invalid char in json text.</font></div><font face="courier new, monospace">                                       <!DOCTYPE html>    <html lang="<br>                     (right here) ------^</font><div><br></div><div>Cheers,</div><div>RM</div></div>
_______________________________________________<br>Dev mailing list    <a href="mailto:Dev@ensembl.org" target="_blank">Dev@ensembl.org</a><br>Posting guidelines and subscribe/unsubscribe info: <a href="https://lists.ensembl.org/mailman/listinfo/dev_ensembl.org" target="_blank">https://lists.ensembl.org/mailman/listinfo/dev_ensembl.org</a><br>Ensembl Blog: <a href="http://www.ensembl.info/" target="_blank">http://www.ensembl.info/</a><br></div></blockquote></div><br></div>_______________________________________________<br>
Dev mailing list    <a href="mailto:Dev@ensembl.org" target="_blank">Dev@ensembl.org</a><br>
Posting guidelines and subscribe/unsubscribe info: <a href="https://lists.ensembl.org/mailman/listinfo/dev_ensembl.org" rel="noreferrer" target="_blank">https://lists.ensembl.org/mailman/listinfo/dev_ensembl.org</a><br>
Ensembl Blog: <a href="http://www.ensembl.info/" rel="noreferrer" target="_blank">http://www.ensembl.info/</a><br>
</blockquote></div>