🎉 75% of content is free forever — Unlock Premium from $10/mo →
CW
NEWSLIVESearch All Content
💼 Servicesℹ️ About✉️ ContactView Pricing Plansfrom $10

Factor Analysis — Latent Variable Models

StatisticsMultivariate Analysis🟢 Free Lesson

Factor Analysis — Latent Variable Models

Statistics

Discovering Hidden Variables That Drive Observed Patterns

Factor analysis identifies latent constructs that explain correlations among observed variables. It reveals underlying dimensions — like intelligence or socioeconomic status — that cannot be measured directly but manifest through multiple indicators.

  • Psychology — Identify personality traits from questionnaire responses

  • Marketing — Discover latent customer segments from behavioral data

  • Education — Measure abstract constructs like academic aptitude from test scores

Beneath the surface of many measured variables lie a few hidden forces shaping them all.


Factor analysis identifies latent (hidden) variables that explain correlations among observed variables. It reduces many correlated measurements into a smaller set of underlying factors.


Factor Loadings

Factor loadings represent the correlation between each observed variable and each factor. They form the loading matrix .


Factor Extraction Methods

Principal Component Method

The most common approach. Factors are extracted sequentially to maximize variance explained.

| Method | Key Idea | When to Use |

|--------|----------|-------------|

| Principal Components | Maximize total variance | Default; data reduction |

| Maximum Likelihood | Maximize likelihood under normality | Normal data; hypothesis testing |

| Principal Axis Factoring | Iteratively estimates communalities | When normality is questionable |

| Minimum Residual | Minimize off-diagonal residuals | Small samples |


Rotation

Rotation makes factors more interpretable by achieving simple structure — each variable loads highly on one factor and lowly on others.

Types of Rotation

| Type | Constraint | When to Use |

|------|-----------|-------------|

| Varimax (orthogonal) | Factors uncorrelated | When factors are independent |

| Promax (oblique) | Factors may correlate | When factors are expected to be related |

| Oblimin (oblique) | Factors may correlate | Flexible oblique rotation |


Number of Factors

Several criteria help determine how many factors to retain:

  1. Kaiser's Rule: Retain factors with eigenvalues > 1

  2. Scree Plot: Look for the "elbow" where eigenvalues level off

  3. Parallel Analysis: Compare eigenvalues to those from random data

  4. Velicer's MAP: Minimize average partial correlations


Assumptions

  • Linearity: Relationships among variables are linear

  • Multivariate normality: Data are approximately normally distributed

  • Adequate sample size: Generally n > 100 (some say n > 5 variables per factor)

  • No perfect multicollinearity: Variables are not perfectly correlated


KMO Test

The Kaiser-Meyer-Olkin measure assesses sampling adequacy.

| KMO Value | Interpretation |

|-----------|---------------|

| 0.9 - 1.0 | Marvelous |

| 0.8 - 0.9 | Meritorious |

| 0.7 - 0.8 | Middling |

| 0.6 - 0.7 | Mediocre |

| 0.5 - 0.6 | Miserable |

| < 0.5 | Unacceptable |


Python Implementation

python

import numpy as np

import pandas as pd

from factor_analyzer import FactorAnalyzer

from factor_analyzer.factor_analyzer import calculate_bartlett_sphericity, calculate_kmo



np.random.seed(42)



# Simulated data with 3 latent factors

n = 500

f1 = np.random.randn(n)

f2 = np.random.randn(n)

f3 = np.random.randn(n)



data = pd.DataFrame({

    'X1': 0.8*f1 + 0.1*np.random.randn(n),

    'X2': 0.7*f1 + 0.2*np.random.randn(n),

    'X3': 0.6*f1 + 0.3*np.random.randn(n),

    'X4': 0.8*f2 + 0.1*np.random.randn(n),

    'X5': 0.7*f2 + 0.2*np.random.randn(n),

    'X6': 0.6*f2 + 0.3*np.random.randn(n),

    'X7': 0.9*f3 + 0.1*np.random.randn(n),

    'X8': 0.7*f3 + 0.2*np.random.randn(n),

})



# Bartlett's test

chi_square, p_value = calculate_bartlett_sphericity(data)

print(f"Bartlett's test: chi2={chi_square:.2f}, p={p_value:.4e}")



# KMO

kmo_all, kmo_model = calculate_kmo(data)

print(f"KMO: {kmo_model:.3f}")



# Factor analysis with 3 factors, varimax rotation

fa = FactorAnalyzer(n_factors=3, rotation='varimax')

fa.fit(data)



# Loadings

loadings = pd.DataFrame(fa.loadings_,

    index=data.columns,

    columns=['Factor 1', 'Factor 2', 'Factor 3'])

print("\nFactor Loadings:")

print(loadings.round(3))



# Variance explained

variance = fa.get_factor_variance()

print(f"\nVariance explained: {variance[1].round(3)}")

print(f"Cumulative: {variance[2].round(3)}")


Worked Example


Key Takeaways


Related Topics


Extended Learning: Beyond the Basics

Key Concepts Summary

This lesson covers fundamental concepts that serve as building blocks for more advanced topics. Master these basics before moving to intermediate and advanced material.

Prerequisite Knowledge

Before studying this topic in depth, ensure you understand:

  • Basic definitions and terminology
  • Core formulas and their derivations
  • Common applications in real-world scenarios
  • Typical pitfalls and misconceptions

Step-by-Step Walkthrough

Let us work through a complete example to solidify understanding:

Step 1: Identify the problem type. Determine which category this problem falls into and which approach is most appropriate.

Step 2: Apply the relevant formula. Substitute known values into the appropriate equation, paying attention to units and constraints.

Step 3: Simplify and solve. Work through the algebra step by step, checking each intermediate result.

Step 4: Verify the answer. Check that the solution satisfies the original conditions and makes logical sense.

Common Mistakes to Avoid

  1. Misidentifying the problem type — Always start by categorizing the problem
  2. Incorrect formula application — Verify the formula applies to your specific case
  3. Unit errors — Always check units are consistent throughout
  4. Sign errors — Pay careful attention to positive and negative values
  5. Rounding too early — Keep full precision until the final answer
  6. Forgetting constraints — Check that solutions satisfy all given conditions

Real-World Applications

Understanding this concept is essential for:

  • Advanced problem solving in examinations
  • Building intuition for more complex topics
  • Developing analytical thinking skills
  • Applying mathematical reasoning to practical situations

Practice Exercises

  1. Basic: Solve 5 problems of increasing difficulty using the core concept.
  2. Intermediate: Apply the concept to word problems with multiple steps.
  3. Advanced: Combine this concept with 2-3 other topics in a comprehensive problem.
  4. Challenge: Create your own problem that requires this concept plus additional knowledge.

Interview and Exam Tips

  • Common question patterns: Identify which exam or interview formats test this topic
  • Time management: Practice completing problems within time constraints
  • Common traps: Know the typical mistakes examiners set as distractors
  • Verification strategy: Develop a quick method to check your answer

Related Topics

Quick Reference Card

ConceptFormula/RuleKey InsightCommon Use
Core DefinitionSee main textUnderstand the intuitionFoundation for all applications
Key FormulaSee main textMemorize the derivationDirect problem solving
Special CaseSee main textRecognize when it appliesSimplifies complex problems
Edge CaseSee main textKnow the limitationsAvoids errors

Further Reading

For students who want to go deeper:

  • Standard textbooks on the subject
  • Research papers applying this concept
  • Online courses with video explanations
  • Practice problem collections with detailed solutions
CW

ChatWhole Learn Editorial Team

Written by experienced data scientists, software engineers, and educators. All content is reviewed by industry professionals to ensure accuracy and relevance.

Last reviewed: 2026-11-14

—
☆☆☆☆☆
0 ratings

Rate & Feedback

Need Expert Statistics Help?

Get personalized tutoring, project support, or professional consulting.

Advertisement