Node border width control in Netgraph

36 Views Asked by At

I want to modify the width of the node border in Netgraph (Python) in order to increase or decrease it. I unfortunately do not find the parameter controlling the width of the border node. Here is as follows a picture of what I want to do.

enter image description here

Is there a way to modify the border of the nodes ? Thank you.

1

There are 1 best solutions below

1
Meher Khurana On

use the node_border parameter in the netgraph.draw() function.

import networkx as nx
import matplotlib.pyplot as plt
import netgraph

# Create a sample graph
G = nx.Graph()
G.add_edges_from([(1, 2), (2, 3), (3, 4)])

# Draw the graph with modified node border width
netgraph.draw(G, node_border=2)

plt.show()