Cytoscape RPC node layout problems

91 views
Skip to first unread message

Rossella Rispoli

unread,
Oct 29, 2012, 3:40:16 PM10/29/12
to cytoscap...@googlegroups.com
Hi to everyone,
I'm bit new to CytoscapeRPC, and I'm trying to create netowrk graph from perl script.
I got some problems to modify the layout to put distane betwen the nodes, to avoid the labels overlaps.

I tried to do this in two different way:

1) I tried to change the label  font size, as follows:

my $done = $client->call(
        "Cytoscape.discreteMapper",     # function name
        $coder->string($networkID),   # identifier of the network
        "default",                                # name of the vizmap to use
        "ID",                                      # name of the attribute to use
        "Node Font Size",                # name of the vis. param. to change
        '5',                                      # default value
       {'p'=> '15'}                                # hash of nodeid - shape
); 

But I got the follows ERROR:

Fault returned from XML RPC Server, fault code 0: No method matching arguments: java.lang.String, java.lang.String, java.lang.String, java.lang.String, java.lang.Integer, java.util.HashMap

2) I noticed that when I changed, from the grafical interface the scale from the layout menu (from 1.0 to 2.0), I obteined a good distances betwen the nodes without overlaps.
   When I tried to use the function Cytoscape.exportView to save my graph with a different scale parameter, as follows:

my $done=$client->call(
    "Cytoscape.exportView",
    $imaje_path, # filename
    "jpg", # file type
    $coder->double('2.5') # scaling factor
);

I didn't recive any changes.

Do you have any suggestions or corrections?

Thanks in advances,

Rossella

Jan Bot

unread,
Oct 31, 2012, 5:40:11 AM10/31/12
to cytoscap...@googlegroups.com
Hi,

The discreteMapper call has been deprecated, use createDiscreteMapper instead. The docs for this function call can be found in the javadoc.

As for the scale parameter: I think it only influences the resolution of the final image.

Cheers,

Jan



--
You received this message because you are subscribed to the Google Groups "cytoscape-discuss" group.
To view this discussion on the web visit https://groups.google.com/d/msg/cytoscape-discuss/-/lHwSi4NoYXsJ.
To post to this group, send email to cytoscap...@googlegroups.com.
To unsubscribe from this group, send email to cytoscape-disc...@googlegroups.com.
For more options, visit this group at http://groups.google.com/group/cytoscape-discuss?hl=en.

Rossella Rispoli

unread,
Nov 7, 2012, 1:28:22 PM11/7/12
to cytoscap...@googlegroups.com
Hi Jan,
thanks for your replay.

I tried to use the createDiscreteMapper function, but I see that the problem is the"Frontier::RPC2->float()" function.
In fact the "Node Font Size" vis. param. to change take in input a folat value.

But when I try to do:

my $es_float= $coder->float(3,14159); (where $coder coming from the follows instruction: my $coder = Frontier::RPC2->new;)

I got this error:

Can't locate object method "float" via package "Frontier::RPC2" !

Do you have any suggestions?

Thanks in advances,
Rossella

Jan Bot

unread,
Nov 14, 2012, 3:21:02 AM11/14/12
to cytoscap...@googlegroups.com
Hi Rossella,

This seems to be a Perl issue. You seem to be using a comma in your float, are you sure that is permitted?

Cheers,

Jan

To view this discussion on the web visit https://groups.google.com/d/msg/cytoscape-discuss/-/EbVmS7TGh30J.
Reply all
Reply to author
Forward
0 new messages