Generate two variables linear correlated
rpearson.Rd
Simulates two numeric variables linear correlated, given a Pearson linear correlation coefficient, that also follows a normal distribution.
Arguments
- n
A numeric integer single value (default = 25), that will be the number of observations to simulate
- pearson
A numeric single value (default = 0.50), that will be the expected Pearson linear correlation coefficient
- tol
A numeric single value (default = 0.10), that will be the tolerance between the simulated and estimated correlation
- mean
A numeric single value (default = 0), that will be the mean of the simulated data
- sd
A numeric single value (default = 1), that will be the standard deviation of the simulated data