Variance-covariance matrix help
MatrixCorr only takes a 1D wave, with an option for a second 1D wave. I have a 3 column 2D wave corresponding to x y and z coords. Am I missing something? Probably(!) please tell me.I'd like to do a eigenvalue decomposition on the resulting variance-covariance matrix (which I think will be possible with the
MatrixEigenV command). I'd like to use the eigenvalues and eigenvectors to fit a plane through the midpoint of the coordinates. If there is a simpler/alternative way to do this please feel free to tell me.
A.G.
WaveMetrics, Inc.
February 2, 2015 at 08:32 am - Permalink
February 3, 2015 at 12:37 am - Permalink
If all your points belong to one "disk" then PCA should be better than trying to fit a plane.
To understand the basics here it may be helpful to consider an example where you construct data similar to your description in the function makeData(). You then apply a rotation using a single rotation about the x-axis using the rotateX() function:
At this point you create the data using:
You can display the two scatters as objects in Gizmo:
You can split the rotated wave into cols as input for PCA:
My PCA command is:
It is actually interesting to display the resulting e-v in Gizmo:
You can append these axes as a path object to Gizmo:
Given the new axes, you do not need to rotate your scatter; all you need to do is define another plane perpendicular to the axis (it will be mostly parallel to your disk) and calculate the distance of each point of your scatter from the plane. You can derive the formula yourself of look it up in section 10.3.1 of "Geometric Tools for Computer Graphics" by Schneider and Eberly.
HTH,
A.G.
WaveMetrics, Inc.
February 3, 2015 at 01:30 pm - Permalink
February 4, 2015 at 06:35 am - Permalink