Hi there, i've seen this several times on different iMac's (all 27 inch models).
It seems it only happens on the models with a v-sync flatcable. The later models with a "normal" connector and separate wires seems not to be affected.
At the moment i have an iMac with the same vertical lines with the additional problem that the whole screen goes black after a few days. When i pust the power button 2 times (standby and out of standby) the screen appears again. The external monitor is not affected and keeps playing when the internal scheen goes black.
Already did a reflow of the GPU and changed the inverter board but no difference.