Question :
Nike company have a test contains missing values. The entries in the matrix are the expression values of genes(rows) under different conditions(columns).
Please use KNN impute algorithm (k=2) to fill the missing values (M1,M2,M3).
Please use Euclidean distance and Manhattan distance to calculate distance among genes separately and compare the result.
|
S1 |
S2 |
S3 |
S4 |
S5 |
S6 |
G1 |
1.0 |
0.7 |
0.3 |
M1 |
3.0 |
1.5 |
G2 |
1.2 |
1.0 |
1.2 |
M2 |
4.0 |
3.0 |
G3 |
3.4 |
2.2 |
2.0 |
1.2 |
2.0 |
1.5 |
G4 |
2.2 |
M3 |
5.0 |
2.0 |
5.0 |
0.8 |
G5 |
0.9 |
2.5 |
3.0 |
0.5 |
1.0 |
1.0 |
G6 |
1.0 |
0.5 |
0.4 |
0.4 |
2.9 |
1.8 |
PLEASE EXPLAIN STEP BY STEP.