Oil edged up above $64 a barrel on Tuesday, after four consecutive days of falls on worries about the economy that have brought the stock market rally to a halt and pushed the dollar higher.

Japan's Nikkei average <.N225> opened lower on persistent economic concerns aggravated last week by weaker-than-expected U.S. employment data for June, while the U.S. dollar gained on rising risk aversion.

The market could find more direction from the American Petroleum Institute's weekly crude and products stocks data to be released at 2030 GMT, and expected to show a fall in crude and a rise in product stocks.

U.S. light crude for August delivery rose 21 cents to $64.26 a barrel by 10:14 p.m. EDT, having settled down 4 percent on Monday at $64.05, its lowest settlement in more than a month. London Brent crude gained 23 cents to $64.28.

At times like this in the cycle where people are still unsure about the outlook, they are more likely to buy U.S. Treasuries and that kind of investment and that is causing a bit of upward pressure on the dollar and a bit of downward pressure on oil prices, said Ben Westmore, commodities analyst at National Australia Bank.

When risk aversion rises, investors cut holdings of stocks and higher-yielding currencies and often buy back yen and U.S. dollars that were used to finance the trades.

Oil prices have fallen 8 percent since the beginning of July after having doubled from lows below $33 hit last December on economic optimism in the second quarter that has since fizzled out.

Growing unrest in Nigeria, where militants have launched at least four attacks against oil installations in the past ten days, put a floor on falling prices in the past few weeks. But it failed to push prices higher on Monday when the main militant group said it had sabotaged a Chevron oil facility and seized a chemical tanker and six crew members.

Analysts polled by Reuters predicted U.S. crude oil inventories fell last week for the fifth week in a row by 2.2 million barrels on average, while they expected gasoline stocks to have gained 800,000 barrels and distillate inventories 1.7 million barrels.

The Energy Information Administration (EIA) will also release its monthly report later on Tuesday. Last month, the EIA raised its forecast for 2009 world demand by 10,000 barrels per day (bpd) to 83.68 million bpd, the first time since September that it had increased the demand estimate in its rolling monthly forecast.

(Editing by Michael Urquhart)