Is there any way to perform bivariate regression using pairwise deletion of missing values in R? na.action options in lm() do not offer such a possibility – the default na.action is na.omit, which is equivalent to listwise deletion. I already tried estimating the covariance matrix using pairwise deletion and then use the function mat.regress (package psych) with the pairwise covariance matrix. However, mat.regress is a function to compute multiple regression (not bivariate). Thank you.
When you use pair wise deletion to estimate a covariance matrix it just means that for any pair of variables you use all available observations that are not missing on either covariate.
So if you had a data matrix
#| A B C ----------- 1| 1 1 NA 2| 2 NA 2 3| NA 3 3 4| 4 4 4
When calculating the covariance between columns
B you would use rows (observations) 1 and 4, and when calculating the covariance between
C you would only use rows 2 and 4.
So in the case of bivariate regression or simple linear regression, it is equivalent to list-wise deletion.