我有一个来自CSV数据的dataframe
(一个矩阵)如下所示:
BS1 BS2 BS3 BS4 BS5 BS6 BS7 BS8 BS9
BS1 0 1 6 1 0 0 0 0 0
BS2 1 0 8 1 0 0 0 0 0
BS3 0 6 0 2 3 1 0 0 0
BS4 0 0 4 0 1 2 0 0 0
BS5 0 1 3 2 0 3 0 0 0
BS6 0 0 0 0 0 0 5 4 2
BS7 0 4 7 3 4 0 0 5 6
BS8 0 0 0 0 0 0 5 0 7
BS9 0 1 5 0 1 0 4 0 0
我想根据CSV矩阵数据制作一个3D图表。但是,XY是字符串。怎么做?你知道吗
预期结果类似于以下链接3D Scatterplot with strings in Python
谢谢你。你知道吗
对于要绘制的每个值,
scatter
函数需要x、y和z值。 试试这个:相关问题 更多 >
编程相关推荐