As is usual in my experience, most rules questions are easily answered if you just actually read the rules...
Start Quote:
7-2. During Round
A player must not make a practice stroke during play of a hole.
Between the play of two holes a player must not make a practice stroke, except that he may practice putting or chipping on or near:
a. the putting green of the hole last played,
b. any practice putting green, or
c. the teeing ground of the next hole to be played in the round,
provided a practice stroke is not made from a hazard and does not unduly delay play (Rule 6-7).
End of Quote
so if your ball is on the green, you cannot practice anywhere...period...you are in the middle of playing a hole...
After you've putted out and are between holes, you may practice {without undue delay} provided you are not practicing from a hazard...