Skip to content

Commit 38fbbfc

Browse files
Adding docstring to grid.negate_depth()
1 parent ce11d4c commit 38fbbfc

File tree

1 file changed

+4
-0
lines changed

1 file changed

+4
-0
lines changed

parcels/grid.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -115,6 +115,10 @@ def depth(self):
115115
return self._depth
116116

117117
def negate_depth(self) -> None:
118+
"""Method to flip the sign of the depth dimension of a Grid.
119+
Note that this method does _not_ change the direction of the vertical velocity;
120+
for that users need to add a fieldset.W.set_scaling_factor(-1.0)
121+
"""
118122
self._depth = -self._depth
119123

120124
@property

0 commit comments

Comments
 (0)