@@ -518,9 +518,9 @@ impacts.Gmsar <- function(obj, ..., n=NULL, tr=NULL, R=NULL, listw=NULL,
518
518
# ###SARAR model
519
519
520
520
gstsls <- function (formula , data = list (), listw , listw2 = NULL ,
521
- na.action = na.fail , zero.policy = attr(listw , " zero.policy" ), pars = NULL , scaleU = FALSE ,
522
- control = list (), verbose = NULL , method = " nlminb" , robust = FALSE ,
523
- legacy = FALSE , W2X = TRUE )
521
+ na.action = na.fail , zero.policy = attr(listw , " zero.policy" ), pars = NULL ,
522
+ scaleU = FALSE , control = list (), verbose = NULL , method = " nlminb" ,
523
+ robust = FALSE , legacy = FALSE , W2X = TRUE , sig2n_k = FALSE )
524
524
{
525
525
526
526
@@ -590,7 +590,7 @@ gstsls<-function (formula, data = list(), listw, listw2=NULL,
590
590
}
591
591
592
592
instr <- cbind(WX , WWX )
593
- firststep <- tsls(y = y , yend = wy , X = x , Zinst = instr , robust = robust , legacy = legacy )
593
+ firststep <- tsls(y = y , yend = wy , X = x , Zinst = instr , robust = robust , legacy = legacy , sig2n_k = sig2n_k )
594
594
595
595
ukp <- residuals(firststep )
596
596
@@ -641,7 +641,7 @@ gstsls<-function (formula, data = list(), listw, listw2=NULL,
641
641
colnames(xt ) <- xcolnames
642
642
colnames(wyt ) <- c(" Rho_Wy" )
643
643
secstep <- tsls(y = yt , yend = wyt , X = xt , Zinst = instr ,
644
- robust = robust , legacy = legacy )
644
+ robust = robust , legacy = legacy , sig2n_k = sig2n_k )
645
645
rho <- secstep $ coefficients [1 ]
646
646
coef.sac <- secstep $ coefficients
647
647
rest.se <- sqrt(diag(secstep $ var ))
0 commit comments