NEW YORK (AP) -- U.S. stocks rose broadly in midday trading Tuesday as traders considered a relatively weak retail sales report and corporate earnings news. Nine of the 10 sectors of the Standard and Poor's 500 were higher, putting the index on track for a fourth straight day of gains. Investors were also keeping an eye on Greece a day after the country struck a preliminary deal with its creditors and a falling Chinese stockmarket.
KEEPING SCORE: The S&P 500 increased eight points, or 0.4 percent, to 2,108 as of 12:11 p.m. Eastern. The Dow Jones industrial average was up 64 points, or 0.4 percent, to 18,041. The Nasdaq composite climbed 35 points, or 0.7 percent, to 5,106.
WHERE ARE THE SHOPPERS? Americans cut back spending at stores and restaurants last month, a sign that they remain cautious despite robust job growth in the past year. Retail sales fell 0.3 percent in June, the weakest showing since February, according to the Commerce Department. That followed a robust 1 percent jump in May.
EXPERT TAKE: James Abate, chief investment officer of Centre Funds, thinks investors are buying stocks on the weak retail sales report because they think it makes it less likely that the Federal Reserve will increase interest rates quickly in the coming months. "It's back to the mindset that bad news is good news," he said.
EARNINGS WATCH: U.S. bank JPMorgan Chase & Co. and Johnson & Johnson both reported second-quarter earnings that were stronger than expected. Bank of America and Google are due to report later in the week. Analysts expect earnings at companies in the S&P 500 index to fall 4.5 percent compared with the prior year, according to S&P Capital IQ. That would be the first drop in earnings since 2009.
BACK TO SCHOOL: Loan servicing company Navient cut its earnings forecast because of weakened credit trends on some student loans and a drop in loans that are coming out of deferment compared with previous years. Its stock plunged $1.79, or 10 percent, to $16.57.
IN THE CHIPS? Micron Technology jumped nearly 12 percent on reports that a Chinese company is preparing a $23 billion bid for the chip maker in what would be China's largest takeover of a U.S. company. Some media reports said that Tsinghua Unigroup Ltd. would bid $21 per Micron share, and that an offer could come this week. Micron gained $2.06 to $19.67.
EUROPE'S DAY: Germany's DAX was up 0.3 percent, France's CAC 40 gained 0.7 percent and Britain's FTSE 100 rose 0.2 percent.
GREECE RESPITE: Greece struck a preliminary rescue deal with other European Union governments Monday that should avert an imminent financial collapse but guarantees years more hardship for its people. The deal removes the immediate threat Greece would default on its debts and leave the euro. But in exchange for a three-year loan program, the Greek prime minister has to persuade skeptical legislators to pass tax increases and other key demands into law by Wednesday.
CHINA'S WOBBLE: The main Chinese index lost 1.2 percent after three straight gains. The government has been trying to halt a slide that drove the Shanghai Composite Index down as much as 30 percent over the past month. State-owned brokerages and government pension funds have pledged to buy stocks, and executives and big shareholders are barred from selling. Hundreds of companies have suspended trading in their shares. Analysts say it is unclear whether the market can hold up once temporary barriers to selling are relaxed.
ASIA'S DAY: Tokyo's Nikkei 225 rose 1.5 percent and Sydney's S&P ASX 200 advanced 1.9 percent. Hong Kong's Hang Seng declined 0.4 percent. South Korea's Kospi lost 0.1 percent.
ENERGY: Benchmark U.S. crude oil rose 65 cents to $52.85 a barrel in New York following news that Iran had struck an international nuclear deal. Higher prices pushed up shares of energy companies 1 percent, the biggest gain among the 10 sectors of the S&P 500.
CURRENCIES: The dollar declined to 123.38 yen from 123.54 yen Monday. The euro edge up to $1.1010 from $1.1003.
BONDS: U.S. government bond prices rose. The yield on the 10-year Treasury note fell to 2.40 percent from 2.45 percent late Monday.