# first, delete existing windows to save memory:
deleteAllWindows(CytoscapeConnection())
window.name <- 'demo.getAllNodeAttributes'
cw <- CytoscapeWindow (window.name, graph=makeSimpleGraph ())
displayGraph (cw)
redraw (cw)
layoutNetwork (cw, 'force-directed')
# get all attributes for all nodes
tbl.noa <- getAllNodeAttributes (cw, onlySelectedNodes=FALSE)
tbl.noa
# type lfc label count
# A kinase -3 Gene A 2
# B transcription factor 0 Gene B 30
# C glycoprotein 3 Gene C 100
selectNodes (cw, 'A')
getAllNodeAttributes (cw, TRUE)
# type lfc label count
# A kinase -3 Gene A 2
Run the code above in your browser using DataLab