Finding a zero meaned matrix vertically and horizontally.
이전 댓글 표시
I am trying to understand the first principles of PCA and was set with an exercise that requires me to create a zero meaned matrix in the direction of the features (columns) and variables (rows).For example,for meaning rows,I just need to calculate each rows mean and subtract it in every single elements in the row.However I also need the column mean to be zero simultanously.How can I achieve this ? Applying the same method for columns then rows does not work as it shifts the rows means after they have been zeroed.
채택된 답변
추가 답변 (1개)
Image Analyst
2022년 2월 11일
0 개 추천
Not sure you need to do that. The documentation for pca() says "By default, pca centers the data and uses the singular value decomposition (SVD) algorithm." so it's done internally for you.
카테고리
도움말 센터 및 File Exchange에서 Dimensionality Reduction and Feature Extraction에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!