Skip to content

Commit

Permalink
src/sage/graphs/generic_graph.py: Add another numpy.set_printoptions
Browse files Browse the repository at this point in the history
  • Loading branch information
Matthias Koeppe committed Aug 10, 2024
1 parent 79aa761 commit b7ab659
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion src/sage/graphs/generic_graph.py
Original file line number Diff line number Diff line change
Expand Up @@ -15993,7 +15993,11 @@ def clustering_coeff(self,
{0: 1/3, 1: 1/3, 2: 0, 3: 1/3, 4: 1/3, 5: 1/3,
6: 1/3, 7: 1/3, 8: 0, 9: 1/3, 10: 1/3, 11: 0}

sage: (graphs.FruchtGraph()).clustering_coeff(weight=True) # needs networkx
sage: # needs networkx
sage: import numpy
sage: if int(numpy.version.short_version[0]) > 1:
....: numpy.set_printoptions(legacy="1.25")
sage: (graphs.FruchtGraph()).clustering_coeff(weight=True)
{0: 0.3333333333333333, 1: 0.3333333333333333, 2: 0,
3: 0.3333333333333333, 4: 0.3333333333333333,
5: 0.3333333333333333, 6: 0.3333333333333333,
Expand Down

0 comments on commit b7ab659

Please sign in to comment.