Answers.Body: <p>Description of how to use biomaRt <a href="http://www.ensembl.org/info/data/biomart/biomart_r_package.html" rel="noreferrer">here</a>. Filter by your list of gene IDs. Get the descriptions etc as attributes. Eg:</p>
  
  <pre><code>&gt; library(biomaRt)
  &gt; ensembl = useEnsembl(biomart="ensembl", dataset="hsapiens_gene_ensembl")
  &gt; IDs &lt;- c("BRCA2","BRAF")
  genedesc &lt;- getBM(attributes=c('external_gene_name','description'), filters = 'external_gene_name', values = IDs, mart =ensembl)
  &gt; genedesc
    external_gene_name                                                                      description
  1               BRAF B-Raf proto-oncogene, serine/threonine kinase [Source:HGNC Symbol;Acc:HGNC:1097]
  2              BRCA2                  BRCA2, DNA repair associated [Source:HGNC Symbol;Acc:HGNC:1101]
  </code></pre>
  
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2017-10-16T15:25:44.523Z
Answers.Text: Thank you for the answer. I did not find a way to return detailed information  using biomaRt. The description fields are just extended gene names.
Answers.UserDisplayName: Peter
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2017-10-16T09:44:18.097Z
Answers.LastActivityDate: 2017-10-16T09:44:18.097Z
Answers.UserDisplayName: Emily_Ensembl
Answers.Body: <p>The easiest and fastest method (which also doesn’t require internet access) is to use <a href="http://bioconductor.org/packages/3.9/bioc/vignettes/AnnotationDbi/inst/doc/IntroToAnnotationPackages.pdf" rel="nofollow noreferrer">annotation packages</a>, e.g. <a href="http://bioconductor.org/packages/3.9/data/annotation/html/org.Mm.eg.db.html" rel="nofollow noreferrer">org.Mm.eg.db</a>:</p>
  
  <pre><code>library(AnnotationDbi)
  library(org.Mm.eg.db)
  
  
  # 1:1 mapping symbol→entrez
  entrez_ids &lt;- mapIds(org.Mm.eg.db, gene_symbols, 'ENTREZ', 'SYMBOL')
  
  # 1:n mapping symbol→…
  print(columns(org.Mm.eg.db))  # check what you can query
  df &lt;- select(org.Mm.eg.db, gene_symbols, c(...), 'SYMBOL')
  </code></pre>
  
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2019-08-14T11:27:34.750Z
Answers.LastActivityDate: 2019-08-14T11:27:34.750Z
Answers.UserDisplayName: flying sheep
Answers.Body: <h2>MyGene.info</h2>
  
  <p>Using the <a href="https://bioconductor.org/packages/release/bioc/html/mygene.html" rel="nofollow noreferrer">R package</a> for the <a href="http://mygene.info" rel="nofollow noreferrer">MyGene.info database</a>:</p>
  
  <pre><code>source("https://bioconductor.org/biocLite.R")
  biocLite("mygene")
  
  library(mygene)
  gene &lt;- getGene("1017", fields="all")
  gene$summary
  </code></pre>
  
  <p>Multiple genes:</p>
  
  <pre><code>gene &lt;- getGenes(c(1347:1350), fields="summary")
  </code></pre>
  
  <hr>
  
  <h2>Entrez database</h2>
  
  <pre><code>library(devtools)
  install_github("ropensci/rentrez")
  
  library(rentrez)
  genes &lt;- entrez_summary(db="gene", id=c(718,720))
  genes$`720`$summary
  </code></pre>
  
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2017-10-16T06:56:20.437Z
Answers.Text: Nice question (and answer, I didn't know about MyGene), if you know what you are looking for maybe it is worth to mention biomaRt
Answers.UserDisplayName: llrs
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2017-10-14T16:31:35.103Z
Answers.LastActivityDate: 2018-01-18T13:43:09.873Z
Answers.LastEditDate: 2018-01-18T13:43:09.873Z
Answers.UserDisplayName: Peter
Body: <p>Given a list of gene IDs, how do you retrieve the gene description, summary and other detailed information in R?</p>
  
Tags: <r><gene><sequence-annotation><public-databases>
Title: Retrieve detailed gene descriptions
ThreadText: # Retrieve detailed gene descriptions
  
  (Asked by: username_0 on 2017-10-14)
  
  Given a list of gene IDs, how do you retrieve the gene description, summary and other detailed information in R?
  
  **Tags:** r, gene, sequence-annotation, public-databases
  
  
  ---
  
  ## 3 answers
  
  ### Answer by username_0 on 2017-10-14. Score: 7 | Accepted answer
  
  ## MyGene.info
  
  Using the [R package](https://bioconductor.org/packages/release/bioc/html/mygene.html) for the [MyGene.info database](http://mygene.info):
  
  ```
  source("https://bioconductor.org/biocLite.R")
  biocLite("mygene")
  
  library(mygene)
  gene <- getGene("1017", fields="all")
  gene$summary
  
  ```
  
  Multiple genes:
  
  ```
  gene <- getGenes(c(1347:1350), fields="summary")
  
  ```
  
  ---
  
  ## Entrez database
  
  ```
  library(devtools)
  install_github("ropensci/rentrez")
  
  library(rentrez)
  genes <- entrez_summary(db="gene", id=c(718,720))
  genes$`720`$summary
  
  ```
  
  > **Comments:**
  > **username_3**: Nice question (and answer, I didn't know about MyGene), if you know what you are looking for maybe it is worth to mention biomaRt  
  
  ---
  
  ### Answer by username_1 on 2017-10-16. Score: 8
  
  Description of how to use biomaRt [here](http://www.ensembl.org/info/data/biomart/biomart_r_package.html). Filter by your list of gene IDs. Get the descriptions etc as attributes. Eg:
  
  ```
  > library(biomaRt)
  > ensembl = useEnsembl(biomart="ensembl", dataset="hsapiens_gene_ensembl")
  > IDs <- c("BRCA2","BRAF")
  genedesc <- getBM(attributes=c('external_gene_name','description'), filters = 'external_gene_name', values = IDs, mart =ensembl)
  > genedesc
    external_gene_name                                                                      description
  1               BRAF B-Raf proto-oncogene, serine/threonine kinase [Source:HGNC Symbol;Acc:HGNC:1097]
  2              BRCA2                  BRCA2, DNA repair associated [Source:HGNC Symbol;Acc:HGNC:1101]
  
  ```
  
  > **Comments:**
  > **username_0**: Thank you for the answer. I did not find a way to return detailed information  using biomaRt. The description fields are just extended gene names.  
  
  ---
  
  ### Answer by username_2 on 2019-08-14. Score: 2
  
  The easiest and fastest method (which also doesn’t require internet access) is to use [annotation packages](http://bioconductor.org/packages/3.9/bioc/vignettes/AnnotationDbi/inst/doc/IntroToAnnotationPackages.pdf), e.g. [org.Mm.eg.db](http://bioconductor.org/packages/3.9/data/annotation/html/org.Mm.eg.db.html):
  
  ```
  library(AnnotationDbi)
  library(org.Mm.eg.db)
  
  # 1:1 mapping symbol→entrez
  entrez_ids <- mapIds(org.Mm.eg.db, gene_symbols, 'ENTREZ', 'SYMBOL')
  
  # 1:n mapping symbol→…
  print(columns(org.Mm.eg.db))  # check what you can query
  df <- select(org.Mm.eg.db, gene_symbols, c(...), 'SYMBOL')
  
  ```
  
  
  ---
  
  