NEW YORK (AP) -- The stock market is getting its momentum back.
All major stocks indexes rose Tuesday, and the biggest gains were in riskier small-company stocks and sectors that do best when the economy is growing.
Major indexes rose for a fourth straight day. The Standard & Poor's 500 index had its best run in two months.
Traders have grown more confident after Friday's strong jobs reports and on expectations of record corporate earnings for the second quarter, which ended June 30. So far, the stock market is up nearly 3 percent in July following a 1.5 percent dip in June, its first monthly decline since October.
The Russell 2000, an index of small-company stocks, rose nearly 1 percent Tuesday. The Dow Jones transportation average, seen as a leading indicator for the broader economy, led all indexes with a 2.3 percent rise, its best performance in a month.
The gains suggest that investors are more certain that the economy's prospects are good. In the first half of the year, stock markets were powered by companies that pay large dividends and are considered a sure way to make money even when the economic outlook is iffy.
The Russell 2000 rose eight points, or 0.9 percent, to 1,018.05. It has gained 4.2 percent in July and is moving deeper into record territory. The index has risen 20 percent, this year, more than its large-company counterparts, the Dow Jones industrial average and the S&P 500 index.
Investors "are starting to go to the more aggressive areas that usually do better in an expansionary economy," said Ryan Detrick, a senior technical strategist at Schaeffer's Investment Research.
The Dow Jones transportation was led by strong gains for Alaska Air Group and FedEx.
The index jumped 148 points to 6,446. Alaska Air Group rose 7 percent after it forecast an additional $50 million a year in revenue from increased fees. FedEx rose 6 percent on speculation that William Ackman's hedge fund, Pershing Square, could invest in the company.
Wall Street is also turning its attention to corporate earnings. Results for the second quarter, which ended nine days ago, should give traders and investors insights into the economy. Market watchers spent most of June trying to figure out where the Federal Reserve was headed with its economic stimulus program.
Along with the quarterly results, investors want to see how confident companies are about the rest of the year, said Cam Albright, director of asset allocation for Wilmington Trust Investment Advisors.
Major U.S. stock indexes have notched a series of all-time highs this year on expectations that earnings will remain at record levels.
"A lot of what the market has justified its advances on is a strong second half for the economy and a strong second half for earnings," said Albright. "It's important that we see verification of that."
Alcoa was the first major company to announce second-quarter results. The aluminum maker late Monday reported a loss that wasn't as big as financial analysts feared. The company benefited from strong demand for aluminum used in autos and airplanes, although that was offset by weaker prices.
Traders weren't impressed by the results, though. After rising initially, the stock ended down 1 cent, or 0.1 percent, to $7.91.
Yum Brands, which owns KFC, Pizza Hut and Taco Bell, and Family Dollar Stores are among the companies reporting their earnings this week. JPMorgan Chase and Wells Fargo will also report.
The Dow Jones industrial average rose 75 points, or 0.5 percent, to 15,300.34. The S&P 500 index gained 11 points, or 0.7 percent, to 1,652.32 The Nasdaq composite rose 19 points, or 0.6 percent, to 3,504.26
The S&P 500 gains were led by industrial firms and companies that provide raw materials. Telecommunications companies, which investors turn to when the economic outlook is gloomier, fell.
The S&P 500 is now just 1 percent below its May 21 record of 1,669. It was down almost 6 percent to 1,573 on June 24.
Stocks have recovered since Fed Chairman Ben Bernanke said that the central bank planned to reduce its economic stimulus.
The central bank is buying $85 billion in bonds a month to keep interest rates low and encourage borrowing and spending. That stimulus has been a major support in the stock markets' four-year bull market.
In government bond trading, the yield on the 10-year Treasury note was unchanged from Monday at 2.64 percent.
The yield has pulled back after surging to 2.74 percent Friday, its highest level in almost two years, after the government reported strong hiring for June.
In commodities trading, the price of oil rose 17 cents, or 0.2 percent to $103.33 a barrel. Gold rose $12, or 1 percent, to $1,246.90 an ounce.
Among other stocks making big moves:
— Barnes and Noble rose 64 cents, or 3.6 percent, to $18.32 after the bookseller said Monday that its CEO is leaving after three years. The company didn't name a replacement.