updated DrawGraph