From 93dfcf95d55441ff38231ecb274bcbf5dabe8de4 Mon Sep 17 00:00:00 2001 From: Andreas Zweili Date: Sun, 20 Oct 2019 21:38:42 +0200 Subject: [PATCH] switch the x and y axis --- sensors/collector/plot.py | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/sensors/collector/plot.py b/sensors/collector/plot.py index a73facb..aafa8f2 100644 --- a/sensors/collector/plot.py +++ b/sensors/collector/plot.py @@ -8,8 +8,8 @@ def temperature(): x_axis = [] y_axis = [] for point in data: - x_axis.append(point.value) - y_axis.append(point.time.value) + y_axis.append(point.value) + x_axis.append(point.time.value) plot_div = plot([Scatter(x=x_axis , y=y_axis, mode='lines', name='temperature', @@ -23,8 +23,8 @@ def humidity(): x_axis = [] y_axis = [] for point in data: - x_axis.append(point.value) - y_axis.append(point.time.value) + y_axis.append(point.value) + x_axis.append(point.time.value) plot_div = plot([Scatter(x=x_axis , y=y_axis, mode='lines', name='humidity', @@ -38,8 +38,8 @@ def pressure(): x_axis = [] y_axis = [] for point in data: - x_axis.append(point.value) - y_axis.append(point.time.value) + y_axis.append(point.value) + x_axis.append(point.time.value) plot_div = plot([Scatter(x=x_axis , y=y_axis, mode='lines', name='pressure',