Skip to content

Commit

Permalink
Fix doctest
Browse files Browse the repository at this point in the history
  • Loading branch information
rhugonnet committed Oct 13, 2022
1 parent ebb36c9 commit 9d13d18
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion xdem/terrain.py
Original file line number Diff line number Diff line change
Expand Up @@ -1144,7 +1144,7 @@ def slope(
[2, 2, 2]])
>>> slope(dem, resolution=1, degrees=True)[1, 1] # Slope in degrees
45.0
>>> np.tan(slope(dem, resolution=2, degrees=True)[1, 1] * np.pi / 180.) # Slope in percentage
>>> np.round(np.tan(slope(dem, resolution=2, degrees=True)[1, 1] * np.pi / 180.), 1) # Slope in percentage
0.5
:returns: A slope map of the same shape as 'dem' in degrees or radians.
Expand Down

0 comments on commit 9d13d18

Please sign in to comment.