reworked plotData creation