PillaiTrace
✖
PillaiTrace
Details

- PillaiTrace[m1,m2] gives Pillai's trace between m1 and m2.
- Pillai's trace is a measure of linear dependence based on partitions of the pooled covariance matrix.
- Pillai's trace is computed as
where
is the covariance matrix of the pooled sample, which can be partitioned into
where
and
correspond to the covariance matrices of the individual datasets.
- The arguments m1 and m2 can be any real‐valued matrices or vectors of equal length.
Examples
open allclose allBasic Examples (3)Summary of the most common use cases
Compute Pillai's trace for two matrices:

https://wolfram.com/xid/0btno843o486-bv14aj

https://wolfram.com/xid/0btno843o486-ce2wv

https://wolfram.com/xid/0btno843o486-i51zwj

Pillai's trace for two vectors:

https://wolfram.com/xid/0btno843o486-gugb6d

https://wolfram.com/xid/0btno843o486-fulot0

Pillai's trace for a matrix and a vector:

https://wolfram.com/xid/0btno843o486-cuzz7n

https://wolfram.com/xid/0btno843o486-c4pua3

https://wolfram.com/xid/0btno843o486-oz384

Scope (3)Survey of the scope of standard use cases
Pillai's trace is typically used to detect linear dependence between random matrices:

https://wolfram.com/xid/0btno843o486-htfobe

https://wolfram.com/xid/0btno843o486-b1crnn

https://wolfram.com/xid/0btno843o486-bwvkw2
Values tend to be near for dependent matrices:

https://wolfram.com/xid/0btno843o486-bqlb9

The value is much smaller for independent matrices:

https://wolfram.com/xid/0btno843o486-bozysc

Pillai's trace for machine-precision reals:

https://wolfram.com/xid/0btno843o486-f29p


https://wolfram.com/xid/0btno843o486-ng52h

Properties & Relations (4)Properties of the function, and connections to other functions
Pillai's trace measures linear dependence:

https://wolfram.com/xid/0btno843o486-gzq8gw

https://wolfram.com/xid/0btno843o486-gcdotf

Pillai's trace cannot detect nonlinear dependency:

https://wolfram.com/xid/0btno843o486-7nvfr

https://wolfram.com/xid/0btno843o486-nazb6e

https://wolfram.com/xid/0btno843o486-j9qi3

https://wolfram.com/xid/0btno843o486-gtfa0z

HoeffdingD can be used to detect some nonlinear dependence structures:

https://wolfram.com/xid/0btno843o486-jor85u

Pillai's trace is asymptotically equivalent to WilksW:

https://wolfram.com/xid/0btno843o486-bt6r2k

Statistical significance can be tested using PillaiTraceTest:

https://wolfram.com/xid/0btno843o486-cpexjt

https://wolfram.com/xid/0btno843o486-g80c7y

https://wolfram.com/xid/0btno843o486-bkwj60


https://wolfram.com/xid/0btno843o486-gj193z

Alternatively, use IndependenceTest to automatically choose a test:

https://wolfram.com/xid/0btno843o486-dow0ew

Wolfram Research (2012), PillaiTrace, Wolfram Language function, https://reference.wolfram.com/language/ref/PillaiTrace.html.
Text
Wolfram Research (2012), PillaiTrace, Wolfram Language function, https://reference.wolfram.com/language/ref/PillaiTrace.html.
Wolfram Research (2012), PillaiTrace, Wolfram Language function, https://reference.wolfram.com/language/ref/PillaiTrace.html.
CMS
Wolfram Language. 2012. "PillaiTrace." Wolfram Language & System Documentation Center. Wolfram Research. https://reference.wolfram.com/language/ref/PillaiTrace.html.
Wolfram Language. 2012. "PillaiTrace." Wolfram Language & System Documentation Center. Wolfram Research. https://reference.wolfram.com/language/ref/PillaiTrace.html.
APA
Wolfram Language. (2012). PillaiTrace. Wolfram Language & System Documentation Center. Retrieved from https://reference.wolfram.com/language/ref/PillaiTrace.html
Wolfram Language. (2012). PillaiTrace. Wolfram Language & System Documentation Center. Retrieved from https://reference.wolfram.com/language/ref/PillaiTrace.html
BibTeX
@misc{reference.wolfram_2025_pillaitrace, author="Wolfram Research", title="{PillaiTrace}", year="2012", howpublished="\url{https://reference.wolfram.com/language/ref/PillaiTrace.html}", note=[Accessed: 19-May-2025
]}
BibLaTeX
@online{reference.wolfram_2025_pillaitrace, organization={Wolfram Research}, title={PillaiTrace}, year={2012}, url={https://reference.wolfram.com/language/ref/PillaiTrace.html}, note=[Accessed: 19-May-2025
]}