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]

Re: st: Nostop in do files

From   Neil Shephard <[email protected]>
To   [email protected]
Subject   Re: st: Nostop in do files
Date   Fri, 22 Oct 2010 15:33:49 +0000

On Fri, Oct 22, 2010 at 3:19 PM, Katia Bobulova
<[email protected]> wrote:
> The option could be dangerous, but it is useful for preliminary analysis.
> I have bot the data and the do files in the same folder.
> So I open the dataset and then I type:
> do 2000, nostop
> where 2000 is the name of my do file I receive the message file
> not found
> Could you please help me to solve this problem?

Without output its pretty hard to tell, but I'll hazard a guess at
what you're doing...

1) You start up Stata

2) You open your file with File -> Open, navigate to the location and
open the dataset

3) You now type 'do 2000, nostop' and get told the file isn't found.

This is because whilst the data file and do file are in the same
location, Stata is not currently "in" that directory.

Type -pwd- to see what directory Stata is in, if the output of this is
NOT the directory where your files are then use the -cd- command to
change directory to the location of the files.

I'll further hazard that your on M$-Windoze, so something like...

cd "c:/this/is/where/i/have/saved/my/files"
use mydata, clear
do 2000, nostop

...should hopefully achieve what you are trying to do (although
obviously substituting the directory path (
"c:/this/is/where/i/have/saved/my/files" double quotes are important
if you have a space in the path) for where you have actually saved it,
and the data file name for the name you have called your data
("mydata", again double quotes are important if you have a space in
the filename)).

Personally I never touch the menu system in Stata, insteading working
exlusively with do-files and -cd-ing to the relevant directory first.

These are very basic (and fundamental) steps to working with Stata.  I
would recommend one of the introductory texts to Stata available from
Stata Press such as...

..or similar.  Alternatively you may find the the Stata NetCourse
useful which covers these


"Our civilization would be pitifully immature without the intellectual
revolution led by Darwin" - Motoo Kimura, The Neutral Theory of
Molecular Evolution

Email - [email protected]
Website -
Photos -
*   For searches and help try:

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