Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Docstrings for RotXYZ and similar could cause confusion with keyword arguments #294

Open
kramsretlow opened this issue Mar 28, 2024 · 0 comments

Comments

@kramsretlow
Copy link

Taking RotXYZ(roll=r, pitch=p, yaw=y) as an example, the docstring says

The keyword argument form applies roll, pitch and yaw to the X, Y and Z axes respectively, in XYZ order.

I began somewhat uninitiated on Euler angles, so it took me quite some time to realize that XYZ order refers the the order of matrix multiplication (RxRyRz), rather than the sequence of actually carrying out the rotations. I thought it meant first rotate around the X axis by r, then around Y by p, then around Z by y.

The first sentence in the same doscstring is super clear, indicating the sequence of rotations and which argument is used for each, so maybe this pattern could be used for the keyword arguments case too. Also perhaps it could be made clear that the keyword arguments essentially relate to argument order, e.g. RotZXY(a, b, c) == RotZXY(roll=b, pitch=c, yaw=a). Or maybe just use X, Y, Z as keyword arguments?

Thanks for your work on the package!

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant