(Originated from this question.)
I unsuccesfully tried to make use of this example.
My attempt was to copy and slighly edit the code at the link. The result is