Moved plot command to a new class