GoodmanKruskalGamma

GoodmanKruskalGamma[v1,v2]

gives the GoodmanKruskal coefficient for the vectors v1 and v2.

GoodmanKruskalGamma[m]

gives the GoodmanKruskal coefficients for the matrix m.

GoodmanKruskalGamma[m1,m2]

gives the GoodmanKruskal coefficients for the matrices m1 and m2.

GoodmanKruskalGamma[dist]

gives the coefficient matrix for the multivariate symbolic distribution dist.

GoodmanKruskalGamma[dist,i,j]

gives the ^(th) coefficient for the multivariate symbolic distribution dist.

Details

  • GoodmanKruskalGamma[v1,v2] gives the GoodmanKruskal coefficient between v1 and v2.
  • GoodmanKruskal is a measure of monotonic association based on the relative order of consecutive elements in the two lists.
  • GoodmanKruskal between and is given by , where is the number of concordant pairs of observations and is the number of discordant pairs.
  • A concordant pair of observations and is one such that both and or both and . A discordant pair of observations is one such that and or and .
  • If no ties are present, is equivalent to KendallTau.
  • The arguments v1 and v2 can be any realvalued vectors of equal length.
  • For a matrix m with columns, GoodmanKruskalGamma[m] is a × matrix of the -coefficients between columns of m.
  • For an × matrix m1 and an × matrix m2, GoodmanKruskalGamma[m1,m2] is a × matrix of the -coefficients between columns of m1 and columns of m2.
  • GoodmanKruskalGamma[dist,i,j] gives where is equal to Probability[(x1-x2)(y1-y2)>0,{{x1,y1}disti,j,{x2,y2}disti,j}] and is equal to Probability[(x1-x2)(y1-y2)<0,{{x1,y1}disti,j,{x2,y2}disti,j}] where disti,j is the ^(th) marginal of dist.
  • GoodmanKruskalGamma[dist] gives a matrix where the ^(th) entry is given by GoodmanKruskalGamma[dist,i,j].

Examples

open allclose all

Basic Examples  (4)

GoodmanKruskal for two vectors:

GoodmanKruskal for a matrix:

GoodmanKruskal for two matrices:

Compute the GoodmanKruskal for a bivariate distribution:

Compare to a simulated value:

Scope  (7)

Data  (4)

Exact input yields exact output:

Approximate input yields approximate output:

Works with large arrays:

SparseArray data can be used:

Distributions and Processes  (3)

GoodmanKruskal matrix for a continuous multivariate distribution:

GoodmanKruskal matrix for derived distributions:

Data distribution:

GoodmanKruskal matrix for a random process at times and :

Applications  (3)

GoodmanKruskal is typically used to detect linear dependence between two vectors:

The absolute magnitude of tends to 1 given strong linear dependence:

The value tends to 0 for linearly independent vectors:

GoodmanKruskal measures linear association:

GoodmanKruskal can only detect monotonic dependency:

HoeffdingD can be used to detect other dependence structures:

Properties & Relations  (5)

GoodmanKruskal ranges from -1 to 1 for negative and positive association, respectively:

The Goodman-Kruskal matrix is symmetric:

The diagonal elements of the GoodmanKruskal matrix are 1:

In the absence of ties, GoodmanKruskal is equivalent to KendallTau:

GoodmanKruskal handles ties differently:

GoodmanKruskal for a bivariate distribution:

Wolfram Research (2012), GoodmanKruskalGamma, Wolfram Language function, https://reference.wolfram.com/language/ref/GoodmanKruskalGamma.html.

Text

Wolfram Research (2012), GoodmanKruskalGamma, Wolfram Language function, https://reference.wolfram.com/language/ref/GoodmanKruskalGamma.html.

CMS

Wolfram Language. 2012. "GoodmanKruskalGamma." Wolfram Language & System Documentation Center. Wolfram Research. https://reference.wolfram.com/language/ref/GoodmanKruskalGamma.html.

APA

Wolfram Language. (2012). GoodmanKruskalGamma. Wolfram Language & System Documentation Center. Retrieved from https://reference.wolfram.com/language/ref/GoodmanKruskalGamma.html

BibTeX

@misc{reference.wolfram_2024_goodmankruskalgamma, author="Wolfram Research", title="{GoodmanKruskalGamma}", year="2012", howpublished="\url{https://reference.wolfram.com/language/ref/GoodmanKruskalGamma.html}", note=[Accessed: 14-November-2024 ]}

BibLaTeX

@online{reference.wolfram_2024_goodmankruskalgamma, organization={Wolfram Research}, title={GoodmanKruskalGamma}, year={2012}, url={https://reference.wolfram.com/language/ref/GoodmanKruskalGamma.html}, note=[Accessed: 14-November-2024 ]}