1
votes

I am new here and I have a question in R. I applied the package matchit to match my propensity score of a glm-output. I created a subset of the original dataset for this because matchit does not allow missings. My problem is, that the original dataset for further analysis have missings in a lot of different scores. I want to carry out t-tests or welch tests with this metrical variables.

How can i combine the variables of the propensity score matching and the variables of the endpoints (with missings) from the original dataset? When I put the variables together before matching I get a error. But I want to create a dataset with the matched individuals and the endpoint variables. Is match.data the way?

Can anyone help me? I hope my question is understandable:-)

1

1 Answers

0
votes

This problem has been fixed in MatchIt 4.0.0, which is now on CRAN. You will no longer get an error about missingness as long as neither the covariates nor the treatment has missingness. You can then call match.data() on the output object to return the matched dataset, which will be identical to the original dataset but only contain the matched units and will have a few additional columns. The missingness in the original endpoint variable will remain.