Hi,
I'm having trouble working out how to color nodes in cytoscape. I have a fairly large network and I know the color I want to assign to each node. I don't understand how to do it though and can't find any examples online. I've seen in the menu that I could import a vizmap file - would that help me? how is the file supposed to look?
I wish I could just have a 4th column in my network file which would allow specifying the node color like "red", "green" etc.
Can anyone help me do this?
1 answer
Hi trelek2
This is from the manual:
Text Passthrough Mapper (New feature for version 2.8) In Cytoscape 2.8.0 and later versions, the Passthrough Mapper can recognize some text representations of values. This means, if you have an integer attribute named Node Size Values, you can directly map those values as the Node Size by setting Node Size Values as controlling attribute name for Node Size Passthrough mapping. The following value types are supported: • Color: Standard color names supported by all browsersor RGB representation in hex
so, you just need to specify your color in the respective column of your input table, and map this column to the node fill color attribute with mapping type "Passthrough Mapping"
Log in to answer this question.