stretch: stretch

Description Usage Arguments Value Examples

View source: R/DCARS.R

Description

The stretch function calculates a 'stretched'/standardised vector of weighted correlations, using previously calculated upper and lower bounds of the statistic (same length vectors). Values are stretched higher or lower symmetrically around 0.

Usage

1
stretch(wcor, upper = 1, lower = -1)

Arguments

wcor

weighted correlation vector

upper

either single numeric or vector of same length as wcor for upper bound of correlation. Default 1

lower

either single numeric or vector of same length as wcor for lower bound of correlation. Default -1

Value

vector standardised weighted correlation vector

Examples

1
2
3
4
5
x = pmax(0,rnorm(100))
y = pmax(0,rnorm(100))
w = runif(100)
wcor = weightedKendallStar(x,y,w)
stretch(wcor, upper = 0.8, lower = -0.3)

shazanfar/DCARS documentation built on Oct. 14, 2020, 11:11 a.m.