view and plot functions should be in another file the gui/ sub-dir.