Business
Jobs
  • About Us
  • Solutions
    • Job Postings
      Post your job and receive qualified candidates in 48h.
    • Candidate Assessments
      500+ technical and psychological tests, plus anti-fraud.
    • Headhunting
      Tailor-made executive search from start to finish.
    • Payroll + EOR
      Payroll dispersal and EOR across 15+ LATAM countries.
  • Pricing
  • Jobs

0

118
Views
selection of node in a graph

I am developing force directed graph in JavaScript and WebGL. My concern is draggable feature like one in d3.js.

For that I want to first achieve the selection of node in the graph which I am not able to figure out how to select it.

My node and edge data are array of property of each node which is position x and y whereas edge array is array of target and destination node.

I want to implement the feature where I can drag the node in the graph with mouse pointer.

One naïve way of thinking is to listen to mouse click event and its mouse location. With that location, iterate over all the nodes location to find if any node is selected. I am pretty sure that would take lot of computation power and time. I don't know if there is any way to achieve this smartly even in this way of implementation.

I don't know if I am correct or not but since d3 use the circle element to represent the node and listen the mouse event in that event handling. Please correct me if I am wrong.

I will be grateful for any kind of feedback or suggestion or guidance. Thank you in advance.

about 4 years ago · Juan Pablo Isaza
Answer question
Find remote jobs

Discover the new way to find a job!

Top jobs
Top job categories
Business
Post vacancy Pricing Sales
Legal
Terms and conditions Privacy policy
© 2026 PeakU Inc. All Rights Reserved.
Andres GPT
Show me some job opportunities
There's an error!