{[ promptMessage ]}

Bookmark it

{[ promptMessage ]}

prg1c05 - Chapter 5 Reading SAS Data Sets 5.1 Introduction...

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

View Full Document Right Arrow Icon
1 Chapter 5: Reading SAS Data Sets 5.1 Introduction to Reading Data 5.2 Using SAS Data as Input 5.3 Subsetting Observations and Variables 5.4 Adding Permanent Attributes
Background image of page 1

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

View Full Document Right Arrow Icon
2 Chapter 5: Reading SAS Data Sets 5.1 Introduction to Reading Data 5.1 Introduction to Reading Data 5.2 Using SAS Data as Input 5.3 Subsetting Observations and Variables 5.4 Adding Permanent Attributes
Background image of page 2
3 Objectives Define the concept of reading from a data source to create a SAS data set. Define the business scenario that will be used when reading from a SAS data set, an Excel worksheet, and a raw data file.
Background image of page 3

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

View Full Document Right Arrow Icon
4 Business Scenario An existing data source contains information on Orion Star sales employees from Australia and the United States. A new SAS data set needs to be created that contains a subset of this existing data source. This new SAS data set must contain the following: only the employees from Australia who are Sales Representatives the employee's first name, last name, salary, job title, and hired date labels and formats in the descriptor portion
Background image of page 4
5 Business Scenario Reading SAS Data Sets Reading Excel Worksheets Reading Delimited Raw Data Files
Background image of page 5

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

View Full Document Right Arrow Icon
6 Business Scenario Reading SAS Data Sets Reading Excel Worksheets Reading Delimited Raw Data Files data ; infile ; input ; ... run; libname ; data ; set ; ... run; libname ; data ; set ; ... run;
Background image of page 6
7
Background image of page 7

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

View Full Document Right Arrow Icon
8 5.01 Multiple Answer Poll Which types of files will you read into SAS? a. SAS data sets b. Excel worksheets c. raw data files d. other e. not sure
Background image of page 8
9 Chapter 5: Reading SAS Data Sets 5.1 Introduction to Reading Data 5.2 Using SAS Data as Input 5.2 Using SAS Data as Input 5.3 Subsetting Observations and Variables 5.4 Adding Permanent Attributes
Background image of page 9

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

View Full Document Right Arrow Icon
10 Objectives Use the DATA step to create a SAS data set from an existing SAS data set.
Background image of page 10
11 Business Scenario Reading SAS Data Sets Reading Excel Worksheets Reading Delimited Raw Data Files
Background image of page 11

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

View Full Document Right Arrow Icon
12 Business Scenario Reading SAS Data Sets Reading Excel Worksheets Reading Delimited Raw Data Files data ; infile ; input ; ... run; libname ; data ; set ; ... run; libname ; data ; set ; ... run;
Background image of page 12
13 Business Scenario Syntax Use the following statements to complete the scenario: LIBNAME libref ' SAS-data-library ' ; DATA output-SAS-data-set ; SET input-SAS-data-set ; WHERE where-expression ; KEEP variable-list ; LABEL variable = ' label ' variable = ' label ' variable = ' label ' ; FORMAT variable(s) format ; RUN; LIBNAME libref ' SAS-data-library ' ; DATA output-SAS-data-set ; SET input-SAS-data-set ; WHERE where-expression ; KEEP variable-list ; LABEL variable = ' label ' variable = ' label ' variable = ' label ' ; FORMAT variable(s) format ; RUN; continued...
Background image of page 13

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

View Full Document Right Arrow Icon
14 Business Scenario Syntax Use the following statements to complete the scenario: LIBNAME libref ' SAS-data-library ' ; DATA output-SAS-data-set ; SET input-SAS-data-set ; WHERE where-expression ; KEEP variable-list ; LABEL variable = ' label ' variable = ' label ' variable = ' label ' ; FORMAT variable(s) format ; RUN; LIBNAME libref ' SAS-data-library ' ; DATA output-SAS-data-set ; SET input-SAS-data-set ; WHERE where-expression ; KEEP variable-list ; LABEL variable = ' label ' variable = ' label ' variable = ' label ' ; FORMAT variable(s) format ; RUN; Part 1 Part 3 Part 2
Background image of page 14
15
Background image of page 15

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

View Full Document Right Arrow Icon
Image of page 16
This is the end of the preview. Sign up to access the rest of the document.

{[ snackBarMessage ]}