data( "Kmenta" )
demand <- consump ~ price + income
supply <- consump ~ price + farmPrice + trend
labels <- list( "demand", "supply" )
system <- list( demand, supply )
## OLS estimation
fitols <- systemfit("OLS", system, labels, data=Kmenta )
## predicted values and limits
predict( fitols )
## predicted values of the first equation
predict( fitols$eq[[1]] )
## predicted values of the second equation
predict( fitols$eq[[2]] )
Run the code above in your browser using DataLab