how can you highlight a proportion of selected nodes

10 views
Skip to first unread message

s.w...@uws.edu.au

unread,
Jun 9, 2009, 11:44:14 PM6/9/09
to cytoscape-helpdesk
Dear There,

I have imported a network file (.sif) from SGD and opened up this
network file in Cytoscape. In the graph, all the nodes have same
colour. But I need to hightlight only some of the nodes. However, it
will be tedious to find each individual nodes from the graph and to
mannually change the colour of selected nodes. By the way I have over
several hundreds nodes and interactions. I wonder if I can change the
network file and then re-open in the Cytoscape? How to do so?

Thank you for your help and I am looking forward to hearing from you
Experts!

Cindy

Maital Ashkenazi

unread,
Jun 10, 2009, 2:16:18 AM6/10/09
to cytoscape...@googlegroups.com
Hi Cindy,

On Wed, Jun 10, 2009 at 6:44 AM, <s.w...@uws.edu.au> wrote:

Dear There,

I have imported a network file (.sif) from SGD and opened up this
network file in Cytoscape. In the graph, all the nodes have same
colour. But I need to hightlight only some of the nodes. However, it
will be tedious to find each individual nodes from the graph and to
mannually change the colour of selected nodes.

On the left hand side you will notice the VizMapper tab. The VizMapper is used to assign visual style to a set of nodes or edges. Here are the steps:
1) Create a new node attribute (e.g. "highlight")
2) Set a value in this attribute for every node you wish to highlight.
3) In VizMapper, associate Node Color with the new attribute, and choose Discrete Mapping as Mapper type.
4) Assign color according to attribute values.

Read more here:
http://www.cytoscape.org/manual/Cytoscape2_6Manual.html#Visual%20Styles

Hope this helps,
Maital

 

Joao Castro

unread,
Jun 10, 2009, 2:32:19 AM6/10/09
to cytoscape...@googlegroups.com
Hi,
I'm no expert and have only been using cytoscape for about a month...
Have you tried using a node attribute file? There you can tag the
different nodes with the properties or groups you want to show and
then use the filters to see them in the graph.

Cheers,
Joao

Marcelo Brandao

unread,
Jun 10, 2009, 1:43:57 PM6/10/09
to cytoscape...@googlegroups.com
Hi Cindy,
I think you may need to manually edit your sif file. Well, you will not
scape from find each interaction. Another way, do you have all the
interaction that you want to hightlight? You may use an simple perl
script to search your list of interactions and build a new sif file
indicating all desireble interactions.
Yeah, I know this solution is quite laborious, sorry :(
Cheers and good lucky!


Marcelo
>
> On Tue, Jun 9, 2009 at 23:44, <s.w...@uws.edu.au> wrote:
>
>> Dear There,
>>
>> I have imported a network file (.sif) from SGD and opened up this
>> network file in Cytoscape. In the graph, all the nodes have same
>> colour. But I need to hightlight only some of the nodes. However, it
>> will be tedious to find each individual nodes from the graph and to
>> mannually change the colour of selected nodes. By the way I have over
>> several hundreds nodes and interactions. I wonder if I can change the
>> network file and then re-open in the Cytoscape? How to do so?
>>
>> Thank you for your help and I am looking forward to hearing from you
>> Experts!
>>
>> Cindy
>>
>>
>
> >
>


--
Marcelo Mendes Brandão
Postdoc fellow
Laboratório de Biologia Molecular de Plantas - ESALQ/USP
Website: http://bioinfo.esalq.usp.br
AtPIN: http://bioinfo.esalq.usp.br/atpin
SKYPE: mmbrand
Tel: (+55) 19 3429 4442

Shaoyu Wang

unread,
Jun 10, 2009, 7:45:45 PM6/10/09
to cytoscape...@googlegroups.com
Hi, Marcelo,
Thank you very much and I don't know how to open and edit sif file either. Any help.
Cindy

Shaoyu Wang

unread,
Jun 10, 2009, 7:47:43 PM6/10/09
to cytoscape...@googlegroups.com
Hi, Joao,
Thank you very much for the help. Where can I find the node attribute file? Can we tag a group of nodes easily?
Cheers
Cindy

-----Original Message-----
From: cytoscape...@googlegroups.com [mailto:cytoscape...@googlegroups.com] On Behalf Of Joao Castro
Sent: Wednesday, June 10, 2009 4:32 PM
To: cytoscape...@googlegroups.com
Subject: [cytoscape-helpdesk] Re: how can you highlight a proportion of selected nodes


Shaoyu Wang

unread,
Jun 10, 2009, 7:49:12 PM6/10/09
to cytoscape...@googlegroups.com
Hi, Maital,
Thank you for this and I will give it a try!
Cheers
Cindy


From: cytoscape...@googlegroups.com [mailto:cytoscape...@googlegroups.com] On Behalf Of Maital Ashkenazi
Sent: Wednesday, June 10, 2009 4:16 PM

To: cytoscape...@googlegroups.com
Subject: [cytoscape-helpdesk] Re: how can you highlight a proportion of selected nodes

Joao Castro

unread,
Jun 10, 2009, 8:19:16 PM6/10/09
to cytoscape...@googlegroups.com
I don't know if there's a better way but I believe you have to tag
them one by one in the node attribute file, but as long as you have a
list of the nodes you want to tag that is pretty easy.

The file looks like this:

NameOfAttribute
Node1Name = value1
Node2Name = value2
Node3Name = value1
...

You can find more information here:
http://www.cytoscape.org/manual/Cytoscape2_6Manual.html#Node%20and%20Edge%20Attributes


Joao

Shaoyu Wang

unread,
Jun 10, 2009, 8:29:27 PM6/10/09
to cytoscape...@googlegroups.com
Thank you for this.

Marcelo Brandão

unread,
Jun 11, 2009, 9:14:59 AM6/11/09
to cytoscape...@googlegroups.com
Hi Cindy,
You can edit it as a regular text, you may use notepad or komodo edit,
for your task. Someone has posted this link
http://www.cytoscape.org/manual/Cytoscape2_6Manual.html#Node%20and%20Edge%20Attributes
it is very usefull, you should give a try.

Cheers

Marcelo

Shaoyu Wang escreveu:
Reply all
Reply to author
Forward
0 new messages