modify diagram