How to get the data (pointwise frequency, amplitude and phase) in a FFT performed on ImageJ?
Here is a very practical illustration. The credit goes to @Herbie and @emartini.



NOTE: The complex window has a slide bar at the bottom, which has to be drawn to the left. Also, it is necessary to click twice on the FFT window without moving the cursor to get the three output values.



The output is concordant with Matlab with adjustments nicely described by @SleuthEye here and here.

Here is an example:



with ImageJ:

Frequency = 10.24 pixels/cycle (25 cycles)
Theta (direction) = 16.26 degrees
Real part = -1.255
Imaginary part = 10.142
Phase = arctan(10.142 / -1.255) = -82.95 degrees
Magnitude = sqrt(10.142^2 + 1.255^2) = 10.2194


and with Matlab:

Im = imread('circ.png');
pkg load image
Im = rgb2gray(Im);

A = fft2(double(Im) / 255);
Ashifted = fftshift(A);
Ashifted(121,153)

i = 121;
j = 153;

center = size(A) / 2 + 1;
dx = (j - center(2)) / size(A,2);
dy = (center(1) - i - 1) / size(A,1);

direction = (atan2(dy, dx))
dir_degrees = direction * (360 / (2*pi)) 
frequency = 1 /sqrt(dx*dx + dy*dy)


The output:

ans =  -1.2553 + 10.1425i
direction =  0.28379
dir_degrees =  16.260
frequency =  10.240