All too often, I see investors heading in the wrong direction en masse. They buy stocks at the top of the market or bonds when interest rates are heading up. Occasionally, though, active investors may be heading in the right direction. A case in point has been the flow of money into certain exchange-traded funds in the first half of this year. Reflecting most hot money trends, billions of dollars moved because of headlines. The Energy Select SPDR ENERGY SELECT SECTOR SPDR ETF XLE -0.55% exchange-traded fund, which I discussed three weeks ago, gathered more than $3 billion in assets in the first half, when crude oil prices climbed and demand for hydrocarbons remained high. The Energy SPDR, which charges 0.16% for annual management expenses and holds Exxon Mobil EXXON MOBIL CORPORATION XOM -0.66% , Chevron CHEVRON CORP. CVX -0.32% , and Schlumberger SCHLUMBERGER LIMITED SLB -0.59% , has climbed 22% in the past 12 months, with nearly one-third of that gain coming in the three months through July 18. Long-term, this may be a solid holding as developing countries such as China and India demand more oil. “We think the Energy Select SPDR is a play of oil prices remaining high and supporting growth for integrated oil & gas and exploration and production companies,” analysts from S&P Capital IQ said in a recent MarketScope Advisor newsletter. Headlines also favored European stocks as represented by the Vanguard FTSE Developed Markets ETF VANGUARD TAX MANAG FTSE DEVELOPED MKTS ETF VEA -0.34% , which holds leading eurozone stocks such as Nestle, Novartis NOVARTIS AG NVS 0.61% , and Roche. The fund has been the top asset gatherer thus far this year, with $4 billion in new money, according to S&P Capital IQ. As Europe continues to recover over the next few years and the European Central Bank keeps rates low, global investors will continue to benefit from this growing optimism. The Vanguard fund has gained nearly 16% for the 12 months through July 18. It charges 0.09% in annual expenses and is a solid holding if you have little or no European exposure in your stock portfolio. Rate Hikes Not all hot money trends make sense, however. As the economy accelerates and interest-rate hikes look increasingly likely, investors are still piling money into bond funds, which lose money under those circumstances. The iShares 7-10 Year Treasury Bond ETF ISHARES TRUST 7-10 YEAR TREASURY BD ETF IEF 0.27% , which holds middle-maturity U.S. Treasury bonds, continued to rank in the top 10 funds in terms of new money in the first half. The fund, which holds nearly $5 billion, is up nearly 4% for the 12 months through July 18, compared with 4.2% for the Barclays U.S. Aggregate Total return index, a benchmark for U.S. Treasuries. The fund charges 0.15% in annual expenses. While investors were able to squeeze a bit more out of bond returns in the first half of this year, they may be living on borrowed time. The U.S. Federal Reserve confirmed recently that it would be ending purchases of U.S. Treasury bonds and mortgage-backed securities in October. This stimulus program, known as “QE2,” has kept interest rates artificially low as the economy has had a chance to recover. The phasing out of QE2 could be bearish for bond funds. Will interest rates climb to reflect growing demand for credit and possibly higher inflation down the road? How will the ending of the Fed’s cheap money program affect U.S. and emerging markets shares? Many pundits believe public corporations may pull back from their enthusiastic stock buybacks and trigger a correction. Yet low inflation and modest employment gains may mute bond market fears. “The Fed is on track to complete tapering in the fourth quarter, and we think there is essentially no chance that it will move the fed funds rate higher this year,” Bob Doll, chief equity strategist with Nuveen Investments in Chicago, said in a recent newsletter. “With the 10-year Treasury ending the quarter at 2.5%, the yield portion of this forecast is more uncertain,” Doll added, “although we expect yields will end the year higher than where they began.” While there could be any number of wild cards spoiling the party for stocks, it is wise to ignore short-term trends and prepare for the eventual climb in interest rates. That means staying away from bond funds with long average maturities along with vehicles like preferred stocks and high-yield bonds that are highly sensitive to interest rates. Longer-term, shares of companies in consumer discretionary, materials and information technology businesses likely to benefit from a global economic resurgence will probably be a good bet. Just keep in mind that the hot money can be wrong, so build a long-haul diversified portfolio that protects against the downside of a torrid trend going from hot to cold.