I want to fit a linear model by R with
family=binomial(link="identity"), however, binomial family do not have identity link. What should I do?
See Wikipedia on the linear probability model, & CV posts here & here for the statistical background. Though not "wrong", you'd want a good reason for using an identity link to model a Bernoulli probability.
According to the
the binomial family [accepts] the links
cauchit, (corresponding to logistic, normal and Cauchy CDFs respectively)
The link and variance arguments have rather awkward semantics for back-compatibility. The recommended way is to supply them is as quoted character strings, but they can also be supplied unquoted (as names or expressions). In addition, they can also be supplied as a length-one character vector giving the name of one of the options, or as a list (for
link, of class
"link-glm"). The restrictions apply only to links given as names: when given as a character string all the links known to
family=binomial(link="identity") works but
family=binomial(link=identity) doesn't. (If you find differently it might be to do with the R version.) To allow for over-dispersion, then use
family=quasi(link="identity", variance = "mu(1-mu)").