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 [aut, cre]
Maintainer: Weihua An <[email protected]>
License: GPL-3
Version: 1.1
Built: 2024-12-05 13:59:21 UTC
Source: CRAN

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. One nice feature of the function is that it can distinguish three types of error dependence, including triadic dependence, mutual dependence, and asymmetric 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. One nice feature of the function is that it can distinguish three types of error dependence, including triadic dependence, mutual dependence, and asymmetric 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. 2023. “A Tale of Twin-Dependence: A New Multivariate Regression Model and an FGLS Estimator for Analyzing Outcomes with Network Dependence." Sociological Methods and Research 52(4): 1947-1980.

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