From 144a6aa7633acefb71854adbfb61cc62d76e56fe Mon Sep 17 00:00:00 2001 From: l_samenv Date: Wed, 28 Aug 2024 09:12:18 +0200 Subject: [PATCH] Fixed binning in seconds (export) --- influxdb.py | 2 +- influxgraph.py | 2 +- 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/influxdb.py b/influxdb.py index 8ae5d51..f775cfc 100644 --- a/influxdb.py +++ b/influxdb.py @@ -155,7 +155,7 @@ class InfluxDataGetter: Parameters : variables ([(str)]) : an array of variable names (Influx) to get the curves for. times ([int]) : the timerange we want the values in. It consists of two values which are Unix timestamps in seconds, first included, second excluded. - interval (int) : the interval (resolution) of the values to get (in nanoseconds). Allows data binning. + interval (int) : the interval (resolution) of the values to get (in seconds). Allows data binning. Returns : pandas.DataFrame : the curves in a single pandas DataFrame diff --git a/influxgraph.py b/influxgraph.py index 8ac23db..3e954df 100644 --- a/influxgraph.py +++ b/influxgraph.py @@ -183,7 +183,7 @@ class InfluxGraph: start, end = int(start), int(end) queried_variables = variables.split(',') - if interval != "None" : interval = self.milliseconds_to_nano(int(interval)) + if interval != "None" : interval = int(interval) df = self.influx_data_getter.get_curves_data_frame(queried_variables, [start, end], interval)