cytoscape.js - Change default size of nodes -


i'm starting use awesome library , want simple thing: change size of nodes.

when nodes server, have size attribute, integer between 1 , 6. display size of node in consequence.

i've tried weight attribute:

for (var = 0; < self.galaxy.nodes.length; i++) {         cy.add({             group: 'nodes',             data: { id: self.galaxy.nodes[i].id.tostring(), weight: self.galaxy.nodes[i].size },             position: { x: self.galaxy.nodes[i].x , y: self.galaxy.nodes[i].y}         });     } 

but unfortunately, size remains constant, , can't find direction in doc. have clue me?

you can set width , height of nodes in stylesheet, using mapper on weight.


Comments

Popular posts from this blog

java - Could not locate OpenAL library -

c++ - Delete matches in OpenCV (Keypoints and descriptors) -

sorting - opencl Bitonic sort with 64 bits keys -