This question is related to an old question in Statalist (http://www.stata.com/statalist/archi.../msg00365.html). I encountered a similar "too many values" error recently. Using trace log, the error appears to come from -levels- command (line 80) in the user-written _gxtile.ado file (*! _gxtile version 1.2 UK 08 Mai 2006). Changing the command to the newer -levelsof- command solves the "too many values" error, but the for loop starting in line 81 of the ado file is very slow to execute. I imagine one can rewrite the outer for loop from line 81 to line 91 as a -by- statement (the inner loop from line 84 to line 90 is probably still necessary), which could substantially improve performance if one has to deal with a large number of categories? While in principle I know how to implement this, I am not familiar with the Stata programming syntax, so if some expert can make an update of this ado file using my suggestion, I (and I'm sure many other Stata users) would greatly appreciate it.
-
Login or Register
- Log in with
Comment