Hi,
Tried to use this function to obtain a correlation matrix from a symmetric one (in some sense of proximity).
I regret to say that the documentation is leaving a lot to be desired.
I don't know what the expression : "If an input parameter is NULL, the corresponding parameter in the Summary Statistics task descriptor remains unchanged." and I guess it is safe to assume that, whoever wrote it did not care to be understood anyway.
To make matters worse, when one goes to "Storage formats of a variance-covariance/correlation/cross-product matrix " they read, facing obvious and total disregard for their time:
"A symmetric variance-covariance/correlation/cross-product matrix with elements c(i,j) is packed as a one-dimensional array cp(i + (2n - j)*(j - 1)/2) for j ≤ i. The size of the array is p*(p+ 1)/2."
What is "n" ?? Trying very hard to keep it civil here !
So let us assume it is the same as p.
In short, what this dyslexic piece of "wording" says is (probably) :
VSL_SS_MATRIX_STORAGE_FULL is a row-major matrix with all the entries filled (only God knows why, but at least this works, if you want/like to write everything twice - who doesn't ! ).
VSL_SS_MATRIX_STORAGE_L_PACKED : a Fortran column-major matrix (again only deity will comprehend why we switched storage layout),
since consecutive i's occupy adjacent memory locations.
The "funny" thing is that this does not work.
Try it with boost's ublas symmetrix_matrix< double, lower, column_major> (in the appropriate namespace, i.e. boost::numeric::ublas) and you will see what you get.
I am sorry for the tone, but have wasted lots of hours to track down the root of the problem, have spent many hours with whimsical storage preferences and sloppy documentation and I am really fed up with this situation, where there is complete lack of consistency across the library (you also ship blas and lapack which are industry standards, no?), and not even an effort for documentation common language.
PS: the extraordinary thing its that from every topic in summary statistics you point to the same awful piece of "documentation" for symmetric matrices acceptable layouts !