Announcement

Collapse
No announcement yet.
X
  • Filter
  • Time
  • Show
Clear All
new posts

  • How to refer to do file name in code

    Say I am trying to create a log file:

    Code:
    log using "Home/Analysis/[insert same file name as my do file]"
    Is there an easy way to tell Stata to refer back to the same do file file name?

  • #2
    So basically, you want to do some kind of reflection to get the name of the currently running do file? Apparently, you can do this with the project package.

    https://www.statalist.org/forums/for...-after-do-file

    Comment


    • #3
      Thanks, this seems useful!

      Comment

      Working...
      X