Renamed script to make editors recognise it as a R-file.
Introduce variables that define size of output device.

Improve program general readability.