Recently I have done an experiment in matlab where I have tried to calculate DFT of a sine wave with different phase shifting. I have figured out that it fails to detect 90 degree and 270 degree phase shift sine waves which should not be happen. Those missing information can be detected in imaginary part of DFT but I want to know how this problem is solved usually. In matlab we can only plot() or stem() real part of fft() outcome. Let me know if I am missing something in DFT basics.
I have attached the matlab code so that you can check the issue.