Calculator Input
Enter variable setup, component loadings, and observation rows. The layout stays single-column overall, while the input areas shift between 3, 2, and 1 columns responsively.
Example Data Table
This example matches the default calculator values so you can test the score viewer immediately.
Example observations
| Observation | Length | Width | Height | Weight |
|---|---|---|---|---|
| Sample A | 11 | 18 | 34 | 44 |
| Sample B | 9 | 22 | 31 | 37 |
| Sample C | 14 | 27 | 29 | 45 |
| Sample D | 8 | 19 | 26 | 32 |
| Sample E | 12 | 24 | 35 | 49 |
Example PCA setup
| Variable | Mean | Std. Dev. | PC1 Loading | PC2 Loading | PC3 Loading |
|---|---|---|---|---|---|
| Length | 10 | 2 | 0.58 | 0.22 | 0.72 |
| Width | 20 | 4 | 0.41 | -0.71 | 0.08 |
| Height | 30 | 5 | 0.55 | 0.18 | -0.52 |
| Weight | 40 | 8 | 0.43 | 0.64 | -0.44 |
Example eigenvalues: 2.8, 0.9, 0.3
Formula Used
PCA scores convert each observation into coordinates on principal components. This is done after standardizing each variable so differences in units do not dominate the analysis.
Step 1: Standardize each variable
zi = (xi - meani) / stdi
Step 2: Calculate each component score
PCk Score = Σ (zi × loadingik)
Step 3: Explained variance
Explained Variance % = eigenvaluek / Σ eigenvalues × 100
Positive or negative scores indicate direction along each component axis. Large absolute values show stronger separation from the dataset center on that component.
How to Use This Calculator
- Choose the number of variables and the number of principal components.
- Enter comma-separated variable names, means, standard deviations, and eigenvalues.
- Paste the loading matrix, using one row for each component.
- Paste observation rows with an optional leading label.
- Click Calculate PCA Scores to generate the score table and graph.
- Use the export buttons to save your results as CSV or PDF.
FAQs
1. What does this PCA Scores Viewer calculate?
It standardizes each observation, applies your component loading matrix, and returns PC scores for every row. It also shows explained variance, a score plot, and export-ready tables.
2. Why are means and standard deviations required?
PCA scores are usually based on standardized variables. Means center the data, and standard deviations scale it. Without that step, variables with larger units can dominate the score values.
3. What format should the loadings matrix use?
Enter one comma-separated row for each principal component. Every row must contain one loading for every variable. If you choose three components and four variables, enter three rows with four values each.
4. Can I paste rows with sample names?
Yes. Each observation row may begin with a label such as Sample A. After the label, enter the numeric values in the same order as your variable names.
5. What does a large positive or negative PC score mean?
It means the observation lies far from the dataset center in that component direction. The sign shows orientation, while the absolute value shows the strength of separation along that axis.
6. Why are eigenvalues included here?
Eigenvalues let the calculator estimate explained variance percentages for each component. That helps you understand how much of the total standardized variation is represented by each PC.
7. What does the magnitude column represent?
Magnitude is the Euclidean length of the observation in principal component space. It summarizes overall distance from the center across the displayed components, helping identify more extreme samples quickly.
8. Can I use this for teaching, reporting, or validation?
Yes. The calculator is useful for classroom demonstrations, score checking, dataset review, and report preparation. Built-in exports and the plot make it easier to share and verify results.