Skip to content

Commit

Permalink
Merge pull request #1314 from pyiron/samwaseda-patch-1
Browse files Browse the repository at this point in the history
[minor] Make height available in plot3d
  • Loading branch information
samwaseda authored Feb 14, 2024
2 parents 42d4863 + 43ad257 commit 1667c11
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 1 deletion.
2 changes: 1 addition & 1 deletion .ci_support/environment-old.yml
Original file line number Diff line number Diff line change
Expand Up @@ -20,4 +20,4 @@ dependencies:
- scipy =1.11.1
- seekpath =1.9.5
- spglib =2.0.2
- structuretoolkit =0.0.15
- structuretoolkit =0.0.19
4 changes: 4 additions & 0 deletions pyiron_atomistics/atomistics/structure/atoms.py
Original file line number Diff line number Diff line change
Expand Up @@ -1210,6 +1210,7 @@ def plot3d(
view_plane=np.array([0, 0, 1]),
distance_from_camera=1.0,
opacity=1.0,
height=None,
):
"""
Plot3d relies on NGLView or plotly to visualize atomic structures. Here, we construct a string in the "protein database"
Expand Down Expand Up @@ -1251,6 +1252,8 @@ def plot3d(
call. (Default is np.array([0, 0, 1]), which is view normal to the x-y plane.)
distance_from_camera (float): Distance of the camera from the structure. Higher = farther away.
(Default is 14, which also seems to be the NGLView default value.)
height (int/float/None): height of the plot area in pixel (only
available in plotly) Default: 600
Possible NGLView color schemes:
" ", "picking", "random", "uniform", "atomindex", "residueindex",
Expand Down Expand Up @@ -1286,6 +1289,7 @@ def plot3d(
view_plane=view_plane,
distance_from_camera=distance_from_camera,
opacity=opacity,
height=height,
)

def pos_xyz(self):
Expand Down

0 comments on commit 1667c11

Please sign in to comment.