iv_estimates | R Documentation |
This function estimates the instrument on dependent effect coefficient (beta) and the proportion of variance explained (eta-squared) in dependent by instrument
iv_estimates(wdata, dependent, instrument, covariates)
wdata |
a data frame passed to function containing necessary data for analysis |
dependent |
a single string character of the column name for the dependent or response (y) variable. |
instrument |
a single string character of the column name for the instrument, which will be set as the independent or explanatory variable in the model. |
covariates |
a character vector that are also column names used to define variables that will be set as covariates. |
returns a lmfit object that is a list containing (1) 'fit' a lm() object and (2) 'summary' a vector of summary statistics.
iv_estimates()
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.