code: def parse_degrees(cls, degrees, arcminutes, arcseconds, direction=None):
          
          degrees = float(degrees)
          negative = degrees < 0
          arcminutes = float(arcminutes)
          arcseconds = float(arcseconds)
  
          if arcminutes or arcseconds:
              more = units.degrees(arcminutes=arcminutes, arcseconds=arcseconds)
              if negative:
                  degrees -= more
              else:
                  degrees += more
  
          if direction in [None, 'N', 'E']:
              return degrees
          elif direction in ['S', 'W']:
              return -degrees
          else:
              raise ValueError("Invalid direction! Should be one of [NSEW].")
docs: Parse degrees minutes seconds including direction (N, S, E, W)