xgi icon indicating copy to clipboard operation
xgi copied to clipboard

Degree assortativity functions don't handle empty hypergraphs

Open nwlandry opened this issue 2 years ago • 1 comments

Returns IndexError.

nwlandry avatar Aug 24 '22 20:08 nwlandry

Now that I think of it, probably nothing handles empty hypergraphs...

leotrs avatar Aug 29 '22 07:08 leotrs

By empty do you mean (1) no nodes and no edges, or (2) just no edges? Do we want to return None for (1) but 0 for (2)?

maximelucas avatar Mar 27 '23 14:03 maximelucas

Agreed. No edges should have a numerical answer, perhaps even 0, inf, or NaN.

No nodes at all should return None, or raise an error.

leotrs avatar Mar 27 '23 14:03 leotrs