Hi Axel,

Both error messages indicate that a regression equation is singular.
The error message of systemfit() indicates that the singularity
appears in the first stage of the two-stage procedure. Hence, it seems
that your instruments are linearly dependent. Please check this and
remove some of the instruments so that they are no longer linearly
dependent.

Best,
Arne

On Fri, May 29, 2009 at 3:39 PM, Axel Leroix<axel.ler...@yahoo.fr> wrote:
> Hello !
>
> I’m trying to estimate a system of equation (demand and supply) using the 
> systemfit package.  My program is:
>
> library(systemfit)
> demand <- tsyud ~ tsyud1 + tsucp + tspo + tssn
> supply <- tscn ~ tsyn + tsqn + tsksn + tsucp
> system <- list(demand=eqdemand, learning = eqsupply)
> labels <- list(demand="eqdemand", learning="eqsupply")
> inst <- ~ tsupp1 + tsupp2 +
> tsupp3 + tsyus1 + tsupf + tsd1 + tsyud1 + tspo + tssn + tsupp + tsus +
> tsus1 + tsyn + tsqn + tsksn
> result2sls <-systemfit(method="2SLS", system, labels, inst=inst)
>
>
> This does not work and I have the following error message that I do not 
> understand its meaning:
>
> Error in solve(crossprod(zMatEq[[i]]), crossprod(zMatEq[[i]], 
> xMatAllThisEq),  :
>   the leading minor of order 3 is not positive definite
>
> Can you help me please to understand the problem?
>
>  Remark1: Please note that in my estimation, the variables tsyud1, tsupp1, 
> tsupp2, tsupp3, and tsyus1 are lagged variables.
>
> Remark2: When I try to estimate each one of my two equations separately using 
> the sem package, I also have an error message:
>
> supplyreg <- tsls(tscn ~ tsyn + tsqn + tsksn + tsucp, ~ tsupp1 + tsupp2 +
> tsupp3 + tsyus1 + tsupf + tsd1 + tsyud1 + tspo + tssn + tsupp + tsus +
> tsus1 + tsyn + tsqn + tsksn)
> summary(supplyreg)
>
> Error in solve.default(crossprod(Z))"Lapack routine dgesv: system is exactly 
> singular"
>
> Do the two error messages mean the same think?
>
> Thank you in advance for your help.
>
>
>
>        [[alternative HTML version deleted]]
>
>
> ______________________________________________
> R-help@r-project.org mailing list
> https://stat.ethz.ch/mailman/listinfo/r-help
> PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
> and provide commented, minimal, self-contained, reproducible code.
>
>



-- 
Arne Henningsen
http://www.arne-henningsen.name

______________________________________________
R-help@r-project.org mailing list
https://stat.ethz.ch/mailman/listinfo/r-help
PLEASE do read the posting guide http://www.R-project.org/posting-guide.html
and provide commented, minimal, self-contained, reproducible code.

Reply via email to