我有一大套我试图在 3D 中显示的数据, 希望找到一个模式。 我花了相当长的时间读、研究和编码, 但后来我意识到我的主要问题不是编程,
Matplotlib s mplot3d 提供了许多选项( 网络框架、 轮廓、 填满的轮廓等 ), 玛雅维(Maya Vi) 也是如此 。 但有很多选择( 以及每个选择都有自己的学习曲线 ), 我几乎迷失了方向, 不知道从哪里开始 。 所以, 我的问题是, 如果必须处理这些数据, 你会使用什么样的计划方法?
我的数据基于日期。 对于每个时间点, 我都会绘制一个值( 列表实际 ) 。
但对于每个时间点,我也有上限、下限和中点。 这些限值和中点基于种子,在不同平面上。
我想辨别点点或确定模式, 在我的实际阅读中何时或之前发生重大改变 。 是所有飞机的上限达到时? 还是相互接近? 实际值达到上限/ 中/ 下限时? 是上/ 中/ 下限时吗? 当一架飞机的上限达到另一架飞机的下限时是上/ 中/ 下限时吗?
在代号I m 粘贴中, 我将数据集简化为几个元素 。 我只是使用简单的散射和线条图, 但是由于数据集的大小( 可能还有 mplot3d 的局限性? ), 我无法使用它来识别我所要寻找的趋势 。
dates = [20110101,20110104,20110105,20110106,20110107,20110108,20110111,20110112]
zAxis0= [ 0, 0, 0, 0, 0, 0, 0, 0]
Actual= [ 1132, 1184, 1177, 950, 1066, 1098, 1116, 1211]
zAxis1= [ 1, 1, 1, 1, 1, 1, 1, 1]
Tops1 = [ 1156, 1250, 1156, 1187, 1187, 1187, 1156, 1156]
Mids1 = [ 1125, 1187, 1125, 1156, 1156, 1156, 1140, 1140]
Lows1 = [ 1093, 1125, 1093, 1125, 1125, 1125, 1125, 1125]
zAxis2= [ 2, 2, 2, 2, 2, 2, 2, 2]
Tops2 = [ 1125, 1125, 1125, 1125, 1125, 1250, 1062, 1250]
Mids2 = [ 1062, 1062, 1062, 1062, 1062, 1125, 1000, 1125]
Lows2 = [ 1000, 1000, 1000, 1000, 1000, 1000, 937, 1000]
zAxis3= [ 3, 3, 3, 3, 3, 3, 3, 3]
Tops3 = [ 1250, 1250, 1250, 1250, 1250, 1250, 1250, 1250]
Mids3 = [ 1187, 1187, 1187, 1187, 1187, 1187, 1187, 1187]
Lows3 = [ 1125, 1125, 1000, 1125, 1125, 1093, 1093, 1000]
import matplotlib.pyplot
from mpl_toolkits.mplot3d import Axes3D
fig = matplotlib.pyplot.figure()
ax = fig.add_subplot(111, projection = 3d )
#actual values
ax.scatter(dates, zAxis0, Actual, color = c , marker = o )
#Upper limits, Lower limts, and Mid-range for the FIRST plane
ax.plot(dates, zAxis1, Tops1, color = r )
ax.plot(dates, zAxis1, Mids1, color = y )
ax.plot(dates, zAxis1, Lows1, color = b )
#Upper limits, Lower limts, and Mid-range for the SECOND plane
ax.plot(dates, zAxis2, Tops2, color = r )
ax.plot(dates, zAxis2, Mids2, color = y )
ax.plot(dates, zAxis2, Lows2, color = b )
#Upper limits, Lower limts, and Mid-range for the THIRD plane
ax.plot(dates, zAxis3, Tops3, color = r )
ax.plot(dates, zAxis3, Mids3, color = y )
ax.plot(dates, zAxis3, Lows3, color = b )
#These two lines are just dummy data that plots transparent circles that
#occpuy the "wall" behind my actual plots, so that the last plane appears
#floating in 3D rather than being pasted to the plot s background
zAxis4= [ 4, 4, 4, 4, 4, 4, 4, 4]
ax.scatter(dates, zAxis4, Actual, color = w , marker = o , alpha=0)
matplotlib.pyplot.show()
我得到了这个阴谋,但它只是不 帮助我看到任何关系。
I m no mathematician or scientist, so what I really need is help choosing the FORMAT in which to visualize my data. Is there an effective way to show this in mplot3d? Or would you use MayaVis? In either case, which library and class(es) would YOU use?
提前感谢。