How create a draw point function

How create a draw point function like that in picture under the post.

Duplicated: