Stack Exchange Network

Stack Exchange network consists of 174 Q&A communities including Stack Overflow, the largest, most trusted online community for developers to learn, share their knowledge, and build their careers.

Visit Stack Exchange

Questions tagged [pca]

Principal component analysis, a technique for dimensionality reduction.

0
votes
1answer
9 views

Guidance needed with dimension reduction for clustering - some numerical, lots of categorical data

I've my data in a Pandas df with 25.000 rows and 1.500 columns without any NaNs. Of the columns about 30 contain numerical data which I standardized with StandardScaler(). The rest are cols with ...
0
votes
2answers
53 views

multivariate clustering, dimensionality reduction and data scalling for regression

I have a dataset with approximately 20000 observations consisting of 40 independent and 1 dependent variable. My initial objective is to develop a model that will predict the dependent variable. I ...
0
votes
3answers
17 views

What best/correct algorithm/procedure to cluster a dataset with a lot 0's?

I'm new to statistics so sorry any major lack of knowledge in the topic, just doing a project for graduation. I'm trying to cluster a Health dataset containing Diseases(3456) and Symptoms(25) ...
0
votes
0answers
12 views

PCA computed by GPflow and Sklearn doesn't match

I am performing PCA analysis by using Sklearn and GPflow. I noticed that the output returned by both the libraries doesn't match. Please see below the sample code snippet- ...
2
votes
1answer
49 views

Is PCA (by eigendecomposition) or SVD better in decorrelating the predictors of a machine learning model?

Is there any reason to think that SVD is better than PCA (by eigendecomposition) in decorrelating the predictors of a machine learning model?
0
votes
1answer
24 views

How to choose PCA or KernelPCA a priori?

I am learning about dimensionality reduction and I understood that one of the most used techniques in ML is PCA. If I understood correctly, I use PCA whenever I want to reduce the number of features ...
2
votes
0answers
22 views

PCA and FastICA in scikit-learn giving near identical results

So after importing my data, transforming it, and splitting into training and test sets I tried running this script for PCA: ...
0
votes
0answers
24 views

POD, PCA analysis

My toy example is as follows: from some CFD calculations (grid =5x5 cells, each cell is associated with a velocity value) I have extracted 3 snapshots (1 snapshot/case) that represent the velocity of ...
1
vote
2answers
46 views

Differences between applying KMeans over PCA and applying PCA over KMeans

Short question: As stated in the title, I'm interested in the differences between applying KMeans over PCA-ed vectors and applying PCA over KMean-ed vectors. Long question: Let's suppose we have a ...
0
votes
1answer
61 views

sklearn.decomposition.PCA explained_variance_ratio_ attribute does not exist

When trying to identify the variance explained by the first two columns of my dataset using the explained_variance_ratio_ attribute of ...
0
votes
0answers
17 views

Incremental subspace learning methods

I want to learn methods for incremental subspace learning. I tried to read papers, but most of them mention incremental PCA. Since, incremental PCA involves computing eigen decomposition for every new ...
0
votes
1answer
13 views

What does it mean if a high or low number of my componenets describe a percentage of the cumulative explained variance?

In the following code run after PCA i can see that X number of components explain Y % of cumulative explained variance (CEV). I would like to know 1- What percentage of the CEV is typically ...
1
vote
1answer
29 views

Can anyone explain me the difference between Factor Anaysis and PCA?

Is PCA and Factor Analysis same? Both are used for Data dimension reduction but theoretically I am not able to find the difference between them? I did FA in SPSS to reduce number of variables in my ...
2
votes
0answers
29 views

A classification machine learning flow chart implimenting dimentionality reduction, upsampling, and cross validation [closed]

I would like to make a flow chart for an ML classifier and make sure that my thinking is correct. Here is a little about my sample: I have 3 classes and about 160 features. I suspect that some of ...
0
votes
0answers
17 views

Can I use MCA on categorical features, and PCA on numeric then combine both for learning

So all is said in the title. I have a mix of both categorical and numeric features, both are more than 20 columns and reside in the same data-set. I am using PCA solution from sklearn.decomposition ...
-1
votes
2answers
37 views

How to plot High Dimensional supervised K-means on a 2D plot chart

I'm Having a ML problem where my data set contains 80 features labelled into 3 groups (0, 1, -1). I want to plot the data on a 2D surface to see how "close" (similar) data with ...
0
votes
0answers
32 views

Does PCA need unevenly distributed data to be successful/meaningful?

I am not quite sure about these assumptions here, but if my data is evenly distributed in the feature space does that mean that PCA will have no impact on the classification result? My thought ...
2
votes
2answers
42 views

Is deduction, genetic programming, PCA, or clustering machine learning according to Tom Mitchells definition?

Tom M. Mitchell defines machine learning as A computer program is said to learn from experience E with respect to some class of tasks T and performance measure P if its performance at tasks in T, ...
4
votes
3answers
109 views

Are dimensionality reduction techniques useful in deep learning

I have been working on machine learning and noticed that most of the time, dimensionality reduction techniques like PCA and t-SNE...
0
votes
0answers
27 views

Feature selection after performing PCA

I have a data set with 57 variables on which I am performing PCA. The PCA returns me a list of principal components, each of which is in turn a list of the loadings to be placed on my variables in a ...
2
votes
0answers
82 views

How to use SVD to reduce the dimension of test data which is not available at the time of SVD?

Usually, when both train and test data are available in the beginning, a dimensionality reduction such as Singular Value Decomposition (SVD) can be applied on both of them as one matrix. The reduced ...
0
votes
0answers
54 views

Number of clusters with eigengap method in spectral clustering

I would like to find the number of clusters for spectral clustering which I could apply to my data. I've tried eigengap technique on a cosine similarity matrix and got the following plot: The gap ...
0
votes
0answers
26 views
0
votes
1answer
23 views

Reconstructing original data points from t-SNE output

I have been trying to understand t-SNE for a while now and I have this very basic question on the comparison of PCA and t-SNE, on which I would really appreciate some help. In case of PCA suppose the ...
4
votes
2answers
237 views

Distributed PCA or an equivalent

We normally have fairly large datasets to model on, just to give you an idea: over 1M features (sparse, average population of features is around 12%); over 60M rows. A lot of modeling algorithms ...
0
votes
1answer
98 views

How to use multiple encoders(one-hot and numerical) together for PCA

I want to implement PCA on a dataset(retail) but the data is categorical. One-hot encoding on some columns like Gender, Fabric, Brand makes sense but on other features like price range, size, I would ...
0
votes
1answer
23 views

PCA - Error minimization and Variance Maximization

I'm studying the PCA algorithm and the theory behind it. I think I understood how does it work and the idea of dimension reduction of the data in order to find a new feature (component) that maximizes ...
0
votes
2answers
39 views

How can we interpret biplot?

This is not a question as such but more likely to be verification (enhancement) of my current understanding. With the thought that it may help future visitors as well, I am taking liberty to make this ...
0
votes
2answers
33 views

Does high regression coefficient for Principal components that don't explain much variance imply that my data is not a good predictor?

There isn't much to add to the question. Essentially i had some data that I reduced to 4 principal components, the first two components of which explain 99% of the variance in my data. Upon building ...
1
vote
1answer
61 views

Using PCA to cluster multidimensional data (RFM variables)

So i am performing k-means clustering on RFM variables (Recency, Frequency, Monetary). The RFM variables are in the form of quantiles (1-4). I used PCA and found the PCA components. I then used the ...
0
votes
3answers
646 views

Predictor Variable vs. Target Variable [closed]

If I find that a variable is not a predictor variable, does that mean it automatically becomes a target variable? I don't believe so because if you have 209 variables, and you find your predictor ...
2
votes
1answer
243 views

Data scaling before PCA: how to deal with categorical values?

I have to apply PCA on a dataset, which contains both numerical and categorical values. In the preprocessing phase, I converted all the categorical values in numerical, so that the software can deal ...
2
votes
1answer
55 views

How can I apply PCA to KNN?

I want to know the do not want to how to use library I will denote a $n\times p$ data matrix by $X$, where $n<p$. That is, each row of $X$ is one sample data with $p$ feature variables. By using ...
2
votes
1answer
74 views

Sklearn Pipelines - How to carry over PCA?

I'm developing a pipeline to fit parameters for a gradient boosting classifier while also fitting the optimum number of features in a PCA model. This is the current setup: ...
5
votes
1answer
92 views

Sklearn PCA with zero components example

I'm simply trying to repeat a benchmark from the sklearn's docs. The unclear part is: n_components = np.arange(0, n_features, 5). They are applying a PCA transform ...
2
votes
0answers
24 views

PCA huge parts of missing data filling

I’m performing PCA on different time series’ and then using K Means clustering to try and group together common factors. The issue I’m facing is that some of the factors come in and out of the time ...
1
vote
0answers
14 views

How to read factor vs. factor plots?

How to read factor vs. factor plots? Particularly, what do negative values mean? Also, why is it possible for features to have negative effect on the factors?
0
votes
2answers
116 views

deepAR RNN from AWS Sagemaker - should I clean the data first?

I test the Sagemaker AWS solution for RNN: deepAR. Previously I used sklearn for this and obviously I cleaned the data to avoid highly correlated time series (KBest,...
0
votes
0answers
47 views

Which algorithm to use when data set has a lot of categorical variable levels and a few numerical variables?

I'm working on a data set containing some numerical and some categorical values. Though after some research I got to know that I can go for encoding techniques to convert categorical to numerical. But,...
1
vote
1answer
69 views

Principal Component Analysis and abnormal data

I know that PCA is good in differentiating between anomalies and normal data and it helps to differentiate between them when it tries to transfer the data to another dimension. I mean it can somehow ...
3
votes
0answers
648 views

ValueError: operands could not be broadcast together with shapes (60002,39) (38,) during pca.transform

I am trying to solve the San Francisco Crime Problem on Kaggle. To begin with, here is my code: ...
1
vote
1answer
402 views

How to implement PCA color augmentation as discussed in AlexNet

I read through "ImageNet Classification with Deep Convolutional Neural Networks" again specifically for details on how to implement PCA color augmentation. I am unsure if I have it right. Here is how ...
1
vote
3answers
82 views

Whats an explanation of PCA that is intuitive for someone in senior leadership who doesn't have a technical background?

I've been pulled onto my first Data Science project at work. Classic problem of predicting sales based on web traffic data, etc. While I don't know about the specific techniques I will be using in my ...
0
votes
1answer
42 views

very low variance explained after applying pca

I applied PCA on MNIST data and found that the first 64 components are able to retain 86% of variance. Is there any problem while applying pca to a big dataset like MNIST. Because in most of the ...
1
vote
0answers
39 views

Scripting inverse PCA or MNF in Orange (biolab)

I have a data table with many rows and columns that I have successfully taken through K-means and PCA workflows in Orange. Now I'm trying to calculate the "minimum noise fraction" of the data. This is ...
1
vote
1answer
51 views

Should Principal components be normalized before applying K means on them?

I want to get the Principal components of a dataset and apply K mean clustering on them. Do I need to Normalized the PCA output before applying Kmeans on them ?
0
votes
1answer
51 views

Performace of Fischer projection as dimension reduction compared to other LDA methods

How is the performance of Fischer projection compared to other LDA methods of dimension reduction? I thought that Fischer projection was a great method of dimension reduction by maximizing class ...
0
votes
0answers
47 views

Replace NaN values in data for pca and using measured errors in linear regression

I have a matrix with 11 variables and 1258 observations for each variable, and another matrix the same size with the corresponding measurement error for the variable. In two variables i have a NaN ...
2
votes
2answers
38 views

distinguish users for recommender system

How can you calculate better video recommendations for a SmartTV app which is used by multiple users in a household. I don't know which user is currently watching the video because the account for the ...
1
vote
2answers
73 views

How to use pca results for linear regression

I have a data set of 11 variables with allot of observations for each one. I want to make linear regression on the variables with the observed $\vec{y}=\alpha +\beta*\vec{X}$ when X is matrix. I'm ...