Added automatic resizing facility in plotting class.