# Forum: help

Monitor Forum | Start New ThreadRE: Wondering if I could use systemfit for my problem [ reply ] By: Arne Henningsen on 2013-10-10 13:44 | [forum:39875] |

Dear Sharon You can rewrite your restriction (which is in vector-form) so that you get N restrictions in scalar-form, where N is the length of each vector c1 to c6. Alternatively, you can transform your restriction into matrix form: c1*a2 + c2*a4 - c3*a6 - c4*a8 - c5*a10 - c6*a12 = 0 cbind( c1, c2, -c3, -c4, -c5, -c6 ) %*% c( a2, a4, a6, a8, a10 ) = 0 cbind( 0, c1, 0, c2, 0, -c3, 0, -c4, 0, -c5, 0, -c6 ) %*% c( a1, a2, a3, a4, a5, a6, a7, a8, a9, a10 ) = 0 You can directly specify the matrix "cbind( 0, c1, 0, c2, 0, -c3, 0, -c4, 0, -c5, 0, -c6 )" as the restriction matrix in systemfit(). Best regards, Arne |

Wondering if I could use systemfit for my problem [ reply ] By: Sharon Xie on 2013-10-10 13:31 | [forum:39874] |

Hi, everyone, I am new to systemfit, and I am wondering if I could use this package to solve my problem. I want to solve a series of equations and I intended to use OLS at beginning to solve each of them. y1=a1+a2*x1 y2=a3+a4*x2 y3=a5+a6*x3 y4=a7+a8*x4 y5=a9+a10*x5 y6=a11+a12*x6 where y1 through y6, x1 through x6 are known vectors, respectively. And I want to estimate a1 through a12. Then, I needed to impose a restriction to fit my research goal. And the restriction is as follows: c1*a2+c2*a4=c3*a6+c4*a8+c5*a10+c6*a12, where c1 through c6 are known vectors too. While I was searching about systemfit's restriction command, I found people normally impose restrictions such as homogeneity and symmetric. However, my restriction includes vectors. So, could you please let me know if systemfit would work for my problem. If so, how can I approach it. Thank you so much for your help. Sharon |