Become an expert in R — Interactive courses, Cheat Sheets, certificates and more!
Get Started for Free

poly.cor

Polyserial correlation


Description

Polyserial correlation.

Usage

poly.cor(x, y)

Arguments

x

The continuous variable.

y

The ordinal variable, a numeric vector with numbers starting from 1.

Details

The polyserial correlation between a continuous and an ordinal variable is calculated. The function is not super fast, yet is faster than other implementations we found.

Value

A list including:

est

A vector with the polyserial correlation and its estimated variance.

test

A vector with the test statistic and its associated p-value.

Author(s)

Michail Tsagris

R implementation and documentation: Michail Tsagris <mtsagris@yahoo.gr>

References

Olsson U., Drasgow F. and Dorans N. J. (1982). The polyserial correlation coefficient. Psychometrika, 47(3):337-347.

See Also

Examples

x <- rnorm(100)
y <- rpois(100, 10) + 1
res<-poly.cor(x, y)

Rfast

A Collection of Efficient and Extremely Fast R Functions

v2.0.1
GPL (>= 2.0)
Authors
Manos Papadakis, Michail Tsagris, Marios Dimitriadis, Stefanos Fafalios, Ioannis Tsamardinos, Matteo Fasiolo, Giorgos Borboudakis, John Burkardt, Changliang Zou, Kleanthi Lakiotaki and Christina Chatzipantsiou.
Initial release
2020-09-13

We don't support your browser anymore

Please choose more modern alternatives, such as Google Chrome or Mozilla Firefox.