handles large data and ability to set x and y max axis