NEW YORK — U.S. stocks took small losses Wednesday as energy companies fell with the price of oil and chemical and materials companies traded lower. That pulled the market lower for August, ending a five-month winning streak. The losses were small, and this proved to be one of the quietest months in recent history for stocks.

On Wednesday:

The Dow Jones industrial average lost 53.42 points, or 0.3 percent, to 18,400.88.

The Standard & Poor’s 500 index slid 5.17 points, or 0.2 percent, to 2,170.95.

The Nasdaq composite declined 9.77 points, or 0.2 percent, to 5,213.22.

For the week:

The Dow is up 5.48 points, or less than 0.1 percent.

The S&P 500 is up 1.91 points, or 0.1 percent.

The Nasdaq is down 5.70 points, or 0.1 percent.

For the year:

The Dow is up 975.85 points, or 5.6 percent.

The S&P 500 is up 127.01 points, or 6.2 percent.

The Nasdaq is up 205.81 points, or 4.1 percent.