Plot Window Control#
- squap.make_3D(row=0, col=0)[source]#
Removes the current plot widget at row
rowand columncoland adds a 3D plot widget. When you aren’t making use of subplots, the defaults replace the main widget.- Parameters:
- Returns:
The created 3D plot widget.
- Return type:
- squap.set_camera(
- x_offset=None,
- y_offset=None,
- z_offset=None,
- distance=None,
- azimuth=None,
- elevation=None,
- fov=None,
Sets the camera offset, distance, rotation and fov using the given arguments.
distance,azimuthandelevationact like polar coordinates around the origin, andx_offset,y_offsetandz_offsetdetermine the position of this origin. Usesquap.align_camera()to experiment with these values and find the correct ones.- Parameters:
x_offset (float, optional) – New x offset of the origin.
y_offset (float, optional) – New y offset of the origin.
z_offset (float, optional) – New z offset of the origin.
distance (float, optional) – New distance between the camera position and the origin.
azimuth (float, optional) – Angle of rotation horizontally around the origin.
elevation (float, optional) – Angle of rotation vertically about the origin.
fov (float, optional) – Field of view.
- squap.align_camera(ax=None, tab=None)[source]#
Adjusts camera position of a 3D plot. Use this to find the correct parameters to set the desired initial camera position with
squap.set_camera().- Parameters:
ax (SubplotWidget3D, optional) – Specifies the plot which the control boxes control. Defaults to the main plot.
tab (InputTable or str, optional) – The tab to which to add the control boxes, or a string that represents the name of the newly created tab which the control boxes will be added to. Defaults to the main input table.