{moderator edit - solution code removed}
With this code, I get correct dimentionality of the X_reduced, but incoorect values
Output
Your original matrix was (3, 10) and it became:
[[-0.43361498 -0.40920865]
[ 0.03306764 -0.1293703 ]
[-0.39103889 -0.3999264 ]]
I dont understand, if there is any fundamental mistake in my implementation of PCA? Can someone help? Thanks in advance