fc4917ae8a7320fc9a258b50d82a177ed2124a91,category_encoders/basen.py,BaseNEncoder,fit_base_n_encoding,#BaseNEncoder#Any#,148
Before Change
values = values[values > 0]
digits = self.calc_required_digits(X, col)
X_unique = pd.DataFrame(index=values)
X_unique_to_cols = X_unique.index.map(lambda x: self.col_transform(x, digits))
for dig in range(digits):
X_unique[str(col) + "_%d" % (dig,)] = X_unique_to_cols.map(
lambda r: int(r[dig]) if r is not None else None)
if self.handle_unknown == "return_nan":
X_unique.loc[-1] = np.nan
elif self.handle_unknown == "value":
After Change
values = values[values > 0]
digits = self.calc_required_digits(values)
X_unique = pd.DataFrame(index=values,
columns=[str(col) + "_%d" % x for x in range(digits)],
data=np.array([self.col_transform(x, digits) for x in range(1, len(values) + 1)]))
if self.handle_unknown == "return_nan":
X_unique.loc[-1] = np.nan
elif self.handle_unknown == "value":
In pattern: SUPERPATTERN
Frequency: 5
Non-data size: 7
Instances
Project Name: scikit-learn-contrib/categorical-encoding
Commit Name: fc4917ae8a7320fc9a258b50d82a177ed2124a91
Time: 2018-12-21
Author: jcastaldo08@gmail.com
File Name: category_encoders/basen.py
Class Name: BaseNEncoder
Method Name: fit_base_n_encoding
Project Name: QUANTAXIS/QUANTAXIS
Commit Name: 6c84e92a061e7cece79775ac761d525b8a8a97e8
Time: 2018-07-28
Author: yutiansut@qq.com
File Name: QUANTAXIS/QAFetch/QAQuery_Async.py
Class Name:
Method Name: QA_fetch_stock_min
Project Name: scikit-learn-contrib/imbalanced-learn
Commit Name: 158258ee583740b1fd142b04371bc4ab0712cdce
Time: 2019-11-17
Author: g.lemaitre58@gmail.com
File Name: imblearn/utils/estimator_checks.py
Class Name:
Method Name: check_samplers_pandas
Project Name: QUANTAXIS/QUANTAXIS
Commit Name: 6c84e92a061e7cece79775ac761d525b8a8a97e8
Time: 2018-07-28
Author: yutiansut@qq.com
File Name: QUANTAXIS/QAFetch/QAQuery_Async.py
Class Name:
Method Name: QA_fetch_stock_day
Project Name: QUANTAXIS/QUANTAXIS
Commit Name: 5c34d497ab32ea731b687c5863f104615f666d06
Time: 2019-02-16
Author: yutiansut@qq.com
File Name: QUANTAXIS/QAFetch/QAQuery.py
Class Name:
Method Name: QA_fetch_index_day