It's that last part that has me thinking ... the automated trades are a huge (the primary?) component of the total trading volume market. The purpose of the codes described here is to make money off of small, short-term fluctuations in stock prices.
There's no explicit connection with the underlying value of the stocks being traded -- this is just a way of making money, or losing less of it, in response to momentary fluctuations.
The resultant disconnect between profits on the one hand, and sound investments on the other, is the sort of thing that creates "bubbles."