Why Sklearn TruncatedSVD's explained variance ratios are not in descending order?
问题 Why Sklearn.decomposition.TruncatedSVD 's explained variance ratios are not ordered by singular values? My code is below: X = np.array([[1,1,1,1,0,0,0,0,0,0,0,0,0,0], [0,0,1,1,1,1,1,1,1,0,0,0,0,0], [0,0,0,0,0,0,1,1,1,1,1,1,0,0], [0,0,0,0,0,0,0,0,0,0,1,1,1,1]]) svd = TruncatedSVD(n_components=4) svd.fit(X4) print(svd.explained_variance_ratio_) print(svd.singular_values_) and the results: [0.17693405 0.46600983 0.21738089 0.13967523] [3.1918354 2.39740372 1.83127499 1.30808033] I heard that a