:SELECT * :FROM term INNER JOIN association AS association1 ON (association1.term_id = term.id) INNER JOIN association AS association2 ON (association1.gene_product_id = association2.gene_product_id) INNER JOIN term AS correlated_term ON (association2.term_id = correlated_term.id) INNER JOIN gene_product ON (association2.gene_product_id = gene_product.id) INNER JOIN dbxref ON (gene_product.dbxref_id = dbxref.id) INNER JOIN species ON (gene_product.species_id = species.id) :WHERE [association1.term_id != association2.term_id] [term.id != correlated_term.id] [term.acc = &term_acc&] [term.name = &term_name&] [correlated_term.term_type = &correlated_term_type&] [correlated_term.acc = &correlated_term_acc&] [correlated_term.name = &correlated_term_name&] [association1.is_not = 0] [association2.is_not = 0] :USE NESTING (set(term(correlated_term(association1)(association2)(gene_product(dbxref)(species))))) // schema: go desc: given a GO term, fetch other GO terms associated with the same gene_product. will also show the gene_products the term pair shares For example, term_name = ribosome and correlated_term_name = protein biosynthesis should yeild a high value for number_of_gps, since these terms are biologically correlated does not use graph structure (direct associations only) example_input: term_acc => SELECT acc FROM term example_input: term_name => SELECT name FROM term ORDER BY name example_input: correlated_term_type => biological_process, cellular_component, molecular_function example_input: correlated_term_acc => SELECT acc FROM term example_input: correlated_term_name => SELECT name FROM term ORDER BY name