我想根据这些数据预测计数列。 但首先,我已经使用LabelEncoder对其进行了编码
我用来编码这些数据的代码是:
def dummyEncode(df)
Hasil = []
columnsToEncode = list(Hasilatribut)
le = LabelEncoder()
for feature in columnsToEncode:
try:
df[feature] : le.fit_transform(df[feature]).astype(float)
except:
print('Error encoding '+feature)
return df
在预测的最后一步,我想将“date”、“tablename”和“attributename”转换为原始类型。 我已经使用了逆_变换,但仍然得到错误
结果仍然类似于“hasil”输出
请帮我解决这个问题
目前没有回答
相关问题 更多 >
编程相关推荐