How to change the Red View to coronal via code?

I want to change the red view to the coronal orientation. Is there a way to do this in the code?

Here’s an example in the script repository that details getting the slice nodes and then being able to add/remove or set the orientation as you are specifically asking about.
https://www.slicer.org/wiki/Documentation/Nightly/ScriptRepository#Change_default_slice_view_orientation