XL4: Line Not Straight in Chart Created with Regression ToolID: Q98452
|
If you use the Regression tool in the Analysis ToolPak, the chart created by selecting the Line Fit Plots option in the Regression dialog box may not contain a straight line.
The line is not straight because the chart that is created is a line chart instead of an xy (scatter) chart.
This is a known problem in Microsoft Excel 4.0. This problem does not occur in Microsoft Excel versions 5.0 and later.
Because a line chart is created instead of an xy chart, the resulting
chart does not contain a straight line for the predicted Y values.
This problem occurs when the X values are not sequential. For example,
if the X values are 1, 2, 3, 4, 5, 6, and so on, a line chart will
plot a straight line for the predicted Y values. However, if the X
values are 1, 2, 5, 6, 10, and 12, a line chart will not plot a
straight line for the predicted Y values.
In order to plot a straight line for the predicted Y values, you must
use an xy (scatter) chart.
Change the chart that was created with the Regression tool to an xy
(scatter) chart:
A1: X B1: Y C1: Predicted Y
A2: 1 B2: 40
A3: 2 B3: 80
A4: 5 B4: 100
A5: 6 B5: 120
A6: 10 B6: 110
A6: 12 B7: 130
=TREND(B2:B7,A2:A7)Note: To enter this formula as an array, press CTRL+SHIFT+ENTER (if you are using Microsoft Excel for Windows), or press COMMAND+ENTER (if you are using Microsoft Excel for the Macintosh).
excel and curve and fitting
"Microsoft Excel Function Reference," version 4.0, page 436
"Microsoft Excel User's Guide 1," version 4.0, page 413
"Microsoft Excel User's Guide 2," version 4.0, pages 41-45
Additional query words: 4.00a ATP add-in addin add in graph tool pack pak best-fit best fit analysis tool pack \* \* M_eXceL
Keywords : xlchart
Version : WINDOWS:4.0,4.0a; MACINTOSH:4.0
Platform : MACINTOSH WINDOWS
Issue type : kbprb
Last Reviewed: April 6, 1999