Pomodoro + Workrave = Well-being

I’ve been a big fan of the Pomodoro Technique for almost a year now. No, I don’t go as far as actually having a ticking timer in my office in front of my co-workers, and I don’t necessarily plan the day in advance, but I do try to break up my work in 25-min iterations punctuated by 5-min breaks.

I used to use Ubuntu’s Timer applet to alert me to take a break, but a month ago I found what I now believe to be the perfect complement to the Pomodoro Technique: a nice little application called Workrave.

Workrave will let you define work intervals after which it will, shall we say, strongly encourage you to take a break and propose a couple of physical exercises. I’ve installed Workrave under Ubuntu (I believe it runs also on Windows) and configured it for:

* no micro-breaks
* a 5-min rest break after 25 min of work
* a daily limit of 8 hours (never reached)

Try it out! It’s completely free and quite nice. I can also recommend the Pomodoro Technique Illustrated book from the Pragmatic Programmers, but you might also want to begin with the free “official” Pomodoro book.

Converting Sweave/R plots for inclusion in Word/OpenOffice

Just a quick note to myself:

When you use Sweave and produce high-quality plots in both EPS and PDF formats, you sometimes want to include them in Word or OpenOffice documents.

You can’t directly include PDF files, and you can only include EPS files when they have a preview, which Sweave will not do by default. And anyway, the EPS version of the graphs are made for black and white printers and will not be in color.

I’m using `convert` from the ImageMagick package to convert the PDF plots to PNG files. However, by default `convert` will give low-quality pictures. To have better images, I do:

convert -density 300 XXX.pdf XXX.png

If you feel geeky enough you can even include this in a Makefile:

figures: $(patsubst %.pdf, %.png, $(wildcard report-*.pdf))

report-%.png : report-%.pdf
convert -density 300 $< $@