Academic Integrity: tutoring, explanations, and feedback — we don’t complete graded work or submit on a student’s behalf.

1. Consider the following small data set: Kane 28 12 2005 12 25 Ambler 22 12 200

ID: 3068629 • Letter: 1

Question

1. Consider the following small data set: Kane 28 12 2005 12 25 Ambler 22 12 2005 8 28 Kane 20 01 2806 13 32 Oakey 32 12 2805 30 5e Oakey 32 1 2806 25 45 Ambler 22 01 2806 15 28 Assume that the columns, from left to right, represent one character variable (town name) and five numeric variables (town number, month, year, low daytime temperature (in degrees F) and high daytime temperature (in degrees F)). a. Use column input to read the data ino a permanent SAS data set by reading the data instream. Print the data set. b. Create a temporary SAS data set from the permanent SAS data set created in part (a). Print the data set.

Explanation / Answer

creat one permanent library in your C drive

to read and write sas datasets.

a. Use column input to read the data ino a permanent SAS data set by reading the data instream. Print the data set.

SAS Code is give below

libname mylib 'C:My SAS Datasets';

data mylib.ds1;

input town_name $ 1-6 town_no 8-9 month 11-12 year 14-17 low_ temp 19-20 high_temp 22-23;

cards;

;

run;

proc print data=mylib.ds1;

run;

Solutionb:

Create a temporary SAS data set from the permanent SAS data set created in part (a). Print the data set.

use set statement

SAS Code is given below:

data ds2;

set mylib.ds1;

run;

proc print data=ds2;

run;