stuff to get plot working