added plotting capabilites