THE JAPANESE election turned into a referendum on the country's outspoken prime minister, Yasuhiro Nakasone. As national elections go, it was less than crucial, since it involved only half the seats in the upper house of the Diet. The power is in the lower house. But as a test of Mr. Nakasone's standing, it was a significant victory for a style of leadership that is, by Japanese standards, unorthodox.

He has been talking openly and explicitly about larger international responsibilities for Japan--including responsibilities for defense, a subject that Japanese politicians have for many years avoided discussing in public. Mr. Nakasone's comments have generated great controversy in Japan, but his trips abroad have been uniformly successful. Last winter he visited Korea--the first time any Japanese prime minister had been there since World War II, and in view of a decidedly scratchy relationship a rather risky venture--and came here to Washington for talks with President Reagan. Last month he made a swing through five southeastern Asian countries, talking about trade and defense, and then was here again for the economic policy meeting at Williamsburg. Whatever else Japanese voters think of Mr. Nakasone, Sunday's returns suggest that they consider him effective in dealing with the rest of the world.

With inflation and unemployment there both phenomenally low, politics in Japan is not driven by the same anxieties that drive most other industrial countries. But it has its own tensions. A former prime minister, Kakuei Tanaka, is under prosecution for accepting bribes from Lockheed aircraft, and Mr. Tanaka continues to be a figure of great influence in Mr. Nakasone's Liberal Democratic Party.

It is as though, for example, Richard Nixon had not been pardoned but, while facing criminal charges, continued to play a central role in the Republican Party. Mr. Tanaka wanted elections for the lower house to be held last weekend, simultaneously with those for the upper house. The idea was to get them all over before Mr. Tanaka faced the verdict that he expects in the autumn. Mr. Nakasone's refusal was a way of putting distance between himself and Mr. Tanaka. That gesture seems to have strengthened Mr. Nakasone substantially, both last Sunday and in preparing for the much more important elections for the lower house that will probably be held early next year.