Modify for loop into map in ScatterPlotItem.py