complex(real = x, imaginary = 0) ^ y
[1] 0.05850958-0.0425097i
As suggested by @9769953
0
Ben Bolker
On
@Clemsang's answer with complex(...) is fine, but you can also do this more compactly via (X+0i)^Y; because R's parser recognizes <number>i as an imaginary value, adding 0i to a numeric quantity makes it complex-valued with Im(.) == 0.
You can do:
As suggested by @9769953