ropensci / taxize

A taxonomic toolbelt for R
https://docs.ropensci.org/taxize
Other
264 stars 58 forks source link

Can/should we add more functionality for the NCBI/entrez API? #193

Closed sckott closed 10 years ago

sckott commented 10 years ago
eduardszoecs commented 10 years ago

1) Don't think that the API supports this 2) get_uid wraps/uses entrez. No need to add an additional dependency.

sckott commented 10 years ago

Okay. Just curious if there are other API methods that NCBI has that we aren't using yet. If we have already exhausted their taxonomic API methods, then cool.

eduardszoecs commented 10 years ago

This is returned by http://eutils.ncbi.nlm.nih.gov/entrez/eutils/efetch.fcgi?db=taxonomy&ID=189838. We could extract the common name...

BTW: get_uid() (and their methods) work also with common names.

<?xml version="1.0"?>
<!DOCTYPE TaxaSet PUBLIC "-//NLM//DTD Taxon, 14th January 2002//EN" "http://www.ncbi.nlm.nih.gov/entrez/query/DTD/taxon.dtd">
<TaxaSet>
  <Taxon>
    <TaxId>189838</TaxId>
    <ScientificName>Baetis</ScientificName>
    <OtherNames>
      <CommonName>blue-winged olives</CommonName>
    </OtherNames>
    <ParentTaxId>172515</ParentTaxId>
    <Rank>genus</Rank>
    <Division>Invertebrates</Division>
    <GeneticCode>
      <GCId>1</GCId>
      <GCName>Standard</GCName>
    </GeneticCode>
    <MitoGeneticCode>
      <MGCId>5</MGCId>
      <MGCName>Invertebrate Mitochondrial</MGCName>
    </MitoGeneticCode>
    <Lineage>cellular organisms; Eukaryota; Opisthokonta; Metazoa; Eumetazoa; Bilateria; Protostomia; Ecdysozoa; Panarthropoda; Arthropoda; Mandibulata; Pancrustacea; Hexapoda; Insecta; Dicondylia; Pterygota; Palaeoptera; Ephemeroptera; Pisciforma; Baetidae</Lineage>
    <LineageEx>
      <Taxon>
        <TaxId>131567</TaxId>
        <ScientificName>cellular organisms</ScientificName>
        <Rank>no rank</Rank>
      </Taxon>
      <Taxon>
        <TaxId>2759</TaxId>
        <ScientificName>Eukaryota</ScientificName>
        <Rank>superkingdom</Rank>
      </Taxon>
      <Taxon>
        <TaxId>33154</TaxId>
        <ScientificName>Opisthokonta</ScientificName>
        <Rank>no rank</Rank>
      </Taxon>
      <Taxon>
        <TaxId>33208</TaxId>
        <ScientificName>Metazoa</ScientificName>
        <Rank>kingdom</Rank>
      </Taxon>
      <Taxon>
        <TaxId>6072</TaxId>
        <ScientificName>Eumetazoa</ScientificName>
        <Rank>no rank</Rank>
      </Taxon>
      <Taxon>
        <TaxId>33213</TaxId>
        <ScientificName>Bilateria</ScientificName>
        <Rank>no rank</Rank>
      </Taxon>
      <Taxon>
        <TaxId>33317</TaxId>
        <ScientificName>Protostomia</ScientificName>
        <Rank>no rank</Rank>
      </Taxon>
      <Taxon>
        <TaxId>1206794</TaxId>
        <ScientificName>Ecdysozoa</ScientificName>
        <Rank>no rank</Rank>
      </Taxon>
      <Taxon>
        <TaxId>88770</TaxId>
        <ScientificName>Panarthropoda</ScientificName>
        <Rank>no rank</Rank>
      </Taxon>
      <Taxon>
        <TaxId>6656</TaxId>
        <ScientificName>Arthropoda</ScientificName>
        <Rank>phylum</Rank>
      </Taxon>
      <Taxon>
        <TaxId>197563</TaxId>
        <ScientificName>Mandibulata</ScientificName>
        <Rank>no rank</Rank>
      </Taxon>
      <Taxon>
        <TaxId>197562</TaxId>
        <ScientificName>Pancrustacea</ScientificName>
        <Rank>no rank</Rank>
      </Taxon>
      <Taxon>
        <TaxId>6960</TaxId>
        <ScientificName>Hexapoda</ScientificName>
        <Rank>superclass</Rank>
      </Taxon>
      <Taxon>
        <TaxId>50557</TaxId>
        <ScientificName>Insecta</ScientificName>
        <Rank>class</Rank>
      </Taxon>
      <Taxon>
        <TaxId>85512</TaxId>
        <ScientificName>Dicondylia</ScientificName>
        <Rank>no rank</Rank>
      </Taxon>
      <Taxon>
        <TaxId>7496</TaxId>
        <ScientificName>Pterygota</ScientificName>
        <Rank>no rank</Rank>
      </Taxon>
      <Taxon>
        <TaxId>33339</TaxId>
        <ScientificName>Palaeoptera</ScientificName>
        <Rank>subclass</Rank>
      </Taxon>
      <Taxon>
        <TaxId>30073</TaxId>
        <ScientificName>Ephemeroptera</ScientificName>
        <Rank>order</Rank>
      </Taxon>
      <Taxon>
        <TaxId>185809</TaxId>
        <ScientificName>Pisciforma</ScientificName>
        <Rank>suborder</Rank>
      </Taxon>
      <Taxon>
        <TaxId>172515</TaxId>
        <ScientificName>Baetidae</ScientificName>
        <Rank>family</Rank>
      </Taxon>
    </LineageEx>
    <CreateDate>2002/03/14 11:39:00</CreateDate>
    <UpdateDate>2011/04/29 16:01:45</UpdateDate>
    <PubDate>2002/09/05 19:00:00</PubDate>
  </Taxon>
</TaxaSet>```
sckott commented 10 years ago

That would be good to extract common names.

I don't think I was aware it worked with common names, that's great.

eduardszoecs commented 10 years ago

I don't think I was aware it worked with common names, that's great.

That's nowhere documented within taxize. And I don't know how good the coverage of NCBI with common names is...

sckott commented 10 years ago

Looks like we don't want to do anything further on this, I'll make another issue though to see if we can pull stuff from rentrez/rpubmed for NCBI taxonomy data