test_metric_aggregator.py 451 B

12345678910111213141516171819202122
  1. #!/usr/bin/env python3
  2. # -*- coding: utf-8 -*-
  3. from draugr.metrics import MetricAggregator
  4. __author__ = "Christian Heider Nielsen"
  5. __doc__ = r"""
  6. """
  7. def test_a():
  8. signals = MetricAggregator(keep_measure_history=False)
  9. for i in range(10):
  10. signals.append(i)
  11. print(signals)
  12. print(signals.measures)
  13. print(signals.variance)
  14. print(signals.calc_moving_average())
  15. print(signals.max)
  16. print(signals.min)