5c94c8388d8e90398471707d40b941f4d53abd11,factor_analyzer/factor_analyzer.py,FactorAnalyzer,_normalize_wls,#Any#Any#Any#,250

Before Change



        // make sure that only the real part of the value
        // is used, if `complex` is returned
        values = sp.real(values)

        // calculate loadings
        // if values are smaller than 0, set them to zero
        loadings = sp.dot(vectors, sp.diag(sp.sqrt(np.maximum(values, 0))))

After Change



        // sort the values and vectors in ascending order
        values = values[::-1][:n_factors]
        vectors = vectors[:, ::-1][:, :n_factors]

        // calculate loadings
        // if values are smaller than 0, set them to zero
Italian Trulli
In pattern: SUPERPATTERN

Frequency: 3

Non-data size: 3

Instances


Project Name: EducationalTestingService/factor_analyzer
Commit Name: 5c94c8388d8e90398471707d40b941f4d53abd11
Time: 2018-04-13
Author: jbiggs@ets.org
File Name: factor_analyzer/factor_analyzer.py
Class Name: FactorAnalyzer
Method Name: _normalize_wls


Project Name: librosa/librosa
Commit Name: 7bca836f56bcb10aaca45ded2088cad722a3416b
Time: 2013-03-09
Author: brm2132@columbia.edu
File Name: librosa/__init__.py
Class Name:
Method Name: istft


Project Name: EducationalTestingService/factor_analyzer
Commit Name: 5c94c8388d8e90398471707d40b941f4d53abd11
Time: 2018-04-13
Author: jbiggs@ets.org
File Name: factor_analyzer/factor_analyzer.py
Class Name: FactorAnalyzer
Method Name: _fit_uls_objective