Implementation of the Albert and Barabasi preferential attachment algorithm as described in ‘Topology of Evolving Networks: Local Events and Universality’, Physical Review Letters Vol 85, Number 24, 1999.
Parameters :  N : int
m :int :
m0 : int, optional
p :float, optional :
q : float, optional


Returns :  G : networkx.Graph

Notes
If p = q = 0 then the algorithm will default to the algorithm described in ‘Emergence of Scaling in Random Networks’ by Barabasi and Albert, Science Vol 286, October 1999.