added efficient plotter version - optimized