CHRR
NLS Investigator for
Windows 95
NLS CD-ROM
User’s Guide

Chapter 4

Performing an Extract

Specifying a Tagset

To perform an extract, an existing tagset must be open. To open a tagset, go to the File component of the Menu Bar and choose "Open Tagset…" Browse and select the desired tagset from the standard Windows dialogue box. When the tagset is open, go to the Extract component of the Menu Bar and choose "Extract Saved Variables." Before choosing "Extract Saved Variables" variables may be reviewed by choosing "Review Saved Variables."

When the function "Extract Saved Variables" is activated, the screen shown below in the figure "Extract Window" will appear. From this window the user may finalize the data file to be extracted in several ways:

The Menu Bar contains the actions to carry out on the sample universe: Run Extract, Stop Extract, Write Codebook, and Exit the extract.

The left half of the window is used to qualify the sample universe of cases by limiting the range of cases and by creating a Boolean Specification.


Extract Window

The right half of the window is used to select the format(s) of the output file.

Information about the extract file such as sample size (number of variables and number of cases) and output file (length, size, and name) is found in the lower left half of the window.

To make selections in this window, press a button, click in a field and type in the limits, or click on a radio button or check box as described below:

If you are using the Youth and Child Data CD-ROM and working with the Children 1986-1994 or Young Adults 1994 data sets, another button, Link to…, will appear on the Menu Bar of the Extract window. This link provides a connection from the Child or Young Adult variables to Female Youth variables from the NLSY79.


Extract in Child Database

Click on it and a dialogue box entitled "Chose a database link" will appear from which you may choose the link to one of the related databases. Use the drop-down menu ( ) to select a database and follow instruction in the subsequent dialogue boxes that appear.

 

 

Specifying the Sample Size

The left half of the window allows the user to manipulate the size of the sample universe by combining four methods. Each method is discussed below.

Case Selection

In the "Select 1 of every __ case(s)" field the number of cases for the extract may be altered. A fraction of the cases may be specified by changing the denominator of the cases.

To change the fraction,

When the number of cases is changed and the cursor is placed in another field, information in the "Number of cases" field will change.


Selecting the Number of Cases

First Case to Read

Instead of always beginning with the first case in the file being read, the "First case to read" can be changed.

To change the first case read,

When the "First case to read" is changed and the cursor is placed in another field, information in the "Number of cases" field will change again.

Last Case to Read

To change the last case to read,

When the "Last case to read" is changed and the cursor is placed in another field, information in the "Number of cases" field will change again.

Boolean Qualification

When the "Edit Boolean Specification" button is pressed, the window shown in below "Create a Boolean Specification" will appear. The Boolean phrase that will be constructed will further manipulate the sample universe by performing operations on the extracted variables that are listed in the right box of the window.

The Boolean phrase is constructed in the top box by selecting variables from the list and qualifying them with the Boolean and arithmetic operators listed, constants, and variables. Rules of arithmetic syntax such as balanced parentheses must be followed. The maximum length of the Boolean string allowed is 255 characters. If violations of syntax or length occur, an error message will be displayed.

  Create a Boolean Specification

Boolean Edit Box

In the following figure, the Boolean phrase is constructed in the top box. You may type in the information in the box, use the buttons and variables displayed on this screen to select the variables and operators, or use a combination of both. When a variable is highlighted in the box on the right, the Description of the variable will appear across the bottom of the screen (e.g., female - How much child care R did at home during 2nd …).


The Boolean Phrase

To select one of the extracted variables (e.g., R2605900) double-click on it in the box on the right. (You may also select a variable by clicking on the Variable button. The Variable field will appear with the Accept and Cancel buttons. Then select the variable from the list in the drop-down menu () and press the Accept button.)

To select one of the operators listed, (e.g., =) type it, or click once on its = button.

To select a constant, (e.g., 1) type it or click on the Constant button. (When you click on the Constant button, the constant field will appear with the Accept and Cancel buttons. Type the constant in the box, use the or to increase or decrease the number in the field and press the Accept button when the number is correct.)

To edit the Boolean Phrase

In the top box, place the cursor at the location in the phrase where the edit will occur, click to activate the text cursor, and type in the edit. In standard Windows fashion, double-clicking over a variable or operator will select the whole term by highlighting it. Begin typing in the edit to replace the selection.

When the phrase is complete, press the Exit button to exit and save the Boolean specification. Or, press the Quit button to exit and not save the Boolean specification.

File Type Specification

Output file specifications may be changed. Each specification is listed in this right half of the window.

In the Extract Data File Type each file type is mutually exclusive. That means that if the radio button for one specification is toggled ‘ON’ () no others may be selected.


Output File Types

In the Optional Output Files one or more file types may be selected by placing a check mark in the check boxes (). Multiple choices in the list may be checked.

 

Data Extract Formats

The following file formats are available in the Extract Data File Type portion of the window.

Note: The SAS and SPSS control statements generated include basic data location, label and missing value information. While every attempt has been made to provide "read-to-use" statements, the platform and version of your specific installation may require modification of these generic control programs. Please consult your local SPSS or SAS coordinator for site-specific problems.

File Size Information

In the right half of the window, lower portion, information about the extract file is displayed in the fields listed below. The original size of the sample universe and output file size appear when the window appears. As the size of the sample universe is changed, this information is reflected in the fields. Other fields display the length of the record in the file and the output file name. These are:


File Size Information

Actions

Several actions may be carried out on the extract file. The buttons in the menu bar controls these actions.

 

Run the Extract

Carefully read the screen to assure that all selected specifications are correct.

When they are correct, press the Run Extract button. When the extract is in-progress, the window shows an in-progress bar (104 of 253) with the number of cases being processed at the bottom left of the screen.


Extract In-progress

The Stop Extract button becomes active and the extract may be aborted when it is pressed.

Summary information on the extract run will appear at the end of processing. This information includes the resulting number of cases read, cases kept, and elapsed time. The resulting output files are listed by name.

Extract Report

Press the Exit button to close the window and return to the Extract window.

 

Write Codebook

Normally the Codebook file of the extract file is produced automatically. But when only the codebook is desired, this button can be used without running the extract. When the Write Codebook button is pressed, no window appears on the screen. A codebook file is created and placed in the directory where the software was installed. This file contains a codebook representation of the variables in the extract file. The name of this codebook file is the same file name as extract file with a .CDB extension (e.g., [file_name].CDB).

NOTE: This codebook file should not be confused with the complete codebook file created when the "Write Documentation" function is selected from the File component of the Main Menu screen. The file name of the complete codebook will be specified at the time of creation.

A sample codebook file for chld-88-2ndpreg.CDB may be found in the Appendix 4, Chld--88-2ndpreg.CDB.

Exit this Menu

When the Exit button is pressed, the user is returned to the Main Menu screen.

Next Step

Write documentation or view sample extract files: chld-88-2ndpreg.CDB, chld-88-2ndpreg.DCT, chld-88-2ndpreg.DOC, chld-88-2ndpreg.SAS, chld-88-2ndpreg.SPS.

 



Go to Chapter 5 - Write Documentation

Go to Table of Contents