# pzconf: Calculate Confidence Intervals for the Difference of Zero... In zeroEQpart: Zero Order vs (Semi) Partial Correlation Test and CI

## Description

The `pzconf` function calculates confidence intervals for a zero order correlation minus a (semi) partial correlation (ρ.xy - ρ.xy.z). It is intended to be used after the `pzcor` function.

## Usage

 `1` ```pzconf(pzcor_obj, level = 0.9) ```

## Arguments

 `pzcor_obj` pzcor object (output from pzcor function). `level` numerical. Confidence level used to calculate the confidence interval. This may be a vector so multiple intervals can be determined.

## Details

The `pzconf` function calculates confidence intervals based on the bootstrap distribution determined from the `pzcor` function. See `?pzcor` for details.

## Value

The confidence interval(s) is(are) displayed in a dataframe with four columns: Level, Lower, Upper, and Warnings. Level refers to the confidence level of the interval. Lower and Upper are the respective lower and upper bounds of the interval. Warnings may say "Max Level Passed" to show that the specified confidence level exceeds the largest confidence interval that can be determined from the test. The largest confidence interval is shown in the last row (named "Max").

`pzcor`
 ``` 1 2 3 4 5 6 7 8 9 10 11 12``` ```require(graphics) require(MASS) # data set.seed(1111) mu <- rep(0,4) Sigma <- matrix(.2, nrow=4, ncol=4) + diag(4)*.8 data <- mvrnorm(n=100, mu=mu, Sigma=Sigma) # p.(1,2) = p.(1,2)|(3,4) test test <- pzcor(data[,1], data[,2], data[,c(3,4)], k = 1000) hist(test\$distribution) pzconf(test, c(0.9, 0.95, 0.99)) ```