Hi,

I am new in R. I would like to do a ordered probit regression using clm2 (in the ordinal package).
My dependent variable y is the way of payment in M&A: y=0 if the deal is financed by stock only, y=1 if the deal is financed by a mix of cash and stock and y=2 if it is by cash only.
My independent variables are CollateralB, Cashavailable and Leverage.

This is the code I wrote:

> library(ordinal)
> datareg<-read.xls("C:/regression.xls")
> myprobit<-clm2(Newpercentagecash ~ CollateralB + CashavailableB + LEVERAGEB, data = datareg, link = "probit")
Error in clm2(Newpercentagecash ~ CollateralB + CashavailableB + LEVERAGEB,  :
  response needs to be a factor

I do not understand this error message. My "y" only equals 0, 1 or 2. I do not understand what a "factor" is.
Could you help me please?

Thank you in advance,

Best regards,

Alice


	[[alternative HTML version deleted]]

