improve plotting API and documentation