2022-02-23

48-12#

①在做T-SEN聚类时,报错

报错信息

②然后上CSDN搜索有人遇到过类似问题,并由详细解答[R语言完成t-SNE分析和画图](R语言完成t-SNE分析和画图_小洁忘了怎么分身的博客-CSDN博客_r语言perplexity
image.png

image.png

③再然后上github搜索这个报错Unable to run RunTSNE. Error in .check_tsne_params(nrow(X), dims = dims, perplexity = perplexity, : perplexity is too large for the number of samples #1345

image.png

④最终解决办法,
i解决方式

设置在RunTSNE函数内设置参数perplexity=10即可。

⑤写在最后,补充一下perplexity参数
什么是perplexity:This value effectively controls how many nearest neighbours are taken into account when constructing the embedding in the low-dimensional space.(该值有效地控制了在低维空间中构建嵌入时考虑的近邻数。)
合理的取值范围:The performance of SNE is fairly robust to changes in the perplexity, and typical values are between 5 and 50.(SNE的性能对于复杂情况的变化是相当稳健的,典型值在5到50之间。)

你可能感兴趣的:(2022-02-23)