Color Nodes In Cytoscape Using An Attribute File?
1
2
Entering edit mode
10.6 years ago
trelek2 ▴ 20

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?

cytoscape • 8.4k views
ADD COMMENT
1
Entering edit mode
10.5 years ago

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"

ADD COMMENT

Login before adding your answer.

Traffic: 2787 users visited in the last hour
Help About
FAQ
Access RSS
API
Stats

Use of this site constitutes acceptance of our User Agreement and Privacy Policy.

Powered by the version 2.3.6