Different from a frequency response graph, an impedance graph indicates load on the amplifier vs frequency. Software produces a sine sweep (or pink noise). This signal is taken from the PC output and amplified. Current (voltage across a known resistance) and voltage of the output is measured, and fed back into the PC. Software then calculates Impedance and compares it to the source signal.
Here is a comparison of a speaker before (gray) and after repairing a fault in the crossover (black). Note the significant difference in impedance at 4kHz.
LIMP by Artalabs is the software used in this project.
It has great calibration tools, and a thorough tutorial.
My example has an amplifier built in (based on TDA7294 monolithic chip).
3.5mm TRS connectors were used for simple interface with PC.
Output of the amplifier passes through a 1R 10W sense resistor.
Sense outputs are voltage dividers, and PC mic level inputs are buffered.