机器学习笔记之正规矩阵的不可逆性

xiaoxiao2021-02-27  284

Normal Equation Non-invertibility

When implementing the normal equation inoctave we want to use the 'pinv' function rather than 'inv.' The 'pinv'function will give you a value of θ evenif XTX is notinvertible.

If XTX is non-invertible, thecommon causes might be having :

·        Redundant features, where two features are very closelyrelated (i.e. they are linearly dependent)

·        Too many features (e.g. m ≤ n). In this case, delete somefeatures or use "regularization" (to be explained in a later lesson).

Solutions to theabove problems include deleting a feature that is linearly dependent withanother or deleting one or more features when there are too many features.

转载请注明原文地址: https://www.6miu.com/read-11863.html

最新回复(0)