{"id":277,"date":"2017-08-01T10:53:58","date_gmt":"2017-08-01T10:53:58","guid":{"rendered":"http:\/\/debian-economist.eu\/wp\/?p=277"},"modified":"2017-08-01T10:53:58","modified_gmt":"2017-08-01T10:53:58","slug":"test-all-coefficients-equal-to-0-with-systemfit-r-package","status":"publish","type":"post","link":"https:\/\/debian-economist.eu\/wp\/?p=277","title":{"rendered":"Test all coefficients equal to 0 with systemfit R package"},"content":{"rendered":"<p>You might use the <a href=\"https:\/\/cran.r-project.org\/web\/packages\/systemfit\/systemfit.pdf\">package systemfit<\/a> to estimate simultaneous equations<a href=\"#fn1\">[1]<\/a>. Systemfit does not explain how to test null coefficients together. The solution is simple. You juste have to compute a diagonal matrix of the dimension equals to the number of coefficients:<br \/>\n<code><br \/>\nn = nrow(as.matrix(fit$coefficients))<br \/>\nRmat <- matrix(0, nrow = n, ncol = n)\nfor (i in 1:n){ Rmat[i,i]=1}\nlinearHypothesis(fit,Rmat)\n<\/code><\/p>\n<p>You replace the variable \"fit\" by the variable corresponding to your systemfit output. And there you are, you can get the results of your F test.<\/p>\n<p><a name=\"fn1\"><\/a>[1] You can refer as well to the <a href=\"https:\/\/cran.r-project.org\/web\/packages\/systemfit\/vignettes\/systemfit.pdf\">vignettes<\/a> to get a detailed explanation.<\/p>\n<p>Views: 241<\/p>","protected":false},"excerpt":{"rendered":"<p>F test with systemfit for null coefficients<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[3],"tags":[215,217,216,179,214],"class_list":["post-277","post","type-post","status-publish","format-standard","hentry","category-hints","tag-coefficients","tag-f-test","tag-null","tag-r","tag-systemfit"],"_links":{"self":[{"href":"https:\/\/debian-economist.eu\/wp\/index.php?rest_route=\/wp\/v2\/posts\/277","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/debian-economist.eu\/wp\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/debian-economist.eu\/wp\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/debian-economist.eu\/wp\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/debian-economist.eu\/wp\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=277"}],"version-history":[{"count":1,"href":"https:\/\/debian-economist.eu\/wp\/index.php?rest_route=\/wp\/v2\/posts\/277\/revisions"}],"predecessor-version":[{"id":278,"href":"https:\/\/debian-economist.eu\/wp\/index.php?rest_route=\/wp\/v2\/posts\/277\/revisions\/278"}],"wp:attachment":[{"href":"https:\/\/debian-economist.eu\/wp\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=277"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/debian-economist.eu\/wp\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=277"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/debian-economist.eu\/wp\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=277"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}