Re: [R] problem of Mahalanobis distance matching using MatchIT

2015-10-02 Thread Giorgio Garziano
About the "distance = NA" issue, please see if this comment helps: https://lists.gking.harvard.edu/pipermail/matchit/2011-January/000174.html Furthermore, the Mahalanobis NA distance values are hard-wired in the code, file matchit.R: ## no distance for full mahalanobis matching if(fn1=="di

[R] problem of Mahalanobis distance matching using MatchIT

2015-10-01 Thread duo wan via R-help
Dear All, I am trying to use simulation to test mahalanobis distance matching method.   Somehow I do not think Matchit is giving me what I want Below is the code: n<-100 x1_contr<-runif(n,0,5) x2_contr<-runif(n,0,5) x_contr<-cbind(x1=x1_contr,x2=x2_contr) x1_treat<-runif(n,1,6) x2_treat<-runif(n,1,