# Solving Estimating Equations using R packages

#### arun

##### New Member
Hello, I am trying to estimate e intraclass correlation parameter of of binary data using extended quasi-likelihood estimation methods.
The below are the estimating equations for the mean and dispersion parameters based on beta-binomial distribution. Which, I captured from An empirical investigation of different operating characteristics of several estimators of the intraclass correlation in the analysis of binary data

I need to know, how can I solve two estimating equations with two unknown parameters in R?
(Note: This is not a GLM model)

I tried it with randomly generated beta-binomial variates using rootSolve R package, but didn't work...

#### GretaGarbo

##### Human
I am not sure what you want to estimate with that model.

Maybe a later model by Nelder might interest you. The book by Lee Nelder and Pawitan about hierarchical generalized linear models. (And many publihed papers) There is a R package “hglm” by Rönnegård.

I have the impression that Nelder in later years did not like gee (generalized estimating equations) that much (According to “Statistical Science” in about 2009)

#### arun

##### New Member
Thank you GreatGarbo.. I will check out hglm.. than you for your suggestion.. But I am not trying to fit a glm, rather
I am simulating beta binomial sample variates as below
Code:
library(VGAM)
set.seed(100)
sample=rbetabinom(n=10, prob=0.4, rho=0.5,size=5)
n=5 #trials
N=10 #sample.size
z=sample/n #Proportions os success
Now I need to estimate the parameters prob and rho using extended quasi-likelihood method given above...

Can I uses the R package "rootSolve" to solve estimating equations?