Stack Exchange Network

Stack Exchange network consists of 175 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.

1
vote
3answers
43 views

K means visualisation after reducing dimensionality with PCA

In clustering ($K$ means, for example) when I have $N$ features and after creating the model (with this $N$ features) to visualize this model I need to reduce this $N$ dimensions into $2$ or $3$ ...
0
votes
0answers
3 views

PCAModel and PipelineModel, how to get explainedVariance

in pyspark PCAModel contains explainedVariance() method , but once you use Pipeline and specify PCA as a "stage", you will get a PipelineModel as an output and this one does not contain ...
2
votes
1answer
48 views

clustering before or after PCA?

I'm newbie into data science, and I had some problems dealing with my project. I'm trying to visualize multidimensional data into 2D after clustering with using a lot of methods. (kmeans, DBSCAN, ...
1
vote
0answers
35 views

Deciding on the number of components in PCA

I have been running my model several times now. Each time i get different results based on what number i put in my PCA component number range (I used raw numbers in the code instead of the range ...
0
votes
1answer
21 views

Unskewing the Data with the PCA's Help

I'm making some RFM Analyses (Customer Segmentation) and, in order to feed the RFM data to K-Means, I need to unskew the data, as K-Means works best when dealing with symmetrical distributions. One ...
0
votes
0answers
30 views

Can we use pca for supervise classification?

My questions are: Can we use "pca feature selection" for supervised classification? What will happen to labels when we use dimension reduction? If I understand it right when we use pca for feature ...
1
vote
1answer
23 views

Feature importance after PCA (or other dimensionality reduction methods)

I have text data which I one hot encoded and then used PCA on it (although I'm experimenting with other methods as well, LDA, NMF..). I am using the result of the dimensionality reduction as an input ...
0
votes
0answers
10 views

Plotting two PCA using same Principal Components to compare data

Background: I have been given a task to replicate functionalities of an old data analytics tool on Python. This tool has set of examples, one of which has a data of a chemical process end of which, ...
0
votes
1answer
34 views

How to find which features have been selected by PCA algorithm?

I used PCA function in MATLAB to decrease features on my data set. By this code I can reduce features from 12 to 8(as an example). It works good but my question is that how can I found with feature ...
0
votes
1answer
28 views

Does PCA decrease the feature on my Data set or just decrease the dimension?

I'm new in AI and sorry if my question is simple. I have a data set and want to use PCA to decrease the feature but after some research on the internet I'm confused about decreasing dimensions and ...
2
votes
1answer
59 views

Measuring distance preservation in dimensionality reduction

I am looking to compare the distance preserved during dimension reductions for several techniques. I have read some papers on similar topics here and here. For example, I would like to use the ...
1
vote
0answers
38 views

Model for time series analysis

I'm new to data analysis and ML in general. I'm working with some friends on this problem: We're trying to predict when a component of a machine will stop working properly so the client can change it ...
7
votes
1answer
81 views

Is it OK to try to find the best PCA k parameter as we do with other hyperparameters?

Principal Component Analysis (PCA) is used to reduce n-dimensional data to k-dimensional data to speed things up in machine learning. After PCA is applied, one can check how much of the variance of ...
0
votes
1answer
31 views

Convert categorical data in numeric preserve euclidean distance

I m looking how to preserve Euclidean distance with categorical attribute. Ad example, if I have a dataset with attribute of people, Age, weight etc..and i find a attribute "sex" where contain "...
0
votes
1answer
34 views

Having difficult interpreting the eigenvectors for a simple 3x2 matrix

I calculated the eigenvectors and eigenvalues from a covariance matrix given a data matrix of 3 columns and 2 rows. I am trying to interpret results but I can't understand on how to interpret them. ...
0
votes
1answer
21 views

Can you apply PCA to part of your dataset?

I am working with kaggle dataset that has over 130 features composed of 116 categorical and 14 continuous features. I plotted the heatmap for the 14 continuous variables and found that most of them ...
0
votes
1answer
29 views

Scaling sparse data for PCA

Not sure how I should interpret the scaling. Is it correct to convert the sparse matrix to a dense matrix by padding with 0's and scale normally?
1
vote
0answers
53 views

Best classification technique for following kind of data set

I have a large table where each record or row represents a single salesperson, and there are 50 columns or dimensions where each column represents one of 50 products potentially sold by any given ...
3
votes
3answers
138 views

Why do we choose principal components based on maximum variance explained?

I've seen many people choose # of principal components for PCA based on maximum variance explained. So my question is do we always have to choose principal components based on maximum variance ...
0
votes
1answer
30 views

target in cluster analisys (PCA)

i m doing dimensionaly reduction using PCA. I don't understand why some dataset already had a target ad example in Iris database or other like this (https://scikit-learn.org/stable/datasets/index.html)...
0
votes
2answers
35 views

In PCA, every principal component a eigen vector?

In pca, we convert predictors into principal components for dimensionality reduction. My assumption is every principal component is a eigen vector with eigen value as sum of squared distance of ...
0
votes
1answer
38 views

PCA in visual Analytics

I m studying visual analytics and i have a theoretical question about this topic. My professor introduced this schema in him slide For connect data to visualisation. Some topic is very easy to ...
2
votes
4answers
44 views

Is dimension reduction helpful to select features for a classification problem?

Let's say I have a data set but I don't know what features are relevant to solve a classification/regression problem. In this case, is it worth/good to use a dimension reduction algorithm and then ...
3
votes
1answer
190 views

PCA, SMOTE and cross validation- how to combine them together?

I was reading a lot recently about PCA and cross validation and it seems that the majority call it malpractice to do PCA before cross validation. I would also like to perform SMOTE, but there is a ...
3
votes
1answer
44 views

Many things behave differently in high dimensional space

It turns out that many things behave very differently in high dimensional space. The below paragraph is picked from a book. I need extra help to understand. The book says, if you pick a random ...
1
vote
0answers
15 views

How to compare Factor and Principal Component Analysis results?

I am currently working on an assignment where I am to perform a comparison of different Dimension Reduction techniques in Python. I am using the Scikit-learn functions to perform PCA and FA. However I ...
-1
votes
2answers
35 views

Similarity measure before and after dimensionality reduction or clustering

I have a dataset with 500 000 samples, each sample contains 30 features. The values of the features are in the range 0.0 to 1.0. ...
1
vote
1answer
28 views

Scale of the data after PCA

I have 4 standard normal features on which I perform PCA. I then take the first principal component (with all of the components). Is it possible to a priori say what is the max and the min value that ...
0
votes
1answer
32 views

How can we apply PCA to reduce dimensionality of a heterogenous dataset?

I have a dataset containing insurance Claims with quantitative and qualitative variables but PCA refuses to convert or work with "string" type variables. This is the code I used : ...
1
vote
0answers
21 views

PCA on conditional heteroscedastic timeseries

What is the correct method of application of PCA on time series data. Since the time series may exhibit conditional heteroscedasticity, application of normal PCA might be wrong as the variance changes ...
0
votes
1answer
13 views

How the original data can be written in the space defined by these M principal components?

Suppose you apply PCA on the data $x_1,...,x_6$ and find that data can be fully described using M principal components $u_1,...,u_M$. How the original data can be written in the space defined by these ...
0
votes
1answer
21 views

Given a 12x12 binary image (only black and white pixels) what is its dimensionality? And how can I define dimensionality of a data space?

Suppose I have a grid 12x12 of pixels that can be only black or white. I can't understand if the dimensionality is 2 or 3. I mean... Is dimension given by 12x12 or 12x12x2 ?
3
votes
1answer
29 views

Ploting eigenvectors

I've generated two clouds of 3d points from multivariate_normal ...
1
vote
1answer
35 views

How to mathematically explain the translational and rotational invariance of PCA

There is a homework question for a course I am self studying (not a student) that is: let our $n \times d$-dimensional data vectors be denoted by $x_1,\ldots,x_n$ and let $R$ be a $d \times d$ ...
2
votes
0answers
64 views

t-SNE on extremely high-dimensional spaces

I successfully applied t-SNE to the number handwriting dataset. n=3823 data points (i.e. handwritten numbers) in an D=64 dimensional space (i.e. 8x8 pixels). Worked great. Now I would like to cluster ...
1
vote
0answers
19 views

I need help interpreting this PCA plot

I have a dataset of 116 observations and 10 numeric variables. The dataset contains information about healthy patients and patients attained with breast cancer. I did a PCA plot showing the cluster of ...
1
vote
0answers
63 views

PCA for unsupervised feature selection [closed]

If I understood correctly, "using results of PCA to select features" (as recommended in this answer) implies visually analysing bi-plots of first two principal components - i.e. the angle between a ...
1
vote
0answers
22 views

Show importance of variables from a data set without a response variable? Use PCA? [closed]

I am trying to find a way to statistically show that some variables in my data set are more important than others to determine its classification. I have an example data set with three variables from ...
2
votes
0answers
26 views

I have data of some movies and their subtitles.I want to classify them based on their ratings

I will convert the subtitles into vectors and use them as features to classify the movies into different categories based on their ratings.The problem that I am facing is my feature vector is much ...
2
votes
1answer
57 views

PCA: projection of positive data on negative side of plane

I did PCA on my data and projected the data on first two eigen vectors. After projection I see that the scatter plot of the data starts from [-1,-1]. My data is all positive. Is it correct for the ...
0
votes
1answer
81 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
171 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 ...
1
vote
3answers
41 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) ...
2
votes
1answer
55 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
31 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
62 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: ...
1
vote
2answers
59 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 ...
1
vote
2answers
837 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
1answer
17 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
37 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 ...