3940
How to programmatically access the transformation matricies of the ICA .trans file
The Independent Components (IC) analysis is used to transform a set of mixed, random signals into components that are mutually independent for multispectral or hyperspectral datasets. The ICA transform produces a transformation matrix of the forward and backward transformation coefficients that are stored in a '.trans' file. The following example shows how you can access these matricies in the .trans file. It uses a undocumented routine, transform_read, that may need to be restored in your ENVI session to use.
Note: Undocumented routines are unsupported by Exelis VIS and may change in a future version without notice.
First, if you are using a fresh IDL session, you will need to enter ENVI batch mode and then you will need to restore the following file:
ENVI>envi_check_save, /transform
Then you can access the items of the undocumented routine:
ENVI> help, /routines, name='transform_read', /full
Compiled Procedures:
TRANSFORM_READ name FLOATING FORWARD_MATRIX INVERSE_EXIST INVERSE_MATRIX IN_NB OUT_NBRESERVE
To access the matricies, use the following syntax:
ENVI>transform_read, 'c:\temp\test.trans',floating=floating, forward_matrix=f, inverse_matrix=I
ENVI> print, f
0.046469395 -0.047097945 0.023922794 0.0024658149
0.038924652 0.0036077139 -0.011178614 -0.00034785035
-0.024674406 0.039495369 -0.046729316 0.017028710
-0.10597201 0.061793592 0.0040064471 -0.0039881298
;----------------------------
MM: June 19, 2015