# Generating TERR Graphics in Spotfire Using Predictive Modeling

Spotfire supports using the TERR engine to create built-in predictive analytics, writing expression functions for ad hoc analysis, or writing more sophisticated scripts to call hand-crafted data functions. The type of prediction to undertake is determined by your data and the kind of an analysis you need to do.

Note: Spotfire provides a range of complex statistical solutions. We address working just with the TERR engine. For more information on working with other statistical engines, see the Spotfire help.

- Access Spotfire predictive modeling from the Tools menu in the Spotfire user interface. This feature delivers visualizations that require no scripting. They are applicable to certain kinds of data sets, generally for common types of predictive statistical analyses. These include the following predictive models.
  - Linear regression
  - Regression tree
  - Logistic regression
  - Classification tree
  See Predictive modeling and the topic What is Predictive Modeling? in the Spotfire help for more information.
- Compute Holt-Winters forecasting in Spotfire from a line chart displaying time series. See the topic Curve Fit Models in the Spotfire help for more information.
- Access Spotfire expression functions that call the TERR engine from the Insert > Calculated Column menu or the Custom Expression dialog box. Use expression functions to call TERR scripts directly from the Spotfire expression language for ad hoc analysis. Alternatively, you can write and store an expression function for later use from the Edit > Data Function Properties, Expression Functions tab. See Expression functions for more information.
- You can access Spotfire data functions from several menus in Spotfire. Begin by finding it in the Tools > Register Data Functions menu in Spotfire. Using data functions, you can map input parameters to columns in your data table in Spotfire, and then use the data function output to create a data table to add to your visualization. You can develop data functions offline, edit an existing data function, or share a data function with others, and then use them in Spotfire to create visualizations. See the section Data functions for more information and example tasks. Also, in the Spotfire help, see the topic How to Use Data Functions for information about managing data functions in Spotfire.