irisclustering.py 文件源码

python
阅读 23 收藏 0 点赞 0 评论 0

项目:iris-Clustering-python-PTVS 作者: mjbahmani 项目源码 文件源码
def GetFeatures(frame):
    #convert data to float
    arr = np.array(frame,dtype=np.float)
    #fill missing values
    from sklearn.preprocessing import Imputer
    imputer = Imputer(strategy='mean')
    arr = imputer.fit_transform(arr)
    #normalize the entire data
    from sklearn.preprocessing import scale
    arr = scale(arr)
    return arr
#=================================================
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号