Was able to scrounge up a solution on my own and thought Iโd post it here in case anyone else runs into this challenge in the future. Plotly (both R and Python) does give you the capability to set the initial view for a 3D plot, itโs just not mentioned in the tutorials so you have to dig pretty extensively. Turns out that you can set the view via the layout.scene.camera() property (interface?) of a figure. My solution ended up looking something like this:
import plotly.graph_objs as go
mySurf = go.Figure
mySurf.add_trace(go.Surface(
colorbar=go.surface.ColorBar(title='myZ'),
colorscale='matter',
name='My 3D surface',
x=myX,y=myY,z=myZ,opacity=0.9))
view = dict(camera=dict(
# Set the location that appears at the center of the view
center=dict(x=0,y=-0.1,z=-0.1),
#default is (0,0,0)
# Set the place from which the camera "eye" views the plot
eye=dict(x=1,y=2,z=0.75
#default is (1.25,1.25,1.25)
))
mySurf.update_layout(scene=view)
mySurf.show()
Note that the coordinates used in center() and eye() are not the numbers used in your actual data. Theyโre relative to the plot itself. Thus, setting center(x=1,y=0,z=0.25) would produce the same centering regardless of your plotโs scale (I think).
Refs: