r1641 Graph ploter function