I am not entirely familiar with the .psd format. However, a rule of thumb is that if you can open an image file in a text editor, see readable code, and modifying the code affects the image, then the image is definitely written in code.
It just depends on the way the file is actually is in practice.
For xslx you basically get a XML file with a single tag, which then contains the whole content as a binary blob, stored in an attribute.
Just like you can make an svt that is essentially a single path tag with hundreds of numbers in a single attribute
And for the record, you can also do a single html tag with a gigantic inline blob binary. Calling that source code is just at best technically correct, because it practically isn't