cor_coeff function installation help - a custom function to calculate the sample correlation coefficient between the Williams-%R for a stock or industry and the 5-index Williams-%R. Directions: Check Column "CY" to see if the cor_coeff function is working. If it is working without any error indications, then you do not need to do anything further. If you get a "#VALUE!" or "#NAME?" error, then follow procedures below. There are two alternative methods for activating the cor_coeff function. Method 1: ======= Download the industries spreadsheet and the file User_functionsA.xla and move them to a reference folder. Open the Industries worksheet sheet and then open the external link reference. Edit > Links Click on the "Change Source" button and browse until you find the file User_functionsA.xla. Then click on it, click OK and then close the dialog box. At this point the cor_coeff function should be operational. Method 2: ======= Download the industries spreadsheet. Open the Industries worksheet sheet and then open the external link reference. Edit > Links Click on the button "Break Links". Then click on it, click OK and then close the dialog box. Next, open the Visual Basic Editor using the Tools pull-down menu. Tools > Macro > Visual Basic Editor In the Visual Basic Editor create a new module Insert > New Module Copy and paste everything beneath the line below into the new window that opens up. Then close the editor. File > Close and Return to Microsoft Excel Save the Industries spreadsheet and reopen it. COPY EVERYTHING BELOW THIS LINE INTO THE NEW MODULE WINDOW for method 2________________________ Function Cor_Coeff(x1, x2, x3, x4, x5, x6, x7, x8, x9, x10, x11, _ y1, y2, y3, y4, y5, y6, y7, y8, y9, y10, y11) ' Calculates the sample correlation coefficient for two pairs of series "x" and "y" ' that each has 11 values. ' Syntax: Checklist(x1, x2, x3, x4, x5, x6, x7, x8, x9, x10, x11, ' y1, y2, y3, y4, y5, y6, y7, y8, y9, y10, y11) ' ' s1 = 11 * (x1 ^ 2 + x2 ^ 2 + x3 ^ 2 + x4 ^ 2 + x5 ^ 2 + x6 ^ 2 + x7 ^ 2 + x8 ^ 2 + x9 ^ 2 + x10 ^ 2 + x11 ^ 2) s2 = (x1 + x2 + x3 + x4 + x5 + x6 + x7 + x8 + x9 + x10 + x11) ^ 2 Sxx = s1 - s2 s3 = 11 * (y1 ^ 2 + y2 ^ 2 + y3 ^ 2 + y4 ^ 2 + y5 ^ 2 + y6 ^ 2 + y7 ^ 2 + y8 ^ 2 + y9 ^ 2 + y10 ^ 2 + y11 ^ 2) s4 = (y1 + y2 + y3 + y4 + y5 + y6 + y7 + y8 + y9 + y10 + y11) ^ 2 Syy = s3 - s4 s5 = 11 * (x1 * y1 + x2 * y2 + x3 * y3 + x4 * y4 + x5 * y5 + x6 * y6 + x7 * y7 + x8 * y8 + x9 * y9 + x10 * y10 + x11 * y11) s6 = (x1 + x2 + x3 + x4 + x5 + x6 + x7 + x8 + x9 + x10 + x11) * (y1 + y2 + y3 + y4 + y5 + y6 + y7 + y8 + y9 + y10 + y11) Sxy = s5 - s6 Cor_Coeff = Sgn(Sxy) * Sxy ^ 2 / (Sxx * Syy) Exit Function End Function