Notice: On April 23, 2014, Statalist moved from an email list to a forum, based at statalist.org.
[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
st: nnmatch error in PSM
From
Katherine Picho <[email protected]>
To
[email protected]
Subject
st: nnmatch error in PSM
Date
Wed, 11 Sep 2013 10:25:25 -0400
Hi all
I'm currently attempting propensity score matching with nearest
neighbor using the nnmatch.
However, at some point in running my ado file, STATA returns an error
message: "Insufficient memory to create more variables:Either increase
memory or decrease m"
I only have about 290 variables in the current dataset (21k observations).
I'm only matching using 3 variables. I'm using STATA IC and the max #
var is 2048 (which is way more that I could ever use for this specific
purpose).
Even when I reduce the dataset to only 40 variables, and still match
on the 3 variables of interest, the problem/ error code remains the
same.
I have 3615 treatment observations that I'd like to match from a pool
of about 16,500 controls (so theoretically this should not be a
problem)
My matching variables are categorical
the nnmatch command that I run (where I run into trouble) is:
nnmatch Depvar trtmt pscore, tc(att) m(1) keep(matched_att) replace
this is where it generates the error message.
I tried to remedy potential memory problems like- compressing the
data/ variables. expanding the memory. (help query, within stata
itself), etc, Nothing works. A search on the statalist archives
indicates that a few people have run into the same problems using
nnmatch-- but none of the queries I found had received any responses
on how to fix the problem.
If anyone here has run into a similar issue that they were able to
fix, please let me know. Thanks!
Katherine
*
* For searches and help try:
* http://www.stata.com/help.cgi?search
* http://www.stata.com/support/faqs/resources/statalist-faq/
* http://www.ats.ucla.edu/stat/stata/