4.5. Selected Functions
The following table lists the definition and form of commonly used functions.
Function name | Form of function | Definition |
---|---|---|
Mathematical | ||
LOG | LOG(numValue) | Natural logarithm |
LOG10 | LOG10(numValue) | Logarithm to the base 10 |
Descriptive Statistics | ||
MAX | MAX(numValue,numValue,...) | Largest non-missing value |
MEAN | MEAN(numValue,numValue,...) | Arithmetic mean of non-missing values |
MIN | MIN(numValue,numValue,...) | Smallest non-missing value |
SUM | SUM(numValue,numValue,...) | Sum of non-missing values |
Character | ||
LENGTH | LENGTH(charValue) | Returns the length of a character value not counting trailing blanks (missing values have a length of 1) |
SUBSTR{Extract} | SUBSTR(charValue,position,n) | Extracts a substring from a character value starting at ‘position’ for ‘n’ characters or ... |
Get The Little SAS® Book for Enterprise Guide® 4.1 now with the O’Reilly learning platform.
O’Reilly members experience books, live events, courses curated by job role, and more from O’Reilly and nearly 200 top publishers.