modified plots.js for testing purposes