Restructured experimentCanvas.js for easier access during event processing.