Hello all,
As the title states, I'd like to threshold the channel 0 of an image, and add the obtained ROI to another sequence.
I'm encountering several problems doing that, probably due to my being completely new to javascript.
First, I don't understand how to use a fixed threshold.
If I try:
cells = Thresholder.threshold(groundtruth, 0, 100)
I'm getting
Can't find method plugins.adufour.thresholder.Thresholder.threshold(icy.sequence.Sequence,number,number)
I can circumvent this using
thresh = KMeans.computeKMeansThresholds(groundtruth, 2)
cells = Thresholder.threshold(groundtruth, 0, thresh)
but this is not really satisfying, as I know the threshold value I want to use.
Second part, I'd like to add the ROI obtained this way to a sequence. So here's what I tried:
seq.addROI(cells)
but I'm getting this error:
Can't find method icy.sequence.Sequence.addROI([Licy.roi.ROI;).
I'm guessing this a type issue, but after unsuccessfully trying a lot of different combinations, I'm turning to the community for help.
Thanks!