GraphNetwork
metExploreViz.GraphNetwork provides functions dedicated to manage your network visualization.
Some functions are dedicated to nodes duplication and to manage side compounds.
#
metExploreViz.GraphNetwork.duplicateANode(nodeObject, vizPanel) This function allows you to duplicate node.
var node = metExploreViz.getNodeByName("acetyl-CoA");
metExploreViz.GraphNetwork.duplicateANode(node, "viz");#
metExploreViz.GraphNetwork.duplicateSideCompounds(vizPanel, callback) This function allows you to duplicate all side compounds in your network. Callback function is optional.
metExploreViz.GraphNetwork.duplicateSideCompounds("viz", func);#
metExploreViz.GraphNetwork.duplicateSideCompoundsById(arrayId, vizPanel) This function allows you to duplicate specific side compounds.
metExploreViz.GraphNetwork.duplicateSideCompoundsById(["M199208", "M198152"], "viz");#
metExploreViz.GraphNetwork.removeSideCompounds() This function allows you to remove all side compounds in your network.
metExploreViz.GraphNetwork.removeSideCompounds(); Some functions are dedicated to manage global network options.
#
metExploreViz.GraphNetwork.play() This functions allows you to play or stop animations depebdubg on network state.
metExploreViz.GraphNetwork.play();#
metExploreViz.GraphNetwork.rescale(vizPanel, callback) This function allows you to rescale network to fit with visulization div.
metExploreViz.GraphNetwork.rescale();#
metExploreViz.GraphNetwork.updateNetwork(vizPanel, vizObject) This function allows you to update network status. For example, after side compounds duplication, you need to update your network to see modifications.
var session = metExploreViz.getSessionById("viz");
metExploreViz.GraphNetwork.updateNetwork("viz", session);