Stocks shot 3 percent higher on Tuesday on speculation Federal Reserve Chairman Ben Bernanke this week would signal new help for the economy, giving investors hope a four-week rout was nearing an end.

Weak data in housing and regional factory activity triggered the latest round of bets that Bernanke will act, even though the Fed's options appear limited. Bernanke speaks to a central bank conference on Friday in Jackson Hole, Wyoming.

I don't think anybody wants to be too short or negative in front of Bernanke's speech, said Jim Awad, managing director at Zephyr Management in New York.

The Dow Jones industrial average was up 322.11 points, or 2.97 percent, at 11,176.76. The Standard & Poor's 500 Index was up 38.53 points, or 3.43 percent, at 1,162.35. The Nasdaq Composite Index was up 100.68 points, or 4.29 percent, at 2,446.06.

Technology and other growth stocks drove much of the gains, with the Nasdaq rising more than 4 percent. The sharp rise echoed the wild swings the market experienced two weeks ago after Standard & Poor's downgraded United States' long-term credit.

Volume was a solid 9.35 billion shares traded on the New York Stock Exchange, the American Stock Exchange and Nasdaq. The daily average for last year was about 8.47 billion.

Even financials, which had been knocked lower earlier by shares of Bank of America, ended positive, with the S&P Financials Index up 3.2 percent.

Bank of America Corp remained under pressure on fears of possible write-offs and the need for capital. Its stock fell 1.9 percent to $6.30 but well off the day's lows.

More than 561 million shares traded in Bank of America, accounting for nearly 6 percent of overall composite volume for the exchanges.

The market has been battered by concerns of another U.S. recession and the worsening euro zone debt crisis.

This is how the start of a rally in an oversold market usually looks like: an aggressive short-term gain like today, said Jack De Gan, chief investment officer at Harbor Advisory Corp in Portsmouth, New Hampshire, suggesting the market may have hit the bottom.

The rally briefly stalled in the afternoon on news of a magnitude of 5.9 earthquake, which struck in Virginia and forced some building evacuations along the U.S. East Coast and Canada, but no major damage or injuries were reported.

Big percentage gainers on the S&P included technology shares Nvidia Corp and JDS Uniphase Corp, both rising about 10 percent.

Among financial stocks, American Express Co and JPMorgan Chase & Co were the top gainers on the Dow. American Express shares rose 4.1 percent to $46.42, while JPMorgan shares advanced 4.1 percent to $34.78.

On the NYSE, advancers beat decliners by a ratio of about six to one, while on the Nasdaq, about five stocks rose for every one that fell.

(Reporting by Angela Moon, Editing by Kenneth Barry)