How do you calculate the power factor of a power supply?
Power factor is defined as the ratio of real power to "apparent" power, where real power is the average of the result of multiplying the instantaneous voltage by the instantaneous current, and "apparent" power is the result of multiplying the RMS voltage by the RMS current.

With a purely resistive load, these two methods yield the same number, so the power factor is unity. With reactive loads, such as lightly-loaded motors, the current is out of phase with the voltage, causing the real power to drop relative to the apparent power and the ratio to be less than unity.

With nonlinear loads, such as power supplies, the current waveform is distorted, giving it a higher RMS value than that of a sinewave. This also causes the ratio to be reduced from unity.

So, to answer your question, one way to estimate the power factor of a power supply is to use a "true RMS" meter to measure its input current, and compare that result with the value that you get with a resistive load drawing the same amount of real power.