SlideShare a Scribd company logo
PROC STANDARD
   SAS FUNCTIONS
   SAS OPERATIONS
        Canicia Smith
  caniciasmith@gmail.com
Office hour: Wed 13:00-14:00
PROC STANDARD
What does proc standard do?
1. It standardizes variables in a data set to a
given mean and standard deviation.
2. It creates a new data set containing the
standardized values




http://support.sas.com/documentation/cdl/en/proc/61895/HTM
L/default/viewer.htm#a000146748.htm
Example




New data set
SAS FUNCTIONS
SAMPLE STATISTICS
Mean
=Mean(var1, var2)
Sum
=Sum(var1, var2)
Square root
=Sqrt(var)
Round
=round(var, .1)
SAMPLE STATISTICS (con.)
Max
max(argument1, argument2)
Min
min(argument1, argument2)
Mod
mod(argument1,argument-2)
Eg. 9/3
Argument1- the dividend=9
Argument2-the divisor=3
LOG
• Log
X=log(var);
PROBABILITY
Ex. Poisson probability distribution
cdf (‘POISSON’, n, m)
N is an integer random variable (range: n=0,1, ..)
M is a numeric mean parameter (range: m>0)
EXPONENTIAL
• Exponential x=exp(1.0)=2.718
exp (argument)
SAS OPERATORS
SAS OPERATORS (ARITHMETIC)

Symbol     Definition     Example
         raise to a
  **                       a**3
         power
  *      multiplication     2*y
  /      division          var/5
  +      addition         num+3
                           var1-
  -      subtraction
                           var2
SAS OPERATORS (COMPARISON)
Symbo    Mnemonic
                          Definition          Example
l        Equivalent
  =         EQ        equal to                  a=3
 ^=         NE        not equal to             a ne 3
  >         GT        greater than             num>5
  <         LT        less than                num<5
                      greater than or equal
 >=         GE                                var>=300
                      to
 <=         LE        less than or equal to   var<=300
                                             num in (3, 4,
 IN          IN       equal to one of a list
                                                 5)
SAS OPERATORS (LOGICAL)

Symbol    Mnemonic Equivalent    Example
   &             AND            (a>b) & (c>d)

   /              OR            (a>b) / (c>d)

   ^             NOT              not (a>b)
QUESTIONS~?????
Possible Exam questions
         Create a data set to give this output.
    Which statement should be inserted to
    produce the group output?
Create a data set to get this output..
Proc means
     What statement would produce
     the following output?
What statements do you need to produce the second
output?
5 students name John (boy), Mary (girl), Dick (boy),
Lucy (girl), and James (boy) has the following scores in
the following subjects:
                      Names
Subject   John   Mary Dick Lucy   James
Math      90     80   78   74     70
English   96     60   78   50     74
French    87     87   56   78     95
Physics 45       65   34   77     73
History 77       66   88   56     89




1. Write a sas program to output this data.
2. Find the mean and sum of each student’s grades.

More Related Content

What's hot

Composition Of Functions
Composition Of FunctionsComposition Of Functions
Composition Of Functions
sjwong
 
Relations and functions
Relations and functionsRelations and functions
Relations and functions
Dreams4school
 
Lesson 3 Operation on Functions
Lesson 3 Operation on FunctionsLesson 3 Operation on Functions
Lesson 3 Operation on Functions
Shann Ashequielle Blasurca
 
L3 functions operations
L3 functions operationsL3 functions operations
L3 functions operations
James Tagara
 
Function and Its Types.
Function and Its Types.Function and Its Types.
Function and Its Types.
Awais Bakshy
 
2.4 operations on functions
2.4 operations on functions2.4 operations on functions
2.4 operations on functions
hisema01
 
Polynomial functions
Polynomial functionsPolynomial functions
Polynomial functions
RossLee20
 
Evaluating functions
Evaluating functionsEvaluating functions
Evaluating functions
REYEMMANUELILUMBA
 
composite functions
composite functionscomposite functions
composite functions
Glory Codilla
 
Operation on functions
Operation on functionsOperation on functions
Operation on functions
Jeralyn Obsina
 
Operations With Functions May 25 2009
Operations With Functions May 25 2009Operations With Functions May 25 2009
Operations With Functions May 25 2009
ingroy
 
4 2 operations on functions
4 2 operations on functions4 2 operations on functions
4 2 operations on functions
hisema01
 
Function Operations
Function OperationsFunction Operations
Function Operations
swartzje
 
Jan. 6 Inverse Functions
Jan. 6 Inverse FunctionsJan. 6 Inverse Functions
Jan. 6 Inverse Functions
RyanWatt
 
Functions
FunctionsFunctions
Functions
SPSV
 
Data Structures - Lecture 8 [Sorting Algorithms]
Data Structures - Lecture 8 [Sorting Algorithms]Data Structures - Lecture 8 [Sorting Algorithms]
Data Structures - Lecture 8 [Sorting Algorithms]
Muhammad Hammad Waseem
 
PPt on Functions
PPt on FunctionsPPt on Functions
PPt on Functions
coolhanddav
 
Algebra 2 Unit 5 Lesson 2
Algebra 2 Unit 5 Lesson 2Algebra 2 Unit 5 Lesson 2
Algebra 2 Unit 5 Lesson 2
Kate Nowak
 
List comprehensions
List comprehensionsList comprehensions
List comprehensions
Jordi Gómez
 
Functions
FunctionsFunctions
Functions
Ankit Bhandari
 

What's hot (20)

Composition Of Functions
Composition Of FunctionsComposition Of Functions
Composition Of Functions
 
Relations and functions
Relations and functionsRelations and functions
Relations and functions
 
Lesson 3 Operation on Functions
Lesson 3 Operation on FunctionsLesson 3 Operation on Functions
Lesson 3 Operation on Functions
 
L3 functions operations
L3 functions operationsL3 functions operations
L3 functions operations
 
Function and Its Types.
Function and Its Types.Function and Its Types.
Function and Its Types.
 
2.4 operations on functions
2.4 operations on functions2.4 operations on functions
2.4 operations on functions
 
Polynomial functions
Polynomial functionsPolynomial functions
Polynomial functions
 
Evaluating functions
Evaluating functionsEvaluating functions
Evaluating functions
 
composite functions
composite functionscomposite functions
composite functions
 
Operation on functions
Operation on functionsOperation on functions
Operation on functions
 
Operations With Functions May 25 2009
Operations With Functions May 25 2009Operations With Functions May 25 2009
Operations With Functions May 25 2009
 
4 2 operations on functions
4 2 operations on functions4 2 operations on functions
4 2 operations on functions
 
Function Operations
Function OperationsFunction Operations
Function Operations
 
Jan. 6 Inverse Functions
Jan. 6 Inverse FunctionsJan. 6 Inverse Functions
Jan. 6 Inverse Functions
 
Functions
FunctionsFunctions
Functions
 
Data Structures - Lecture 8 [Sorting Algorithms]
Data Structures - Lecture 8 [Sorting Algorithms]Data Structures - Lecture 8 [Sorting Algorithms]
Data Structures - Lecture 8 [Sorting Algorithms]
 
PPt on Functions
PPt on FunctionsPPt on Functions
PPt on Functions
 
Algebra 2 Unit 5 Lesson 2
Algebra 2 Unit 5 Lesson 2Algebra 2 Unit 5 Lesson 2
Algebra 2 Unit 5 Lesson 2
 
List comprehensions
List comprehensionsList comprehensions
List comprehensions
 
Functions
FunctionsFunctions
Functions
 

Viewers also liked

0220課程介紹(1)
0220課程介紹(1)0220課程介紹(1)
0220課程介紹(1)景淳 許
 
0227心理學史簡介
0227心理學史簡介0227心理學史簡介
0227心理學史簡介景淳 許
 
1011 sas 實習課
1011 sas 實習課1011 sas 實習課
1011 sas 實習課景淳 許
 
10/04 SAS 實習課
10/04 SAS 實習課10/04 SAS 實習課
10/04 SAS 實習課
景淳 許
 
0927 sas實習課
0927 sas實習課0927 sas實習課
0927 sas實習課景淳 許
 
服務設計Ncku2013
服務設計Ncku2013服務設計Ncku2013
服務設計Ncku2013景淳 許
 
2013 感性工學概述
2013  感性工學概述2013  感性工學概述
2013 感性工學概述景淳 許
 
研究方法&工具
研究方法&工具研究方法&工具
研究方法&工具
景淳 許
 
11/01 SAS 快速複習
11/01 SAS 快速複習11/01 SAS 快速複習
11/01 SAS 快速複習景淳 許
 
20130318 社群網路與人工智慧
20130318 社群網路與人工智慧20130318 社群網路與人工智慧
20130318 社群網路與人工智慧
景淳 許
 
Class 1 f_mri_intro
Class 1 f_mri_introClass 1 f_mri_intro
Class 1 f_mri_intro
景淳 許
 
0306大腦與行為
0306大腦與行為0306大腦與行為
0306大腦與行為景淳 許
 
0927 sas english version
0927 sas english version0927 sas english version
0927 sas english version
景淳 許
 
Updated Storage Module
Updated Storage ModuleUpdated Storage Module
Updated Storage Module
Enhance Technology, Inc.
 
Demystifying Storage - Building large SANs
Demystifying  Storage - Building large SANsDemystifying  Storage - Building large SANs
Demystifying Storage - Building large SANs
Directi Group
 
VMware - Virtual SAN - IT Changes Everything
VMware - Virtual SAN - IT Changes EverythingVMware - Virtual SAN - IT Changes Everything
VMware - Virtual SAN - IT Changes Everything
VMUG IT
 
Compoñentes internas do ordenador
Compoñentes internas do ordenadorCompoñentes internas do ordenador
Compoñentes internas do ordenador
irocho
 

Viewers also liked (20)

0220課程介紹(1)
0220課程介紹(1)0220課程介紹(1)
0220課程介紹(1)
 
0227心理學史簡介
0227心理學史簡介0227心理學史簡介
0227心理學史簡介
 
1011 sas 實習課
1011 sas 實習課1011 sas 實習課
1011 sas 實習課
 
10/04 SAS 實習課
10/04 SAS 實習課10/04 SAS 實習課
10/04 SAS 實習課
 
Open data
Open dataOpen data
Open data
 
0927 sas實習課
0927 sas實習課0927 sas實習課
0927 sas實習課
 
服務設計Ncku2013
服務設計Ncku2013服務設計Ncku2013
服務設計Ncku2013
 
2013 感性工學概述
2013  感性工學概述2013  感性工學概述
2013 感性工學概述
 
研究方法&工具
研究方法&工具研究方法&工具
研究方法&工具
 
11/01 SAS 快速複習
11/01 SAS 快速複習11/01 SAS 快速複習
11/01 SAS 快速複習
 
意識
意識意識
意識
 
20130318 社群網路與人工智慧
20130318 社群網路與人工智慧20130318 社群網路與人工智慧
20130318 社群網路與人工智慧
 
Class 1 f_mri_intro
Class 1 f_mri_introClass 1 f_mri_intro
Class 1 f_mri_intro
 
0320記憶(2)
0320記憶(2)0320記憶(2)
0320記憶(2)
 
0306大腦與行為
0306大腦與行為0306大腦與行為
0306大腦與行為
 
0927 sas english version
0927 sas english version0927 sas english version
0927 sas english version
 
Updated Storage Module
Updated Storage ModuleUpdated Storage Module
Updated Storage Module
 
Demystifying Storage - Building large SANs
Demystifying  Storage - Building large SANsDemystifying  Storage - Building large SANs
Demystifying Storage - Building large SANs
 
VMware - Virtual SAN - IT Changes Everything
VMware - Virtual SAN - IT Changes EverythingVMware - Virtual SAN - IT Changes Everything
VMware - Virtual SAN - IT Changes Everything
 
Compoñentes internas do ordenador
Compoñentes internas do ordenadorCompoñentes internas do ordenador
Compoñentes internas do ordenador
 

Similar to SAS 11/01

R for Statistical Computing
R for Statistical ComputingR for Statistical Computing
R for Statistical Computing
Mohammed El Rafie Tarabay
 
presentation.pptx
presentation.pptxpresentation.pptx
presentation.pptx
raghav415187
 
R is a very flexible and powerful programming language, as well as a.pdf
R is a very flexible and powerful programming language, as well as a.pdfR is a very flexible and powerful programming language, as well as a.pdf
R is a very flexible and powerful programming language, as well as a.pdf
annikasarees
 
Functions.ppt
Functions.pptFunctions.ppt
Functions.ppt
MaritesBarredo
 
R code for data manipulation
R code for data manipulationR code for data manipulation
R code for data manipulation
Avjinder (Avi) Kaler
 
R code for data manipulation
R code for data manipulationR code for data manipulation
R code for data manipulation
Avjinder (Avi) Kaler
 
Ggplot2 work
Ggplot2 workGgplot2 work
Ggplot2 work
ARUN DN
 
R and data mining
R and data miningR and data mining
R and data mining
Chaozhong Yang
 
INTRODUCTION TO MATLAB presentation.pptx
INTRODUCTION TO MATLAB presentation.pptxINTRODUCTION TO MATLAB presentation.pptx
INTRODUCTION TO MATLAB presentation.pptx
Devaraj Chilakala
 
R programming
R programmingR programming
R programming
Pramodkumar Jha
 
Matlab Workshop Presentation
Matlab Workshop PresentationMatlab Workshop Presentation
Matlab Workshop Presentation
Jairo Maldonado-Contreras
 
INTRODUCTION TO STATA.pptx
INTRODUCTION TO STATA.pptxINTRODUCTION TO STATA.pptx
INTRODUCTION TO STATA.pptx
Dhananjaykumar464035
 
20100528
2010052820100528
20100528
byron zhao
 
20100528
2010052820100528
20100528
byron zhao
 
Matlab ppt
Matlab pptMatlab ppt
Matlab ppt
chestialtaff
 
Introduction To Lisp
Introduction To LispIntroduction To Lisp
Introduction To Lisp
kyleburton
 
Adobe
AdobeAdobe
Storyboard math
Storyboard mathStoryboard math
Storyboard math
shandex
 
bobok
bobokbobok
MA3696 Lecture 5
MA3696 Lecture 5MA3696 Lecture 5
MA3696 Lecture 5
Brunel University
 

Similar to SAS 11/01 (20)

R for Statistical Computing
R for Statistical ComputingR for Statistical Computing
R for Statistical Computing
 
presentation.pptx
presentation.pptxpresentation.pptx
presentation.pptx
 
R is a very flexible and powerful programming language, as well as a.pdf
R is a very flexible and powerful programming language, as well as a.pdfR is a very flexible and powerful programming language, as well as a.pdf
R is a very flexible and powerful programming language, as well as a.pdf
 
Functions.ppt
Functions.pptFunctions.ppt
Functions.ppt
 
R code for data manipulation
R code for data manipulationR code for data manipulation
R code for data manipulation
 
R code for data manipulation
R code for data manipulationR code for data manipulation
R code for data manipulation
 
Ggplot2 work
Ggplot2 workGgplot2 work
Ggplot2 work
 
R and data mining
R and data miningR and data mining
R and data mining
 
INTRODUCTION TO MATLAB presentation.pptx
INTRODUCTION TO MATLAB presentation.pptxINTRODUCTION TO MATLAB presentation.pptx
INTRODUCTION TO MATLAB presentation.pptx
 
R programming
R programmingR programming
R programming
 
Matlab Workshop Presentation
Matlab Workshop PresentationMatlab Workshop Presentation
Matlab Workshop Presentation
 
INTRODUCTION TO STATA.pptx
INTRODUCTION TO STATA.pptxINTRODUCTION TO STATA.pptx
INTRODUCTION TO STATA.pptx
 
20100528
2010052820100528
20100528
 
20100528
2010052820100528
20100528
 
Matlab ppt
Matlab pptMatlab ppt
Matlab ppt
 
Introduction To Lisp
Introduction To LispIntroduction To Lisp
Introduction To Lisp
 
Adobe
AdobeAdobe
Adobe
 
Storyboard math
Storyboard mathStoryboard math
Storyboard math
 
bobok
bobokbobok
bobok
 
MA3696 Lecture 5
MA3696 Lecture 5MA3696 Lecture 5
MA3696 Lecture 5
 

SAS 11/01