Matrix factorization
Matrix factorization is the decomposition or approximation of a matrix as a product of simpler, often lower-dimensional or structured matrices.
AI-Powered Search
Matrix factorization is a mathematical technique that decomposes a user-item interaction matrix into lower-dimensional factors representing users, latent attributes, and items.
- How it is used
- Improves personalized recommendations and search relevance when sparse interactions limit direct collaborative-filtering lookup.
- How deep it goes
- Defines matrix decomposition, latent factors, dot-product prediction, and reconstruction, but does not detail model-training procedures.
- Examples
- Uses movie purchases, appliance colors, entertainment systems, smartphones, and reconstructed preference matrices.
- What you can do after
- Apply it to infer unseen user-item preferences and discover item similarities from sparse interaction signals.
AI Recommender Systems
Matrix factorization is a technique that decomposes a user-item interaction matrix into lower-dimensional factor matrices representing users and items.
- How it is used
- Serves as a collaborative-filtering method for learning user and item embeddings and generating recommendation candidates.
- How deep it goes
- Works through factor matrices and dot products, then outlines alternating least-squares updates without deriving their closed-form solutions.
- Examples
- Uses a small movie-rating matrix and two-factor dot products to illustrate observed and missing preferences.
- What you can do after
- Apply it via the implicit library to learn factors with ALS, predict preferences, and find similar items.
Read how AI Recommender Systems explains matrix factorization →
Grokking Machine Learning
An algorithmic technique that represents a matrix through products of lower-dimensional matrices to reduce its row and column dimensions.
- How it is used
- Simplifies data by reducing both the rows and columns of a matrix, and can support predictions from user–movie ratings.
- How deep it goes
- Defines the smaller-matrix product idea and illustrates recommendation use, but gives no factorization procedure or equations.
- Examples
- Uses a user–movie rating table to illustrate extracting movie features and predicting ratings.
- What you can do after
- Understand how a smaller-matrix product can simplify data and help predict ratings from user–movie features.
Read how Grokking Machine Learning explains matrix factorization →
Also covered in
- Deep Learning with R, Third Edition
- Geometry for Programmers
- Grokking Machine Learning, Second EditionIn early access (MEAP)
- Transformers in Action
What to know first
- arrayAn array is an ordered collection of elements organized in one or more dimensions and accessible by position or index.
- collaborative filteringCollaborative filtering is a recommendation technique that infers preferences or associations from interaction patterns among users, items, or other entities.
- content-based recommenderA content-based recommender suggests items whose features resemble those of items matching a user’s interests or prior interactions.
- linear algebraLinear algebra is the branch of mathematics concerned with vectors, vector spaces, matrices, linear transformations, and systems of linear equations.
Related concepts
- alternating least squaresincludes · Alternating least squares is an iterative optimization algorithm that alternately estimates each factor matrix while holding the others fixed.
- user-item interaction matrixuses · A user-item interaction matrix is a matrix whose rows represent users, columns represent items, and entries encode their interactions, preferences, or ratings.
- collaborative filteringused by · Collaborative filtering is a recommendation technique that infers preferences or associations from interaction patterns among users, items, or other entities.
- latent semantic analysisused by · Latent semantic analysis is a text-analysis technique that uses dimensionality reduction of term-document data to represent latent relationships among words and documents.
- scalar multiplicationuses · Scalar multiplication is an operation that combines a scalar with a vector or other mathematical object according to the rules of its algebraic structure.
Questions about matrix factorization
What is matrix factorization?
Matrix factorization is the decomposition or approximation of a matrix as a product of simpler, often lower-dimensional or structured matrices.
Which Manning books explain matrix factorization?
AI-Powered Search, AI Recommender Systems and Grokking Machine Learning.
What should I know before learning matrix factorization?
Manning books that teach matrix factorization usually introduce array, collaborative filtering, content-based recommender and linear algebra first.
What kinds of matrix factorization are there?
Kinds of matrix factorization include alternating least squares and nonnegative matrix factorization.
These guides are generated from the text of Manning books by Manning's knowledge graph and link to the sections they draw on. The full books are available on liveBook and at manning.com.


