Lecture14-STATA - Lecture 14 Introduction to STATA Our next...

Info iconThis preview shows pages 1–2. Sign up to view the full content.

View Full Document Right Arrow Icon
Lecture 14 – Introduction to STATA Our next step is to learn how to use the computer to carry out the computations for us. In what follows, commands you should enter appear in lower-case boldface. Instructions for STATA 1) Formatting a disk -(this should be done before entering STATA)- a) double-click on the “My Computer” icon on the desktop b) Click the icon for the drive ‘a:’ c) From the file menu, choose format d) Choose the capacity of the disk e) Click start f) When formatting is complete, click on close . 2) To open Small STATA either double-click on the STATA icon, or, if there is no icon, choose Start and then Program and then STATA. 3) First, notice that there are four windows: STATA Results, STATA Commands, Variables and Review. STATA Results will show you the output of everything you are doing. STATA Commands is the window where you enter commands. The Variables window shows what variables are in the database you are using. The Review window records the commands you have used. If you want to reuse one, you can click on the command in the review window and it will appear in the command window. Above the windows is a toolbar with buttons. Move the cursor to each button, without clicking, and familiarize yourself with the functions, including the “log”, “viewer”, “do-file editor,” and “data editor.” 4) Keeping a log of your session . It is often useful to retain a complete log of your session for future reference. Since you are working with shared computers, it is best to keep your log on your own diskette. Enter the command log using a:\practice.log . This will create a file with a log of all commands you subsequently enter and their results. That is, it is a copy of everything that shows up in the Results Window. You can subsequently load it into Word and edit it. 5) Annotating a STATA program . You will be writing small programs in STATA to send commands to the computer. You will want to annotate the program you are writing to tell yourself what you have done. Whenever you want to get out of the programming mode (in the STATA COMMANDS window) and write a comment that STATA will not interpret as a command, you may begin a line with a * . Your comment must be only one- line long. Hit <enter> to move to a new line, and then begin the new line with a *. Finish your comment, then hit enter again to enter the STATA programming mode. 6) Data: The first thing we must learn to do is to enter data into a STATA data file. There are two methods we will learn to do this. The first is the method you must use for data that you have developed yourself, i.e., it is data that is not on-line anywhere, and hence cannot be down-loaded into a STATA file. The method may also be useful even for data that is online if the data set is small and you must do a lot of cleanup of the on-line file before it can be used. You will understand what this means after next class.
Background image of page 1

Info iconThis preview has intentionally blurred sections. Sign up to view the full version.

View Full DocumentRight Arrow Icon
Image of page 2
This is the end of the preview. Sign up to access the rest of the document.

This note was uploaded on 03/03/2011 for the course ECO 230 taught by Professor Yongjinpark during the Spring '11 term at Conn College.

Page1 / 5

Lecture14-STATA - Lecture 14 Introduction to STATA Our next...

This preview shows document pages 1 - 2. Sign up to view the full document.

View Full Document Right Arrow Icon
Ask a homework question - tutors are online