mirror of
https://github.com/fhswf/aki_prj23_transparenzregister.git
synced 2025-06-21 19:13:54 +02:00
Removed the edge color extra definition (#532)
This commit is contained in:
@ -109,15 +109,6 @@ def create_2d_graph( # noqa PLR0913
|
|||||||
# ids = list(nx.get_node_attributes(graph, "id").values())
|
# ids = list(nx.get_node_attributes(graph, "id").values())
|
||||||
|
|
||||||
# # Get the Node Text
|
# # Get the Node Text
|
||||||
# node_names = []
|
|
||||||
# for key, value in nodes.items():
|
|
||||||
# if "name" in value:
|
|
||||||
# node_names.append(value["name"])
|
|
||||||
# else:
|
|
||||||
# node_names.append(value["firstname"] + " " + value["lastname"])
|
|
||||||
# # Add Color and Names to the Scatter Plot.
|
|
||||||
# print(colors)
|
|
||||||
# print(node_names)
|
|
||||||
node_trace.marker.color = colors
|
node_trace.marker.color = colors
|
||||||
node_trace.marker.line = {"color": "#2e2c2f", "width": 0.5}
|
node_trace.marker.line = {"color": "#2e2c2f", "width": 0.5}
|
||||||
node_trace.text = node_names
|
node_trace.text = node_names
|
||||||
|
@ -177,13 +177,7 @@ def create_3d_graph( # noqa : PLR0913
|
|||||||
node_trace.marker.size = list(np.cbrt(metrics[metric]) * 200)
|
node_trace.marker.size = list(np.cbrt(metrics[metric]) * 200)
|
||||||
|
|
||||||
# Set the Color and width of Edges for better highlighting.
|
# Set the Color and width of Edges for better highlighting.
|
||||||
edge_colors = []
|
edge_trace.line = {"color": "rgb(255,105,180)", "width": edge_thickness}
|
||||||
for row in edges:
|
|
||||||
if row["type"] == "HAFTENDER_GESELLSCHAFTER":
|
|
||||||
edge_colors.append("rgb(255,0,0)")
|
|
||||||
else:
|
|
||||||
edge_colors.append("rgb(255,105,180)")
|
|
||||||
edge_trace.line = {"color": edge_colors, "width": edge_thickness}
|
|
||||||
|
|
||||||
# Add Relation_Type as a Description for the edges.
|
# Add Relation_Type as a Description for the edges.
|
||||||
if edge_annotation:
|
if edge_annotation:
|
||||||
|
Reference in New Issue
Block a user