U.S. stocks rose, ending their longest losing streak since January, amid better-than-forecast earnings and as Chinese equities pulled back from a selloff.

The Standard & Poor’s 500 Index increased 1.2 percent to 2,093.26 at 4 p.m. in New York, as the gauge climbed to its average price during the past 100 days.

Chinese equities lost 1.7 percent today, after sinking as much as 5.1 percent. Shares tumbled 8.5 percent Monday amid weaker-than-expected economic data and concern that a three-week rally sparked by unprecedented government intervention is unsustainable.

The S&P 500 fell 2.9 percent in the previous five sessions as a Chinese stock rout spurred concern about the nation’s economic growth and some corporate earnings disappointed. The index has declined for four of the last five weeks and is up 1.5 percent this month, after nearly erasing its July gain yesterday.

Source: Bloomberg