R Extension Commands for SPSS Statistics
IBM® SPSS® Statistics - Essentials for R includes a
set of working examples of R extensions for IBM SPSS Statistics that provide
capabilities beyond what is available with built-in SPSS Statistics
procedures. All of the R extensions include a custom dialog and an extension command. The extension
commands can be run from SPSS Statistics command
syntax in the same manner as any built-in command such as
FREQUENCIES. You can
generate command syntax for each extension command from the associated custom dialog.
|Menu location||Command name||Description|
|Analyze>Reports>Apriori||SPSSINC APRIORI||Discover frequent itemsets, association rules using the Apriori algorithm.|
|Analyze>Correlate>Heterogeneous Correlations||SPSSINC HETCOR||Calculate correlations between nominal, ordinal, and scale variables.|
|Analyze>Descriptive Statistics>Two-Variable or Group Q-Q Plot||SPSSINC QQPLOT2||Two variable or two group Q-Q plot.|
|Analyze>Regression>Quantile Regression||SPSSINC QUANTREG||Estimate one or more conditional quantiles for a linear model.|
|Analyze>RanFor Estimation||SPSSINC RANFOR||Estimate random forest.|
|Analyze>Ranfor Prediction||SPSSINC RANPRED||Compute predicted values for new data using forests from SPSSINC RANFOR.|
|Analyze>Regression>Robust Regression||SPSSINC ROBUST REGR||Estimate a linear regression model by robust regression, using an M estimator.|
|Analyze>Regression>Tobit Regression||SPSSINC TOBIT REGR||Estimate a regression model whose dependent variable has a fixed lower bound, upper bound, or both.|
|Analyze>Survival>Cox Regression Extension||STATS COXREGR||Cox (proportional hazards) regression.|
|Analyze>Classify>Predict Using Density Cluster||STATS DBPRED||Prediction based on density-based clustering.|
|Analyze>Classify>Density-Based Clustering||STATS DBSCAN||Density-based clustering.|
|Analyze>Regression>Equation Systems||STATS EQNSYSTEM||Estimate system of linear equations.|
|Analyze>Scale>Extended Rasch||STATS EXRASCH||Calculate standard and extended Rasch models.|
|Analyze>Regression>Firth Logistic Regression||STATS FIRTHLOG||Firth logistic regression.|
|Analyze>Forecasting>GARCH Models||STATS GARCH||GARCH models.|
|Analyze>Generalized Linear Models>Generalized Boosted Regression||STATS GBM||Estimate generalized boosted regression models.|
|Analyze>Generalized Linear Models>Generalized Boosted Regression Prediction||STATS GBMPRED||Calculate predictions for generalized boosted regression models.|
|File>Get R Workspace||STATS GET R||Get information about R workspace contents and create SPSS datasets.|
|Analyze>Scale>Graded Response Model||STATS GRM||Fit graded response models to ordinal data.|
|Analyze>Scale>Item Response Model||STATS IRM||Fit three parameter item response models.|
|Analyze>Loglinear>Latent Class Analysis||STATS LATENT CLASS||Latent Class Analysis.|
|Analyze>Descriptive Statistics>Calculate Adjusted P Values||STATS PADJUST||Calculate p-values adjusted for multiple testing.|
|Analyze>Generalized Linear Models>Proportional Regression||STATS PROPOR REGR||Linear models for dependent variables that are proportions.|
|Analyze>Generalized Linear Models>Proportional Regression Prediction||STATS PROPOR REGRPRED||Calculate predicted values for proportional regression models.|
|Analyze>Regression>Regression Discontinuity||STATS RDD||Regression discontinuity analysis.|
|Analyze>Regression>Regression Relative Importance||STATS RELIMP||Relative importance measures for regression.|
|Analyze>Survival>Parametric Regression||STATS SURVREG||Parametric survival regression.|
|Analyze>Classify>Support Vector Machines||STATS SVM||Support vector machine.|
|Analyze>Generalized Linear Models>Zero-Inflated Count Models||STATS ZEROINFL||Estimate and predict a zero-inflated count model.|
The Heterogeneous Correlations extension requires both the IBM SPSS Statistics - Integration Plug-in for R and the IBM SPSS Statistics - Integration Plug-in for Python. The IBM SPSS Statistics - Integration Plug-in for Python is included with IBM SPSS Statistics - Essentials for Python, which is installed by default with your IBM SPSS Statistics product.
- Help for each of the R extensions is available from the Help button on the associated dialog box. The help is not, however, integrated with the SPSS Statistics Help system.
- Complete syntax help for each of the extension commands is available by positioning the cursor
within the command (in a syntax window) and pressing the F1 key. It is also available by running the
command and including the
/HELPsubcommand. For example:
SPSSINC HETCOR /HELP.The command syntax help is not, however, integrated with the SPSS Statistics Help system and is not included in the Command Syntax Reference.Note: The F1 mechanism for displaying help is not supported in distributed mode.
- If the menu location that is specified for an extension command is not present in your IBM SPSS Statistics product, then look on the Extensions menu for the associated dialog.
- The dialogs were created with the Custom Dialog Builder in IBM SPSS Statistics. You can view the design for any of the dialogs and you can customize them using the Custom Dialog Builder. It is available from Extensions>Utilities>Custom Dialog Builder (Compatibility mode).... To view the design for a dialog, choose File>Open Installed from within the Custom Dialog Builder.
- The implementation code (R source code file) and XML specification files for each of the R
extension commands can be found in the location where extension commands are installed on your
computer. To view the location, run the
SHOW EXTPATHSsyntax command. The output displays a list of locations under the heading "Locations for extension commands". The files are installed to the first writable location in the list.
- You may need to set your SPSS Statistics locale to
match the SPSS Statistics output
OLANG) in order to display extended characters properly, even when working in Unicode mode. For example, if the output language is Japanese then you may need to set your SPSS Statistics locale to Japanese, as in
- Other extension commands that are not included in IBM SPSS Statistics - Essentials for R are available
for download from the Extension Hub, accessible from Extensions>Extension
Hub. The Extension Hub also displays any updates that are available for the extension
commands included with IBM SPSS Statistics - Essentials for R in addition to
updates for any other extensions that you installed.Note: Extensions are always installed, or downloaded, to your local computer from the Extension Hub. If you work in distributed analysis mode, then you must separately install the extensions on the server. For information, see Core System > Extensions> Installing local extension bundles in the Help system.
- If you are installing extensions on SPSS Statistics Server, you can use a script to install multiple extensions at once. For information, see Core System > Extensions> Installing local extension bundles > Batch installation of extension bundles in the Help system.