TOKYO, Sept 18 (Reuters) - Japanese shares inched up on Friday but hovered below their post-pandemic high touched earlier this week, as investors grew cautious about expensive valuations and a murky earnings outlook ahead of a long weekend.

At midday, Japan's Nikkei share average was up 0.03% at 23,326.00 and the broader Topix 0.22% to 1,642.01.

Both the indexes stopped well short of testing a near seven-month peak scaled on Monday on hopes new Japanese Prime Minister Yoshihide Suga will ensure political stability and policy continuity.

Many of the day's top performers were recent laggards, such as railway operators and carmakers, as investors bought them back to close their positions ahead of a four-day weekend.

The market will be closed on Monday and Tuesday for a national holiday.

East Japan Railway gained 2.3% and West Japan Railway was up 1.9%. But, both were still down about 6% this week after they gave a guidance of record annual losses earlier in the week.

"The companies hit hard by the coronavirus are likely to post underwhelming earnings as the railway companies have shown this week," said Norihiro Fujito, chief investment strategist at Mitsubishi UFJ Morgan Stanley Securities.

"The Nikkei is already trading at 23 times the earnings and the Topix 24 times. Investors will hesitate to buy at current levels."

Some battered cyclicals also gained, with Nissan Motor rising 1.5% and Isuzu Motors gaining 3.8%.

Buy-back in those shares, however, will have run its course by this week, some analysts said, as margin sellers need to close their positions within six months and Friday falls to six months from the market's trough hit on March 17, the peak of virus-led massive selling.

Telecom shares stayed under pressure as Suga has been calling for lower mobile tariffs. NTT Docomo, KDDI and SoftBank, fell 1.8%, 2.6% and 2.6% respectively. (Reporting by Hideyuki Sano; editing by Uttaresh.V)