back start next
[start] [1] [2] [3] [4] [5] [6] [7] [8] [9] [10] [ 11 ] [12] [13] [14] [15] [16] [17] [18] [19] [20] [21] [22] [23] [24] [25] [26] [27] [28] [29] [30] [31] [32] [33] [34] [35] [36] [37] [38] [39] [40] [41] [42] [43] [44] [45] [46] [47] [48] [49] [50] [51] [52] [53] [54] [55] [56] [57] [58] [59] [60] [61] [62] [63] [64] [65] [66] [67] [68] [69] [70] [71] [72] [73] [74] [75] [76] [77] [78] [79] [80] [81] [82] [83] [84] [85] [86] [87] [88] [89] [90] [91] [92] [93] [94] [95] [96] [97] [98] [99] [100] [101] [102] [103] [104] [105] [106] [107] [108] [109] [110] [111] [112] [113] [114] [115] [116] [117] [118] [119] [120] [121] [122] [123] [124] [125] [126] [127] [128] [129] [130] [131] [132] [133] [134] [135] [136] [137] [138] [139] [140] [141] [142] [143] [144] [145] [146] [147] [148] [149] [150] [151] [152] [153] [154] [155] [156] [157] [158] [159] [160] [161] [162] [163] [164] [165] [166] [167] [168] [169] [170] [171] [172] [173] [174] [175] [176] [177] [178] [179] [180] [181] [182] [183] [184] [185] [186] [187] [188] [189] [190] [191] [192] [193] [194] [195] [196] [197] [198] [199] [200] [201] [202] [203] [204] [205]
11 "I Ik line that causes S to be the snriallest: possible value will be tbe best choice for these <Jatn points rhe square of y, always positive, thereby TnaniSyin the imnportance of those <lata points that are farther from the approximated line on either side and reduone the signi tican of those piiints for which the approximation is good To use thr lei* tsquare . imethod for solvirvg th comsoybean pnce relationship, look for the solution to the straight line, = ti + bx, expressed as Here, N is the number of data points and 1 represents the sum over N points. To solve these equations, construct a table of com and soybean values and calculate all ttie unique sums in the preceding formulas individually" (Table 32). Substitute these values into the formulas and solve for a and b. 13 4 >  1 = .336 The etiuation for the li Selecting values of x and solving for gives the results shown in Table 33. The results of the linear approximation are shown in Fure 33. The slope of .336 indicates that for every $1 increase in the price of soybeans, ttiere is a corresponding increase of 33.60 in corn. This is not far from what would be expected for farm income. Because the corn yield per acre is 2.5 times greater than the soybean yield in most parts of the United States, the ratio 1/2.5 should yield a slope of about .4. Considering areas where soybeans are altematives to cotton and other crops, and the tendency for midwest farmers to plant mostly corn, a relatively higher price for soybeans is not surprising. Letting ttie Computer Do ttie Work Having methodically worked through the calculations for linear regression, it should not be a surprise that the solution is readily available on any spreadsheet program or in strat lAppen.l,::2..a"er.ac.jiuterpr ram to solve the .Iri ht4ine f tiieir asw asthe iihiiear pies TABLE 32 Totals for LeastSquares Solution
egj testing software. Nevertheless, it is difficult to use the results of these programs unless you can interpret the answer. Spreadsheet programs simply require that you indicate the two columns that represent the independent and dependent variables. If you simply want to have time as the independent variable, you can create a column of sequential numbers: 1, 2, 3, and so forth. The spreadsheet program will give you a table of statistics including the slope, yintercept, and correlation coefficient (discussed in the next section), and a level of confidence. Look for a Regression Dialog Box in your spreadsheet program and follow the instructions. It is often found under Tools 1 Numeric Tools 1 Regression. Programming Tools More specific tools are available in strategj testing software, although all of it is restricted to linear regression. You should expect to find ftmctions that will find the following: FIGLIRE 33 Scatter diagram of com, sojbean pairs with Imear regression solution. Linear regression slopereturns the slope of the straight line given the data series (e.g.. the closing prices) and the period over which the line will be drawn (e.g.. 20 dajs). Linear regression anglethe same as the slope ftmction but the answer is expressed in degrees Linear regression valuecalculates the slope of the regression line then projects that line into the ftiture, returning the value of the ftiture point. This requires the user to spedfj the data series, the period over which the line will be calculated, and the number of periods into the ftiture. Projecting the value can also be done by finding the slope, s, and performing the following calculation: Projected price = starting price + s x (calculation period + projection period) where the starting price is at the beginning of the calculation period. LINEAR CORRELATION
solving the leastsquares equation for the best fit does not mean that the answer can be used. there is alwajs a solution to the least squares method, but there might not be a valid linear relationship between the two sets of data. you may think that two data items affect one another, such as the amount of disposable income and the purchase of television sets, but that might not be the case. the linear correlation, which uses a value called the coefficient of determination r,(sq) or the correlation coefficient, expresses the relationship of the data on a scale from +1 (perfect positive correlation), to 0 (no relationship between the data), to 1 (perfect negative correlation), as shown in figure 34. the correlation coefficient is derived from the deviation, or vanation, in the data. it is based on the relationship [ill cttrvi:<l.ii>i1 = total i=?*4. rpluinetil (leviuiioEi + uiieKplaioccI cleiiaiirin 4 i. y,  v> "If sum hf intliviiUial tlifff rentres from if. x < V, jo tlie Mim of the tliftWerites hetwetn t tht Fitittl lint and the ai/erage; explained ticfiat ft tn is £ (v.  V.>. he sum ot" tht remaining loretzast Lbanjinit this into .« ratio gives Lintfxplained deviation iot;il ciexiation = L s alreadj culcuialed (/vX> SSj) otherieht appljtng the formula to the comsoybean data and usmg the sums fran table 32 gives
[start] [1] [2] [3] [4] [5] [6] [7] [8] [9] [10] [ 11 ] [12] [13] [14] [15] [16] [17] [18] [19] [20] [21] [22] [23] [24] [25] [26] [27] [28] [29] [30] [31] [32] [33] [34] [35] [36] [37] [38] [39] [40] [41] [42] [43] [44] [45] [46] [47] [48] [49] [50] [51] [52] [53] [54] [55] [56] [57] [58] [59] [60] [61] [62] [63] [64] [65] [66] [67] [68] [69] [70] [71] [72] [73] [74] [75] [76] [77] [78] [79] [80] [81] [82] [83] [84] [85] [86] [87] [88] [89] [90] [91] [92] [93] [94] [95] [96] [97] [98] [99] [100] [101] [102] [103] [104] [105] [106] [107] [108] [109] [110] [111] [112] [113] [114] [115] [116] [117] [118] [119] [120] [121] [122] [123] [124] [125] [126] [127] [128] [129] [130] [131] [132] [133] [134] [135] [136] [137] [138] [139] [140] [141] [142] [143] [144] [145] [146] [147] [148] [149] [150] [151] [152] [153] [154] [155] [156] [157] [158] [159] [160] [161] [162] [163] [164] [165] [166] [167] [168] [169] [170] [171] [172] [173] [174] [175] [176] [177] [178] [179] [180] [181] [182] [183] [184] [185] [186] [187] [188] [189] [190] [191] [192] [193] [194] [195] [196] [197] [198] [199] [200] [201] [202] [203] [204] [205]
