Skip to content

Edge Weight first pass for VFOI #245

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
6 tasks done
jdanish opened this issue May 22, 2023 · 9 comments
Closed
6 tasks done

Edge Weight first pass for VFOI #245

jdanish opened this issue May 22, 2023 · 9 comments
Assignees
Milestone

Comments

@jdanish
Copy link
Collaborator

jdanish commented May 22, 2023

Add the option to include edge weight into the net.create interface.

  • Add a weight attribute which is a number above 0 to the edge editing interface.
  • For backwards compatibility, assume a weight of 1 if nothing was there, and add it.
  • Have a template settable maximum size for how edges are displayed so anything above that number is displayed as that number. Long-term we might also want this to be based on node size.
  • long-term, Kalani would like to be able to turn the max on / off if possible. Not needed short-term.
  • Add to filters.
  • Add to table view.
@jdanish jdanish added this to the Spring 2024 milestone May 22, 2023
@jdanish jdanish changed the title Edge Weight Edge Weight first pass for VFOI May 22, 2023
@benloh benloh assigned daveseah and unassigned benloh May 26, 2023
@daveseah
Copy link
Collaborator

Did we make a reference anywhere for what the needed files to touch were?

@benloh
Copy link
Collaborator

benloh commented May 27, 2023

See #252 for a reference that covers all the steps.

@daveseah
Copy link
Collaborator

daveseah commented Jun 1, 2023

Have a template settable maximum size for how edges are displayed so anything above that number is displayed as that number. Long-term we might also want this to be based on node size.

I'm assuming that this means the maximum width of the line in a unit like pixels.

@jdanish
Copy link
Collaborator Author

jdanish commented Jun 1, 2023

Yes, the actual number in the edge table should not change, but the display should have a maximum width so that we don't blow out the rest of the graph.

@daveseah
Copy link
Collaborator

daveseah commented Jun 1, 2023

Yes, the actual number in the edge table should not change, but the display should have a maximum width so that we don't blow out the rest of the graph.

I am still a bit confused by this phrasing. Does "actual number in the edge table" refer to the the count of edges? or is this a link to the weight attribute being added?

  • If it's count, that implies to me that we limit how many edges can be shown somehow.
  • If it's weight, then that ties the "weight" concept to a visual representation "line width".
  • If it's not either, then I am missing what this means

@jdanish
Copy link
Collaborator Author

jdanish commented Jun 1, 2023

My understanding (@kalanicraig please verify):

Each edge has a weight. Right now, all edges are defaulting to 1.
The width of the line between two nodes is the sum of edge weights. So 2 edges of weight 1 is a total of 2, but 2 edges of weight 2 is a total of 4.

So if we have:

A -> B weight 2
B -> A weight 2
A -> B weight 1

All three would be listed in the edge table. However, when drawing the line between A and B, the system would note that there is a total weight of 5. If the max is 5, it'll draw it that way. If the max is 4, it'll draw a width 4 line, but if you look at the tables or filters the weights will be as listed above.

Incidentally, the display would be a bi-directional arrow in this case A <-> B.

That help? Sorry to be unclear.

@daveseah
Copy link
Collaborator

daveseah commented Jun 1, 2023

That helps a lot! Thanks! I didn't realize that bidirectional edges were modeled in this way, so that was my missing bit of knowledge to make sense of it.

@jdanish
Copy link
Collaborator Author

jdanish commented Jun 1, 2023

Well, we are breaking some norms but I am AOK with that as it gives us flexibility. People can enforce norms on their own if they want. :).

@daveseah daveseah assigned benloh and unassigned daveseah Jun 9, 2023
@daveseah
Copy link
Collaborator

daveseah commented Jun 9, 2023

Ben helped me add the weight support for UI, data writing, edge table.
Passing this issue to Ben to add the viewgraph data transformation a D3 displayObject list (it has to combine individual edges in the source data to single edges)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants