Statalist The Stata Listserver

[Date Prev][Date Next][Thread Prev][Thread Next][Date index][Thread index]

st: macro with a dot

From   Robert Kraut <>
To   stata <>
Subject   st: macro with a dot
Date   Sat, 04 Mar 2006 14:20:17 -0500

I am trying to create a macro to refer to the directory where data and
files are stored, so I can move do files easily between computers. I
define the dir macro as:

   local  dir F:\\\0_freshmen\transition\

I would like to be able to refer to the directory using a form like:


and have this expand to


But when I try to refer to dir's values, I get an error, as if the dir
value is broken at the dot included in a directory names:

    dis `dir'
    data\0_freshmen\transition\ invalid name

I am using stata v9 on a windows machine.

Any suggestions?
Robert Kraut
Herbert A Simon Professor of Human Computer Interaction
Carnegie Mellon University, 3515 NSH
5000 Forbes Ave, Pittsburgh, PA 15213
(o) 412 268-7694  (f) 412 268-1266
web:  email:

*   For searches and help try:

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