Turn off and turn on monitor that is connected to display port using command

In ubuntu to turn off and on monitor using command:

xrandr --output DP1 --off

To turn it on again, left of HDMI monitor you can use:

xrandr --output DP1 --left-of HDMI1 --auto

To list monitors, to see their names ie HDM1, DP1 etc:

 xrandr -q