Snippet Name
|
Description
|
---|---|
Catalogs
|
|
Edit a SOURCE Entry
|
enables you to specify
the content for the SOURCE entry type in a catalog. The SOURCE entry
can contain the same code as SAS programs.
|
List Catalogs
|
lists in a SAS table all of the catalogs in the specified library. By default, this table is saved in the Work library and with catalogs as the filename.
|
List Catalog Entries
|
lists all the catalog
types in the specified catalog.
|
Print GRSEG Entry
|
prints the GRSEG entry to the open destinations specified by the SAS Output Delivery
System (ODS output).
|
Data
|
|
DS2 Code
|
provides a template for a DS2 program. DS2 is a SAS programming language that is appropriate for advanced
data manipulation. DS2 is included with Base SAS and shares core features with the
SAS DATA step. DS2 exceeds the DATA step by adding variable scoping, user-defined methods, ANSI SQL data types, and user-defined packages. The DS2 SET statement accepts embedded FedSQL syntax, and the run-time-generated
queries can exchange data interactively between DS2 and any supported database. This allows
SQL preprocessing of input tables, which effectively combines the power of the two languages. For more information,
see SAS DS2 Language Reference.
|
DS2 Package
|
provides a template for a DS2 package. A package is similar to a DS2 program. The package body consists of a set of global
declarations and a list of methods. The main syntactical differences are the PACKAGE
and ENDPACKAGE statements. These statements define a block with global scope. For
more information, see SAS DS2 Language Reference.
|
DS2 Thread
|
provides a template for a DS2 threaded program. Typically, DS2 code runs sequentially.
That is, one process
runs to completion before the next process begins. It is possible to run more than
one process concurrently, using threaded processing. In threaded processing, each
concurrently executing section of code is said to be running in a thread. For more information, see SAS DS2 Language Reference.
|
Generate CSV File
|
enables you to export SAS data as a comma-separated text file.
|
Generate PowerPoint
Slide
|
enables you to stream Microsoft PowerPoint output to your web browser.
|
Generate XML File
|
enables you to export SAS data as an XML file that you can view in your web browser.
|
Import CSV File
|
enables you to import a comma-separated file and write the output to a SAS data set.
|
Import XLSX File
|
enables you to import a Microsoft XLSX file and write the output to a SAS data set.
|
Simulate Linear Regression
Data
|
creates an input data source that you can use for linear regression analysis. Linear regression analysis tries to assign a linear function to your data by using the least squares method.
|
Simulate One-Way ANOVA
Data
|
creates an input data source that considers one treatment factor with three treatment
levels. When you analyze
this data by using the One-Way ANOVA task, the goal is to test for differences among
the means of the levels and to quantify these differences.
|
Descriptive
|
|
Custom ODS Output
|
provides a template for creating HTML, PDF, and RTF output by using the SAS Output
Delivery System. For
more information, see SAS Output Delivery System: User's Guide.
|
PROC SQL
|
provides a template for writing SQL queries. For more information, see SAS SQL Procedure User's Guide.
|
Graph
Note: For more information about
the SGPLOT, SGPANEL, and SGSCATTER procedures, see SAS ODS Graphics: Procedures Guide.
|
|
Bar Panel
|
uses the VBAR statement in the SGPANEL procedure and enables you to create multiple
bar charts.
|
Box Panel
|
uses the VBOX statement in the SGPANEL procedure and enables you to create multiple
box plots.
|
Comparative Scatter
Plot
|
uses the COMPARE statement in the SGSCATTER procedure. This code snippet creates a comparative panel of scatter plots with shared axes.
|
Dot Plot
|
uses the DOT statement in the SGPLOT procedure. Dot plots summarize horizontally the values of a category variable. By default, each dot represents the frequency for each value of the category variable.
|
Fit Plot
|
uses the REG statement in the SGPLOT procedure. This code snippet produces a regression
plot with a quadratic fit and includes confidence limits.
|
HBar Plot
|
uses the HBAR statement in the SGPLOT procedure. This code snippet creates a horizontal bar chart that summarizes the values of a category variable.
|
HighLow Plot
|
uses the HIGHLOW statement in the SGPLOT procedure. High-low charts show how several
values of one variable relate to one value of another variable. Typically, each variable
value on the horizontal axis has several corresponding values on the vertical axis.
|
Histogram Plot
|
uses the HISTOGRAM statement in the SGPLOT procedure. This code snippet produces a
histogram with two density plots. In this snippet, one density plot uses a normal
density estimate and the other density plot uses a kernel density estimate.
|
Scatter Plot Matrix
|
uses the MATRIX statement in the SGSCATTER procedure. This code snippet creates a
scatter plot matrix.
|
VBox Plot
|
uses the VBOX statement in the SGPLOT procedure. A box plot summarizes the data and indicates the median, upper and lower quartiles, and minimum and maximum values. The plot provides a quick visual summary that easily
shows center, spread, range, and any
outliers. The SGPLOT and the SGPANEL procedures have separate statements for creating horizontal
and vertical box plots.
|
Macro
Note: For more information about
SAS macros, see SAS Macro Language: Reference.
|
|
SAS Macro Char Functions
|
provides several examples of these SAS macros that work with character values:
|
SAS Macro Do Statement
|
designates the beginning of a section of a macro definition that is treated as a unit until a matching %END statement is encountered. This macro
section is called a %DO group.
A simple %DO statement often appears in conjunction with %IF-%THEN-%ELSE statements to designate a section
of the macro to be processed depending on whether the %IF condition is true or false.
Note: SAS also provides a %DO iterative
statement, which is different from the code that is generated by this
snippet. For more information, see SAS Macro Language: Reference.
|
SAS Macro If Statement
|
conditionally processes
a portion of a macro. The expression that is the condition for the
%IF-%THEN-%ELSE statement can contain only operands that are constant
text or text expressions that generate text.
|
SAS Macro Parameters
|
names one or more local macro variables whose values you specify when you invoke the macro. There are two types of macro
variables: positional and keyword. Parameters are local to the macro that defines
them. You must supply each parameter name. You cannot use a text expression to generate it. A parameter list can contain
any number of macro parameters separated by commas. The macro variables in the parameter list are usually referenced
in the macro.
|
SAS Macro
|
provides a basic template for working with SAS macros. Macros enable you to perform
many tasks, including substituting text in a program.
A SAS program can contain any number of macros, and you can invoke a macro multiple
times in a single program. For more information, see SAS Macro Language: Reference.
|
SAS Macro Quoting
|
provides examples of macro functions that tell the macro processor to interpret special characters and mnemonics as text rather than as part of the macro language.
|
SAS Macro Quoting (continued)
|
For more information
about macro complication and macro execution, see SAS Macro Language: Reference.
|
SAS Macro Variables
|
provides examples of how to create user-defined global and local macro variables.
Macro variables are tools that enable you to dynamically modify the text in a SAS
program through symbolic substitution. You can assign large or small amounts of text
to macro variables. Then you can use that text by simply referencing the variable
that contains the text.
Macro variables that are defined by the macro programmer are called user-defined macro
variables. Macro variables that are defined by the macro processor are called automatic
macro
variables. You can define and use macro variables anywhere in SAS programs, except
within data lines.
|
IML
Note: These snippets are available
only if your site licenses SAS/IML.
|
|
Find Roots of Nonlinear
Equation
|
|
Fit by using Maximum
Likelihood
|
uses maximum likelihood estimation to estimate parameters for the normal density estimate.
|
Generate a Bootstrap
Distribution
|
uses the IML procedure to create and analyze a bootstrap distribution of the sample mean.
|
Integrate a Function
|
enables you to numerically
integrate a one-dimensional function by using the QUAD subroutine
in SAS/IML software. Use the QUAD subroutine to numerically find the
definite integral of a function on a finite, semi-infinite, or infinite
domain.
|
Simulate Multivariate
Normal Data
|
simulates data from a multivariate normal distribution with a specified mean and covariance.
|