removed whitespaces internally and added code to support multiple variables functions (even though the plot is still only in 2D