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

st: Tracing in Stata

From   John Bates <>
To   Stata <>
Subject   st: Tracing in Stata
Date   Tue, 5 May 2009 09:41:15 -0700 (PDT)



Is there any way to figure what line in a for loop Stata is erroring on?  The best way I know of is to do -set tracedepth 1- and -set trace on-.  This works, BUT it's annoying because Stata traces down into function calls that I don't care about.  For example, assume there is an error somewhere in the following (potentially very long) for loop:

forval x = 1/20 {

I just want to know which line in the for loop the error is without having trace go down into the regress ADO code etc.  This is not a problem outside of the for loop because Stata goes line-by-line down do files by default.  All in all, a very minor issue, but one that frustrates me.  Ideally there would be a -set tracedepth 0- option which would address this.



*   For searches and help try:

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