🎉Community Raffle - Win $25

An exclusive raffle opportunity for active members like you! Complete your profile, answer questions and get your first accepted badge to enter the raffle.
Join and Win

Workflow: Predicting a binary variable with the Logistic Regression block

IanBDUser: "IanBD"
Altair Employee
Updated by IanBD

The Logistic Regression block enables you to apply a logistic regression predictive model to a dataset.

The following demonstrates how to use the Logistic Regression block to create a logistic regression model for an input dataset ExamResults.csv (which contains observations that describe a range of test scores from a schoo) that predicts the likelihood of a student passing an exam based on their hours of study.

  1. Import the ExamResults.csv dataset onto a Workflow canvas using the Text File Import block.
  2. Expand the Model Training group in the Workflow palette, then click and drag a Logistic Regression block onto the Workflow canvas.
  3. Click the Output port of the ExamResults dataset block and drag a connection towards the Input port of the Logistic Regression block.
  4. Double-click the Logistic Regression block to display the Configure Logistic Regression dialog box.
  5. In the Logistic Regression dialog box:
    1. In the Dependent variable drop-down list, select Pass?.
    2. From the Event drop-down list, select 1 (one).
    3. In the Unselected Effect Variables list, select HoursStudy.
    4. Click Select to move the variable to the Selected Effect Variables list.
    5. Clear the Class checkbox for the variable.
  6. Click OK to save the configuration and close the Configure Logistic Regression dialog box.

A green execution status is displayed in the Output ports of the Logistic Regression block and the new Logistic Regression Model. The Logistic Regression block output can be used with a Score block to make predictions on a dataset.

Comments

No comments on this post.