# Shape2SSCM: Calculation of the Spatial Sign Covariance Matrix In sscor: Robust Correlation Estimation and Testing Based on Spatial Signs

## Description

`Shape2SSCM` transforms the theoretical shape matrix of an elliptical distribution into the spatial sign covariance matrix.

## Usage

 `1` ```Shape2SSCM(V) ```

## Arguments

 `V` (required) p x p matrix representing the theoretical shape matrix.

## Details

The calculation consists of three steps. First one calculates eigenvectors and eigenvalues of the shape matrix by the function `eigen`. Then one determines the related eigenvalues of the SSCM using the function `evShape2evSSCM` and finally one expands the resulting eigendecomposition consisting of the eigenvectors of the Shape matrix and the eigenvalues of the SSCM. Note that this procedure only works for elliptical distributions.

## Value

p x p symmetric numerical matrix, representing the spatial sign covariance matrix, which corresponds to the given shape matrix.

## References

Dürre, A., Vogel, D., Fried, R. (2015): Spatial sign correlation, Journal of Multivariate Analyis, vol. 135, 89–105. arvix 1403.7635

Dürre, A., Tyler, D. E., Vogel, D. (2016): On the eigenvalues of the spatial sign covariance matrix in more than two dimensions, to appear in: Statistics and Probability Letters. arvix 1512.02863

Calculating the theoretical shape from the theoretical SSCM `SSCM2Shape`
Calculating the eigenvalues of the SSCM `evShape2evSSCM`
 ``` 1 2 3 4 5 6 7 8 9 10 11 12 13``` ```# defining a shape matrix with trace 1 V <- matrix(c(1,0.8,-0.2,0.8,1,0,-0.2,0,1),ncol=3)/3 V # calculating the related SSCM SSCM <- Shape2SSCM(V) # recalculate the shape based on the SSCM V2 <- SSCM2Shape(SSCM) V2 # error is negligible sum(abs(V-V2)) ```