Principal Component Analysis Action Set

Provides actions for performing principal component analysis

nipals Action

Extracts principal components by using the nonlinear iterative partial least squares (NIPALS) method.

CASL Syntax

pca.nipals <result=results> <status=rc> /
attributes={{
format="string",
formattedLength=integer,
label="string",
required parameter name="variable-name",
nfd=integer,
nfl=integer
}, {...}},
code={
casOut={
caslib="string"
compress=TRUE | FALSE
indexVars={"variable-name-1" <, "variable-name-2", ...>}
label="string"
lifetime=64-bit-integer
maxMemSize=64-bit-integer
memoryFormat="DVR" | "INHERIT" | "STANDARD"
name="table-name"
onDemand=TRUE | FALSE
promote=TRUE | FALSE
replace=TRUE | FALSE
replication=integer
tableRedistUpPolicy="DEFER" | "NOREDIST" | "REBALANCE"
threadBlockSize=64-bit-integer
timeStamp="string"
where={"string-1" <, "string-2", ...>}
},
comment=TRUE | FALSE,
fmtWdth=integer,
indentSize=integer,
intoCutPt=double,
iProb=TRUE | FALSE,
labelId=integer,
lineSize=integer,
noTrim=TRUE | FALSE,
pCatAll=TRUE | FALSE,
tabForm=TRUE | FALSE
},
display={
caseSensitive=TRUE | FALSE,
exclude=TRUE | FALSE,
excludeAll=TRUE | FALSE,
keyIsPath=TRUE | FALSE,
names={"string-1" <, "string-2", ...>},
pathType="LABEL" | "NAME",
traceNames=TRUE | FALSE
},
epsilon=double,
gpu={
enable=TRUE | FALSE
},
groupbyLimit=64-bit-integer,
inputs={{
format="string",
formattedLength=integer,
label="string",
required parameter name="variable-name",
nfd=integer,
nfl=integer
}, {...}},
maxIter=integer,
n=integer,
noCenter=TRUE | FALSE,
noScale=TRUE | FALSE,
output={
required parameter casOut={
caslib="string"
compress=TRUE | FALSE
indexVars={"variable-name-1" <, "variable-name-2", ...>}
label="string"
lifetime=64-bit-integer
maxMemSize=64-bit-integer
memoryFormat="DVR" | "INHERIT" | "STANDARD"
name="table-name"
promote=TRUE | FALSE
replace=TRUE | FALSE
replication=integer
tableRedistUpPolicy="DEFER" | "NOREDIST" | "REBALANCE"
threadBlockSize=64-bit-integer
timeStamp="string"
where={"string-1" <, "string-2", ...>}
},
copyVars={"variable-name-1" <, "variable-name-2", ...>},
h="string",
residual="string",
score="string",
std="string",
stdsse="string",
t2="string"
},
outputTables={
groupByVarsRaw=TRUE | FALSE,
includeAll=TRUE | FALSE,
names={"string-1" <, "string-2", ...>} | {key-1={casouttable-1} <, key-2={casouttable-2}, ...>},
repeated=TRUE | FALSE,
replace=TRUE | FALSE
},
prefix="string",
store={
caslib="string",
compress=TRUE | FALSE,
indexVars={"variable-name-1" <, "variable-name-2", ...>},
label="string",
lifetime=64-bit-integer,
maxMemSize=64-bit-integer,
memoryFormat="DVR" | "INHERIT" | "STANDARD",
name="table-name",
promote=TRUE | FALSE,
replace=TRUE | FALSE,
replication=integer,
tableRedistUpPolicy="DEFER" | "NOREDIST" | "REBALANCE",
threadBlockSize=64-bit-integer,
timeStamp="string",
where={"string-1" <, "string-2", ...>}
},
required parameter table={
caslib="string",
computedOnDemand=TRUE | FALSE,
computedVars={{
format="string",
formattedLength=integer,
label="string",
required parameter name="variable-name",
nfd=integer,
nfl=integer
}, {...}},
computedVarsProgram="string",
dataSourceOptions={key-1=any-list-or-data-type-1 <, key-2=any-list-or-data-type-2, ...>},
groupBy={{
format="string",
formattedLength=integer,
label="string",
required parameter name="variable-name",
nfd=integer,
nfl=integer
}, {...}},
groupByMode="NOSORT" | "REDISTRIBUTE",
importOptions={fileType="ANY" | "AUDIO" | "AUTO" | "BASESAS" | "CSV" | "DELIMITED" | "DOCUMENT" | "DTA" | "ESP" | "EXCEL" | "FMT" | "HDAT" | "IMAGE" | "JMP" | "LASR" | "PARQUET" | "SOUND" | "SPSS" | "VIDEO" | "XLS", fileType-specific-parameters},
required parameter name="table-name",
orderBy={{
format="string",
formattedLength=integer,
label="string",
required parameter name="variable-name",
nfd=integer,
nfl=integer
}, {...}},
singlePass=TRUE | FALSE,
vars={{
format="string",
formattedLength=integer,
label="string",
required parameter name="variable-name",
nfd=integer,
nfl=integer
}, {...}},
where="where-expression",
whereTable={
casLib="string"
dataSourceOptions={adls_noreq-parameters | bigquery-parameters | cas_noreq-parameters | clouddex-parameters | db2-parameters | dnfs-parameters | esp-parameters | fedsvr-parameters | gcs_noreq-parameters | hadoop-parameters | hana-parameters | impala-parameters | informix-parameters | jdbc-parameters | mongodb-parameters | mysql-parameters | odbc-parameters | oracle-parameters | path-parameters | postgres-parameters | redshift-parameters | s3-parameters | sapiq-parameters | sforce-parameters | singlestore_standard-parameters | snowflake-parameters | spark-parameters | spde-parameters | sqlserver-parameters | ss_noreq-parameters | teradata-parameters | vertica-parameters | yellowbrick-parameters}
importOptions={fileType="ANY" | "AUDIO" | "AUTO" | "BASESAS" | "CSV" | "DELIMITED" | "DOCUMENT" | "DTA" | "ESP" | "EXCEL" | "FMT" | "HDAT" | "IMAGE" | "JMP" | "LASR" | "PARQUET" | "SOUND" | "SPSS" | "VIDEO" | "XLS", fileType-specific-parameters}
required parameter name="table-name"
vars={{
format="string",
formattedLength=integer,
label="string",
required parameter name="variable-name",
nfd=integer,
nfl=integer
}, {...}}
where="where-expression"
}
},
varDef="DF" | "N" | "WDF" | "WEIGHT" | "WGT"
;
indicates a required parameter

Summary: Input and Output Tables

If a row includes a subparameter, you can specify the name, caslib, and so on in the subparameter. Otherwise, you can specify the name, caslib, and so on in the parameter.

Parameters for Reading Input Tables

Parameter

Subparameter

Description

required parametertable

specifies the settings for an input table.

Parameters for Creating Output Tables

Parameter

Subparameter

Description

 code

casOut

writes SAS DATA step code for computing predicted values of the fitted model.

 output

required parametercasOut

specifies the output table to be created to contain observationwise statistics. If you do not specify any statistic, then only the principal component scores are included.

 outputTables

names

lists the names of results tables to save as CAS tables on the server.

 store

specifies the output table to be created to save model fit information that you can use for scoring.

Parameter Descriptions

attributes={{casinvardesc-1} <, {casinvardesc-2}, ...>}

changes the attributes of variables used in this action. Currently, attributes specified on the inputs and nominals parameter are ignored.

For more information about specifying the attributes parameter, see the common casinvardesc parameter (Appendix A: Common Parameters).

Aliases attribute
attr

code={aircodegen}

writes SAS DATA step code for computing predicted values of the fitted model.

For more information about specifying the code parameter, see the common aircodegen parameter (Appendix A: Common Parameters).

display={displayTables}

specifies a list of results tables to send to the client for display.

For more information about specifying the display parameter, see the common displayTables parameter (Appendix A: Common Parameters).

epsilon=double

specifies the convergence criterion for the iterative method.

Default 1E-12
Range 0–1

gpu={pca_gpu}

specifies the settings for graphics processing units (GPUs). If you specify the groupBy subparameter in the table parameter, the gpu parameter is ignored. If no GPU is available, the CPU is used to perform model computation.

enable=TRUE | FALSE

when set to True, enables the action to use GPUs to perform model computation on GPU-equipped machines (one GPU is used on each machine).

Default FALSE

groupbyLimit=64-bit-integer

suppresses the analysis if the number of BY groups exceeds the specified value.

Minimum value 1

inputs={{casinvardesc-1} <, {casinvardesc-2}, ...>}

specifies the variables to be analyzed. For the NIPALS, ITERGS, and EIG methods, you can analyze only numeric variables. If you omit the parameter, all numeric variables that are not specified in other parameters are analyzed. You must specify either INPUTS or MODEL for the RANDOMPCA method, but you can use both numeric and categorical variables.

For more information about specifying the inputs parameter, see the common casinvardesc parameter (Appendix A: Common Parameters).

Aliases input
vars
var

maxIter=integer

specifies the maximum number of iterations for the iterative method.

Default 500
Range 0–MACINT

n=integer

specifies the number of principal components to be computed. If the value is 0, all principal components are computed.

Default 0
Minimum value 0

noCenter=TRUE | FALSE

when set to True, suppresses centering of the numeric variables to be analyzed.

Default FALSE

noScale=TRUE | FALSE

when set to True, suppresses scaling of the numeric variables to be analyzed.

Default FALSE

output={iterOutput}

specifies the output table to be created to contain observationwise statistics. If you do not specify any statistic, then only the principal component scores are included.

The iterOutput value can be one or more of the following:

* casOut={casouttable}

specifies the output table.

For more information about specifying the casOut parameter, see the common casouttable (Form 1) parameter (Appendix A: Common Parameters).

copyVars={"variable-name-1" <, "variable-name-2", ...>}

copies one or more variables from the input table to the output table.

Alias copyVar
h="string"

specifies the approximate leverage. If the value is an empty string, the prefix H is used to name the output variables.

residual="string"

specifies residuals for each analysis variable. If the value is an empty string, the prefix R is used to name the output variables.

Aliases r
resid
score="string"

specifies principal component scores for each principal component. If the value is an empty string, the prefix Score is used to name the output variables.

std="string"

specifies standardized (centered and scaled) analysis variable values for each analysis variable. If the value is an empty string, the prefix Std is used to name the output variables.

stdsse="string"

specifies the sum of squares of residuals for standardized analysis variables. If the value is an empty string, the prefix StdSSE is used to name the output variables.

t2="string"

specifies a scaled sum of squares of score values. If the value is an empty string, the prefix TSquare is used to name the output variables.

Alias tSquare

outputTables={outputTables}

lists the names of results tables to save as CAS tables on the server.

For more information about specifying the outputTables parameter, see the common outputTables parameter (Appendix A: Common Parameters).

Alias displayOut

prefix="string"

specifies a prefix for naming the principal components.

Default "Prin"

store={casouttable}

specifies the output table to be created to save model fit information that you can use for scoring.

For more information about specifying the store parameter, see the common casouttable (Form 1) parameter (Appendix A: Common Parameters).

Alias saveState

* table={castable}

specifies the settings for an input table.

For more information about specifying the table parameter, see the common castable (Form 1) parameter (Appendix A: Common Parameters).

varDef="DF" | "N" | "WDF" | "WEIGHT" | "WGT"

specifies the divisor to use in calculating variances and standard deviations.

Default DF

nipals Action

Extracts principal components by using the nonlinear iterative partial least squares (NIPALS) method.

Lua Syntax

results, info = s:pca_nipals{
attributes={{
format="string",
formattedLength=integer,
label="string",
required parameter name="variable-name",
nfd=integer,
nfl=integer
}, {...}},
code={
casOut={
caslib="string"
compress=true | false
indexVars={"variable-name-1" <, "variable-name-2", ...>}
label="string"
lifetime=64-bit-integer
maxMemSize=64-bit-integer
memoryFormat="DVR" | "INHERIT" | "STANDARD"
name="table-name"
onDemand=true | false
promote=true | false
replace=true | false
replication=integer
tableRedistUpPolicy="DEFER" | "NOREDIST" | "REBALANCE"
threadBlockSize=64-bit-integer
timeStamp="string"
where={"string-1" <, "string-2", ...>}
},
comment=true | false,
fmtWdth=integer,
indentSize=integer,
intoCutPt=double,
iProb=true | false,
labelId=integer,
lineSize=integer,
noTrim=true | false,
pCatAll=true | false,
tabForm=true | false
},
display={
caseSensitive=true | false,
exclude=true | false,
excludeAll=true | false,
keyIsPath=true | false,
names={"string-1" <, "string-2", ...>},
pathType="LABEL" | "NAME",
traceNames=true | false
},
epsilon=double,
gpu={
enable=true | false
},
groupbyLimit=64-bit-integer,
inputs={{
format="string",
formattedLength=integer,
label="string",
required parameter name="variable-name",
nfd=integer,
nfl=integer
}, {...}},
maxIter=integer,
n=integer,
noCenter=true | false,
noScale=true | false,
output={
required parameter casOut={
caslib="string"
compress=true | false
indexVars={"variable-name-1" <, "variable-name-2", ...>}
label="string"
lifetime=64-bit-integer
maxMemSize=64-bit-integer
memoryFormat="DVR" | "INHERIT" | "STANDARD"
name="table-name"
promote=true | false
replace=true | false
replication=integer
tableRedistUpPolicy="DEFER" | "NOREDIST" | "REBALANCE"
threadBlockSize=64-bit-integer
timeStamp="string"
where={"string-1" <, "string-2", ...>}
},
copyVars={"variable-name-1" <, "variable-name-2", ...>},
h="string",
residual="string",
score="string",
std="string",
stdsse="string",
t2="string"
},
outputTables={
groupByVarsRaw=true | false,
includeAll=true | false,
names={"string-1" <, "string-2", ...>} | {key-1={casouttable-1} <, key-2={casouttable-2}, ...>},
repeated=true | false,
replace=true | false
},
prefix="string",
store={
caslib="string",
compress=true | false,
indexVars={"variable-name-1" <, "variable-name-2", ...>},
label="string",
lifetime=64-bit-integer,
maxMemSize=64-bit-integer,
memoryFormat="DVR" | "INHERIT" | "STANDARD",
name="table-name",
promote=true | false,
replace=true | false,
replication=integer,
tableRedistUpPolicy="DEFER" | "NOREDIST" | "REBALANCE",
threadBlockSize=64-bit-integer,
timeStamp="string",
where={"string-1" <, "string-2", ...>}
},
required parameter table={
caslib="string",
computedOnDemand=true | false,
computedVars={{
format="string",
formattedLength=integer,
label="string",
required parameter name="variable-name",
nfd=integer,
nfl=integer
}, {...}},
computedVarsProgram="string",
dataSourceOptions={key-1=any-list-or-data-type-1 <, key-2=any-list-or-data-type-2, ...>},
groupBy={{
format="string",
formattedLength=integer,
label="string",
required parameter name="variable-name",
nfd=integer,
nfl=integer
}, {...}},
groupByMode="NOSORT" | "REDISTRIBUTE",
importOptions={fileType="ANY" | "AUDIO" | "AUTO" | "BASESAS" | "CSV" | "DELIMITED" | "DOCUMENT" | "DTA" | "ESP" | "EXCEL" | "FMT" | "HDAT" | "IMAGE" | "JMP" | "LASR" | "PARQUET" | "SOUND" | "SPSS" | "VIDEO" | "XLS", fileType-specific-parameters},
required parameter name="table-name",
orderBy={{
format="string",
formattedLength=integer,
label="string",
required parameter name="variable-name",
nfd=integer,
nfl=integer
}, {...}},
singlePass=true | false,
vars={{
format="string",
formattedLength=integer,
label="string",
required parameter name="variable-name",
nfd=integer,
nfl=integer
}, {...}},
where="where-expression",
whereTable={
casLib="string"
dataSourceOptions={adls_noreq-parameters | bigquery-parameters | cas_noreq-parameters | clouddex-parameters | db2-parameters | dnfs-parameters | esp-parameters | fedsvr-parameters | gcs_noreq-parameters | hadoop-parameters | hana-parameters | impala-parameters | informix-parameters | jdbc-parameters | mongodb-parameters | mysql-parameters | odbc-parameters | oracle-parameters | path-parameters | postgres-parameters | redshift-parameters | s3-parameters | sapiq-parameters | sforce-parameters | singlestore_standard-parameters | snowflake-parameters | spark-parameters | spde-parameters | sqlserver-parameters | ss_noreq-parameters | teradata-parameters | vertica-parameters | yellowbrick-parameters}
importOptions={fileType="ANY" | "AUDIO" | "AUTO" | "BASESAS" | "CSV" | "DELIMITED" | "DOCUMENT" | "DTA" | "ESP" | "EXCEL" | "FMT" | "HDAT" | "IMAGE" | "JMP" | "LASR" | "PARQUET" | "SOUND" | "SPSS" | "VIDEO" | "XLS", fileType-specific-parameters}
required parameter name="table-name"
vars={{
format="string",
formattedLength=integer,
label="string",
required parameter name="variable-name",
nfd=integer,
nfl=integer
}, {...}}
where="where-expression"
}
},
varDef="DF" | "N" | "WDF" | "WEIGHT" | "WGT"
}
indicates a required parameter

Summary: Input and Output Tables

If a row includes a subparameter, you can specify the name, caslib, and so on in the subparameter. Otherwise, you can specify the name, caslib, and so on in the parameter.

Parameters for Reading Input Tables

Parameter

Subparameter

Description

required parametertable

specifies the settings for an input table.

Parameters for Creating Output Tables

Parameter

Subparameter

Description

 code

casOut

writes SAS DATA step code for computing predicted values of the fitted model.

 output

required parametercasOut

specifies the output table to be created to contain observationwise statistics. If you do not specify any statistic, then only the principal component scores are included.

 outputTables

names

lists the names of results tables to save as CAS tables on the server.

 store

specifies the output table to be created to save model fit information that you can use for scoring.

Parameter Descriptions

attributes={{casinvardesc-1} <, {casinvardesc-2}, ...>}

changes the attributes of variables used in this action. Currently, attributes specified on the inputs and nominals parameter are ignored.

For more information about specifying the attributes parameter, see the common casinvardesc parameter (Appendix A: Common Parameters).

Aliases attribute
attr

code={aircodegen}

writes SAS DATA step code for computing predicted values of the fitted model.

For more information about specifying the code parameter, see the common aircodegen parameter (Appendix A: Common Parameters).

display={displayTables}

specifies a list of results tables to send to the client for display.

For more information about specifying the display parameter, see the common displayTables parameter (Appendix A: Common Parameters).

epsilon=double

specifies the convergence criterion for the iterative method.

Default 1E-12
Range 0–1

gpu={pca_gpu}

specifies the settings for graphics processing units (GPUs). If you specify the groupBy subparameter in the table parameter, the gpu parameter is ignored. If no GPU is available, the CPU is used to perform model computation.

enable=true | false

when set to True, enables the action to use GPUs to perform model computation on GPU-equipped machines (one GPU is used on each machine).

Default false

groupbyLimit=64-bit-integer

suppresses the analysis if the number of BY groups exceeds the specified value.

Minimum value 1

inputs={{casinvardesc-1} <, {casinvardesc-2}, ...>}

specifies the variables to be analyzed. For the NIPALS, ITERGS, and EIG methods, you can analyze only numeric variables. If you omit the parameter, all numeric variables that are not specified in other parameters are analyzed. You must specify either INPUTS or MODEL for the RANDOMPCA method, but you can use both numeric and categorical variables.

For more information about specifying the inputs parameter, see the common casinvardesc parameter (Appendix A: Common Parameters).

Aliases input
vars
var

maxIter=integer

specifies the maximum number of iterations for the iterative method.

Default 500
Range 0–MACINT

n=integer

specifies the number of principal components to be computed. If the value is 0, all principal components are computed.

Default 0
Minimum value 0

noCenter=true | false

when set to True, suppresses centering of the numeric variables to be analyzed.

Default false

noScale=true | false

when set to True, suppresses scaling of the numeric variables to be analyzed.

Default false

output={iterOutput}

specifies the output table to be created to contain observationwise statistics. If you do not specify any statistic, then only the principal component scores are included.

The iterOutput value can be one or more of the following:

* casOut={casouttable}

specifies the output table.

For more information about specifying the casOut parameter, see the common casouttable (Form 1) parameter (Appendix A: Common Parameters).

copyVars={"variable-name-1" <, "variable-name-2", ...>}

copies one or more variables from the input table to the output table.

Alias copyVar
h="string"

specifies the approximate leverage. If the value is an empty string, the prefix H is used to name the output variables.

residual="string"

specifies residuals for each analysis variable. If the value is an empty string, the prefix R is used to name the output variables.

Aliases r
resid
score="string"

specifies principal component scores for each principal component. If the value is an empty string, the prefix Score is used to name the output variables.

std="string"

specifies standardized (centered and scaled) analysis variable values for each analysis variable. If the value is an empty string, the prefix Std is used to name the output variables.

stdsse="string"

specifies the sum of squares of residuals for standardized analysis variables. If the value is an empty string, the prefix StdSSE is used to name the output variables.

t2="string"

specifies a scaled sum of squares of score values. If the value is an empty string, the prefix TSquare is used to name the output variables.

Alias tSquare

outputTables={outputTables}

lists the names of results tables to save as CAS tables on the server.

For more information about specifying the outputTables parameter, see the common outputTables parameter (Appendix A: Common Parameters).

Alias displayOut

prefix="string"

specifies a prefix for naming the principal components.

Default "Prin"

store={casouttable}

specifies the output table to be created to save model fit information that you can use for scoring.

For more information about specifying the store parameter, see the common casouttable (Form 1) parameter (Appendix A: Common Parameters).

Alias saveState

* table={castable}

specifies the settings for an input table.

For more information about specifying the table parameter, see the common castable (Form 1) parameter (Appendix A: Common Parameters).

varDef="DF" | "N" | "WDF" | "WEIGHT" | "WGT"

specifies the divisor to use in calculating variances and standard deviations.

Default DF

nipals Action

Extracts principal components by using the nonlinear iterative partial least squares (NIPALS) method.

Python Syntax

results=s.pca.nipals(
attributes=[{
"format":"string",
"formattedLength":integer,
"label":"string",
required parameter "name":"variable-name",
"nfd":integer,
"nfl":integer
}<, {...}>],
code={
"casOut":{
"caslib":"string"
"compress":True | False
"indexVars":["variable-name-1" <, "variable-name-2", ...>]
"label":"string"
"lifetime":64-bit-integer
"maxMemSize":64-bit-integer
"memoryFormat":"DVR" | "INHERIT" | "STANDARD"
"name":"table-name"
"onDemand":True | False
"promote":True | False
"replace":True | False
"replication":integer
"tableRedistUpPolicy":"DEFER" | "NOREDIST" | "REBALANCE"
"threadBlockSize":64-bit-integer
"timeStamp":"string"
"where":["string-1" <, "string-2", ...>]
},
"comment":True | False,
"fmtWdth":integer,
"indentSize":integer,
"intoCutPt":double,
"iProb":True | False,
"labelId":integer,
"lineSize":integer,
"noTrim":True | False,
"pCatAll":True | False,
"tabForm":True | False
},
display={
"caseSensitive":True | False,
"exclude":True | False,
"excludeAll":True | False,
"keyIsPath":True | False,
"names":["string-1" <, "string-2", ...>],
"pathType":"LABEL" | "NAME",
"traceNames":True | False
},
epsilon=double,
gpu={
"enable":True | False
},
groupbyLimit=64-bit-integer,
inputs=[{
"format":"string",
"formattedLength":integer,
"label":"string",
required parameter "name":"variable-name",
"nfd":integer,
"nfl":integer
}<, {...}>],
maxIter=integer,
n=integer,
noCenter=True | False,
noScale=True | False,
output={
required parameter "casOut":{
"caslib":"string"
"compress":True | False
"indexVars":["variable-name-1" <, "variable-name-2", ...>]
"label":"string"
"lifetime":64-bit-integer
"maxMemSize":64-bit-integer
"memoryFormat":"DVR" | "INHERIT" | "STANDARD"
"name":"table-name"
"promote":True | False
"replace":True | False
"replication":integer
"tableRedistUpPolicy":"DEFER" | "NOREDIST" | "REBALANCE"
"threadBlockSize":64-bit-integer
"timeStamp":"string"
"where":["string-1" <, "string-2", ...>]
},
"copyVars":["variable-name-1" <, "variable-name-2", ...>],
"h":"string",
"residual":"string",
"score":"string",
"std":"string",
"stdsse":"string",
"t2":"string"
},
outputTables={
"groupByVarsRaw":True | False,
"includeAll":True | False,
"names":["string-1" <, "string-2", ...>] | {"key-1":{casouttable-1} <, "key-2":{casouttable-2}, ...>},
"repeated":True | False,
"replace":True | False
},
prefix="string",
store={
"caslib":"string",
"compress":True | False,
"indexVars":["variable-name-1" <, "variable-name-2", ...>],
"label":"string",
"lifetime":64-bit-integer,
"maxMemSize":64-bit-integer,
"memoryFormat":"DVR" | "INHERIT" | "STANDARD",
"name":"table-name",
"promote":True | False,
"replace":True | False,
"replication":integer,
"tableRedistUpPolicy":"DEFER" | "NOREDIST" | "REBALANCE",
"threadBlockSize":64-bit-integer,
"timeStamp":"string",
"where":["string-1" <, "string-2", ...>]
},
required parameter table={
"caslib":"string",
"computedOnDemand":True | False,
"computedVars":[{
"format":"string",
"formattedLength":integer,
"label":"string",
required parameter "name":"variable-name",
"nfd":integer,
"nfl":integer
}<, {...}>],
"computedVarsProgram":"string",
"dataSourceOptions":{"key-1":{any-list-or-data-type-1} <, "key-2":{any-list-or-data-type-2}, ...>},
"groupBy":[{
"format":"string",
"formattedLength":integer,
"label":"string",
required parameter "name":"variable-name",
"nfd":integer,
"nfl":integer
}<, {...}>],
"groupByMode":"NOSORT" | "REDISTRIBUTE",
"importOptions":{"fileType":"ANY" | "AUDIO" | "AUTO" | "BASESAS" | "CSV" | "DELIMITED" | "DOCUMENT" | "DTA" | "ESP" | "EXCEL" | "FMT" | "HDAT" | "IMAGE" | "JMP" | "LASR" | "PARQUET" | "SOUND" | "SPSS" | "VIDEO" | "XLS", fileType-specific-parameters},
required parameter "name":"table-name",
"orderBy":[{
"format":"string",
"formattedLength":integer,
"label":"string",
required parameter "name":"variable-name",
"nfd":integer,
"nfl":integer
}<, {...}>],
"singlePass":True | False,
"vars":[{
"format":"string",
"formattedLength":integer,
"label":"string",
required parameter "name":"variable-name",
"nfd":integer,
"nfl":integer
}<, {...}>],
"where":"where-expression",
"whereTable":{
"casLib":"string"
"dataSourceOptions":{adls_noreq-parameters | bigquery-parameters | cas_noreq-parameters | clouddex-parameters | db2-parameters | dnfs-parameters | esp-parameters | fedsvr-parameters | gcs_noreq-parameters | hadoop-parameters | hana-parameters | impala-parameters | informix-parameters | jdbc-parameters | mongodb-parameters | mysql-parameters | odbc-parameters | oracle-parameters | path-parameters | postgres-parameters | redshift-parameters | s3-parameters | sapiq-parameters | sforce-parameters | singlestore_standard-parameters | snowflake-parameters | spark-parameters | spde-parameters | sqlserver-parameters | ss_noreq-parameters | teradata-parameters | vertica-parameters | yellowbrick-parameters}
"importOptions":{"fileType":"ANY" | "AUDIO" | "AUTO" | "BASESAS" | "CSV" | "DELIMITED" | "DOCUMENT" | "DTA" | "ESP" | "EXCEL" | "FMT" | "HDAT" | "IMAGE" | "JMP" | "LASR" | "PARQUET" | "SOUND" | "SPSS" | "VIDEO" | "XLS", fileType-specific-parameters}
required parameter "name":"table-name"
"vars":[{
"format":"string",
"formattedLength":integer,
"label":"string",
required parameter "name":"variable-name",
"nfd":integer,
"nfl":integer
}<, {...}>]
"where":"where-expression"
}
},
varDef="DF" | "N" | "WDF" | "WEIGHT" | "WGT"
)
indicates a required parameter

Summary: Input and Output Tables

If a row includes a subparameter, you can specify the name, caslib, and so on in the subparameter. Otherwise, you can specify the name, caslib, and so on in the parameter.

Parameters for Reading Input Tables

Parameter

Subparameter

Description

required parametertable

specifies the settings for an input table.

Parameters for Creating Output Tables

Parameter

Subparameter

Description

 code

casOut

writes SAS DATA step code for computing predicted values of the fitted model.

 output

required parametercasOut

specifies the output table to be created to contain observationwise statistics. If you do not specify any statistic, then only the principal component scores are included.

 outputTables

names

lists the names of results tables to save as CAS tables on the server.

 store

specifies the output table to be created to save model fit information that you can use for scoring.

Parameter Descriptions

attributes=[{casinvardesc-1} <, {casinvardesc-2}, ...>]

changes the attributes of variables used in this action. Currently, attributes specified on the inputs and nominals parameter are ignored.

For more information about specifying the attributes parameter, see the common casinvardesc parameter (Appendix A: Common Parameters).

Aliases attribute
attr

code={aircodegen}

writes SAS DATA step code for computing predicted values of the fitted model.

For more information about specifying the code parameter, see the common aircodegen parameter (Appendix A: Common Parameters).

display={displayTables}

specifies a list of results tables to send to the client for display.

For more information about specifying the display parameter, see the common displayTables parameter (Appendix A: Common Parameters).

epsilon=double

specifies the convergence criterion for the iterative method.

Default 1E-12
Range 0–1

gpu={pca_gpu}

specifies the settings for graphics processing units (GPUs). If you specify the groupBy subparameter in the table parameter, the gpu parameter is ignored. If no GPU is available, the CPU is used to perform model computation.

"enable":True | False

when set to True, enables the action to use GPUs to perform model computation on GPU-equipped machines (one GPU is used on each machine).

Default False

groupbyLimit=64-bit-integer

suppresses the analysis if the number of BY groups exceeds the specified value.

Minimum value 1

inputs=[{casinvardesc-1} <, {casinvardesc-2}, ...>]

specifies the variables to be analyzed. For the NIPALS, ITERGS, and EIG methods, you can analyze only numeric variables. If you omit the parameter, all numeric variables that are not specified in other parameters are analyzed. You must specify either INPUTS or MODEL for the RANDOMPCA method, but you can use both numeric and categorical variables.

For more information about specifying the inputs parameter, see the common casinvardesc parameter (Appendix A: Common Parameters).

Aliases input
vars
var

maxIter=integer

specifies the maximum number of iterations for the iterative method.

Default 500
Range 0–MACINT

n=integer

specifies the number of principal components to be computed. If the value is 0, all principal components are computed.

Default 0
Minimum value 0

noCenter=True | False

when set to True, suppresses centering of the numeric variables to be analyzed.

Default False

noScale=True | False

when set to True, suppresses scaling of the numeric variables to be analyzed.

Default False

output={iterOutput}

specifies the output table to be created to contain observationwise statistics. If you do not specify any statistic, then only the principal component scores are included.

The iterOutput value can be one or more of the following:

* "casOut":{casouttable}

specifies the output table.

For more information about specifying the casOut parameter, see the common casouttable (Form 1) parameter (Appendix A: Common Parameters).

"copyVars":["variable-name-1" <, "variable-name-2", ...>]

copies one or more variables from the input table to the output table.

Alias copyVar
"h":"string"

specifies the approximate leverage. If the value is an empty string, the prefix H is used to name the output variables.

"residual":"string"

specifies residuals for each analysis variable. If the value is an empty string, the prefix R is used to name the output variables.

Aliases r
resid
"score":"string"

specifies principal component scores for each principal component. If the value is an empty string, the prefix Score is used to name the output variables.

"std":"string"

specifies standardized (centered and scaled) analysis variable values for each analysis variable. If the value is an empty string, the prefix Std is used to name the output variables.

"stdsse":"string"

specifies the sum of squares of residuals for standardized analysis variables. If the value is an empty string, the prefix StdSSE is used to name the output variables.

"t2":"string"

specifies a scaled sum of squares of score values. If the value is an empty string, the prefix TSquare is used to name the output variables.

Alias tSquare

outputTables={outputTables}

lists the names of results tables to save as CAS tables on the server.

For more information about specifying the outputTables parameter, see the common outputTables parameter (Appendix A: Common Parameters).

Alias displayOut

prefix="string"

specifies a prefix for naming the principal components.

Default "Prin"

store={casouttable}

specifies the output table to be created to save model fit information that you can use for scoring.

For more information about specifying the store parameter, see the common casouttable (Form 1) parameter (Appendix A: Common Parameters).

Alias saveState

* table={castable}

specifies the settings for an input table.

For more information about specifying the table parameter, see the common castable (Form 1) parameter (Appendix A: Common Parameters).

varDef="DF" | "N" | "WDF" | "WEIGHT" | "WGT"

specifies the divisor to use in calculating variances and standard deviations.

Default DF

nipals Action

Extracts principal components by using the nonlinear iterative partial least squares (NIPALS) method.

R Syntax

results <– cas.pca.nipals(s,
attributes=list( list(
format="string",
formattedLength=integer,
label="string",
required parameter name="variable-name",
nfd=integer,
nfl=integer
) <, list(...)>),
code=list(
casOut=list(
caslib="string"
compress=TRUE | FALSE
indexVars=list("variable-name-1" <, "variable-name-2", ...>)
label="string"
lifetime=64-bit-integer
maxMemSize=64-bit-integer
memoryFormat="DVR" | "INHERIT" | "STANDARD"
name="table-name"
onDemand=TRUE | FALSE
promote=TRUE | FALSE
replace=TRUE | FALSE
replication=integer
tableRedistUpPolicy="DEFER" | "NOREDIST" | "REBALANCE"
threadBlockSize=64-bit-integer
timeStamp="string"
where=list("string-1" <, "string-2", ...>)
),
comment=TRUE | FALSE,
fmtWdth=integer,
indentSize=integer,
intoCutPt=double,
iProb=TRUE | FALSE,
labelId=integer,
lineSize=integer,
noTrim=TRUE | FALSE,
pCatAll=TRUE | FALSE,
tabForm=TRUE | FALSE
),
display=list(
caseSensitive=TRUE | FALSE,
exclude=TRUE | FALSE,
excludeAll=TRUE | FALSE,
keyIsPath=TRUE | FALSE,
names=list("string-1" <, "string-2", ...>),
pathType="LABEL" | "NAME",
traceNames=TRUE | FALSE
),
epsilon=double,
gpu=list(
enable=TRUE | FALSE
),
groupbyLimit=64-bit-integer,
inputs=list( list(
format="string",
formattedLength=integer,
label="string",
required parameter name="variable-name",
nfd=integer,
nfl=integer
) <, list(...)>),
maxIter=integer,
n=integer,
noCenter=TRUE | FALSE,
noScale=TRUE | FALSE,
output=list(
required parameter casOut=list(
caslib="string"
compress=TRUE | FALSE
indexVars=list("variable-name-1" <, "variable-name-2", ...>)
label="string"
lifetime=64-bit-integer
maxMemSize=64-bit-integer
memoryFormat="DVR" | "INHERIT" | "STANDARD"
name="table-name"
promote=TRUE | FALSE
replace=TRUE | FALSE
replication=integer
tableRedistUpPolicy="DEFER" | "NOREDIST" | "REBALANCE"
threadBlockSize=64-bit-integer
timeStamp="string"
where=list("string-1" <, "string-2", ...>)
),
copyVars=list("variable-name-1" <, "variable-name-2", ...>),
h="string",
residual="string",
score="string",
std="string",
stdsse="string",
t2="string"
),
outputTables=list(
groupByVarsRaw=TRUE | FALSE,
includeAll=TRUE | FALSE,
names=list("string-1" <, "string-2", ...>) | list(key-1=list(casouttable-1) <, key-2=list(casouttable-2), ...>),
repeated=TRUE | FALSE,
replace=TRUE | FALSE
),
prefix="string",
store=list(
caslib="string",
compress=TRUE | FALSE,
indexVars=list("variable-name-1" <, "variable-name-2", ...>),
label="string",
lifetime=64-bit-integer,
maxMemSize=64-bit-integer,
memoryFormat="DVR" | "INHERIT" | "STANDARD",
name="table-name",
promote=TRUE | FALSE,
replace=TRUE | FALSE,
replication=integer,
tableRedistUpPolicy="DEFER" | "NOREDIST" | "REBALANCE",
threadBlockSize=64-bit-integer,
timeStamp="string",
where=list("string-1" <, "string-2", ...>)
),
required parameter table=list(
caslib="string",
computedOnDemand=TRUE | FALSE,
computedVars=list( list(
format="string",
formattedLength=integer,
label="string",
required parameter name="variable-name",
nfd=integer,
nfl=integer
) <, list(...)>),
computedVarsProgram="string",
dataSourceOptions=list(key-1=list(any-list-or-data-type-1) <, key-2=list(any-list-or-data-type-2), ...>),
groupBy=list( list(
format="string",
formattedLength=integer,
label="string",
required parameter name="variable-name",
nfd=integer,
nfl=integer
) <, list(...)>),
groupByMode="NOSORT" | "REDISTRIBUTE",
importOptions=list(fileType="ANY" | "AUDIO" | "AUTO" | "BASESAS" | "CSV" | "DELIMITED" | "DOCUMENT" | "DTA" | "ESP" | "EXCEL" | "FMT" | "HDAT" | "IMAGE" | "JMP" | "LASR" | "PARQUET" | "SOUND" | "SPSS" | "VIDEO" | "XLS", fileType-specific-parameters),
required parameter name="table-name",
orderBy=list( list(
format="string",
formattedLength=integer,
label="string",
required parameter name="variable-name",
nfd=integer,
nfl=integer
) <, list(...)>),
singlePass=TRUE | FALSE,
vars=list( list(
format="string",
formattedLength=integer,
label="string",
required parameter name="variable-name",
nfd=integer,
nfl=integer
) <, list(...)>),
where="where-expression",
whereTable=list(
casLib="string"
dataSourceOptions=list(adls_noreq-parameters | bigquery-parameters | cas_noreq-parameters | clouddex-parameters | db2-parameters | dnfs-parameters | esp-parameters | fedsvr-parameters | gcs_noreq-parameters | hadoop-parameters | hana-parameters | impala-parameters | informix-parameters | jdbc-parameters | mongodb-parameters | mysql-parameters | odbc-parameters | oracle-parameters | path-parameters | postgres-parameters | redshift-parameters | s3-parameters | sapiq-parameters | sforce-parameters | singlestore_standard-parameters | snowflake-parameters | spark-parameters | spde-parameters | sqlserver-parameters | ss_noreq-parameters | teradata-parameters | vertica-parameters | yellowbrick-parameters)
importOptions=list(fileType="ANY" | "AUDIO" | "AUTO" | "BASESAS" | "CSV" | "DELIMITED" | "DOCUMENT" | "DTA" | "ESP" | "EXCEL" | "FMT" | "HDAT" | "IMAGE" | "JMP" | "LASR" | "PARQUET" | "SOUND" | "SPSS" | "VIDEO" | "XLS", fileType-specific-parameters)
required parameter name="table-name"
vars=list( list(
format="string",
formattedLength=integer,
label="string",
required parameter name="variable-name",
nfd=integer,
nfl=integer
) <, list(...)>)
where="where-expression"
)
),
varDef="DF" | "N" | "WDF" | "WEIGHT" | "WGT"
)
indicates a required parameter

Summary: Input and Output Tables

If a row includes a subparameter, you can specify the name, caslib, and so on in the subparameter. Otherwise, you can specify the name, caslib, and so on in the parameter.

Parameters for Reading Input Tables

Parameter

Subparameter

Description

required parametertable

specifies the settings for an input table.

Parameters for Creating Output Tables

Parameter

Subparameter

Description

 code

casOut

writes SAS DATA step code for computing predicted values of the fitted model.

 output

required parametercasOut

specifies the output table to be created to contain observationwise statistics. If you do not specify any statistic, then only the principal component scores are included.

 outputTables

names

lists the names of results tables to save as CAS tables on the server.

 store

specifies the output table to be created to save model fit information that you can use for scoring.

Parameter Descriptions

attributes=list( list(casinvardesc-1) <, list(casinvardesc-2), ...>)

changes the attributes of variables used in this action. Currently, attributes specified on the inputs and nominals parameter are ignored.

For more information about specifying the attributes parameter, see the common casinvardesc parameter (Appendix A: Common Parameters).

Aliases attribute
attr

code=list(aircodegen)

writes SAS DATA step code for computing predicted values of the fitted model.

For more information about specifying the code parameter, see the common aircodegen parameter (Appendix A: Common Parameters).

display=list(displayTables)

specifies a list of results tables to send to the client for display.

For more information about specifying the display parameter, see the common displayTables parameter (Appendix A: Common Parameters).

epsilon=double

specifies the convergence criterion for the iterative method.

Default 1E-12
Range 0–1

gpu=list(pca_gpu)

specifies the settings for graphics processing units (GPUs). If you specify the groupBy subparameter in the table parameter, the gpu parameter is ignored. If no GPU is available, the CPU is used to perform model computation.

enable=TRUE | FALSE

when set to True, enables the action to use GPUs to perform model computation on GPU-equipped machines (one GPU is used on each machine).

Default FALSE

groupbyLimit=64-bit-integer

suppresses the analysis if the number of BY groups exceeds the specified value.

Minimum value 1

inputs=list( list(casinvardesc-1) <, list(casinvardesc-2), ...>)

specifies the variables to be analyzed. For the NIPALS, ITERGS, and EIG methods, you can analyze only numeric variables. If you omit the parameter, all numeric variables that are not specified in other parameters are analyzed. You must specify either INPUTS or MODEL for the RANDOMPCA method, but you can use both numeric and categorical variables.

For more information about specifying the inputs parameter, see the common casinvardesc parameter (Appendix A: Common Parameters).

Aliases input
vars
var

maxIter=integer

specifies the maximum number of iterations for the iterative method.

Default 500
Range 0–MACINT

n=integer

specifies the number of principal components to be computed. If the value is 0, all principal components are computed.

Default 0
Minimum value 0

noCenter=TRUE | FALSE

when set to True, suppresses centering of the numeric variables to be analyzed.

Default FALSE

noScale=TRUE | FALSE

when set to True, suppresses scaling of the numeric variables to be analyzed.

Default FALSE

output=list(iterOutput)

specifies the output table to be created to contain observationwise statistics. If you do not specify any statistic, then only the principal component scores are included.

The iterOutput value can be one or more of the following:

* casOut=list(casouttable)

specifies the output table.

For more information about specifying the casOut parameter, see the common casouttable (Form 1) parameter (Appendix A: Common Parameters).

copyVars=list("variable-name-1" <, "variable-name-2", ...>)

copies one or more variables from the input table to the output table.

Alias copyVar
h="string"

specifies the approximate leverage. If the value is an empty string, the prefix H is used to name the output variables.

residual="string"

specifies residuals for each analysis variable. If the value is an empty string, the prefix R is used to name the output variables.

Aliases r
resid
score="string"

specifies principal component scores for each principal component. If the value is an empty string, the prefix Score is used to name the output variables.

std="string"

specifies standardized (centered and scaled) analysis variable values for each analysis variable. If the value is an empty string, the prefix Std is used to name the output variables.

stdsse="string"

specifies the sum of squares of residuals for standardized analysis variables. If the value is an empty string, the prefix StdSSE is used to name the output variables.

t2="string"

specifies a scaled sum of squares of score values. If the value is an empty string, the prefix TSquare is used to name the output variables.

Alias tSquare

outputTables=list(outputTables)

lists the names of results tables to save as CAS tables on the server.

For more information about specifying the outputTables parameter, see the common outputTables parameter (Appendix A: Common Parameters).

Alias displayOut

prefix="string"

specifies a prefix for naming the principal components.

Default "Prin"

store=list(casouttable)

specifies the output table to be created to save model fit information that you can use for scoring.

For more information about specifying the store parameter, see the common casouttable (Form 1) parameter (Appendix A: Common Parameters).

Alias saveState

* table=list(castable)

specifies the settings for an input table.

For more information about specifying the table parameter, see the common castable (Form 1) parameter (Appendix A: Common Parameters).

varDef="DF" | "N" | "WDF" | "WEIGHT" | "WGT"

specifies the divisor to use in calculating variances and standard deviations.

Default DF
Last updated: March 05, 2026