Fit single factor models
sfModel(formula, data, response, factor, time, constrained = FALSE, save.data = TRUE, correlation = NULL)
formula | a formula of the form |
---|---|
data | a data frame in which |
constrained | a logical indicating whether the model parameters are constrained |
correlation | an optional |
an lm object with some additional attributes
#> Generalized least squares fit by REML #> Model: log(iGDP) ~ iK + iYear #> Data: data #> Log-restricted-likelihood: 90.73298 #> #> Coefficients: #> (Intercept) iK iYear #> -0.07143534 0.10760947 0.01775149 #> #> Degrees of freedom: 51 total; 48 residual #> Residual standard error: 0.0318531sfModel(response = "iGDP", factor = "iK", time = "iYear", data = EconUK)#> Generalized least squares fit by REML #> Model: log(iGDP) ~ iK + iYear #> Data: data #> Log-restricted-likelihood: 90.73298 #> #> Coefficients: #> (Intercept) iK iYear #> -0.07143534 0.10760947 0.01775149 #> #> Degrees of freedom: 51 total; 48 residual #> Residual standard error: 0.0318531