sébastien saegesser
2011-Apr-14 14:38 UTC
[R] how to code a restriction matrix with the following restrictions
Dear list members, I need to fit a regression with two inequality constraints. I look up in the literature and R archive and found some ways to do it, for example using the ic.infer package. However I do not know how to write in R my constraints. In the package help, it is told that I have to create the restriction matrix ui. Can someone help me to code the matrix? In short I run the regression:Return=alpha + beta*benchmark(i) + u My goal is to find the constrained alpha with the following two restrictions: alpha + (beta -1)Rfmin* <=0 alpha + (beta -1)Rfmax* <=0 *To facilitate the code I will find the value of Rfmin and Rfmax separately so I will have a vector (Rfmin, Rfmax)' directly available. Anyone know how I can code the matrix ui representing the above restrictions, so I can fit the constrained regression? Thanks for your help, seb [[alternative HTML version deleted]]
sébastien saegesser
2011-Apr-14 19:47 UTC
[R] how to code a restriction matrix with the following restrictions
Dear list members, I need to fit a regression with two inequality constraints. I look up in the literature and R archive and found some ways to do it, for example using the ic.infer package. However I do not know how to write in R my constraints. In the package help, it is told that I have to create the restriction matrix ui. Can someone help me to code the matrix? In short I run the regression:Return=alpha + beta*benchmark(i) + u My goal is to find the constrained alpha with the following two restrictions: alpha + (beta -1)Rfmin* <=0 alpha + (beta -1)Rfmax* <=0 *To facilitate the code I will find the value of Rfmin and Rfmax separately so I will have a vector (Rfmin, Rfmax)' directly available. Anyone know how I can code the matrix ui representing the above restrictions, so I can fit the constrained regression? Thanks for your help, seb [[alternative HTML version deleted]]
Maybe Matching Threads
- least squares regression using (inequality) restrictions
- Which package/function for solving weighted linear least squares with inequality and equality constraints?
- Constrainted Nonlinear Optimization - lack of convergence
- dovecot on OSF/1 4.0
- Translation of Linear minimization probelm from matlab to r