Questions tagged [pca]

Principal component analysis (PCA) is a statistical technique for dimension reduction often used in clustering or factor analysis. Given any number of explanatory or causal variables, PCA ranks the variables by their ability to explain greatest variation in the data. It is this property that allows PCA to be used for dimension reduction, i.e. to identify the most important variables from amongst a large set possible influences.

Overview

Principal component analysis (PCA) is a statistical technique for dimension reduction often used in clustering or factor analysis. Given any number of explanatory or causal variables, PCA ranks the variables by their ability to explain greatest variation in the data. It is this property that allows PCA to be used for dimension reduction, i.e. to identify the most important variables from amongst a large set possible influences.

Mathematically, principal component analysis (PCA) amounts to an orthogonal transformation of possibly correlated variables (vectors) into uncorrelated variables called principal component vectors.

Tag usage

Questions on tag should be about implementation and programming problems, not about the statistical or theoretical properties of the technique. Consider whether your question might be better suited to Cross Validated, the StackExchange site for statistics, machine learning and data analysis.

In scientific software for statistical computing and graphics, functions princomp and prcomp compute PCA.

2728 questions
0
votes
0 answers

MercerKernel and Kernel PCA using smile in Java

Smile KPCA Code Image So, I came across the concept of Kernel PCA for feature extraction. Currently, I am using smile's Java jar for kernel pca. While reading about their code, I also have doubts about Mercer Kernel. I want someone to explain the…
Riya
  • 11
  • 1
0
votes
1 answer

How to add a factor column to a data frame (in R)

I currently have a data set with mercury in fish levels (as values). I wanted to add another column classifying the concentration as "low" "medium" or "high", based on a value I would determine. Ex:<0.1 is considered low, between 0.1 and 0.3 is…
Reb
  • 1
0
votes
0 answers

> library("factoextra") Error in library("factoextra") : there is no package called ‘factoextra’

I've been trying to install the package factoextra to do pca plots. However, when I try to install the packages it says it is already installed and it asks me to restart the r session. Then when I'm trying to load the library it says >…
0
votes
1 answer

Error Call to publish() on an invalid Publisher?

I created a ROS node for lane detection from laser scans using PCA. Also wonted to visualize the lanes . So I created a marker and then published the marker. The code can be build with catkin_ make. But when running the node is has the error. So…
Bob9710
  • 205
  • 3
  • 15
0
votes
0 answers

getting this error while doing pca analysis

import keras import tensorflow as tf data = tf.keras.datasets.mnist.load_data(path="mnist.npz") import numpy as np def pca(X): # Normalize the data X_mean = np.mean(X, axis=0) X_std = np.std(X, axis=0) X_std[X_std == 0] = 1e-6 #…
0
votes
0 answers

Error when using Principle Component Analysis with Point Clouds in ROS?

I would like to use PCA on the point clouds to find the lane . So the Principle Component Analysis should work fine for this problem. So Im not sure how to correctly use PCA with Point Clouds and ROS. Here is the code that I create so far #include…
Bob9710
  • 205
  • 3
  • 15
0
votes
0 answers

align step file to point of clouds python

I am trying to align a step file with a 3D model to a point of clouds of the object 3D scan. I am doing the following steps and using the open3d module. Convert the step file to stl and then to a point of clouds. Calculate the center of the scan…
Xico97
  • 1
  • 1
0
votes
0 answers

PCA line keeping with laser scan data?

Im trying to detect the corridor area (walls) using 2D Lidar while robot is moving. I would like to use PCA (Principle Component Analysis ) and ROS . I didnt find any examples in ROS using laser scan data and PCA. I find an ROS example of OpenCV…
Bob9710
  • 205
  • 3
  • 15
0
votes
0 answers

Why does factor analysis in Stata not restrict the to factors with eigenvalues greater than one when using maximum likelihood criterion?

I am comparing two different methods for factor analysis in Stata: principal factors (as specified by the pf option) and maximum likelihood (as specified by the ml option). Here are the two commands I am comparing: sysuse auto factor price mpg…
Bicep
  • 1,093
  • 4
  • 14
0
votes
0 answers

Reducing dimensionality to create a unique variable

I have a dataset including dozens of health-related variables: some of them are quantitative (such as 'Body Mass Index') and some of them are qualitative (such as the variable isDrinking, that takes 0 (no) and 1 (yes) for values as answers to the…
0
votes
0 answers

how to preform feature dimension reduction using SVD?

so, I have read a lot about SVD component analysis and I know that X is being factorized into unitary matrix U and diagonal matrix S, and another unitary matrix Vt and I have read that in order to make dimension reduction from N features to L where…
abdo Salm
  • 1,678
  • 4
  • 12
  • 22
0
votes
0 answers

Adding ind labels to a pca biplot

I'm making a biplot for a PCA, but the individuals are only showing up as points. Is there any way to keep the variables and individuals grouped and have the name label appear over each point? I ask this because it's important to see the groups they…
0
votes
0 answers

Principal Component Analysis and Correlation in R

Could you please explain how to use principal components in principal component analysis in a correlation analysis? I performed a PCA on my dataset and extracted 2 components; Now I'm wondering how to use pearson or spearman correlation analaysis to…
0
votes
0 answers

MLPRegressor training results in 1 layer 1 node network. What does this mean?

I have been trying to train an MLP regression model. The data has way more dimensions than samples. The approach I took is first run PCA on it such that the amount of left over dimensions < samples. What I seem to experience (using GridSearchCV) is…
Peter Coppens
  • 103
  • 2
  • 7
0
votes
0 answers

What to do with the results of PCA?

So I have the G1, G2 and G3 columns in my data. They represent students' grades G1 - first period grade (numeric: from 0 to 20) G2 - second period grade (numeric: from 0 to 20) G3 - final grade (numeric: from 0 to 20, output target) G1, G2, G3 head…
Hey
  • 1
  • 1
1 2 3
99
100