use show hide to change diagram