| Library: | metrics |
| See also: | sir2 |
| Macro: | sir | |
| Description: | Calculates the effective dimension-reduction (edr) directions by Sliced Inverse Regression (Li, 1991) |
| Usage: | {edr, eigen} = sir (x, y, h) | |
| Input: | ||
| x | n x p matrix, the explonatory variable | |
| y | n vector, the dependent variable | |
| h | scalar, number of slices (h>=2) width of slice (0 < h < 1) elements in a slice (-h) | |
| Output: | ||
| edr | p x p matrix containing estimates of the edr | |
| eigen | p vector of the eigenvalues | |
randomize (10178) x = normal (300, 3) b = #(1, 0 ,1) y = sin (x*b) + normal(300) b = sir (x, y, -20) b.edr b.eigen
estimates of the edr, b.edr, and the eigenvalues, b.eigen
| Library: | metrics |
| See also: | sir2 |