Query Metapaths Random Nodes
Return metapaths for a random source and target node for which at least one metapath with path count information exists in the database.
GET /v1/metapaths/random-nodes/?format=api
http://identifiers.org/ncbigene/161", "source": "Entrez Gene", "license": "CC0 1.0", "chromosome": "11", "description": "adaptor-related protein complex 2, alpha 2 subunit" }, "metanode": "Gene" }, "target": { "id": 38188, "identifier": "GO:0016491", "identifier_type": "str", "name": "oxidoreductase activity", "properties": { "url": "http://purl.obolibrary.org/obo/GO_0016491", "source": "Gene Ontology", "license": "CC BY 4.0" }, "metanode": "Molecular Function" }, "path_counts": [ { "id": 129693515, "adjusted_p_value": 9.611036295990477e-23, "path_count": 19967, "dwpc": 3.321674447276205, "p_value": 2.044901339572442e-24, "reversed": false, "metapath_abbreviation": "GeAeGpMF", "metapath_name": "Gene–expresses–Anatomy–expresses–Gene–participates–Molecular Function", "metapath_length": 3, "metapath_path_count_density": 0.8601219999999999, "metapath_path_count_mean": 432.481, "metapath_path_count_max": 34277, "metapath_dwpc_raw_mean": 5.82376e-05, "metapath_n_similar": 47, "metapath_p_threshold": 0.0004926624476413501, "metapath_id": "GeAeGpMF", "metapath_reversed": false, "metapath_metaedges": [ [ "Gene", "Anatomy", "expresses", "both" ], [ "Anatomy", "Gene", "expresses", "both" ], [ "Gene", "Molecular Function", "participates", "both" ] ], "dgp_id": 32213945, "dgp_source_degree": 52, "dgp_target_degree": 697, "dgp_n_dwpcs": 47800, "dgp_n_nonzero_dwpcs": 47800, "dgp_nonzero_mean": 3.069067607316235, "dgp_nonzero_sd": 0.024291059458263247, "dgp_reversed": false, "cypher_query": "MATCH path = (n0:Gene)-[:EXPRESSES_AeG]-(n1)-[:EXPRESSES_AeG]-(n2)-[:PARTICIPATES_GpMF]-(n3:MolecularFunction)\nUSING JOIN ON n1\nWHERE n0.identifier = 161 // AP2A2\nAND n3.identifier = 'GO:0016491' // oxidoreductase activity\nAND n0 <> n2\nWITH\n[\nsize((n0)-[:EXPRESSES_AeG]-()),\nsize(()-[:EXPRESSES_AeG]-(n1)),\nsize((n1)-[:EXPRESSES_AeG]-()),\nsize(()-[:EXPRESSES_AeG]-(n2)),\nsize((n2)-[:PARTICIPATES_GpMF]-()),\nsize(()-[:PARTICIPATES_GpMF]-(n3))\n] AS degrees, path\nWITH path, reduce(pdp = 1.0, d in degrees| pdp * d ^ -0.5) AS PDP\nWITH collect({paths: path, PDPs: PDP}) AS data_maps, count(path) AS PC, sum(PDP) AS DWPC\nUNWIND data_maps AS data_map\nWITH data_map.paths AS path, data_map.PDPs AS PDP, PC, DWPC\nRETURN\n path AS neo4j_path,\n substring(reduce(s = '', node IN nodes(path)| s + '–' + node.name), 1) AS path,\n PDP,\n 100 * (PDP / DWPC) AS percent_of_DWPC\nORDER BY percent_of_DWPC DESC\nLIMIT 10" }, { "id": 4331346, "adjusted_p_value": 7.471781814050854e-06, "path_count": 1498, "dwpc": 3.2664204605101697, "p_value": 1.5897408115001817e-07, "reversed": false, "metapath_abbreviation": "GdAdGpMF", "metapath_name": "Gene–downregulates–Anatomy–downregulates–Gene–participates–Molecular Function", "metapath_length": 3, "metapath_path_count_density": 0.663678, "metapath_path_count_mean": 33.4844, "metapath_path_count_max": 5788, "metapath_dwpc_raw_mean": 4.8799300000000006e-05, "metapath_n_similar": 47, "metapath_p_threshold": 0.0004926624476413501, "metapath_id": "GdAdGpMF", "metapath_reversed": false, "metapath_metaedges": [ [ "Gene", "Anatomy", "downregulates", "both" ], [ "Anatomy", "Gene", "downregulates", "both" ], [ "Gene", "Molecular Function", "participates", "both" ] ], "dgp_id": 31359005, "dgp_source_degree": 8, "dgp_target_degree": 697, "dgp_n_dwpcs": 196000, "dgp_n_nonzero_dwpcs": 196000, "dgp_nonzero_mean": 3.0512072181862546, "dgp_nonzero_sd": 0.041180757252789885, "dgp_reversed": false, "cypher_query": "MATCH path = (n0:Gene)-[:DOWNREGULATES_AdG]-(n1)-[:DOWNREGULATES_AdG]-(n2)-[:PARTICIPATES_GpMF]-(n3:MolecularFunction)\nUSING JOIN ON n1\nWHERE n0.identifier = 161 // AP2A2\nAND n3.identifier = 'GO:0016491' // oxidoreductase activity\nAND n0 <> n2\nWITH\n[\nsize((n0)-[:DOWNREGULATES_AdG]-()),\nsize(()-[:DOWNREGULATES_AdG]-(n1)),\nsize((n1)-[:DOWNREGULATES_AdG]-()),\nsize(()-[:DOWNREGULATES_AdG]-(n2)),\nsize((n2)-[:PARTICIPATES_GpMF]-()),\nsize(()-[:PARTICIPATES_GpMF]-(n3))\n] AS degrees, path\nWITH path, reduce(pdp = 1.0, d in degrees| pdp * d ^ -0.5) AS PDP\nWITH collect({paths: path, PDPs: PDP}) AS data_maps, count(path) AS PC, sum(PDP) AS DWPC\nUNWIND data_maps AS data_map\nWITH data_map.paths AS path, data_map.PDPs AS PDP, PC, DWPC\nRETURN\n path AS neo4j_path,\n substring(reduce(s = '', node IN nodes(path)| s + '–' + node.name), 1) AS path,\n PDP,\n 100 * (PDP / DWPC) AS percent_of_DWPC\nORDER BY percent_of_DWPC DESC\nLIMIT 10" }, { "id": 1491678, "adjusted_p_value": 0.0011566508812158429, "path_count": 4216, "dwpc": 3.3458029106628695, "p_value": 2.460959321735836e-05, "reversed": false, "metapath_abbreviation": "GeAdGpMF", "metapath_name": "Gene–expresses–Anatomy–downregulates–Gene–participates–Molecular Function", "metapath_length": 3, "metapath_path_count_density": 0.80995, "metapath_path_count_mean": 92.24, "metapath_path_count_max": 6744, "metapath_dwpc_raw_mean": 3.94901e-05, "metapath_n_similar": 47, "metapath_p_threshold": 0.0004926624476413501, "metapath_id": "GeAdGpMF", "metapath_reversed": false, "metapath_metaedges": [ [ "Gene", "Anatomy", "expresses", "both" ], [ "Anatomy", "Gene", "downregulates", "both" ], [ "Gene", "Molecular Function", "participates", "both" ] ], "dgp_id": 32067245, "dgp_source_degree": 52, "dgp_target_degree": 697, "dgp_n_dwpcs": 47800, "dgp_n_nonzero_dwpcs": 47800, "dgp_nonzero_mean": 3.061532159481726, "dgp_nonzero_sd": 0.06809571923142312, "dgp_reversed": false, "cypher_query": "MATCH path = (n0:Gene)-[:EXPRESSES_AeG]-(n1)-[:DOWNREGULATES_AdG]-(n2)-[:PARTICIPATES_GpMF]-(n3:MolecularFunction)\nUSING JOIN ON n1\nWHERE n0.identifier = 161 // AP2A2\nAND n3.identifier = 'GO:0016491' // oxidoreductase activity\nAND n0 <> n2\nWITH\n[\nsize((n0)-[:EXPRESSES_AeG]-()),\nsize(()-[:EXPRESSES_AeG]-(n1)),\nsize((n1)-[:DOWNREGULATES_AdG]-()),\nsize(()-[:DOWNREGULATES_AdG]-(n2)),\nsize((n2)-[:PARTICIPATES_GpMF]-()),\nsize(()-[:PARTICIPATES_GpMF]-(n3))\n] AS degrees, path\nWITH path, reduce(pdp = 1.0, d in degrees| pdp * d ^ -0.5) AS PDP\nWITH collect({paths: path, PDPs: PDP}) AS data_maps, count(path) AS PC, sum(PDP) AS DWPC\nUNWIND data_maps AS data_map\nWITH data_map.paths AS path, data_map.PDPs AS PDP, PC, DWPC\nRETURN\n path AS neo4j_path,\n substring(reduce(s = '', node IN nodes(path)| s + '–' + node.name), 1) AS path,\n PDP,\n 100 * (PDP / DWPC) AS percent_of_DWPC\nORDER BY percent_of_DWPC DESC\nLIMIT 10" }, { "id": 99198362, "adjusted_p_value": 0.002741299521921778, "path_count": 3609, "dwpc": 3.314221831432889, "p_value": 5.832552174301655e-05, "reversed": false, "metapath_abbreviation": "GeAuGpMF", "metapath_name": "Gene–expresses–Anatomy–upregulates–Gene–participates–Molecular Function", "metapath_length": 3, "metapath_path_count_density": 0.8023020000000001, "metapath_path_count_mean": 88.1799, "metapath_path_count_max": 6417, "metapath_dwpc_raw_mean": 4.13213e-05, "metapath_n_similar": 47, "metapath_p_threshold": 0.0004926624476413501, "metapath_id": "GeAuGpMF", "metapath_reversed": false, "metapath_metaedges": [ [ "Gene", "Anatomy", "expresses", "both" ], [ "Anatomy", "Gene", "upregulates", "both" ], [ "Gene", "Molecular Function", "participates", "both" ] ], "dgp_id": 32368745, "dgp_source_degree": 52, "dgp_target_degree": 697, "dgp_n_dwpcs": 47800, "dgp_n_nonzero_dwpcs": 47800, "dgp_nonzero_mean": 3.0644234299333433, "dgp_nonzero_sd": 0.06326112272516549, "dgp_reversed": false, "cypher_query": "MATCH path = (n0:Gene)-[:EXPRESSES_AeG]-(n1)-[:UPREGULATES_AuG]-(n2)-[:PARTICIPATES_GpMF]-(n3:MolecularFunction)\nUSING JOIN ON n1\nWHERE n0.identifier = 161 // AP2A2\nAND n3.identifier = 'GO:0016491' // oxidoreductase activity\nAND n0 <> n2\nWITH\n[\nsize((n0)-[:EXPRESSES_AeG]-()),\nsize(()-[:EXPRESSES_AeG]-(n1)),\nsize((n1)-[:UPREGULATES_AuG]-()),\nsize(()-[:UPREGULATES_AuG]-(n2)),\nsize((n2)-[:PARTICIPATES_GpMF]-()),\nsize(()-[:PARTICIPATES_GpMF]-(n3))\n] AS degrees, path\nWITH path, reduce(pdp = 1.0, d in degrees| pdp * d ^ -0.5) AS PDP\nWITH collect({paths: path, PDPs: PDP}) AS data_maps, count(path) AS PC, sum(PDP) AS DWPC\nUNWIND data_maps AS data_map\nWITH data_map.paths AS path, data_map.PDPs AS PDP, PC, DWPC\nRETURN\n path AS neo4j_path,\n substring(reduce(s = '', node IN nodes(path)| s + '–' + node.name), 1) AS path,\n PDP,\n 100 * (PDP / DWPC) AS percent_of_DWPC\nORDER BY percent_of_DWPC DESC\nLIMIT 10" }, { "id": 15175718, "adjusted_p_value": 0.0027880663421125914, "path_count": 799, "dwpc": 3.1315647327286205, "p_value": 5.932056047048067e-05, "reversed": false, "metapath_abbreviation": "GuAuGpMF", "metapath_name": "Gene–upregulates–Anatomy–upregulates–Gene–participates–Molecular Function", "metapath_length": 3, "metapath_path_count_density": 0.688246, "metapath_path_count_mean": 27.8548, "metapath_path_count_max": 4276, "metapath_dwpc_raw_mean": 5.21958e-05, "metapath_n_similar": 47, "metapath_p_threshold": 0.0004926624476413501, "metapath_id": "GuAuGpMF", "metapath_reversed": false, "metapath_metaedges": [ [ "Gene", "Anatomy", "upregulates", "both" ], [ "Anatomy", "Gene", "upregulates", "both" ], [ "Gene", "Molecular Function", "participates", "both" ] ], "dgp_id": 36280697, "dgp_source_degree": 7, "dgp_target_degree": 697, "dgp_n_dwpcs": 295200, "dgp_n_nonzero_dwpcs": 295200, "dgp_nonzero_mean": 2.9727005120822594, "dgp_nonzero_sd": 0.040609719766678654, "dgp_reversed": false, "cypher_query": "MATCH path = (n0:Gene)-[:UPREGULATES_AuG]-(n1)-[:UPREGULATES_AuG]-(n2)-[:PARTICIPATES_GpMF]-(n3:MolecularFunction)\nUSING JOIN ON n1\nWHERE n0.identifier = 161 // AP2A2\nAND n3.identifier = 'GO:0016491' // oxidoreductase activity\nAND n0 <> n2\nWITH\n[\nsize((n0)-[:UPREGULATES_AuG]-()),\nsize(()-[:UPREGULATES_AuG]-(n1)),\nsize((n1)-[:UPREGULATES_AuG]-()),\nsize(()-[:UPREGULATES_AuG]-(n2)),\nsize((n2)-[:PARTICIPATES_GpMF]-()),\nsize(()-[:PARTICIPATES_GpMF]-(n3))\n] AS degrees, path\nWITH path, reduce(pdp = 1.0, d in degrees| pdp * d ^ -0.5) AS PDP\nWITH collect({paths: path, PDPs: PDP}) AS data_maps, count(path) AS PC, sum(PDP) AS DWPC\nUNWIND data_maps AS data_map\nWITH data_map.paths AS path, data_map.PDPs AS PDP, PC, DWPC\nRETURN\n path AS neo4j_path,\n substring(reduce(s = '', node IN nodes(path)| s + '–' + node.name), 1) AS path,\n PDP,\n 100 * (PDP / DWPC) AS percent_of_DWPC\nORDER BY percent_of_DWPC DESC\nLIMIT 10" }, { "id": 167712915, "adjusted_p_value": 0.006324683887626807, "path_count": 3120, "dwpc": 3.2595284057114724, "p_value": 0.00013456774228993206, "reversed": false, "metapath_abbreviation": "GuAeGpMF", "metapath_name": "Gene–upregulates–Anatomy–expresses–Gene–participates–Molecular Function", "metapath_length": 3, "metapath_path_count_density": 0.750252, "metapath_path_count_mean": 86.99, "metapath_path_count_max": 13373, "metapath_dwpc_raw_mean": 4.12408e-05, "metapath_n_similar": 47, "metapath_p_threshold": 0.0004926624476413501, "metapath_id": "GuAeGpMF", "metapath_reversed": false, "metapath_metaedges": [ [ "Gene", "Anatomy", "upregulates", "both" ], [ "Anatomy", "Gene", "expresses", "both" ], [ "Gene", "Molecular Function", "participates", "both" ] ], "dgp_id": 36237697, "dgp_source_degree": 7, "dgp_target_degree": 697, "dgp_n_dwpcs": 295200, "dgp_n_nonzero_dwpcs": 295200, "dgp_nonzero_mean": 3.0240346279801242, "dgp_nonzero_sd": 0.06315136512421929, "dgp_reversed": false, "cypher_query": "MATCH path = (n0:Gene)-[:UPREGULATES_AuG]-(n1)-[:EXPRESSES_AeG]-(n2)-[:PARTICIPATES_GpMF]-(n3:MolecularFunction)\nUSING JOIN ON n1\nWHERE n0.identifier = 161 // AP2A2\nAND n3.identifier = 'GO:0016491' // oxidoreductase activity\nAND n0 <> n2\nWITH\n[\nsize((n0)-[:UPREGULATES_AuG]-()),\nsize(()-[:UPREGULATES_AuG]-(n1)),\nsize((n1)-[:EXPRESSES_AeG]-()),\nsize(()-[:EXPRESSES_AeG]-(n2)),\nsize((n2)-[:PARTICIPATES_GpMF]-()),\nsize(()-[:PARTICIPATES_GpMF]-(n3))\n] AS degrees, path\nWITH path, reduce(pdp = 1.0, d in degrees| pdp * d ^ -0.5) AS PDP\nWITH collect({paths: path, PDPs: PDP}) AS data_maps, count(path) AS PC, sum(PDP) AS DWPC\nUNWIND data_maps AS data_map\nWITH data_map.paths AS path, data_map.PDPs AS PDP, PC, DWPC\nRETURN\n path AS neo4j_path,\n substring(reduce(s = '', node IN nodes(path)| s + '–' + node.name), 1) AS path,\n PDP,\n 100 * (PDP / DWPC) AS percent_of_DWPC\nORDER BY percent_of_DWPC DESC\nLIMIT 10" }, { "id": 50054173, "adjusted_p_value": 0.006391266250989206, "path_count": 1063, "dwpc": 3.280223901381645, "p_value": 0.00013598438831891927, "reversed": false, "metapath_abbreviation": "GdAuGpMF", "metapath_name": "Gene–downregulates–Anatomy–upregulates–Gene–participates–Molecular Function", "metapath_length": 3, "metapath_path_count_density": 0.6554369999999999, "metapath_path_count_mean": 29.0486, "metapath_path_count_max": 5575, "metapath_dwpc_raw_mean": 4.96269e-05, "metapath_n_similar": 47, "metapath_p_threshold": 0.0004926624476413501, "metapath_id": "GdAuGpMF", "metapath_reversed": false, "metapath_metaedges": [ [ "Gene", "Anatomy", "downregulates", "both" ], [ "Anatomy", "Gene", "upregulates", "both" ], [ "Gene", "Molecular Function", "participates", "both" ] ], "dgp_id": 31466205, "dgp_source_degree": 8, "dgp_target_degree": 697, "dgp_n_dwpcs": 196000, "dgp_n_nonzero_dwpcs": 196000, "dgp_nonzero_mean": 3.0505214180348936, "dgp_nonzero_sd": 0.061690100337144456, "dgp_reversed": false, "cypher_query": "MATCH path = (n0:Gene)-[:DOWNREGULATES_AdG]-(n1)-[:UPREGULATES_AuG]-(n2)-[:PARTICIPATES_GpMF]-(n3:MolecularFunction)\nUSING JOIN ON n1\nWHERE n0.identifier = 161 // AP2A2\nAND n3.identifier = 'GO:0016491' // oxidoreductase activity\nAND n0 <> n2\nWITH\n[\nsize((n0)-[:DOWNREGULATES_AdG]-()),\nsize(()-[:DOWNREGULATES_AdG]-(n1)),\nsize((n1)-[:UPREGULATES_AuG]-()),\nsize(()-[:UPREGULATES_AuG]-(n2)),\nsize((n2)-[:PARTICIPATES_GpMF]-()),\nsize(()-[:PARTICIPATES_GpMF]-(n3))\n] AS degrees, path\nWITH path, reduce(pdp = 1.0, d in degrees| pdp * d ^ -0.5) AS PDP\nWITH collect({paths: path, PDPs: PDP}) AS data_maps, count(path) AS PC, sum(PDP) AS DWPC\nUNWIND data_maps AS data_map\nWITH data_map.paths AS path, data_map.PDPs AS PDP, PC, DWPC\nRETURN\n path AS neo4j_path,\n substring(reduce(s = '', node IN nodes(path)| s + '–' + node.name), 1) AS path,\n PDP,\n 100 * (PDP / DWPC) AS percent_of_DWPC\nORDER BY percent_of_DWPC DESC\nLIMIT 10" } ], "n_metapaths": 7, "pathcount_table_random_id": 50054173, "pathcount_table_max_id": 169602979 }{ "source": { "id": 37515, "identifier": "161", "identifier_type": "int", "name": "AP2A2", "properties": { "url": "