From 55b3c4bb5b8ad9ef23eec125048ff8e4fea4f7fe Mon Sep 17 00:00:00 2001 From: KunoiSayami Date: Thu, 9 Jun 2022 02:42:07 +0800 Subject: feat: Support multiple target and show image script Signed-off-by: KunoiSayami --- image.py | 16 ++++++++++++++++ 1 file changed, 16 insertions(+) create mode 100755 image.py (limited to 'image.py') diff --git a/image.py b/image.py new file mode 100755 index 0000000..199ba9f --- /dev/null +++ b/image.py @@ -0,0 +1,16 @@ +#!/usr/bin/env python3 +import matplotlib.pyplot as plt + +x = [] +y = [] + +with open('test') as fin: + for line in fin.read().splitlines(): + x_, y_ = list(map(int, line.strip().split(','))) + x.append(x_) + y.append(y_) + +plt.plot(x, y) +plt.xlabel('x') +plt.ylabel('y') +plt.show() -- cgit v1.3.1