You are on page 1of 1

Parser :

Pyton

Expression :
GetAzimuthPolyline( !Shape!)

Code Block :
import math
def GetAzimuthPolyline(shape):
radian = math.atan((shape.lastpoint.x - shape.firstpoint.x)/(shape.lastpoint.y -
shape.firstpoint.y))
degrees = radian * 180 / math.pi
return degrees

You might also like