[R] Retrieving response variable in the probit

Steven Yen syen04 at gmail.com
Mon May 2 00:01:26 CEST 2016


Can anyone tell me how to retrieve the response (dependent) variable
from a probit regression object (as much as model.matrix(obj)
retrieves the data matrix). Below is a self-runnable set of codes.
Thank you!

library(sampleSelection)
data<-read.csv("https://dl.dropboxusercontent.com/u/220037024/Yen/data/pta.csv")
eq1<-d~sex+age+educ
p1<-probit(eq1,data=data)
summary(p1)
attributes(p1)



More information about the R-help mailing list