[R] outer() or some other function for regression prediction with 2 IVs

Joseph Clark joeclark77 at hotmail.com
Tue Jul 10 05:35:41 CEST 2012


Thanks. I was able to get what I wanted by doing this:

 

predxn <- function(s,d) { coef(m3)[1] + coef(m3)[2]*s + coef(m3)[3]*s^2 + coef(m3)[4]*d + coef(m3)[5]*d^2 }


But it's not very elegant...

 

 

 

// joseph w. clark , phd candidate
\\ usc marshall school of business 		 	   		  


More information about the R-help mailing list