Global economic optimism spurs strong rally; Dow jumps 204 Updated at 4:05 p.m. ET: Stocks rallied strongly Friday as data in China allayed concerns about a further slowing of global growth and banks advanced after JPMorgan released earnings. The Dow Jones industrial average closed the day up 204 points, while the tech-rich Nasdaq composite added 42 points. The day's rally erased the broader market's losses for the week. Shares of JPMorgan Chase, the largest U.S. bank, rallied after it reported a quarterly profit of nearly $5 billion despite bad derivatives bets that resulted in credit trading losses of $4.4 billion. The bank's profit defused concerns about the long-term impact of a multibillion-dollar trading losses in the quarter. Concerns about slowing growth have pressured stocks, leading to a string of losses by the S&P so far this week. "The market was very oversold, so with China looking better than we previously thought, and JPMorgan looking like it has healed itself, things appear contained for the moment," said John Manley, chief equity strategist at Wells Fargo Funds Management in New York. We're putting in a bottom, not a top. The CBOE Volatility index, Wall Street's so-called fear gauge, fell 7 percent. Financial stocks were the top gainers of the day. JPMorgan said it had lost a total of $5.8 billion in 2012 from trading losses and said some traders might have tried to conceal the extent of the losses earlier this year. The bank said it would restate its previously filed interim financial statement for the first quarter. Shares of Wells Fargo & Co rose after the biggest U.S. mortgage lender reported second-quarter earnings that beat estimates on strong mortgage banking income and improved credit quality. Labor Department data showed U.S. producer prices unexpectedly rose 0.1 percent in June, against analyst estimates for a decline of 0.5 percent. The market's reaction to this data was muted. The Thomson Reuters/University of Michigan Surveys of Consumers preliminary reading on the overall index on consumer sentiment fell to 72.0 from 73.2 in June, shy of expectations as Americans took a dim view of their finances and job prospects. Earnings season continues in full swing next week, with Intel Corp, Citigroup , Johnson & Johnson and Coca-Cola Co among the names reporting. Insight on the market's rise in afternoon trading, with Stephanie Link, The Street; Gary Wedbush, Wedbush Securities; and CNBC's David Faber.