| Type: | Package | 
| Title: | Correcting for Attenuation Due to Measurement Error | 
| Version: | 1.0.0 | 
| Description: | Confidence curves, confidence intervals and p-values for correlation coefficients corrected for attenuation due to measurement error. Implements the methods described in Moss (2019, <doi:10.48550/arXiv.1911.01576>). | 
| License: | MIT + file LICENSE | 
| URL: | https://github.com/JonasMoss/attenuation/ | 
| BugReports: | https://github.com/JonasMoss/attenuation/issues | 
| Encoding: | UTF-8 | 
| LazyData: | true | 
| Suggests: | testthat, covr, spelling | 
| RoxygenNote: | 6.1.1 | 
| Language: | en-US | 
| NeedsCompilation: | no | 
| Packaged: | 2019-11-06 17:29:17 UTC; jonas | 
| Author: | Jonas Moss | 
| Maintainer: | Jonas Moss <jonas.gjertsen@gmail.com> | 
| Repository: | CRAN | 
| Date/Publication: | 2019-11-08 09:00:02 UTC | 
Confidence curves for attenuated correlation coefficients.
Description
Confidence curves for attenuated correlation coefficients.
Usage
cc(r, N, lower = -1, upper = 1, by = 0.001, method = "corr",
  k = NULL)
Arguments
| r | Numeric vector of three elements in [-1,1].  | 
| N | Numeric vector of three positive integers.  | 
| lower | Lower bound for the curve. Defaults to -1. | 
| upper | Upper bound for the curve. Defaults to 1. | 
| by | Increment of the sequence from  | 
| method | The type of confidence curve. Can be  | 
| k | Numeric vector of two positive integers.  | 
Value
An object of class ccaf.
Examples
    r = c(0.20, sqrt(0.45), sqrt(0.55))
    N = c(100, 100, 100)
    plot(cc(r, N))
Calculate a confidence interval for an attenuated correlation coefficient.
Description
Calculate a confidence interval for an attenuated correlation coefficient.
Usage
ci(r, N, level = 0.95, method = "corr", k = NULL)
Arguments
| r | Numeric vector of three elements in [-1,1].  | 
| N | Numeric vector of three positive integers.  | 
| level | Numeric in [0, 1]. Confidence level of the interval. Defaults to 0.95. | 
| method | The type of confidence curve. Can be  | 
| k | Numeric vector of two positive integers.  | 
Value
Numeric in [0, 1]. The p-value under null-hypothesis rho.
Examples
    r = c(0.20, sqrt(0.45), sqrt(0.55))
    N = c(100, 100, 100)
    ci(r, N) # Calculates 95% confidence set for rho.
Add a plot a confidence curve of attenuated correlation coefficients.
Description
Add a plot a confidence curve of attenuated correlation coefficients.
Usage
## S3 method for class 'ccaf'
lines(x, type = "l", col = "red3", lwd = 2, ...)
Arguments
| x | An object of class  | 
| type | The type of plot. | 
| col | The color of the curve. | 
| lwd | The thickness of the curve. | 
| ... | Passed to  | 
Value
An invisible copy of x.
Merges two lists.
Description
Merges two lists.
Usage
listmerge(x, y, type = c("merge", "template"))
Arguments
| x | A list of default arguments. | 
| y | A list of supplied arguments | 
| type | If  | 
Value
A merged list where conflicts are solved in favour of y. Does not preserve ordering.
Calculate the p-value for an attenuated correlation coefficient.
Description
This function calculates four types of p-values for correlations coefficients
corrected for attenuation, chosen in "method". The different p-values
are described in Moss (2019). "corr" is the correlation based
p-value, "cronbach" is the Cronbach alpha based p-value,
"HS" is the Hunter-Schmidt p-value, while "free" is the
correlation based p-value without positive constraints.
Usage
p_value(rho, r, N, method = "corr", k = NULL)
Arguments
| rho | Numeric vector in [-1,1]. The correlation under the null hypothesis. | 
| r | Numeric vector of three elements in [-1,1].  | 
| N | Numeric vector of three positive integers.  | 
| method | The type of p-value. Can be  | 
| k | Numeric vector of two positive integers.  | 
Value
Numeric in [0, 1]. The p-value under the null-hypothesis that the true correlation is rho.
Examples
    r = c(0.20, sqrt(0.45), sqrt(0.55))
    N = c(100, 100, 100)
    p_value(rho = 0, r, N) # Tests rho = 0.
Plot a confidence curve of attenuated correlation coefficients.
Description
Plot a confidence curve of attenuated correlation coefficients.
Usage
## S3 method for class 'ccaf'
plot(x, y, level = 0.95, ...)
Arguments
| x | An object of class  | 
| y | Ignored; supported for compatibility with the  | 
| level | Level to highlight. Defaults to 0.95. If  | 
| ... | Passed to  | 
Value
An invisible copy of x.
Print method for ccaf
Description
Print method for ccaf
Usage
## S3 method for class 'ccaf'
print(x, digits = 3, ...)
Arguments
| x | Object of class  | 
| digits | Passed to  | 
| ... | Ignored. | 
Value
Invisible copy of x.