Some fixes to plotting.