我有绘制的散点图多维的EPlotting散点图特点
我想绘制音频的值在散点图上清晰的视觉效果功能(不是我有我的训练5个的音频文件设置的问题 - 我将用它来训练KNN/SVM等增加我的数据集之后)
标记的training_labels是 [0, 0, 1, 2, 1]
虽然training_feature值
[
[103.359375, [11, 36, 60, 85, 110, 134, 159, 183, 208, 232, 257, 286, 310, 335]],
[89.10290948275862, [11, 41, 69, 98, 127, 155, 184, 213, 241, 270, 299, 327, 356]],
[151.99908088235293, [7, 24, 41, 57, 73, 90, 107, 123, 140, 157, 173, 189, 206, 223, 239, 256, 272, 290, 307, 325, 343, 360, 377]],
[143.5546875, [39, 57, 77, 95, 114, 132, 150, 168, 186, 204, 222, 239, 256, 272, 288, 305, 322, 340]],
[83.35433467741936, [8, 38, 70, 101, 137, 168, 199, 230, 266, 298, 334, 365]]
]
进行分类的每个对象有2个特点叫tempo
和beat per minute
我怎么能在散点图中绘制的?
我尝试以下,但它失败,因为x和y
featureA = [x[0] for x in training_features]
featureB = [x[1] for x in training_features]
plt.scatter(featureA[:2], featureB[:2])
plt.scatter(featureA[2:], featureB[2:], color='r')
plt.xlabel('Beat Frame')
plt.ylabel('Tempo')
的大小之间的差异这给我一个错误ValueError: setting an array element with a sequence.
。请帮助:)
编辑:还有一两件事,我怎么能绘制多个功能即(> 2),我想使用频谱质心,过零率,MFCC等,然后画出结果
你必须每x值超过10的y值。你需要告诉我们你想对什么进行阴谋。 – ImportanceOfBeingErnest
我不知道tbh,我只是为了检查它们如何在scatterplot中可视化@ImportanceOfBeingErnest –