X <- c(0,-0.3,-0.6,-0.9) # Various water potentials
y <- c(44,10,10,4) # Number of germinated seeds
n <- c(100,100,100,100) # Total number of viable seeds
n_y <- n-y
sg.mat <- cbind(y,n_y)
res.glm1 <- glm(sg.mat~ X,family=binomial(link=logit)) # Using logit transformation
my.bdl<- BaseWPDist(res.glm1)
res.glm2 <- glm(sg.mat~ X,family=binomial(link=probit)) # Using probit transformation
my.bdp<- BaseWPDist(res.glm2)
res.glm3 <- glm(sg.mat~ X,family=binomial(link=cloglog))# Using cloglog transformation
my.bdcl<- BaseWPDist(res.glm3)
Run the code above in your browser using DataLab