tmuetze / Bioconductor_RCy3_the_new_RCytoscape

Update RCytoscape to work for Cytoscape 3.0 and higher using CyREST
16 stars 10 forks source link

Issue selecting nodes with selectNodes() #29

Open risserlin opened 8 years ago

risserlin commented 8 years ago

I ran the below code and I am not sure what I am doing wrong. I am just trying to select two nodes but the selectNode function just returns all the node names (twice) and doesn't select the nodes specified. (I attached the session file that I used.)

library("RCy3")

get connection to cytoscape window

cy <- CytoscapeConnection ()

get all the names of the cytoscape windows

em_name <- getWindowList(cy) em_name 'test_network'

cw <- existing.CytoscapeWindow(title = "test_network" ,copy.graph.from.cytoscape.to.R = FALSE) em_graph <- getGraphFromCyWindow(cy, "test_network") em_graph A graphNEL graph with directed edges Number of Nodes = 5 Number of Edges = 5

selectNodes(cw, c('RESPONSE TO CYTOKINE%GOBP%GO:0034097','CYTOKINE-MEDIATED SIGNALING PATHWAY%GOBP%GO:0019221')) [1] "RESPONSE TO CYTOKINE%GOBP%GO:0034097"
[2] "RESPONSE TO INTERFERON-GAMMA%GOBP%GO:0034341"
[3] "INTERFERON SIGNALING%REACTOME DATABASE ID RELEASE 56%913531"
[4] "CYTOKINE-MEDIATED SIGNALING PATHWAY%GOBP%GO:0019221"
[5] "INTERFERON GAMMA SIGNALING%REACTOME DATABASE ID RELEASE 56%877300" [1] "RESPONSE TO CYTOKINE%GOBP%GO:0034097"
[2] "RESPONSE TO INTERFERON-GAMMA%GOBP%GO:0034341"
[3] "INTERFERON SIGNALING%REACTOME DATABASE ID RELEASE 56%913531"
[4] "CYTOKINE-MEDIATED SIGNALING PATHWAY%GOBP%GO:0019221"
[5] "INTERFERON GAMMA SIGNALING%REACTOME DATABASE ID RELEASE 56%877300"

risserlin commented 8 years ago

forgot to add the session file. Here is a link to the session: https://www.dropbox.com/s/th66qtbcljhkt3f/test_nodeselection.cys?dl=0

AlexanderPico commented 6 years ago

Confirmed to work in latest RCy3: https://github.com/cytoscape/RCy3/issues/7