How to determine what the Seemingly Unrelated Regression error means in R

Posted by user2154571 on Stack Overflow See other posts from Stack Overflow or by user2154571
Published on 2013-07-02T23:00:49Z Indexed on 2013/07/02 23:05 UTC
Read the original article Hit count: 409

Filed under:

I'm using the systemfit() function to conduct a seemingly unrelated regression and am getting the following error:

Error in solve(sigma, tol = solvetol) : Lapack routine dsptrf returned error code 1

Yet, I'm unable to find the meaningful interpretation of what the error suggests is going on. Below is some simulated code that works to show what functions I'm using (the simulated code does not produce an error). Thanks for thoughts on this error.

y <- sample(seq(1:4), 100, replace = TRUE)
x1 <- sample(seq(0:1), 100, replace = TRUE) -1
x2 <- sample(seq(0:1), 100, replace = TRUE) - 1
x3 <- sample(seq(1:4), 100, replace = TRUE)
frame <- as.data.frame(cbind(y,x1,x2, x3))

mod_1 <- y ~ x1 + x3 + x1:x3
mod_2 <- y ~ x2 + x3 + x2:x3

output <- systemfit(list(mod_1, mod_2), data = frame, method = "SUR")

© Stack Overflow or respective owner

Related posts about r