Why the ROI table BioVoxxel Cluster Indicator Non-fused cannot be saved?

fiji
imagej
biovoxxel

#1

I have the following image:

captured

Then I tried to binarize and perform clustering with the following code:

open("my_data.captured.tiff");
run("HSB Stack");
run("Slice Keeper", "first=1 last=1 increment=1");
selectWindow("my_data.captured.tiff");
run("Close");
run("Make Binary");

run("Cluster Indicator", "cluster_diameter=100 density=3 iterations=100 method=[average NND] ");

// Perform cluster 


run("Set Measurements...", "area mean standard modal min centroid center perimeter bounding fit shape feret's integrated median skewness kurtosis area_fraction stack display redirect=None decimal=3");
run("To ROI Manager");
run("Labels...", "color=red font=24 show draw"); 
roiManager("Select", 0);
roiManager("Split");
roiManager("Select", 0);
roiManager("Delete");


for(r=0; r<roiManager("Count"); r++) {
	roiManager("Select", r);
	run("Analyze Particles...", "display exclude summarize");
}

selectWindow("Results");
saveAs("Results", "my_data_captured.clustered.csv");	

Notice that I exclude fuse in this line:

run("Cluster Indicator", "cluster_diameter=100 density=3 iterations=100 method=[average NND] fuse");

The error I get is this:

And my_data_captured.clustered.csv is not created at all.

How can I resolve the problem?


#2

My first quick guess would be that the error message you’re seeing (Image with composite selection required) comes from this line:

Why are you trying to split your selection here? Did you try removing that line from your macro?


#3

Hi @Peverall_Dubois,

first of all, if you do not get the fused ROIs any splitting doesn’t make sense because they are all individual circles.

Second, if you get the fused ROIs and add them to the ROI Manager,
grafik

then you need to select the ROI and you will be able to run the split command

grafik


#4

The problem with your results table is that you did not specify where to save it. you just gave it a name. most likely it ended up in some temporary folder. In the save as command you need to specify the full file path. Please check out the Built-in macro functions page.

saveAs(format, path)
Saves the active image, lookup table, selection, measurement results, selection XY coordinates or text window to the specified file path. The format argument must be “tiff”, “jpeg”, “gif”, “zip”, “raw”, “avi”, “bmp”, “fits”, “png”, “pgm”, “text image”, “lut”, “selection”, “results”, “xy Coordinates” or “text”. Use saveAs(format) to have a “Save As” dialog displayed.