mahalanobis distance with non symmetric and positive covariance
2 visualizaciones (últimos 30 días)
Mostrar comentarios más antiguos
I have an array of 36 vectors with 46 dimensions. I'm trying to find the distance between my 36 vectors by using mahalanobis distance. I can't apply it in matlab because the covariance result is not symmetric and positive definite.
Could you help me with that please ?
0 comentarios
Respuestas (2)
John D'Errico
el 22 de Feb. de 2015
A covariance matrix based on fewer samples than variables must always be singular. I'm not sure what this says about the distances you would compute, but nearestSPD will make a matrix usable for any tool that requires a Cholesky decomposition.
0 comentarios
Ver también
Categorías
Más información sobre Creating and Concatenating Matrices en Help Center y File Exchange.
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!