@@ -464,10 +464,10 @@ Here's some example code that generates and plots a random graph, with node colo
|
464 | 464 | ```{code-cell} ipython |
465 | 465 | import networkx as nx |
466 | 466 | import matplotlib.pyplot as plt |
467 | | -np.random.seed(1234) |
| 467 | +rng = np.random.default_rng(1234) |
468 | 468 | |
469 | 469 | # Generate a random graph |
470 | | -p = dict((i, (np.random.uniform(0, 1), np.random.uniform(0, 1))) |
| 470 | +p = dict((i, (rng.uniform(0, 1), rng.uniform(0, 1))) |
471 | 471 | for i in range(200)) |
472 | 472 | g = nx.random_geometric_graph(200, 0.12, pos=p) |
473 | 473 | pos = nx.get_node_attributes(g, 'pos') |
|