16. Reading raw data in fixed fields. GIORGIO RUSSOLILLO - Cours de prépara)on à la cer)fica)on SAS «Base Programming» 364

Size: px
Start display at page:

Download "16. Reading raw data in fixed fields. GIORGIO RUSSOLILLO - Cours de prépara)on à la cer)fica)on SAS «Base Programming» 364"

Transcription

1 16. Reading raw data in fixed fields 364

2 Reading raw Dataset: three solu)ons You can mix all of them! Data that SAS cannot read without further informa)on 365

3 Reading standard data with column input: review Using column input you can read standard data arranged in fixed fields (columns) DATA SAS-dataset(s) ; INFILE file-specifica+on <op+ons> ; INPUT variable <$> startcol-endcol ; Features of column input: - You can read fields in any order - You can read character variable values that contain embedded blanks - No placeholder is required for missing data: A blank field is read as missing - Fields or part of fields can be re-read - Fields do not have to be separated by delimiters 366

4 Column input: an example FILENAME import '\\psf\home\documents\my SAS Files\ReadingRawData\Colinput.txt'; DATA imp_colinput; INFILE import; INPUT LastNames $ 1-7 FirstName $ 9-13 JobTitle Salary ; PROC CONTENTS data=imp_colinput; PROC PRINT data=imp_colinput; You can choose the order of the imported fields and/or re-read fields: INPUT FirstName $ 9-13 LastNames $ 1-7 JobTitle Salary ; INPUT FirstName $ 9-13 LastNames $ 1-7 JobTitle JobTitle Salary ; 367

5 Forma{ed Input Using formaned input you can read standard and non standard data arranged in fixed fields (columns), keeping the nice features of the column input INPUT <pointer-control> variable informat ; - pointer-control posi)ons the input pointer on a specified column - variable is the name of the variable - informat is the special instruc)on that specifies how SAS reads the raw data - When using forma{ed input you don t need to specify startcol and endcol - The pointer-control indicates a star)ng point for a field and the informat specifies the length of the field 368

6 Informats - $BINARYw. - $VARYINGw. - $w. - COMMAw.d - DATEw. - DATETIMEw. - HEXw. - JULIANw. - MMDDYYw. - NENGOw. - PDw.d - PERCENTw.d - TIMEw. - w.d INPUT <pointer-control> variable informat ; An informat is an istruc)on that tells to SAS how to read raw data. Note that: - Each informat contains a w value to indicate the width of the raw data field - Each informat also contains a period, which is a required delimiter - For some informats the op)onal value specifies the number of implied decimal places - Informats for reading character data always begin with a dollar sign Among the others.. h{p://support.sas.com/documenta)on/cdl/en/lrdict/64316/html/default/viewer.htm#a htm 369

7 Three Informats $w. : to read character data. - the w represents the total number of columns that contain the raw data field IMPORTANT: In forma{ed input the w represents the width of the field in the raw data file (not in the SAS dataset) w.d : to read standard numeric data. - the w represents the total number of columns that contain the raw data field - the d specifies the number of implied decimal places for the value - the d is not necessary if: - There are no implied decimals - The data already contains a decimal point (in this case d is ignored) COMMAw.d : to read non standard numeric data. - the w represents the total number of columns that contain the raw data field - the d specifies the number of implied decimal places for the value - the d is not necessary if: - There are no implied decimals - The data already contains a decimal point (in this case it is ignored) - It removes embedded: - Blanks, Commas, Dashes, dollar signs, percent signs, right parentheses, le parentheses (which are interpreted as a minus sign)) 370

8 Two «column pointer controls» INPUT <pointer-control> variable informat ; : it moves the input pointer to a specific column number - Default = 1 - +n : it moves the input pointer forward n columns - You can use nota)on +(-n) to move the +n pointer backwards 371

9 Forma{ed input: an example Using pointer: FILENAME import '\\psf\home\documents\my SAS Files\ReadingRawData\Forminput.txt'; DATA imp_forminput; INFILE import; LastNames FirstName JobTitle Salary COMMA10. ; PROC CONTENTS data=imp_colinput; N.B.: informat length = 3 PROC PRINT data=imp_forminput; Using both and +n pointers, inver)ng the fields: FILENAME import '\\psf\home\documents\my SAS Files\ReadingRawData\Forminput.txt'; DATA imp_forminput; INFILE import; INPUT LastNames $7. +1 FirstName $5. +5 Salary JobTitle 3. ; PROC PRINT data=imp_forminput; 372

10 Record Formats How are the file records (rows, observa)ons.. ) organized? The end-of-record marker can be fixed or not Fixed-Length record format files have an end-of-record marker azer a predetermined numbers of columns (typically 80). Variable-Length record format files have an end-of-record marker azer the last field in each record. - These files may cause problems if missing data occurs at the end of a record or when SAS encounters an end-of-record marker before all fields are completely read 373

11 The PAD op)on INFILE file-name PAD ; The op)on PAD pads each record with blanks so that all data lines have the same length. Useful when: missing data occur at the end of the record SAS encounters an end-of-record marker before all the fields are read (because the maximum length of the record is reached) You can change the maximum record length depends on your OS. You can change it by specifying the LRECL= op)on 374

12 The PAD op)on: an example Using the PAD op)on: FILENAME import '\\psf\home\documents\my SAS Files\ReadingRawData\Varlengthinput.txt'; DATA imp_varlengthinput; INFILE import PAD; INPUT Dept Receipts COMMA8.; PROC PRINT data=imp_varlengthinput; 375

13 Specifying a list of variables When using Forma{ed input, you can specify a range of variables in the INPUT statement. In this case the variables names and the informat must be enclosed in parentheses. E.g.: - INPUT (Gio1-Gio3) (6.); 376

17. Reading free-format data. GIORGIO RUSSOLILLO - Cours de prépara)on à la cer)fica)on SAS «Base Programming» 386

17. Reading free-format data. GIORGIO RUSSOLILLO - Cours de prépara)on à la cer)fica)on SAS «Base Programming» 386 17. Reading free-format data 386 Reading free format data: The list input A raw dataset is free-format when it is not arranged in fixed fields. -> Fields are separated by a delimiter List input allows

More information

18. Reading date and )me values. GIORGIO RUSSOLILLO - Cours de prépara)on à la cer)fica)on SAS «Base Programming» 394

18. Reading date and )me values. GIORGIO RUSSOLILLO - Cours de prépara)on à la cer)fica)on SAS «Base Programming» 394 18. Reading date and )me values 394 How SAS stores date values - A SAS date value is stored as the number of days from January 1, 1960, to the given date - A SAS Bme value is stored as the number of seconds

More information

Chapter 2: Getting Data Into SAS

Chapter 2: Getting Data Into SAS Chapter 2: Getting Data Into SAS Data stored in many different forms/formats. Four categories of ways to read in data. 1. Entering data directly through keyboard 2. Creating SAS data sets from raw data

More information

Getting Your Data into SAS The Basics. Math 3210 Dr. Zeng Department of Mathematics California State University, Bakersfield

Getting Your Data into SAS The Basics. Math 3210 Dr. Zeng Department of Mathematics California State University, Bakersfield Getting Your Data into SAS The Basics Math 3210 Dr. Zeng Department of Mathematics California State University, Bakersfield Outline Getting data into SAS -Entering data directly into SAS -Creating SAS

More information

SAS 101. Based on Learning SAS by Example: A Programmer s Guide Chapter 21, 22, & 23. By Tasha Chapman, Oregon Health Authority

SAS 101. Based on Learning SAS by Example: A Programmer s Guide Chapter 21, 22, & 23. By Tasha Chapman, Oregon Health Authority SAS 101 Based on Learning SAS by Example: A Programmer s Guide Chapter 21, 22, & 23 By Tasha Chapman, Oregon Health Authority Topics covered All the leftovers! Infile options Missover LRECL=/Pad/Truncover

More information

REFERENCE SECTION Chapter Chapter Chapter Chapter 237 Chapter Chapter Chapter 7

REFERENCE SECTION Chapter Chapter Chapter Chapter 237 Chapter Chapter Chapter 7 REFERENCE SECTION Chapter 1 SAS Enterprise Guide Basics 159 Chapter 2 Bringing Data into a Project 191 Chapter 3 Changing the Way Data Values Are Displayed 225 Chapter 4 Modifying Data Using the Query

More information

REFERENCE SECTION Chapter Chapter Chapter Chapter 201 Chapter Chapter Chapter Chapter 8

REFERENCE SECTION Chapter Chapter Chapter Chapter 201 Chapter Chapter Chapter Chapter 8 REFERENCE SECTION Chapter 1 SAS Enterprise Guide Basics 133 Chapter 2 Bringing Data into a Project 167 Chapter 3 Changing the Way Data Values Are Displayed 189 Chapter 4 Modifying Data in the Query Builder

More information

Chapter 1 The DATA Step

Chapter 1 The DATA Step Chapter 1 The DATA Step 1.1 Structure of SAS Programs...1-3 1.2 SAS Data Sets... 1-12 1.3 Creating a Permanent SAS Data Set... 1-18 1.4 Writing a SAS DATA Step... 1-24 1.5 Creating a DATA Step View...

More information

SAS Certification Handout #6: Ch

SAS Certification Handout #6: Ch SAS Certification Handout #6: Ch. 16-18 /************ Ch. 16 ******************* /* Suppose we have numeric variables ModelNumber Price Weight Change and date variable Date, plus a string variable Designer

More information

Creation of SAS Dataset

Creation of SAS Dataset Creation of SAS Dataset Contents SAS data step Access to PC files Access to Oracle Access to SQL 2 SAS Data Step Contents Creating SAS data sets from raw data Creating and managing variables 3 Creating

More information

Accessing Data and Creating Data Structures. SAS Global Certification Webinar Series

Accessing Data and Creating Data Structures. SAS Global Certification Webinar Series Accessing Data and Creating Data Structures SAS Global Certification Webinar Series Accessing Data and Creating Data Structures Becky Gray Certification Exam Developer SAS Global Certification Michele

More information

Basic Concept Review

Basic Concept Review Basic Concept Review Quiz Using the Programming Workspace Referencing Files and Setting Options Editing and Debugging SAS Programs End of Review SAS Format Format Formats are variable

More information

Chapter 7 File Access. Chapter Table of Contents

Chapter 7 File Access. Chapter Table of Contents Chapter 7 File Access Chapter Table of Contents OVERVIEW...105 REFERRING TO AN EXTERNAL FILE...105 TypesofExternalFiles...106 READING FROM AN EXTERNAL FILE...107 UsingtheINFILEStatement...107 UsingtheINPUTStatement...108

More information

USING SAS SOFTWARE TO COMPARE STRINGS OF VOLSERS IN A JCL JOB AND A TSO CLIST

USING SAS SOFTWARE TO COMPARE STRINGS OF VOLSERS IN A JCL JOB AND A TSO CLIST USING SAS SOFTWARE TO COMPARE STRINGS OF VOLSERS IN A JCL JOB AND A TSO CLIST RANDALL M NICHOLS, Mississippi Dept of ITS, Jackson, MS ABSTRACT The TRANSLATE function of SAS can be used to strip out punctuation

More information

22S:166. Checking Values of Numeric Variables

22S:166. Checking Values of Numeric Variables 22S:1 Computing in Statistics Lecture 24 Nov. 2, 2016 1 Checking Values of Numeric Variables range checks when you know what the range of possible values is for a given quantitative variable internal consistency

More information

Database Programming with SQL 5-1 Conversion Functions. Copyright 2015, Oracle and/or its affiliates. All rights reserved.

Database Programming with SQL 5-1 Conversion Functions. Copyright 2015, Oracle and/or its affiliates. All rights reserved. Database Programming with SQL 5-1 Objectives This lesson covers the following objectives: Provide an example of an explicit data-type conversion and an implicit data-type conversion Explain why it is important,

More information

MARK CARPENTER, Ph.D.

MARK CARPENTER, Ph.D. MARK CARPENTER, Ph.D. Module 1 : THE DATA STEP (1, 2, 3) Keywords : DATA, INFILE, INPUT, FILENAME, DATALINES Procedures : PRINT Pre-Lecture Preparation: create directory on your local hard drive called

More information

2. Referencing Files and Sepng Op+ons. GIORGIO RUSSOLILLO - Cours de prépara+on à la cer+fica+on SAS «Base Programming» 47

2. Referencing Files and Sepng Op+ons. GIORGIO RUSSOLILLO - Cours de prépara+on à la cer+fica+on SAS «Base Programming» 47 2. Referencing Files and Sepng Op+ons GIORGIO RUSSOLILLO - Cours de prépara+on à la cer+fica+on SAS «Base Programming» 47 Defining SAS libraries To reference a permanent SAS file you: - Assign a name (libref)

More information

Introduction OR CARDS. INPUT DATA step OUTPUT DATA 8-1

Introduction OR CARDS. INPUT DATA step OUTPUT DATA 8-1 Introduction Thus far, all the DATA step programs we have seen have involved reading and writing only SAS data sets. In this chapter we will present techniques to read and write external or "raw" files

More information

SAS Data Libraries. Objectives. Airline Data Library. SAS Data Libraries. SAS Data Libraries FILES LIBRARIES

SAS Data Libraries. Objectives. Airline Data Library. SAS Data Libraries. SAS Data Libraries FILES LIBRARIES Reading Raw Data, Formats and Data Types 2.1 SAS Data Libraries 2.2 SAS List Reports from SAS Data Sets 2.3 Formats in SAS 2.4 Reading Raw Data into SAS 2.5 Minitab List Reports from Minitab Worksheets

More information

9. Producing HTML output. GIORGIO RUSSOLILLO - Cours de prépara+on à la cer+fica+on SAS «Base Programming» 207

9. Producing HTML output. GIORGIO RUSSOLILLO - Cours de prépara+on à la cer+fica+on SAS «Base Programming» 207 9. Producing HTML output 207 The Output Delivery System (ODS) With ODS, you can easily create output in a variety of formats including: - HyperText Markup Language (HTML) output - RTF output - PDF output

More information

DSCI 325: Handout 2 Getting Data into SAS Spring 2017

DSCI 325: Handout 2 Getting Data into SAS Spring 2017 DSCI 325: Handout 2 Getting Data into SAS Spring 2017 Data sets come in many different formats. In some situations, data sets are stored on paper (e.g., surveys) and other times data are stored in huge

More information

Welcome to Top 10 SAS Functions

Welcome to Top 10 SAS Functions Welcome to Top 10 SAS Functions Goal and Agenda By the end of this meeting, you will understand 10 key SAS functions purpose, value and features. What are SAS functions? Why use them? Use Case Manipulating

More information

9. Producing HTML output. GIORGIO RUSSOLILLO - Cours de prépara+on à la cer+fica+on SAS «Base Programming» 208

9. Producing HTML output. GIORGIO RUSSOLILLO - Cours de prépara+on à la cer+fica+on SAS «Base Programming» 208 9. Producing HTML output 208 The Output Delivery System (ODS) With ODS, you can easily create output in a variety of formats including: - HyperText Markup Language (HTML) output - RTF output - PDF output

More information

Unit 4. Input/Output Functions

Unit 4. Input/Output Functions Unit 4 Input/Output Functions Introduction to Input/Output Input refers to accepting data while output refers to presenting data. Normally the data is accepted from keyboard and is outputted onto the screen.

More information

The INPUT Statement: Where

The INPUT Statement: Where The INPUT Statement: Where It's @ Ronald Cody, Ed.D. Robert Wood Johnson Medical School Introduction One of the most powerful features of SAS software is the ability to read data in almost any form. For

More information

Importing Part Information in Sage BusinessWorks 2012

Importing Part Information in Sage BusinessWorks 2012 Importing Part Information in Sage BusinessWorks 2012 Sage BusinessWorks Accounting import format requirements: 1. The import file must be in a comma delimited variable (.CSV) text format. Each field can

More information

work.test temp.test sasuser.test test

work.test temp.test sasuser.test test DSCI 325 Midterm Practice Test Spring 2017 Name: 1. Consider the following four names used to create a SAS data set: work.test temp.test sasuser.test test How many of these will be stored as permanent

More information

Informats. Informats Under UNIX. HEXw. informat. $HEXw. informat. Details CHAPTER 13

Informats. Informats Under UNIX. HEXw. informat. $HEXw. informat. Details CHAPTER 13 207 CHAPTER 13 Informats Informats Under UNIX 207 Informats Under UNIX This chapter describes SAS informats that have behavior or syntax this is specific to UNIX environments. Each informat description

More information

Formats and the Format Procedure

Formats and the Format Procedure Formats and the Format Procedure Assigning Formats for Display While labels are used to change how a variable name is displayed, formats are used to change how data values are displayed. Formats are assigned

More information

INTRODUCTION TO SAS HOW SAS WORKS READING RAW DATA INTO SAS

INTRODUCTION TO SAS HOW SAS WORKS READING RAW DATA INTO SAS TO SAS NEED FOR SAS WHO USES SAS WHAT IS SAS? OVERVIEW OF BASE SAS SOFTWARE DATA MANAGEMENT FACILITY STRUCTURE OF SAS DATASET SAS PROGRAM PROGRAMMING LANGUAGE ELEMENTS OF THE SAS LANGUAGE RULES FOR SAS

More information

ERROR: ERROR: ERROR:

ERROR: ERROR: ERROR: ERROR: ERROR: ERROR: Formatting Variables: Back and forth between character and numeric Why should you care? DATA name1; SET name; if var = Three then delete; if var = 3 the en delete; if var = 3 then

More information

Using an ICPSR set-up file to create a SAS dataset

Using an ICPSR set-up file to create a SAS dataset Using an ICPSR set-up file to create a SAS dataset Name library and raw data files. From the Start menu, launch SAS, and in the Editor program, write the codes to create and name a folder in the SAS permanent

More information

ECLT 5810 SAS Programming - Introduction

ECLT 5810 SAS Programming - Introduction ECLT 5810 SAS Programming - Introduction Why SAS? Able to process data set(s). Easy to handle multiple variables. Generate useful basic analysis Summary statistics Graphs Many companies and government

More information

Reading data in SAS and Descriptive Statistics

Reading data in SAS and Descriptive Statistics P8130 Recitation 1: Reading data in SAS and Descriptive Statistics Zilan Chai Sep. 18 th /20 th 2017 Outline Intro to SAS (windows, basic rules) Getting Data into SAS Descriptive Statistics SAS Windows

More information

ASSIGNMENT #2 ( *** ANSWERS ***) 1

ASSIGNMENT #2 ( *** ANSWERS ***) 1 ASSIGNMENT #2 ( *** ANSWERS ***) 1 * problem #1 *** WHERE WILL THE PERMANENT SAS DATA SET BE WRITTEN libname x 'i:\' CREATE A PERMANENT SAS DATA SET NAMED CLINICAL USE AN INFILE STATEMENT TO TELL SAS WHERE

More information

Getting Information from a Table

Getting Information from a Table ch02.fm Page 45 Wednesday, April 14, 1999 2:44 PM Chapter 2 Getting Information from a Table This chapter explains the basic technique of getting the information you want from a table when you do not want

More information

WKn Chapter. Note to UNIX and OS/390 Users. Import/Export Facility CHAPTER 9

WKn Chapter. Note to UNIX and OS/390 Users. Import/Export Facility CHAPTER 9 117 CHAPTER 9 WKn Chapter Note to UNIX and OS/390 Users 117 Import/Export Facility 117 Understanding WKn Essentials 118 WKn Files 118 WKn File Naming Conventions 120 WKn Data Types 120 How the SAS System

More information

BEYOND FORMAT BASICS 1

BEYOND FORMAT BASICS 1 BEYOND FORMAT BASICS 1 CNTLIN DATA SETS...LABELING VALUES OF VARIABLE One common use of a format in SAS is to assign labels to values of a variable. The rules for creating a format with PROC FORMAT are

More information

Lecture 1 Getting Started with SAS

Lecture 1 Getting Started with SAS SAS for Data Management, Analysis, and Reporting Lecture 1 Getting Started with SAS Portions reproduced with permission of SAS Institute Inc., Cary, NC, USA Goals of the course To provide skills required

More information

Write SAS Code to Generate Another SAS Program A Dynamic Way to Get Your Data into SAS

Write SAS Code to Generate Another SAS Program A Dynamic Way to Get Your Data into SAS Paper 175-29 Write SAS Code to Generate Another SAS Program A Dynamic Way to Get Your Data into SAS Linda Gau, Pro Unlimited @ Genentech, Inc., South San Francisco, CA ABSTRACT In this paper we introduce

More information

Simple sets of data can be expressed in a simple table, much like a

Simple sets of data can be expressed in a simple table, much like a Chapter 1: Building Master and Detail Pages In This Chapter Developing master and detail pages at the same time Building your master and detail pages separately Putting together master and detail pages

More information

The steps to create Table1 using Microsoft Excel are illustrated on the following pages.

The steps to create Table1 using Microsoft Excel are illustrated on the following pages. Tables can be created in Microsoft Excel in three ways: (1) Simply by typing in the data in the columns and rows of the spread sheet. Then add the appropriate table headings and applying boarders were

More information

Formats. Formats Under UNIX. HEXw. format. $HEXw. format. Details CHAPTER 11

Formats. Formats Under UNIX. HEXw. format. $HEXw. format. Details CHAPTER 11 193 CHAPTER 11 Formats Formats Under UNIX 193 Formats Under UNIX This chapter describes SAS formats that have behavior or syntax that is specific to UNIX environments. Each format description includes

More information

STAT:5400 Computing in Statistics

STAT:5400 Computing in Statistics STAT:5400 Computing in Statistics Introduction to SAS Lecture 18 Oct 12, 2015 Kate Cowles 374 SH, 335-0727 kate-cowles@uiowaedu SAS SAS is the statistical software package most commonly used in business,

More information

Notes on Chapter 1 Variables and String

Notes on Chapter 1 Variables and String Notes on Chapter 1 Variables and String Note 0: There are two things in Python; variables which can hold data and the data itself. The data itself consists of different kinds of data. These include numbers,

More information

University of Texas at Arlington, TX, USA

University of Texas at Arlington, TX, USA Dept. of Computer Science and Engineering University of Texas at Arlington, TX, USA A file is a collec%on of data that is stored on secondary storage like a disk or a thumb drive. Accessing a file means

More information

You can use Dreamweaver to build master and detail Web pages, which

You can use Dreamweaver to build master and detail Web pages, which Chapter 1: Building Master and Detail Pages In This Chapter Developing master and detail pages at the same time Building your master and detail pages separately Putting together master and detail pages

More information

chapter 2 G ETTING I NFORMATION FROM A TABLE

chapter 2 G ETTING I NFORMATION FROM A TABLE chapter 2 Chapter G ETTING I NFORMATION FROM A TABLE This chapter explains the basic technique for getting the information you want from a table when you do not want to make any changes to the data and

More information

The Programmer's Solution to the Import/Export Wizard

The Programmer's Solution to the Import/Export Wizard The Programmer's Solution to the Import/Export Wizard Lora D. Delwiche, University of California, Davis, CA Susan J. Slaughter, SAS Consultant, Davis, CA Abstract Do you like what the Import/Export Wizard

More information

Stamina Software Pty Ltd. TRAINING MANUAL Viságe BIT VIEWER

Stamina Software Pty Ltd. TRAINING MANUAL Viságe BIT VIEWER Stamina Software Pty Ltd TRAINING MANUAL Viságe BIT VIEWER Version: 3 31 st October 2011 Viságe BIT Viewer TABLE OF CONTENTS VISÁGE BIT VIEWER... 2 ELEMENTS OF THE VISÁGE BIT VIEWER SCREEN... 3 TITLE...

More information

proc print data=account; <insert statement here> run;

proc print data=account; <insert statement here> run; Statistics 6250 Name: Fall 2012 (print: first last ) Prof. Fan NetID #: Midterm Three Instructions: This is an in-class and open book midterm. You must write your answers on the provide spaces. Give concise

More information

SAS PROGRAMMING AND APPLICATIONS (STAT 5110/6110): FALL 2015 Module 2

SAS PROGRAMMING AND APPLICATIONS (STAT 5110/6110): FALL 2015 Module 2 SAS PROGRAMMING AND APPLICATIONS (STAT 5110/6110): FALL 2015 Department of MathemaGcs and StaGsGcs Phone: 4-3620 Office: Parker 364- A E- mail: carpedm@auburn.edu Web: hup://www.auburn.edu/~carpedm/stat6110

More information

What Is New in CSI-Data-Miner 6.0A and B?

What Is New in CSI-Data-Miner 6.0A and B? Data-Miner 6.0A "Auto" and "Task" mode scripts Data-Miner will now run in either "Auto" mode or "Task" mode. Auto is the way that previous versions of Data-Miner have operated with reading and writing

More information

Bluepoint AIS File Export PS_BPAIS Application 13352

Bluepoint AIS File Export PS_BPAIS Application 13352 Bluepoint AIS File Export PS_BPAIS Application 13352 Bluepoint AIS File Export 2011-2014 Fiserv, Inc. or its affiliates. All rights reserved. This work is confidential and its use is strictly limited.

More information

Other Data Sources SAS can read data from a variety of sources:

Other Data Sources SAS can read data from a variety of sources: Other Data Sources SAS can read data from a variety of sources: Plain text files, including delimited and fixed-column files Spreadsheets, such as Excel Databases XML Others Text Files Text files of various

More information

Use That SAP to Write Your Code Sandra Minjoe, Genentech, Inc., South San Francisco, CA

Use That SAP to Write Your Code Sandra Minjoe, Genentech, Inc., South San Francisco, CA Paper DM09 Use That SAP to Write Your Code Sandra Minjoe, Genentech, Inc., South San Francisco, CA ABSTRACT In this electronic age we live in, we usually receive the detailed specifications from our biostatistician

More information

MISSOVER, TRUNCOVER, and PAD, OH MY!! or Making Sense of the INFILE and INPUT Statements. Randall Cates, MPH, Technical Training Specialist

MISSOVER, TRUNCOVER, and PAD, OH MY!! or Making Sense of the INFILE and INPUT Statements. Randall Cates, MPH, Technical Training Specialist MISSOVER, TRUNCOVER, and PAD, OH MY!! or Making Sense of the INFILE and INPUT Statements. Randall Cates, MPH, Technical Training Specialist ABSTRACT The SAS System has many powerful tools to store, analyze

More information

SAS Certification Handout #7: Ch

SAS Certification Handout #7: Ch SAS Certification Handout #7: Ch. 19-21 /************ Ch. 19 ********************/ /* Consider a mailing list example, partial from http://mlb.mlb.com/team/ 1---+----10---+----20---+ Kansas City Royals

More information

Objective 1: Familiarize yourself with basic database terms and definitions. Objective 2: Familiarize yourself with the Access environment.

Objective 1: Familiarize yourself with basic database terms and definitions. Objective 2: Familiarize yourself with the Access environment. Beginning Access 2007 Objective 1: Familiarize yourself with basic database terms and definitions. What is a Database? A Database is simply defined as a collection of related groups of information. Things

More information

15. Processing variables with arrays. GIORGIO RUSSOLILLO - Cours de prépara)on à la cer)fica)on SAS «Base Programming» 343

15. Processing variables with arrays. GIORGIO RUSSOLILLO - Cours de prépara)on à la cer)fica)on SAS «Base Programming» 343 15. Processing variables with arrays 343 SAS Arrays A SAS array is a temporary grouping of SAS variables under a single name. It exists only for the dura)on of the DATA step Useful for processing several

More information

12. Combining SAS datasets. GIORGIO RUSSOLILLO - Cours de prépara)on à la cer)fica)on SAS «Base Programming» 269

12. Combining SAS datasets. GIORGIO RUSSOLILLO - Cours de prépara)on à la cer)fica)on SAS «Base Programming» 269 12. Combining SAS datasets 269 Appending datasets in different situa)ons PROC PRINT DATA=Lib9_3.emps; PROC PRINT DATA=Lib9_3.emps2008; PROC PRINT DATA=Lib9_3.emps2009; PROC PRINT DATA=Lib9_3.emps2010;

More information

Importing CSV Data to All Character Variables Arthur L. Carpenter California Occidental Consultants, Anchorage, AK

Importing CSV Data to All Character Variables Arthur L. Carpenter California Occidental Consultants, Anchorage, AK PharmaSUG 2017 QT02 Importing CSV Data to All Character Variables Arthur L. Carpenter California Occidental Consultants, Anchorage, AK ABSTRACT Have you ever needed to import data from a CSV file and found

More information

CS102: Standard I/O. %<flag(s)><width><precision><size>conversion-code

CS102: Standard I/O. %<flag(s)><width><precision><size>conversion-code CS102: Standard I/O Our next topic is standard input and standard output in C. The adjective "standard" when applied to "input" or "output" could be interpreted to mean "default". Typically, standard output

More information

six hundred ninety-two

six hundred ninety-two 27 CHAPTER 5 Formats Definition 27 Syntax 27 Using Formats 28 Ways to Specify Formats 28 PUT Statement 29 PUT Function 29 %SYSFUNC 29 FORMAT Statement 29 ATTRIB Statement 30 Permanent versus Temporary

More information

Arithmetic Expressions 9/7/16 44

Arithmetic Expressions 9/7/16 44 Arithmetic Expressions 9/7/16 44 Roundoff Errors Floa,ng point values are not exact This is a limita,on of binary values; not all floa,ng point numbers have an exact representa,on Open PyCharm, open a

More information

More Skills 11 Format and Position Report Controls

More Skills 11 Format and Position Report Controls = CHAPTER 5 Access More Skills 11 Format and Position Report Controls Controls can be aligned using buttons on the Ribbon. Using the Ribbon s alignment tools can be quicker and more accurate than positioning

More information

11. Reading SAS datasets. GIORGIO RUSSOLILLO - Cours de prépara)on à la cer)fica)on SAS «Base Programming» 242

11. Reading SAS datasets. GIORGIO RUSSOLILLO - Cours de prépara)on à la cer)fica)on SAS «Base Programming» 242 11. Reading SAS datasets 242 Reading a single SAS dataset DATA SAS-dataset; SET SAS-dataset; ; - SAS-dataset in the DATA statement is the name (libref.filename) of the dataset to be

More information

Using Maps with the JSON LIBNAME Engine in SAS Andrew Gannon, The Financial Risk Group, Cary NC

Using Maps with the JSON LIBNAME Engine in SAS Andrew Gannon, The Financial Risk Group, Cary NC Paper 1734-2018 Using Maps with the JSON LIBNAME Engine in SAS Andrew Gannon, The Financial Risk Group, Cary NC ABSTRACT This paper serves as an introduction to reading JSON data via the JSON LIBNAME engine

More information

SAS/FSP 9.2. Procedures Guide

SAS/FSP 9.2. Procedures Guide SAS/FSP 9.2 Procedures Guide The correct bibliographic citation for this manual is as follows: SAS Institute Inc. 2008. SAS/FSP 9.2 Procedures Guide. Cary, NC: SAS Institute Inc. SAS/FSP 9.2 Procedures

More information

FSEDIT Procedure Windows

FSEDIT Procedure Windows 25 CHAPTER 4 FSEDIT Procedure Windows Overview 26 Viewing and Editing Observations 26 How the Control Level Affects Editing 27 Scrolling 28 Adding Observations 28 Entering and Editing Variable Values 28

More information

ACCESS Procedure Reference

ACCESS Procedure Reference 59 CHAPTER 5 ACCESS Procedure Reference Introduction 59 Case Sensitivity in the ACCESS Procedure 60 ACCESS Procedure 60 Description 61 PROC ACCESS Statement Options 62 Options 62 SAS System Passwords for

More information

Getting Started with the XML Engine

Getting Started with the XML Engine 3 CHAPTER 1 Getting Started with the XML Engine What Does the XML Engine Do? 3 Understanding How the XML Engine Works 3 Assigning a Libref to an XML Document 3 Importing an XML Document 4 Exporting an

More information

Contents. Overview How SAS processes programs Compilation phase Execution phase Debugging a DATA step Testing your programs

Contents. Overview How SAS processes programs Compilation phase Execution phase Debugging a DATA step Testing your programs SAS Data Step Contents Overview How SAS processes programs Compilation phase Execution phase Debugging a DATA step Testing your programs 2 Overview Introduction This section teaches you what happens "behind

More information

68000 Assembler by Paul McKee. User's Manual

68000 Assembler by Paul McKee. User's Manual Contents 68000 Assembler by Paul McKee User's Manual 1 Introduction 2 2 Source Code Format 2 2.1 Source Line Format............................... 2 2.1.1 Label Field............................... 2 2.1.2

More information

Tips for working efficiently with Excel's fill handle

Tips for working efficiently with Excel's fill handle Tips for working efficiently with Excel's fill handle The fill handle is a remarkably useful Excel tool. Here are some techniques that should be useful to the average Excel user. Excel s fill handle is

More information

Template Versatility Using SAS Macro Language to Generate Dynamic RTF Reports Patrick Leon, MPH

Template Versatility Using SAS Macro Language to Generate Dynamic RTF Reports Patrick Leon, MPH Versatility Using SAS Macro Language to Generate Dynamic RTF Reports Versatility Using SAS Macro Language to Generate Dynamic RTF Reports ABSTRACT SAS Macro Language can be used to enhance many report-generating

More information

Unit 4. Scalar Functions and Arithmetic

Unit 4. Scalar Functions and Arithmetic Unit 4. Scalar Functions and Arithmetic What This Unit Is About Scalar functions can be used to manipulate column or expression values. This unit will discuss the format and syntax of basic scalar functions.

More information

WRITE SAS CODE TO GENERATE ANOTHER SAS PROGRAM

WRITE SAS CODE TO GENERATE ANOTHER SAS PROGRAM WRITE SAS CODE TO GENERATE ANOTHER SAS PROGRAM A DYNAMIC WAY TO GET YOUR DATA INTO THE SAS SYSTEM Linda Gau, ProUnlimited, South San Francisco, CA ABSTRACT In this paper we introduce a dynamic way to create

More information

CS101: Fundamentals of Computer Programming. Dr. Tejada www-bcf.usc.edu/~stejada Week 1 Basic Elements of C++

CS101: Fundamentals of Computer Programming. Dr. Tejada www-bcf.usc.edu/~stejada Week 1 Basic Elements of C++ CS101: Fundamentals of Computer Programming Dr. Tejada stejada@usc.edu www-bcf.usc.edu/~stejada Week 1 Basic Elements of C++ 10 Stacks of Coins You have 10 stacks with 10 coins each that look and feel

More information

Course contents. Overview: Goodbye, calculator. Lesson 1: Get started. Lesson 2: Use cell references. Lesson 3: Simplify formulas by using functions

Course contents. Overview: Goodbye, calculator. Lesson 1: Get started. Lesson 2: Use cell references. Lesson 3: Simplify formulas by using functions Course contents Overview: Goodbye, calculator Lesson 1: Get started Lesson 2: Use cell references Lesson 3: Simplify formulas by using functions Overview: Goodbye, calculator Excel is great for working

More information

SUGI 29 Data Warehousing, Management and Quality

SUGI 29 Data Warehousing, Management and Quality Building a Purchasing Data Warehouse for SRM from Disparate Procurement Systems Zeph Stemle, Qualex Consulting Services, Inc., Union, KY ABSTRACT SAS Supplier Relationship Management (SRM) solution offers

More information

Using Custom Number Formats

Using Custom Number Formats APPENDIX B Using Custom Number Formats Although Excel provides a good variety of built-in number formats, you may find that none of these suits your needs. This appendix describes how to create custom

More information

Chapter 2 The Design Window

Chapter 2 The Design Window Chapter 2 Objectives Chapter 2 The Design Window Learn about Crystal sections Move objects Use Toolbars, Icons, and Menus Format fields Add Special Fields Change a Group Use the Crystal Field Explorer

More information

Find2000: A Search Tool to Find Date-Related Strings in SAS

Find2000: A Search Tool to Find Date-Related Strings in SAS Find2000: A Search Tool to Find Date-Related Strings in SAS Sarah L. Mitchell, Qualex Consulting Services, Inc. Michael Gilman, Qualex Consulting Services, Inc. Figure 1 Abstract Although SAS Version 6

More information

Mobile Forms Integrator

Mobile Forms Integrator Mobile Forms Integrator Introduction Mobile Forms Integrator allows you to connect the ProntoForms service (www.prontoforms.com) with your accounting or management software. If your system can import a

More information

PASS4TEST. IT Certification Guaranteed, The Easy Way! We offer free update service for one year

PASS4TEST. IT Certification Guaranteed, The Easy Way!  We offer free update service for one year PASS4TEST IT Certification Guaranteed, The Easy Way! \ http://www.pass4test.com We offer free update service for one year Exam : A00-201 Title : SAS base programming exam Vendors : SASInstitute Version

More information

Open VMS SUMSLP Utility Manual

Open VMS SUMSLP Utility Manual Open VMS SUMSLP Utility Manual Order Number: AA PS6EA TE May 1993 SUMSLP is a batch-oriented editor that allows multiple update files to be applied to a single input file. Revision/Update Information:

More information

SAIL Address-level Export File Structure & Data Transfer

SAIL Address-level Export File Structure & Data Transfer SAIL Address-level Export File Structure & Data Transfer Introduction The SAIL Databank is a central repository containing anonymised person-level and address-level data drawn from operational and national

More information

Writing Programs in SAS Data I/O in SAS

Writing Programs in SAS Data I/O in SAS Writing Programs in SAS Data I/O in SAS Statistics 135 Autumn 2005 Copyright c 2005 by Mark E. Irwin Writing SAS Programs Your SAS programs can be written in any text editor, though you will often want

More information

SQL Server 2008 Tutorial 3: Database Creation

SQL Server 2008 Tutorial 3: Database Creation SQL Server 2008 Tutorial 3: Database Creation IT 5101 Introduction to Database Systems J.G. Zheng Fall 2011 DDL Action in SQL Server Creating and modifying structures using the graphical interface Table

More information

Introduction to SAS Mike Zdeb ( , #1

Introduction to SAS Mike Zdeb ( , #1 Mike Zdeb (402-6479, msz03@albany.edu) #1 (1) INTRODUCTION Once, the acronym SAS actually did stand for Statistical Analysis System. Now, when you use the term SAS, you are referring to a collection of

More information

Unit 2 Fine-tuning Spreadsheets, Functions (AutoSum)

Unit 2 Fine-tuning Spreadsheets, Functions (AutoSum) Unit 2 Fine-tuning Spreadsheets, Functions (AutoSum) Manually adjust column width Place the pointer on the line between letters in the Column Headers. The pointer will change to double headed arrow. Hold

More information

Introduction to SAS Programs. Objectives. SAS Programs. Sample Data. File Containing Data: boxhunter.dat

Introduction to SAS Programs. Objectives. SAS Programs. Sample Data. File Containing Data: boxhunter.dat Introduction to Statistical omputing SS, Minitab, and xcel Simple ata ntry and asic Reporting 1.1 Introduction to SS Programs 1.2 Introduction to Minitab Programs 1.3 Introduction to xcel Spreadsheets

More information

Contents. About This Book...1

Contents. About This Book...1 Contents About This Book...1 Chapter 1: Basic Concepts...5 Overview...6 SAS Programs...7 SAS Libraries...13 Referencing SAS Files...15 SAS Data Sets...18 Variable Attributes...21 Summary...26 Practice...28

More information

Accessibility Features in the SAS Intelligence Platform Products

Accessibility Features in the SAS Intelligence Platform Products 1 CHAPTER 1 Overview of Common Data Sources Overview 1 Accessibility Features in the SAS Intelligence Platform Products 1 SAS Data Sets 1 Shared Access to SAS Data Sets 2 External Files 3 XML Data 4 Relational

More information

Econ Stata Tutorial I: Reading, Organizing and Describing Data. Sanjaya DeSilva

Econ Stata Tutorial I: Reading, Organizing and Describing Data. Sanjaya DeSilva Econ 329 - Stata Tutorial I: Reading, Organizing and Describing Data Sanjaya DeSilva September 8, 2008 1 Basics When you open Stata, you will see four windows. 1. The Results window list all the commands

More information

Unit 2 Fine-tuning Spreadsheets, Functions (AutoSum)

Unit 2 Fine-tuning Spreadsheets, Functions (AutoSum) Unit 2 Fine-tuning Spreadsheets, Functions (AutoSum) Select a Row or a Column Place your pointer over the Column Header (gray cell at the top of a column that contains a letter identifying the column)

More information

Effective use of functions for F5-F9 CBEs

Effective use of functions for F5-F9 CBEs Effective use of functions for F5-F9 CBEs On-demand and session CBEs On-demand CBE (F1-F4) Session CBEs (F5-F9) Can be taken at any time Available during the March, June, September and December exam weeks.

More information

Excel Formulas 2018 Cindy Kredo Page 1 of 23

Excel Formulas 2018 Cindy Kredo Page 1 of 23 Excel file: Excel_Formulas_BeyondIntro_Data.xlsx Lab One: Sumif, AverageIf and Countif Goal: On the Demographics tab add formulas in Cells C32, D32 and E32 using the above functions. Use the cross-hair

More information