turn on suggestions

Auto-suggest helps you quickly narrow down your search results by suggesting possible matches as you type.

Showing results for

- JMP User Community
- :
- Discussions
- :
- Plotting Multiple linear regression line on one gr...

Topic Options

- Subscribe to RSS Feed
- Mark Topic as New
- Mark Topic as Read
- Float this Topic for Current User
- Bookmark
- Subscribe
- Printer Friendly Page

- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Get Direct Link
- Email to a Friend
- Report Inappropriate Content

May 16, 2017 1:59 AM
(630 views)

Hi There!

I have 10 Y measurements all against one X, how do I compare the responses on one graph using the linear regression lines (on the scatterplots)? The Y are in triplicates. I have attached the Excel file with the data.

2 ACCEPTED SOLUTIONS

Accepted Solutions

- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Get Direct Link
- Email to a Friend
- Report Inappropriate Content

May 16, 2017 2:29 AM
(1242 views)

Solution

There are three ways that you use to 'compare' the 10 regressions. You need to stack the ten Y columns first for all ten of them to work.(Select Tables > Stack) Try these methods with the stacked data table:

- Bivariate: Select Analyze > Fit Y by X. Enter the column of stacked measurements in Y role and predictor in X role. Click OK. Click the red triangle at the top of Bivariate and select Group by. Select the label column to identify the groups and click OK. Now click the red triangle again and select Fit Line.
- Fit Least Squares: Select Analyze > Fit Model. Enter the column of stacked measurements in Y role. Select the predictor X column and the label column. Click Macros and select Full Factorial. Click Run.
- Graph Builder: Select Graph > Graph Builder. Drag column of stacked measurements to Y drop zone and the predictor X column to the X zone. Drag the label column to the Overlay zone. Remove the smooth element and add the regression element (use element buttons above the canvas or right-click the canvas and use menu commands).

Learn it once, use it forever!

- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Get Direct Link
- Email to a Friend
- Report Inappropriate Content

May 16, 2017 4:58 AM
(1224 views)

Solution

- 1. Select
**File**>**Preferences**>**Fonts**. - It depends on your method.
**Bivariate**: the equation for each group is provided in separate reports below the plot.- See
**Help**>**Books**>**Basic Analysis**> chapter 5.

- See
**Fit Least Squares**: this model is more complex so there isn't a separate equation for each group. Instead, there are separate parameters for each group. It should be clear from the Parameter Estimates report but you can also see it in the column formula is you click the red triangle next to Response and select**Save Columns**>**Prediction Formula**.- See
**Help**>**Books**>**Fitting Linear Models**> chapter 3.

- See
**Graph Builder**: the equations for the linear trend lines are available in the properties on the left side below the list of columns.- See
**Help**>**Books**>**Essential Graphing**>**Line of Fit**in chapter 3.

- See

Learn it once, use it forever!

3 REPLIES

- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Get Direct Link
- Email to a Friend
- Report Inappropriate Content

May 16, 2017 2:29 AM
(1243 views)

There are three ways that you use to 'compare' the 10 regressions. You need to stack the ten Y columns first for all ten of them to work.(Select Tables > Stack) Try these methods with the stacked data table:

- Bivariate: Select Analyze > Fit Y by X. Enter the column of stacked measurements in Y role and predictor in X role. Click OK. Click the red triangle at the top of Bivariate and select Group by. Select the label column to identify the groups and click OK. Now click the red triangle again and select Fit Line.
- Fit Least Squares: Select Analyze > Fit Model. Enter the column of stacked measurements in Y role. Select the predictor X column and the label column. Click Macros and select Full Factorial. Click Run.
- Graph Builder: Select Graph > Graph Builder. Drag column of stacked measurements to Y drop zone and the predictor X column to the X zone. Drag the label column to the Overlay zone. Remove the smooth element and add the regression element (use element buttons above the canvas or right-click the canvas and use menu commands).

Learn it once, use it forever!

- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Get Direct Link
- Email to a Friend
- Report Inappropriate Content

May 16, 2017 4:00 AM
(617 views)

Thank you very much both methods have worked very well. I have two more questions,

1. How do I format the Y and X axis titles, I have been able to change the naming but not able to bold or increase the font size. Formaing the Y and X axis scale I have managed.

2. Is it possible to obtain the Equation of each of the line fitted in the model? How do I do that?

- Mark as New
- Bookmark
- Subscribe
- Subscribe to RSS Feed
- Get Direct Link
- Email to a Friend
- Report Inappropriate Content

May 16, 2017 4:58 AM
(1225 views)

- 1. Select
**File**>**Preferences**>**Fonts**. - It depends on your method.
**Bivariate**: the equation for each group is provided in separate reports below the plot.- See
**Help**>**Books**>**Basic Analysis**> chapter 5.

- See
**Fit Least Squares**: this model is more complex so there isn't a separate equation for each group. Instead, there are separate parameters for each group. It should be clear from the Parameter Estimates report but you can also see it in the column formula is you click the red triangle next to Response and select**Save Columns**>**Prediction Formula**.- See
**Help**>**Books**>**Fitting Linear Models**> chapter 3.

- See
**Graph Builder**: the equations for the linear trend lines are available in the properties on the left side below the list of columns.- See
**Help**>**Books**>**Essential Graphing**>**Line of Fit**in chapter 3.

- See

Learn it once, use it forever!