You are trying to execute a Java plugin as a macro.
Please read the description how to install the plugin:
I have already installed the plugins based on the descriptions and the result is still the same.
Just save the file to the ImageJ plugins directory (with *.java extension). Then open the file, compile and run it:
Plugins->Compile And Run…
Open a stack before (seems to be required) else you will run into an error with this plugin (line 138).