snap-python icon indicating copy to clipboard operation
snap-python copied to clipboard

GetPageRank() got an unexpected keyword argument 'C'

Open habedi opened this issue 10 years ago • 2 comments

In the documentations it's mentioned that GetPageRank accepts 3 keyword arguments, C, Eps and MaxIter but when i call it in my code like this for instance

...
g = snap.GenRndGnm(snap.PNGraph, 100, 1000)
PRankH = snap.TIntFltH()
snap.GetPageRank(g, PRankH, C=0.8, Eps=10e-8, MaxItr=100)

I get an error as: Traceback (most recent call last): File "", line 1, in TypeError: GetPageRank() got an unexpected keyword argument 'C'

a bug in the documentations maybe. regards.

habedi avatar Jul 03 '15 13:07 habedi

Hi,

Thanks for the note. We added this issue to our todo list. A workaround is to omit parameter names: snap.GetPageRank(g, PRankH, 0.8, 10e-8, 100)

Cheers, Rok

On 07/03/2015 06:30 AM, hassan abedi wrote:

In the documentations it's mentioned that GetPageRank accepts 3 keyword arguments, C, Eps and MaxIter but when i call it in my code like this for instance

... g= snap.GenRndGnm(snap.PNGraph,100,1000) PRankH= snap.TIntFltH() snap.GetPageRank(g, PRankH,C=0.8,Eps=10e-8,MaxItr=100)

I get an error as: Traceback (most recent call last): File "", line 1, in TypeError: GetPageRank() got an unexpected keyword argument 'C'

— Reply to this email directly or view it on GitHub https://github.com/snap-stanford/snap-python/issues/48.

roks avatar Jul 06 '15 19:07 roks

Thanks for the suggestion.

habedi avatar Jul 08 '15 17:07 habedi