matthewjdenny / GERGM

An R package to estimate Generalized Exponential Random Graph Models
38 stars 10 forks source link

where can I find p-value for coefficients? #5

Closed runnytone closed 6 years ago

runnytone commented 6 years ago

Thanks for your contribution. where can I find p-value for coefficients? Thank you.

runnytone commented 6 years ago

If there is no p-value for coefficients. How can I know the significance of coefficients?

matthewjdenny commented 6 years ago

Hi,

Thanks for checking out the package. The GERGM package does not calculate p-values for users. The standard approach is to use a z test (https://en.wikipedia.org/wiki/Z-test) to calculate a 95% confidence interval for the coefficients:

lower bound = coefficient - 1.96 coefficient standard error upper bound = coefficient + 1.96 coefficient standard error

Then if zero does not fall in this range, we would say that the coefficient is different from zero at the alpha = 0.05 level, or alternatively, that the p value was less than 0.05. There is a pretty nice explanation of this here:

https://en.wikipedia.org/wiki/P-value

In general, you should take a look at the Estimate_Plot() function to get a sense of the significance and sign of coefficient from the model.

Hope this helps!

runnytone commented 6 years ago

Thank you very much for your prompt reply. I can come back to my work now. I hope stargazer can adapt to GERGM in the future so that users can export results of GERGM into latex easily. Besides, Is there any comparison between Krivitsky(2012)‘s ergm.count and GERGM? Thanks for your contribution, which makes a lot of ideas possible.

matthewjdenny commented 6 years ago

Krivitsky's model would be considered a special case of the GERGM, where the edges can only take on positive integer values. A stargazer addition would be nice, but we tend to favor a graphical representation of the parameter estimates in our own work. Thanks for checking out the package and feel free to get in touch with future issues.