-
Notifications
You must be signed in to change notification settings - Fork 73
Open
Description
So I have been looking for Graph APIs and the networkx for python is very rich and powerful. It has a lot of things but I just want to start with the ones that are simpler/useful.
In the link I provided a lot of them are already implemented so I thought that would be nice to have the following:
degree :: Graph a -> a -> Int- Returns the degree of a certain vertexdegreehistogram :: Graph a -> [(a, Float)]- Returns de list of the frequency of each degree value.density :: Graph a -> Float- Returns the density of the graphreverse :: Graph a -> Graph a- Returns the graph with the edges revertedselfLoops :: Graph a -> Int- Returns the number of selfLoops in the graph
I want to discuss some of the types of these functions, if it makes sense to add these kind of functions and how to integrate this in alga. I also am thinking of doing isConnected :: Graph -> Bool and implement graph generation functions like Erdos Renyi/Barabasi-Albert.
should these functions be integrated in Graph API ?