. /* Below two examples on how to use R_BIS.SPS and R_TETRA.SPS. */ /* To make the syntax work you have to edit this file as a */ /* SPSS-Syntax file into the SPSS syntax window, then select */ /* the whole or parts of it and press the RUN button at the top */ /* of syntax window. */ /* */ /* A note of caution: "Caution should be exercised in the use of */ /* biserial and tetrachoric correlations, particularly in */ /* multivariate analyses. Remember that they are not observed */ /* correlations in the data, but rather hypothetical ones */ /* depending on the normality of the distributions underlying */ /* the dichotomies." (Cohen & Cohen, 1983, p. 67) */ /* */ /* Cohen, J. & Cohen, P. (1983). Applied multiple regression/ */ /* correlation analysis for the behavioral sciences. */ /* Hillsdale, NJ: Lawrence Erlbaum. */ /* ------------------------------------------------------------ */ /* Example 1: First, you have to define the macro by using the */ /* include command of the respective file (only */ /* once per SPSS session). Assuming that the file */ /* R_BIS.SPS is located in the folder C:\SPSSWIN\JOBS */ /* the command is: */ include 'c:\spsswin\jobs\r_bis.sps'. /* Now you have to define your data. Using your own real data, */ /* instead of the following block from DATA LIST to END DATA you */ /* have to get your data file interactively or via the GET */ /* command: */ data list list /x y. begin data 0 67 0 72 0 70 0 69 1 66 1 64 1 68 end data. /* In this case you have only 7 cases (less than 41), thus, */ /* there is no need to change the default value for mxloop. */ /* Otherwise, you would have to increase this value via the SET */ /* command to a number that is >= the number of cases in your */ /* data file. Assuming that you have 2345 cases, you could use */ /* the following command: */ SET MXLOOP=2400. /* Now you can calculate the biserial correlation of the */ /* dichotomous variable x and the continous variable y: */ r_bis x y. /* If you want to save your data, remember that the above call */ /* of the macro has renamed your current data file to */ /* _temp_.sav (its content, however, has remained the same). */ /* In order to compare the result with the Pearson product */ /* moment correlation you can use the SPSS procedure */ /* CORRELATION: */ corr x y. /* ------------------------------------------------------------ */ /* Example 2: First, you have to define the macro by using the */ /* include command of the respective file (only */ /* once per SPSS session). Assuming that the file */ /* R_TETRA.SPS is located in the folder */ /* C:\SPSSWIN\JOBS the command is: */ include 'c:\spsswin\jobs\r_tetra.sps'. /* Now you have to define your data. Using your own real data, */ /* instead of the following block from DATA LIST to END DATA you */ /* have to get your data file interactively or via the GET */ /* command: */ data list list /x y. begin data 0 1 1 1 0 0 0 0 1 0 1 1 0 0 1 1 0 0 1 1 end data. /* In this case you have only 10 cases (less than 41), thus, */ /* there is no need to change the default value for mxloop. */ /* Otherwise, you would have to increase this value via the SET */ /* command to a number that is >= your number of cases in your */ /* data file. Assuming that you have 2345 cases, you could use */ /* the following command: */ SET MXLOOP=2400. /* Now you can calculate the tetrachoric correlation of the */ /* dichotomous variables x and y: */ tetcorr x y. /* If you want to save your data, remember that the above call */ /* of the macro has renamed your current data file to */ /* _temp_.sav (its content, however, has remained the same). */ /* In order to compare the result with the Pearson product */ /* moment correlation you can use the SPSS procedure */ /* CORRELATION: */ corr x y. /* In case that SPSS does no longer report the commands issued, */ /* use the following SET-command: */ set printback=on.