add drawGraph to local controller