Windows environment
Stata Windows environment
Stata is available at CPC in both the Windows and Unix environments. Stata commands are identical in the two environments. The Graphical User Interfaces (GUI) are almost the same in MS Windows and Unix X-Windows. Although Stata can also be run in a non-GUI form, the GUI is much more convenient for learning Stata.
This page talks about the MS Windows GUI environment. We recommend that you use Stata in Windows while getting acquainted with it. You may choose to move to the non-GUI environment under Unix after getting acquainted with Stata commands and learning how to work with do-files.
The Stata manual set includes a volume "Getting Started with Stata for Windows." It's a readable yet thorough introduction, and much of it is a tutorial. If you don't have access to that volume, you can use this page for some general pointers to get you started.
Starting and stopping Stata
On desktop computers at CPC, Stata is available only through the Start menu at the bottom-left corner of your screen. Click on Start, Software Run, Statistics, Stata 9 Run. Click on the "X" in the upper right corner to stop Stata. (To get started using Stata on a CPC Unix platform, contact cpchelp@unc.edu.)
If you have data in memory, and you've changed the data in any way (even sorting), Stata won't let you quit without either saving the data to a permanent file or clearing data from memory. If you're sure you don't want to save the data in memory, you can type:
exit,clear
to get out of Stata.
4 windows
Stata gives you 4 windows: Command, Results, Review, and Variables.
* Command: type a command here and press Enter
* Results: the results of your command are displayed here
* Review: each command you type is displayed here
o Click on a command to put it into the command window for editing
o Double-click on a command to execute it directly
* Variables: lists the variables in memory
o Click on a variable name to put it into the command window
You can resize these 4 windows independently, and you can resize the outer window as well. To save your window size changes, click on Prefs, Save Windowing Preferences
Menus
Stata displays 9 drop-down menus across the top of the outer window:
* File
o Open: open a Stata data file (use)
o Save/Save as: save the Stata data in memory to disk
o Do: execute a do-file
o Filename: copy a filename to the command line
o Print: print log or graph
o Exit: quit Stata
* Edit
o Copy/Paste: copy text among the Command, Results, and Log windows
o Copy Table: copy table from Results window to another file
o Table copy options: what to do with table lines in Copy Table
* Prefs - all Stata-related preferences
* Data, Graphics, Statistics - build and run Stata commands from menus
* User - menus for user-supplied Stata commands (download from Internet)
* Window - bring a Stata window to the front
* Help - Stata command syntax and keyword searches
Button bar
The buttons on the button bar are from left to right (equivalent command is in bold):
* Open a Stata data file: use
* Save the Stata data in memory to disk: save
* Print a log or graph
* Open a log, or suspend/close an open log: log
* Bring the log window to the front (if a log is open)
* Bring a viewer window to the front (such as a Help window)
* Bring the graph window to the front (if you've created a graph)
* Open a do-file
* Edit the data in memory: edit
* Browse the data in memory: browse
* Scroll another page when --more-- is displayed: Space Bar
* Stop current command or do-file: Ctrl-Break
Sources of help
* Help menu
o Command: almost the full reference manual for each Stata command
o Search: keyword search of the manuals, technical bulletins, and frequently asked questions
* Data, Graphics, and Statistics menus
o build a command with the correct syntax for you
o lead you to consider options that you might easily overlook
* Manuals
o Reference manuals: alphabetic by command, very easy to use
o User's Guide: function oriented
o Graphics Manual: all graphics commands
o Getting Started: how to use Stata in Windows or Unix
* Stata tutorials: type tutorial to see what Stata provides (graphics, regression, and more)
Senin, 09 Maret 2009
Langganan:
Posting Komentar (Atom)
Tidak ada komentar:
Posting Komentar