8

Here's a Perl script that can do this: #!/usr/bin/env perl use strict; use warnings; ## Change this to whatever taxon you are working with my $taxon = 'taxon:1000'; chomp(my $date = `date +%Y%M%d`); my (%aspect, %gos); ## Read the GO.terms_and_ids file to get the aspect (sub ontology) ## of each GO term. open(my $fh, $ARGV[0]) or die "Need a GO....


6

I guess the following code will help, source("https://bioconductor.org/biocLite.R") biocLite("biomaRt") library("biomaRt") ensembl = useMart("ensembl", dataset = "hsapiens_gene_ensembl") #listAttributes(ensembl) mapping <- getBM(attributes = c("ensembl_gene_id", "hgnc_symbol", "go_id"), mart = ensembl) head(mapping)


6

Here's an example for the mouse genome: library(org.Mm.eg.db) select(org.Mm.eg.db, c("GO:0048406"), c("GENENAME","SYMBOL"), c("GO")) You get output like: GENENAME SYMBOL 1 pregnancy zone protein Pzp 2 nerve growth factor receptor (TNFR superfamily, member 16) Ngfr ...


4

I can offer this as a way to scrape the data from the Abcam resource: library(rvest) library(dplyr) antigens <- read_html("http://www.abcam.com/primary-antibodies/human-cd-antigen-guide") %>% html_node("table") %>% html_table(header = TRUE) # what targets expressed in "Langerhans" ? antigens %>% filter(grepl("Langerhans", `Cellular ...


4

The link to the FTP for the GOA database files is listed on the GOA Downloads page. The file containing the mapping info you seek, goa_uniprot.all, comes in two formats, .gaf and .gpa. The README in the FTP directory linked provides details on the structure of the files. Below is the first 20 lines of the .gaf file after uncompressing. Column 2 contains the ...


4

Sorry, this was my mistake in the last question. To search down the ontology, rather than just for the specific association with a term, biomaRt needs a different filter: 'go_parent_term'. Try: gene <- getBM(attributes = c('external_gene_name'), filters = 'go_parent_term', values = 'GO:0030098', mart = ensembl)


3

You can use BioMart to filter by your GO term and get the genes as attributes. BioMart is ontology-aware so will pull out all genes associated with your term and with any of its child terms. There is no need to look up the GO child terms as BioMart already deals with this. A term may have more than one parent term, but if it's associated with a gene then ...


3

use a XSLT processor (http://php.net/manual/en/class.xsltprocessor.php) with the following stylesheet. <?xml version='1.0' encoding="UTF-8"?> <xsl:stylesheet xmlns:xsl='http://www.w3.org/1999/XSL/Transform' version='1.0'> <xsl:output method="html"/> <xsl:template match="/"> <div> <xsl:apply-...


2

The DAVID tool is always interesting, and easy to try: https://david.ncifcrf.gov/gene2gene.jsp You submit a list of genes, it uses several different annotation databases to annotate the gene list, and then it clusters the results and tests for statistical enrichment. You can potentially learn about functional enrichment in your gene list from several ...


2

There are two topics here to be discussed. Gene Set Enrichment Analysis and a kernel Density plot. GSEA The Wikipedia page about Gene Set Enrichment Analysis covers well the principle and the tools that can be used to calculate it. To cite it: The general steps are summarized below: Calculate the enrichment score (ES) that represents the amount to which the ...


2

I don't know how to do that in R but I think this is what you want: I used http://json2table.com for view the data structure of the JSON file, then I used json_normalize to normalize the JSON data into a flat table using the key [result] to a list of DataFrames for each index in the JSON file. Then, I concatenated the list of DataFrames in a single one with ...


2

I suggest you give DAVID a try. Specifically, their Functional Annotation tool. Just enter your list of protein IDs, and it will return groups of proteins where particular GO functions are overrepresented. This should at least help you start categorizing your list into functional groups.


2

Using the UniProt website API (https://www.uniprot.org/help/api) this could be done with a query like https://www.uniprot.org/uniprot/?query=name%3A%22type%20IV%20secretion%20protein%20Rhs%22&columns=id%2Centry%20name%2Creviewed%2Cprotein%20names%2Cgenes%2Cgo(biological%20process)%2Cgo(molecular%20function)%2Cgo(cellular%20component)&sort=score or, ...


1

That package was deprecated in Bioconductor version 3.13 after several attempts to contact the package author/maintainer. Your options include reverting back to Bioconductor version 3.12 or using one of the other options for GO/pathway enrichment analyses, e.g. topGO, enrichR, or clusterProfiler.


1

This is usually done using AnnotationDbi in combination with the annotation database for human org.Hs.eg.db. library(org.Hs.eg.db) genes <- c("ENSG00000102055", "ENSG00000232605", "ENSG00000136828", "ENSG00000159197", "ENSG00000201394", "ENSG00000278580", "...


1

I think to identify latent variables, PCA is probably not going to work. NMF might be worth trying. You might want to check out a method called consensus NMF (cNMF) (https://elifesciences.org/articles/43803) published in eLife. The author described some latent variables corresponds to cell types, while others corresponds to cell-cycle or metabolic states of ...


1

What is "click here for details" saying? That link should contain an explanation of what happened. GSEA usually requires entrez_id to run. If your list contains gene_symbols, then before enrichment, you need to convert the genes names. This can and is (always) tricky as genes are known with different names. For example, by googling I couldn't find any AASS3 ...


1

Short answer, we get our annotations from GOA, which has the three listed. We're in touch with GOA to see why they differ from MGI.


1

One way to do this would be to plot the first 10 GO categories of the the CC sub ontology (CC from cellular component). Or you can just visit the official webpage to see the list of children terms of them. However there aren't only 4 or 5 categories, so you could arbitrary pick some of those.


Only top voted, non community-wiki answers of a minimum length are eligible