SAS Program, SAS Log - Example B7 | STAT 479, Exams of Statistics

Material Type: Exam; Professor: Marasinghe; Class: CMPTR PROCESSG DATA; Subject: STATISTICS; University: Iowa State University; Term: Unknown 1989;

Typology: Exams

Pre 2010

Uploaded on 09/02/2009

koofers-user-hy3
koofers-user-hy3 šŸ‡ŗšŸ‡ø

5

(1)

10 documents

1 / 24

Toggle sidebar

This page cannot be seen from the preview

Don't miss anything!

bg1
Example B7
SAS PROGRAM
libname mylib 'C:\Documents and Settings\...\stat479\';
proc univariate data=mylib.fueldat plots normal;
var pop income;
id state;
title 'Use of Proc Univariate to Examine Distributions:1';
run;
proc univariate data=mylib.fueldat cibasic mu0=4 500 trim=2;
var income fuel;
id state;
title 'Use of Proc Univariate to Compute Statistics:2';
run;
proc univariate data=mylib.fueldat noprint;
var fuel percent;
output out=stats pctlpts=33.3 66.7 pctlpre=fuel lic;
title 'Calculation of User Specified Percentile Points';
run;
proc print data=stats;
run;
pf3
pf4
pf5
pf8
pf9
pfa
pfd
pfe
pff
pf12
pf13
pf14
pf15
pf16
pf17
pf18

Partial preview of the text

Download SAS Program, SAS Log - Example B7 | STAT 479 and more Exams Statistics in PDF only on Docsity!

Example

B

SAS^ PROGRAM libname^

mylib^ 'C:\Documents and Settings...\stat479'; proc^ univariate

data=mylib.fueldat

plots^ normal;

var^ pop income;id^ state;title^ 'Use of Proc Univariate to Examine Distributions:1'; run ; proc^ univariate

data=mylib.fueldat

cibasic^

mu0=^4

trim=^2 ;

var^ income fuel;id^ state;title^ 'Use of Proc Univariate to Compute Statistics:2'; run ; proc^ univariate

data=mylib.fueldat

noprint;

var^ fuel percent;output^ out=stats

pctlpts=

33.3^ 66.

pctlpre=fuel lic;

title^ 'Calculation of User Specified Percentile Points'; run ; proc^ print data=stats; run ;

SAS^ Log 1 options

ls=80^ ps=

nodate^ pageno=1;

2 libname

mylib^ 'C:\Documents and Settings\mervyn\My

Documents\Classwork\stat479';

NOTE:^ Libref

MYLIB^ was

successfully assigned

as^ follows:

Engine:^

V

Physical Name:^ C:\Documents

and^ Settings\mervyn\My Documents\Classwork\stat

3 4 proc

univariate

data=mylib.fueldat

plots^ normal;

5 var

pop^ income; 6 id

state; 7 title

'Use^ of^

Proc^ Univariate

to^ Examine

Distributions:1';

8 run;NOTE:^ PROCEDURE

UNIVARIATE

used^ (Total

process time):

real^ time

0.29 seconds cpu^ time

0.04 seconds

9 10 proc

univariate

data=mylib.fueldat

cibasic^

mu0=4^500

trim=2;

11 var

income fuel; 12 id

state; 13 title

'Use^ of^

Proc^ Univariate to

Compute^

Statistics:2';

14 run;NOTE:^ PROCEDURE

UNIVARIATE

used^ (Total

process time):

real^ time

0.09 seconds cpu^ time

0.01 seconds

SAS^ Output

Use^ of^ Proc

Univariate

to^ Examine Distributions: The^ UNIVARIATE

Procedure Variable:

pop^ (Population(in

thousands)) Moments

N^

48 Sum

Weights

Mean^

Sum^ Observations

Std^ Deviation

Variance

Skewness

Kurtosis

Uncorrected

SS^

Corrected

SS^

Coeff^ Variation

Std^ Error^ Mean

Basic Statistical Measures Location

Variability

Mean^

Std^

Deviation

Median^

Variance

Mode^

.^

Range^

Interquartile Range

Tests for Location:

Mu0=

Test^

-Statistic-

-----p Value------

Student's

t^ t^

Pr^ > |t|^

Sign^

M^

24 Pr

>=^ |M|^

Signed^ Rank

S^

588 Pr

>=^ |S|^

Tests^ for

Normality

Test^

--Statistic---

-----p

Value------

Shapiro-Wilk

W^ 0.

Pr^ <

W^ <0.

Kolmogorov-Smirnov

D^

0.^

Pr^ >^ D^

Cramer-von

Mises^

W-Sq^ 0.

Pr^ > W-Sq^ <0.

Anderson-Darling

A-Sq

Pr^ > A-Sq^ <0.

Extreme^ Observations ----------------Lowest---------------Value^ state

Obs

345 Wyoming

462 Vermont

527 Nevada

565 Delaware

579 South

Dakota^

Extreme^ Observations ----------------Highest---------------Value^

state^

Obs

Illinois^

Texas^

Pennsylvania 18366 New York^ 20468 California

Use^ of^ Proc

Univariate

to^ Examine Distributions: The^ UNIVARIATE

Procedure Variable:

pop^ (Population(in

thousands))

Stem^ Leaf

#^

Boxplot

|^ +^ |

|^ |

----+----+----+----+Multiply Stem.Leaf by 10**+

Use^ of^ Proc

Univariate

to^ Examine Distributions: The^ UNIVARIATE

Procedure

Variable:

income (Per^ capita

Income(in

thsnds.)) Moments

N^

48 Sum

Weights

Mean^

Sum^ Observations

Std^ Deviation

Variance

Skewness

Kurtosis

Uncorrected

SS^

Corrected

SS^

Coeff^ Variation

Std^ Error^ Mean

Basic Statistical Measures Location

Variability

Mean^

Std^

Deviation

Median^

Variance

Mode^

Range

Interquartile

Range^

Tests for Location:

Mu0=

Test^

-Statistic-

-----p Value------

Student's

t^ t^

Pr^ > |t|^

Sign^

M^

24 Pr

>=^ |M|^

Signed^ Rank

S^

588 Pr

>=^ |S|^

Tests^ for

Normality

Test^

--Statistic---

-----p

Value------

Shapiro-Wilk

W^ 0.

Pr^ <

W^

Kolmogorov-Smirnov

D^

0.^

Pr^ >^ D^

Cramer-von

Mises^

W-Sq^ 0.

Pr^ > W-Sq^ >0.

Anderson-Darling

A-Sq

Pr^ > A-Sq^ >0.

Extreme^ Observations ----------------Lowest----------------Value^

state^

Obs

3.^

Mississippi

3.^

Alabama^

3.^

Arkansas^

3.^

South^ Carolina

3.^

Louisiana

Extreme^ Observations ----------------Highest---------------Value^

state^

Obs

5.^

New^ Jersey

5.^ Illinois^

5.^

Nevada^

5.^

New^ York^

5.^ Connecticut

Use^ of^ Proc

Univariate

to^ Examine Distributions: The^ UNIVARIATE

Procedure

Variable:

income (Per^ capita

Income(in

thsnds.))

Stem^ Leaf

#^

Boxplot

|^ |

|^ +^ |

|^ |

|^ |

|^ |

|^ |

----+----+----+----+Multiply Stem.Leaf by

Use of^ Proc Univariate

to^ Compute

Statistics:

The^ UNIVARIATE

Procedure

Variable:

income (Per^ capita

Income(in

thsnds.)) Moments

N^

48 Sum

Weights

Mean^

Sum^ Observations

Std^ Deviation

Variance

Skewness

Kurtosis

Uncorrected

SS^

Corrected

SS^

Coeff^ Variation

Std^ Error^ Mean

Basic Statistical Measures Location

Variability

Mean^

Std^

Deviation

Median^

Variance

Mode^

Range

Interquartile

Range^

Basic^ Confidence

Limits^ Assuming

Normality

Parameter

Estimate 95% Confidence Limits

Mean^

4.^

4.^

Std^ Deviation

Variance

0.^

0.^

Tests for Location:

Mu0=

Test^

-Statistic-

-----p Value------

Student's

t^ t^

Pr^ > |t|^

Sign^

M^

7 Pr^

>=^ |M|^

Signed^ Rank

S^

248.^

Pr >=^ |S|

Quantiles

(Definition

Quantile Estimate 100% Max

99%^

95%^

90%^

75% Q^

50% Median

25% Q^

10%^

5%^

1%^

0%^ Min^

Extreme^ Observations ----------------Lowest----------------Value^

state^

Obs

3.^

Mississippi

3.^ Alabama^ 3.^ Arkansas^ 3.^ South^ Carolina 3.^ Louisiana

Extreme^ Observations ----------------Highest---------------Value^

state^

Obs

5.^

New^ Jersey

5.^

Illinois^

5.^

Nevada^

5.^

New York^

5.^

Connecticut

Use of^ Proc Univariate

to^ Compute

Statistics: The^ UNIVARIATE

Procedure

Variable:

fuel^ (Fuel

Consumption

(in^ gallons/person)) Moments

N^

48 Sum

Weights

Mean^

Sum^ Observations

Std^ Deviation

Variance

Skewness

Kurtosis

Uncorrected

SS^

Corrected

SS^

Coeff^ Variation

Std^ Error^ Mean