Package 'fglsnet'

Title: A Feasible Generalized Least Squares Estimator for Regression Analysis of Outcomes with Network Dependence
Description: The function estimates a multivariate regression model for outcomes with network dependence.
Authors: Weihua An
Maintainer: Weihua An <[email protected]>
License: GPL-3
Version: 1.0
Built: 2024-11-14 02:58:02 UTC
Source: https://github.com/cran/fglsnet

Help Index


Simulated data for demonstrating "fglsnet".

Description

Simulated data for demonstrating "fglsnet".

Usage

data(dat)

Format

An object of class list of length 3.

Details

Y is the outcome. X contains the regressors including the intercept.. M is the dependence network.


A Feasible Generalized Least Squares Estimator for Regression Analysis of Outcomes with Network Dependence

Description

fglsnet estimates a multivariate regression model for analyzing outcomes with network dependence.

Usage

fglsnet(
  formula,
  M = NULL,
  directed = TRUE,
  mcorr = TRUE,
  CSE = FALSE,
  k = 10,
  data = data
)

Arguments

formula

A formula indicating the regression model.

M

The dependence network.

directed

Whether the dependence network is directed or undirected.

mcorr

Whether request multiple correlation coefficients to distinguish triadic, mutual, and asymmetric error dependence.

CSE

Whether use clustered standard error for the residual regression. Default cluster is the ego unit.

k

The number of iterations in the fgls estimation.

data

The data that are used for the regression.

Details

The function estimates a multivariate regression model for analyzing outcomes with network dependence.

Value

A list containing the coefficient coef, the testing results on the error correlations rtest, the estimated error variance Sigma, the estimated error correlation matrix Omega, and the OLS estimates ols.

References

An, Weihua. 2021. “A Tale of Twin-Dependence: A New Multivariate Regression Model and an FGLS Estimator for Analyzing Outcomes with Network Dependence." Sociological Methods and Research. (Forthcoming)

Greene, William H. (2008). Econometric Analysis (6th edition). New Jersey: Pearson Prentice Hall.

Examples

data(dat)

g <- fglsnet(Y~ X-1, M = dat$M, directed = TRUE, mcorr = 1, k = 5, data = dat)

g$coef