modified for angles in deg or rad format