            newDataset.data.push({
                    x: randomScalingFactor(),
                    y: randomScalingFactor(),
                    r: Math.abs(randomScalingFactor()) / 5,
                });
            }

            bubbleChartData.datasets.push(newDataset);
            window.myChart.update();
        });

        document.getElementById('addData').addEventListener('click', function() {
            if (bubbleChartData.datasets.length > 0) {
                for (var index = 0; index < bubb