Quaternion rotation Maxscript


Does anyone know the math or the method to conver Daz Quaternion rotation to 3ds Max and vice versa ?

The axis swap is doing my head in.

12 months ago I could have worked it out, but I don’t want to have to learn all 3d rotational algebra again.

Just for reference: daz Studio axis +Y up, +X to the right, +Z towards the viewer
3ds Max +Z is up +X to the right, +Y is away from the viewer

my intuition tells me to rotate the normalized quaternion in max by euler -90°

but I tried that and it was clearly wrong.