def plot_gyroscope(self):
"""Plot gyroscope"""
gyro_x = [data["wf"] for data in self.oxts]
gyro_y = [data["wl"] for data in self.oxts]
gyro_z = [data["wu"] for data in self.oxts]
fig = plt.figure()
plt.suptitle("Gyroscope")
ax1 = fig.add_subplot(311)
ax2 = fig.add_subplot(312)
ax3 = fig.add_subplot(313)
ax1.plot(self.timestamps, gyro_x)
ax1.set_xlabel("Date Time")
ax1.set_ylabel("rad s^-1")
ax1.set_xlim([self.timestamps[0], self.timestamps[-1]])
ax2.plot(self.timestamps, gyro_y)
ax2.set_xlabel("Date Time")
ax2.set_ylabel("rad s^-1")
ax2.set_xlim([self.timestamps[0], self.timestamps[-1]])
ax3.plot(self.timestamps, gyro_z)
ax3.set_xlabel("Date Time")
ax3.set_ylabel("rad s^-1")
ax3.set_xlim([self.timestamps[0], self.timestamps[-1]])
fig.tight_layout()
评论列表
文章目录