The P_CORRELATE function computes the partial correlation coefficient of a dependent variable and one particular independent variable when the effects of all other variables involved are removed.

This routine is written in the IDL language. Its source code can be found in the file ```
p_correlate.pro
```

in the ```
lib
```

subdirectory of the IDL distribution.

An *
n*
-element integer, single-, or double-precision floating-point vector that specifies the independent variable data.

Define three sample populations:

X0 = [64, 71, 53, 67, 55, 58, 77, 57, 56, 51, 76, 68]

X1 = [57, 59, 49, 62, 51, 50, 55, 48, 52, 42, 61, 57]

X2 = [ 8, 10, 6, 11, 8, 7, 10, 9, 10, 6, 12, 9]

result = P_CORRELATE(X0, X1, REFORM(X2, 1, N_ELEMENTS(X2)))

*;
Compute the partial correlation of X0 and X1 with the effects of X2 removed.*

A_CORRELATE , CORRELATE , C_CORRELATE , M_CORRELATE , R_CORRELATE