cardiff: Moving plotting code in separate function
cardiff: Moving plotting code in separate function

To make the code easier to read, let's make a function about the
plotting stuff.

lebauce/edeploy,enovance/edeploy,lebauce/edeploy,redhat-cip/edeploy,lebauce/edeploy,redhat-cip/edeploy,lebauce/edeploy,redhat-cip/edeploy,enovance/edeploy,enovance/edeploy,enovance/edeploy,redhat-cip/edeploy