How to Solve NameError: name 'LinearDiscriminantAnalysis' is not defined -- sklearn

Solution: Import the 'LinearDiscriminantAnalysis' module

To Solve the error, add the following line to the top of your code.

from sklearn.discriminant_analysis import LinearDiscriminantAnalysis

 

For more information:
Python LinearDiscriminantAnalysis sklearn