My Account Log in

1 option

Reading external data files using SAS : examples handbook / Michele M. Burlew.

Van Pelt Library QA76.9.F53 B87 2002
Loading location information...

Available This item is available for access.

Log in to request item
Format:
Book
Author/Creator:
Burlew, Michele M.
Language:
English
Subjects (All):
SAS (Computer file).
File organization (Computer science).
Physical Description:
vii, 278 pages : illustrations ; 28 cm
Place of Publication:
Cary, NC : SAS Pub., 2002.
Summary:
Reading External Data Files Using SAS: Examples Handbook is packed with examples that illustrate the many common issues you face when reading external data files. Whether you need to handle a variety of input styles (list, column, formatted, and named), accommodate external file features, or use different methods for reading the data, you're sure to find examples in this book that address your coding requirements. The examples illustrate techniques that range from simple to complex, and you can easily copy, modify, and reuse the examples.
Contents:
Methods of Reading Raw Data 2
Understanding Data Sources 3
Understanding Data Values 4
Reading Raw Data with the INPUT Statement 5
A Checklist in Specifying Your External File 11
Chapter 2 Specifying the Structure of External Files
Example 2.1 Reading Space Delimited Data 16
Example 2.2 Reading Comma Delimited Data 19
Example 2.3 Reading Tab Delimited Data 21
Example 2.4 Reading Delimited Data Where the Delimiter May Be Part of the Data 23
Example 2.5 Reading Missing Data Values When the Values Are Not Aligned in Columns 27
Example 2.6 Reading Nonstandard Data Values That Are Not Aligned in Columns 30
Example 2.7 Reading Multiple External Files 33
Example 2.8 Reading Multiple External Files Where the Names of the External Files Are Stored in Another External File 41
Example 2.9 Reading from Multiple External Files and Determining the Names of the External Files within the DATA Step 46
Example 2.10 Obtaining the Name of the External File Currently Being Read 50
Example 2.11 Reading Column Aligned Data from Variable Length Data Lines 55
Example 2.12 Processing Missing and Incomplete Data When Reading Column Aligned Data from Variable Length Data Line 59
Example 2.13 Stopping a DATA Step If Data Values Are Not Found in the Current Data Line 61
Chapter 3 Controlling How SAS Reads External Files
Example 3.1 Reading Multiple Data Lines to Create a Single Observation 68
Example 3.2 Creating Multiple Observations from a Single Data Line 72
Example 3.3 Creating Multiple Observations from a Single Data Line and Retaining Identifier Information from the Data Line for Each Observation 74
Example 3.4 Reading Repeating Data Values When the Number of Repeating Data Values is Known 79
Example 3.5 Creating a Single Observation from an Unknown Number of Data Lines 82
Example 3.6 Reading Data with Varying Record Layouts 85
Example 3.7 Reading Hierarchical Data Lines 97
Example 3.8 Reading Variable Width Data Values That Are Not Delimited 103
Example 3.9 Reading Varying Width Data Values That Are Not Delimited and Calculating the Width within the DATA Step 107
Example 3.10 Detecting When SAS Reaches the End of an External File 112
Example 3.11 Limiting the Number of Data Lines Read from an External File 117
Example 3.12 Reading Special Missing Values 122
Example 3.13 Updating a SAS Data Set with Transactions Read from an External File 126
Example 3.14 Reading Nonstandard Numeric Data Values and Converting Them to Standard Numeric Data Values by Examining the Data Value 134
Chapter 4 Operating System Specific Features When Reading External Files
Example 4.1 Directory-based Systems: Reading Wide Records 142
Example 4.2 Reading from Multiple External Files That Have the Same Layout 146
Example 4.3 Reading an External File That Is in One of Several Directories 150
Example 4.4 Specifying the Name of an External File When Starting a SAS Session 154
Example 4.5 Obtaining Information About the Characteristics of an External File 158
Example 4.6 Reading an External File from a Remote System, Creating a Data Set on the Remote System, and Presenting the Data Locally 164
Example 4.7 OS/390: Reading Data from Specific Members of a Partitioned Data Set 168
Example 4.8 OS/390: Reading a VSAM KSDS Data Set 173
Example 4.9 Directory-based Systems: Reading a Fixed-Length EBCDIC File on an ASCII System 177
Example 4.10 Reading Variable-Length Data Lines from a Binary Stream File 184
Example 4.11 Directory-based Systems: Reading Multiple External Files from a Directory 188
Example 4.12 Reading an External File That Contains Carriage-Control Characters in the First Byte 194
Example 4.13 OS/390: Reading an External File Created by a COBOL Program 198
Example 4.14 OpenVMS: Reading an External File Stored on a Tape 202
Example 4.15 OS/390: Reading an External File Stored on a Tape 209
Example 4.16 UNIX: Reading an External File from Tape 213
Chapter 5 Importing External Files with the Import Wizard and the External File Interface
Example 5.1 Reading Delimited Data Values with the Import Wizard 219
Example 5.2 Reading Delimited Data Values with the External File Interface (EFI) 226
Chapter 6 Using ACCESS Methods and the XML LIBNAME Engine to Read Data
Example 6.1 Reading from an External File Stored on a Remote Host with the FTP Access Method 237
Example 6.2 Reading Multiple Files Stored on a Remote Host with the FTP Access Method 240
Example 6.3 Transmitting Data Between SAS Applications through a TCP/IP Socket 246
Example 6.4 Reading an Entry from a SAS Catalog 250
Example 6.5 Reading a Microsoft Excel Worksheet with DDE 252
Example 6.6 Reading Data from a Web Page 256
Example 6.7 Reading an XML Document 259.
Notes:
Includes index.
ISBN:
1590471156
9781590471159
OCLC:
51652521

The Penn Libraries is committed to describing library materials using current, accurate, and responsible language. If you discover outdated or inaccurate language, please fill out this feedback form to report it and suggest alternative language.

Find

Home Release notes

My Account

Shelf Request an item Bookmarks Fines and fees Settings

Guides

Using the Find catalog Using Articles+ Using your account