The S&P 500 and the Dow Industrials rose on Friday, boosted by strong industrial output numbers, though all three of Wall Street’s major indexes posted losses for the week. The Nasdaq was barely changed at Friday’s market close.

February’s industrial production jumped 1.1 percent, the largest increase in four months.

The energy sector led the major sectors of the S&P 500 with a 1.0 percent gain, as oil prices rose 1.7 percent.

Friday’s gains came at the end of a rocky week dominated by concerns of a trade war with China and political turmoil, which began with the ouster of Secretary of State Rex Tillerson.

Keep in mind that the Federal Reserve is expected to raise the benchmark interest rates. Rate-sensitive sectors, such as utilities and real estate, rose on Friday, but they could perform poorly if rates increase sharply.

For the week, the Dow was down 1.57 percent, the S&P lost 1.04 percent, and the Nasdaq declined by 1.27 percent.

Walmart gained 1.9 percent after the University of Michigan’s preliminary reading of its consumer sentiment index rose more than expected to 102.0.

Adobe was up 3.1 percent, reaching an all-time high during the session, after the company exceeded analysts’ profit and revenue estimates for the seventh straight quarter.

Micron rose 3.0 percent after Baird analysts raised their price target on the stock by $40 to $100. Western Digital gained 4.1 percent, hitting a three-year high during the session, after Baird upgraded the stock’s rating to “outperform.”

Approximately 9.54 billion shares changed hands on the major domestic equity exchanges, as compared to the 7.2 billion share average over the past 20 trading days.

Housing Mixed

Homebuilding fell more than expected in February as a plunge in the construction of multi-family housing units offset a second straight monthly increase in single-family projects.

According to a report by the Commerce Department on Friday, housing starts declined 7.0 percent to a seasonally adjusted annual rate of 1.236 million units. Data for January was revised up slightly to show groundbreaking increasing to a 1.329 million-unit pace instead of the previously reported 1.326 million units. Permits for future home building decreased 5.7 percent to a rate of 1.298 million units in February.

While the volatile multi-family housing segment accounted for the decline in home building last month, the broader housing market appears to be slowing.

Sales of both new and previously owned homes have slumped in recent months as a dearth of properties on the market pushed up prices, sidelining some first-time home buyers. House price gains topped 6.0 percent in December.

Mortgage rates have also risen, with the 30-year fixed-rate currently averaging 4.44 percent, not too far from a four-year high of 4.46 percent, according to mortgage finance agency Freddie Mac. But the housing market remains underpinned by a robust labor market.

There is growing optimism that tightening job market conditions will translate into faster wage growth in the second half of this year. Annual wage growth has been stuck below 3.0 percent even as the unemployment rate has dropped to a 17-year low of 4.1 percent.

Single-family homebuilding, which accounts for the largest share of the housing market, increased 2.9 percent to a rate of 902,000 units in February. Single-family home construction rose in the Northeast, South and West, but tumbled in the Midwest.

Permits to build single-family homes slipped 0.6 percent in February to a 872,000 unit-pace. With permits lagging starts, single-family home construction could slow in the months ahead.

A survey on Thursday showed confidence among homebuilders dipping in March but remaining in strong territory. Builders were less upbeat about sales and buyer traffic over the next six months.

Starts for the volatile multi-family housing segment fell 26.1 percent to a rate of 334,000 units in February, the lowest level since September 2017. Permits for the construction of multi-family homes dropped 14.8 percent to a 426,000 unit-pace.

Housing completions increased 7.8 percent to a rate of 1.319 million units in February. That was the highest level since January 2008. The number of single-family houses completed last month was the highest since March 2008.

There were 501,000 single-family housing units under construction in February, the most since June 2008. This should help to alleviate some of the property shortage and probably slow the house price inflation.

Industrial Production Up

industrial production rose sharply during in February, aided by strong increases in output at factories and mines. The broad-based rise in production likely reflected increased investment spending in the wake of hefty corporate income tax cuts, which came into effect in January. However, tariffs on steel and aluminum imports imposed by President Donald Trump last week could weigh on output.

According to a report by the Federal Reserve on Friday, industrial production was up 1.1 percent last month. That was the largest increase in four months and followed a 0.3 percent decline in January.

Manufacturing output chalked up a gain of 1.2 percent, making it the largest gain since October, after falling 0.2 percent in January. Production of primary metals, which include steel and aluminum increased 0.5 percent last month after jumping 1.5 percent in January.

Output of fabricated metal products, which use steel and aluminum, climbed 1.6 percent in February after rising 0.4 percent in the prior month.

Production at mines was up 4.3 percent last month, due to an 11.6 percent increase in oil and gas well drilling. The gains in manufacturing and mining production offset a weather-driven 4.7 percent decline in the output of utilities.

Industrial capacity utilization, a measure of how fully firms are using their resources, increased 0.7 percentage point to 78.1 percent, its highest reading since January 2015. It remains 1.7 percentage points below its long-run average.

Officials at the Fed tend to look at utilization measures as a signal of how much slack remains in the economy — how far growth has room to run before it becomes inflationary. Capacity use at factories rose to its highest level since April 2008.

Steadily rising price pressures and a tightening labor market are giving the Fed all the more reason to raise interest rates next Wednesday.