Making a summary report of the findings

Hi,

I have original pictures and after doing the analysis and calculations, I end up with 3 or 4 windows with information.
Now, it is possible to save each window (table or picture) to the harddrive and from there I can make a word document and past all the results in it.
However, I was wondering if it is possible to export all the windows at once to a certain document. Does anybody have an idea on how to do that?

Your help or thoughts is highly appreciated. Thnx.

1 Like

Hi @Ricco ,

with ImageJ-Macro-Markdown, you can write a script that turns into a report MD, HTML or PDF when executing:

Let us know if this helps!

Best,
Robert

2 Likes

Hi Robert,

I am working on it days now but I still didn’t get it to work.
When I write a script (basically a macro that I use to get the mesuerments done) it is well executed. But as a summary it opens a html file with only the command line of the script. There is also a log file opened without any text.
I already selected and changed language to IJ1 Macro Markdown. The file however is an .ijm file.

Do you know what I am doing wrong?
Please help.

1 Like

Hi @Ricco ,

you may not be doing anything “wrong”, IJMMD is just a young project, that’s not perfect yet :wink:

If you refer to a “Summary” table, the issue might be that IJMMD only sees “Results” tables. Can you try renaming your summary table?

Table.rename("Summary", "Results");

If this doesn’t solve the issue, it would be great if you could post the code you are running and a screenshot that shows the problem. :slightly_smiling_face:

Let us know if the suggestion works.

Best,
Robert

When I use a macro, it ends up with these three results: the original picture, the calculation picture and the table with results.

I want to have these 3 items summerized in one document (PDF) without having to save these items individually.

1 Like

Can you share the code which does that?

sure:

run(“Set Measurements…”, “centroid fit redirect=None decimal=2”);
setBatchMode(true);
run(“Duplicate…”, " “);
run(“Split Channels”); close(); close();
run(“Bandpass Filter…”, “filter_large=500 filter_small=0 suppress=None tolerance=0”);
setAutoThreshold(“Default”);
setOption(“BlackBackground”, true);
run(“Convert to Mask”);
run(“Canvas Size…”, “width=”+(getWidth-50)+” height="+(getHeight-50)+" position=Center");
run(“Select All”);
run(“Invert”);
run(“Analyze Particles…”, “size=5000-Infinity show=[Overlay Masks] display exclude clear add”);
N=Table.size;
n=0;
do {
y=Table.get(“Y”, n);
n++;
} while (abs(y-Table.get(“Y”, n))<Table.get(“Major”, n) && n<N-1);
Table.renameColumn(“Y”, “Rank”);
if ( N%n != 0 ) exit(“Unequal row lengths.\nPlugin Quits!”);
m=N/n;
a=newArray(n);
for ( j=0; j<m; j++ ) {
k=j*n;
for ( i=0; i<n; i++ ) {
a[i]=Table.get(“X”, k+i);
}
b=Array.rankPositions(a);
for ( i=0; i<n; i++ ) {
roiManager(“select”, k+b[i]);
roiManager(“rename”, “”+(i+k+1));
Table.set(“Rank”, k+b[i], i+k+1);
}
}
run(“From ROI Manager”);
run(“Labels…”, “color=black font=14 show use draw bold”);
Table.deleteColumn(“X”);
Table.sort(“Rank”);
Table.deleteColumn(“Rank”);
d=Table.getColumn(“Major”);
mi=Table.getColumn(“Minor”);
for ( i=0; i<N; i++ ) d[i]=(d[i]+mi[i])*0.5;
Table.renameColumn(“Angle”, “Mean Diameter”);
Table.setColumn(“Mean Diameter”, d);
setBatchMode(false );
exit();

Ok, I think it has something to do with the “exit();” command at the very end. Can you remove it?

Almost there :grinning:.

I removed the exit and now I have the colored picture and table, so that’s great!
But it starts with plotting the code. What can I do to remove that?

Sorry, but I don’t know. IJMMD is meant for plotting the code :slight_smile:

:joy:

Thank you anyway! Much appreciated your help.
I will try to figure out how I can do it so it works for me.

Best regards.

1 Like

You’re welcome :slight_smile: