我正在尝试使用SciKit-Learn在我的数据集上执行PCA。我目前有2,208行和53,741列(特性)。因此,我想使用PCA来降低这个数据集的维数。我在关注Hands-On Machine Learning with SciKit-Learn and TensorFlowX_reduced = <
我尝试在一个维度为m x n的矩阵上运行PCA,其中m是特征的数量,n是样本的数量。from sklearn.decomposition import PCApca = PCA(n_components=nf)
# Xis the matrix transposed (n samples on the rows, m features