1 2 3 4 5 6 7 8 9 10 11 12 13 14 15
import os import subprocess def plot(start, end, states=1, script="anim3d.plt"): path = 'gnuplot/' if os.name == 'nt': path = path.replace('/','\\') subprocess.run(["gnuplot", "-e", f"states={states};", "-e", f"start={start};" , "-e", f"end={end};", "-c", path + script])