Agriculture Reference
In-Depth Information
button in the Main window. You will notice across the top of the Data
Editor are the names of the individual variables (e.g., number, variety,
harvest date, etc.). Each column then represents a specific variable or,
in the jargon of Stata, a varlist, and each row represents an observation.
As mentioned previously, there are other options with this com-
mand, for example, changing the variable labels. To do this, select
this command again, indicate the file to load (Variety 2000 Test
Data .txt), and then list new variable names in the appropriate field
(FigureĀ 2.4). Let's use the following names with spaces between each
(no var date rep yield harv). Make sure to check the Replace data in
memory; otherwise you will get an error message because Stata will
not overwrite data in memory unless you explicitly tell it to. Now you
will notice that the variable names have changed from what they were
originally to the new names. Stata automatically changes the case of
variable names to lower case, but you can force Stata to maintain the
case by checking the Preserve variable case checkbox.
Another option with this function is the selection of storage type.
Generally, you would leave this as Use Default. This lets Stata deter-
mine the appropriate storage type. When you first viewed the Data
Editor, you would have noticed a couple of columns were in red indi-
cating they were text or string variables. This is because Stata has
interpreted these variables as strings. Numeric data (black) can be
forced to a specific data type with this command, either as a float
or long variable. These data types are used for numbers with many
decimal places (more precision) and require more computer memory
for each data point. In general, it is best to let Stata determine the
appropriate data type.
This command also can be set to use specific delimiters, i.e., what
character is used to separate the variables. Generally, it is best to let
Stata determine this, but you can select a specific delimiter. This may
be useful in a case where more than one delimiter character is in a
dataset, such as commas and tabs, and the tabs are the delimiters you
wish to use. The commas are just part of numbers (e.g., 9,999).
Finally, at the bottom of this dialog window are several icons
(FigureĀ 2.4). The question mark icon will open a Viewer window with
information on using this particular command. The R will reset the
dialog to an empty condition clearing all the fields. The final icon
looks like two pages and copies this command to the clipboard. You
Search WWH ::




Custom Search