Dimensionality reduction on matrices with missing entries

Hi guys,
I wanted to do dimensionality reduction on many matrices so that they all have the same dimensions.
So, I have matrices of the dimensions: 50x220, 50x190, 50x300, 50x235, 50x149, etc. At the end I want to reduce second dimension to 10 so I would have matrices 50x10, 50x10, 50x10, 50x10 and so on for each of them. The problem is that in my case I have matrices with missing values and I use the general pca function for raw data.
So I have matrices something like that:
X(1).matrix = [1 2 3 ...
3 4 5 ...
3 4 4 ...
6 NaN 7 ...
...........
NaN NaN NaN]
X(2).matrix = [3 4 5 ...
5 6 7 ...
4 4 4 ...
NaN 3 3 ...
NaN 4 4 ...
...........
NaN NaN 7]
X(3).matrix = [3 3 3
2 1 3
...........
NaN 1 2]
After applying function pca I just get some coeff. But I dont know how to actually get to the dimensionality reduction (i.e. matrices having dimensions 50x10 dimensions). Thanks in advance for your time and help!

回答 (1 件)

KSSV
KSSV 2019 年 5 月 24 日
編集済み: KSSV 2019 年 5 月 24 日

0 投票

[coeff,score,latent] = pca(mymatrix)
here latent gives you variance of the principal components in decreasing order. You can pick the first n (10) number of columns.

1 件のコメント

Spresi
Spresi 2019 年 5 月 24 日
編集済み: Spresi 2019 年 5 月 24 日
Thanks for the answer!
So, I pick the first 10 columns of score matrix right?
Or do I pick the first 10 rows of the score matrix?

サインインしてコメントする。

カテゴリ

ヘルプ センター および File ExchangeDimensionality Reduction and Feature Extraction についてさらに検索

質問済み:

2019 年 5 月 24 日

編集済み:

2019 年 5 月 24 日

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by