Bookmark and Share

Notice: On April 23, 2014, Statalist moved from an email list to a forum, based at

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

st: CEM speed up.

From   "Subramanian, Hemang" <>
To   "" <>
Subject   st: CEM speed up.
Date   Sat, 29 Dec 2012 00:07:36 +0000

Hi Stata-list,

 I need help with speeding up the execution of CEM. I'm running coarsened exact matching on about 1.8 million (rows) records. The command used is as follows:
My machine is a significantly powerful 32 Gig - 4 QuadCore processor server.
I need the CEM generated weights to run my regressions to validate the effect of treatment on my dependent variable.
My command is follows:
cem matchid(#0) mileage(25000 50000 75000 100000 150000) , tr(treated)

matchid  is  a generated ID with about 1,50,000 values and is a stratification variable.
mileage is a discrete variable with a set of values from 0 to 900,000.
treated is the treatment indicator with a value - ( 1 or 0)
I am trying to  obtain matches within each bucket  (ie. matchid ) or create strata within each matchid.
The weights generated by Cem will further be used to deduce the causal effect.
I tried using the noimb which suppresses the L1 vector distance calculations and it does help with smaller data.
Can anyone suggest alternate ways to speeden up the command's execution  or ways by which I could split up the above query or point me to the logic that does the weight calculation in CEM?.

warm regards.
Hemang C Subramanian

Hemang C Subramanian
Ph.D. Candidate, Information Technology & Management,
Primary Instructor - Business Programming
Ernest K Scheller Jr. College of Business
Georgia Tech, 800 W. Peachtree Street,
Atlanta 30318

*   For searches and help try:

© Copyright 1996–2017 StataCorp LLC   |   Terms of use   |   Privacy   |   Contact us   |   Site index