Hi folks,
I want to analyse fluorescence probes inside of cells. I have images in DAPI, FITC and CY5. I had success with nuclei detection by thresholding and the particle analysis. Then I save my particle analysis result as an ROI to use it with the other channels and to count the fluorescence particles. But I want to count the fluorescence particles not only in the nuclei but also in the cytoplasm. Is it possible to expand the ROI around each nuclei for lets say 5 or 10 pixels to also measure particles in the cytoplasm of the cells? Any ideas? Many greetings Robert -- Sent from: http://imagej.1557.x6.nabble.com/ -- ImageJ mailing list: http://imagej.nih.gov/ij/list.html |
Dear Robert,
Yes, see Edit > Selection > Enlarge Best wishes Kees Dr Ir K.R. Straatman Senior Experimental Officer Advanced Imaging Facility Centre for Core Biotechnology Services University of Leicester www.le.ac.uk/advanced-imaging-facility -----Original Message----- From: ImageJ Interest Group [mailto:[hidden email]] On Behalf Of Robert Niestroj-Pahl Sent: 16 April 2018 13:11 To: [hidden email] Subject: Nuclei detection - how can I expand my ROI for the cell membrane? Hi folks, I want to analyse fluorescence probes inside of cells. I have images in DAPI, FITC and CY5. I had success with nuclei detection by thresholding and the particle analysis. Then I save my particle analysis result as an ROI to use it with the other channels and to count the fluorescence particles. But I want to count the fluorescence particles not only in the nuclei but also in the cytoplasm. Is it possible to expand the ROI around each nuclei for lets say 5 or 10 pixels to also measure particles in the cytoplasm of the cells? Any ideas? Many greetings Robert -- Sent from: http://imagej.1557.x6.nabble.com/ -- ImageJ mailing list: http://imagej.nih.gov/ij/list.html -- ImageJ mailing list: http://imagej.nih.gov/ij/list.html |
In reply to this post by Robert Niestroj-Pahl
Good day Robert,
you may have a look at "Edit >> Selection >> Enlarge..." and it is always a good idea to study the ImageJ user guide: <https://imagej.nih.gov/ij/docs/guide/index.html> Regards Herbie :::::::::::::::::::::::::::::::::::::::::::::::::: Am 16.04.18 um 14:11 schrieb Robert Niestroj-Pahl: > Hi folks, > I want to analyse fluorescence probes inside of cells. I have images in > DAPI, FITC and CY5. > I had success with nuclei detection by thresholding and the particle > analysis. Then I save my particle analysis result as an ROI to use it with > the other channels and to count the fluorescence particles. But I want to > count the fluorescence particles not only in the nuclei but also in the > cytoplasm. Is it possible to expand the ROI around each nuclei for lets say > 5 or 10 pixels to also measure particles in the cytoplasm of the cells? > Any ideas? > > Many greetings > > Robert > > > > -- > Sent from: http://imagej.1557.x6.nabble.com/ > > -- > ImageJ mailing list: http://imagej.nih.gov/ij/list.html > -- ImageJ mailing list: http://imagej.nih.gov/ij/list.html |
Thanks Herbie,
I found this command. My selection of the nuclei is now enlarged, but the watershed segmentation is gone! I can't count the single cells any more. Do you know a way how to keep the nuclei segmentation? Best regards Robert -- Sent from: http://imagej.1557.x6.nabble.com/ -- ImageJ mailing list: http://imagej.nih.gov/ij/list.html |
When you do Analyze Particles, select the option to "Add to Manager"
to add each individual ROI to the list in the ROI Manager; that will keep them separate. Then you can loop the enlargement and further analysis steps through each ROI in the list, e.g.: numROIs = roiManager("count"); for(i = 0; i < numROIs; i++){ roiManager("Select", i); run("Enlarge...", "enlarge=5"); //5 pixel enlargement roiManager("Add"); } //now loop through enlarged ROIs only to do analysis -Esteban On Mon, Apr 16, 2018, 5:33 AM Robert Niestroj-Pahl <[hidden email]> wrote: > > Thanks Herbie, > > I found this command. My selection of the nuclei is now enlarged, but the > watershed segmentation is gone! I can't count the single cells any more. Do > you know a way how to keep the nuclei segmentation? > Best regards > > Robert > > > > -- > Sent from: http://imagej.1557.x6.nabble.com/ > > -- > ImageJ mailing list: http://imagej.nih.gov/ij/list.html -- ImageJ mailing list: http://imagej.nih.gov/ij/list.html |
In reply to this post by Robert Niestroj-Pahl
Hi Robert,
if you create the selection to a mask, you could try Gabriel Landini's BinaryDilateNoMerge8 or on the mask, then convert it back to a selection. http://www.mecourse.com/landinig/software/software.html Unfortunately, it does dilation with a square structure element, not a circular one. An alternative, starting with a binary image, with circular dilation: //assumes you have white background, black particles: run("Options...", "iterations=1 count=1 pad do=Nothing"); //the 'watershed' segmentation you mentioned run("Watershed"); //and now the operations for a no-merge dilation run("Invert"); run("Distance Map"); run("Find Maxima...", "noise=0 output=[Segmented Particles]"); run("Create Selection"); close(); run("Restore Selection"); run("Make Inverse"); run("Set...", "value=255"); setThreshold(0, 5); // 5 pixels dilation (max. 254) run("Convert to Mask"); Michael ________________________________________________________________ On 16/04/2018 14:32, Robert Niestroj-Pahl wrote: > Thanks Herbie, > > I found this command. My selection of the nuclei is now enlarged, but the > watershed segmentation is gone! I can't count the single cells any more. Do > you know a way how to keep the nuclei segmentation? > Best regards > > Robert -- ImageJ mailing list: http://imagej.nih.gov/ij/list.html |
In reply to this post by G. Esteban Fernandez
Hi Esteban,
very elegant solution thank you! But now I have overlapping ROI. There might be the chance of counting particles twice. Do you also know a workaround for that? Best wishes Robert -- Sent from: http://imagej.1557.x6.nabble.com/ -- ImageJ mailing list: http://imagej.nih.gov/ij/list.html |
In reply to this post by Michael Schmid
Hi Michael,
thanks for the code, for me very appealing because it produces no overlapping ROI (like Estebans proposal). But the macro only works from time to time... sometimes I get only a white Image and sometimes I get skeletonized structures, only in one of three or four runs it works. Do you know what can cause the problems? I tried to clear my ROI manager first, but that seems not to be the problem. Best wishes Robert -- Sent from: http://imagej.1557.x6.nabble.com/ -- ImageJ mailing list: http://imagej.nih.gov/ij/list.html |
Hi Robert,
could you post a test image that does not work for you? (or upload it to some site) Then I can try to find out what is wrong. By the way, I don't use the ROI Manager in my macro. Michael ________________________________________________________________ On 17/04/2018 10:31, Robert Niestroj-Pahl wrote: > Hi Michael, > thanks for the code, for me very appealing because it produces no > overlapping ROI (like Estebans proposal). But the macro only works from time > to time... sometimes I get only a white Image and sometimes I get > skeletonized structures, only in one of three or four runs it works. Do you > know what can cause the problems? I tried to clear my ROI manager first, but > that seems not to be the problem. > > Best wishes > > Robert -- ImageJ mailing list: http://imagej.nih.gov/ij/list.html |
Hi Micheal,
thanks for help. See my screenshot below <http://imagej.1557.x6.nabble.com/file/t381965/Screen_Shot_2018-04-17_at_10.png> That is the Image I tried you macro on: <http://imagej.1557.x6.nabble.com/file/t381965/S5104_MP_IMage_1_Dapi_500_ms_1g_20x.jpg> Robert -- Sent from: http://imagej.1557.x6.nabble.com/ -- ImageJ mailing list: http://imagej.nih.gov/ij/list.html |
Hi Robert,
ok, I see, the 'Restore selection' sometimes fails. I could solve the problem by adding a "Select none", which makes sure the selection is saved as "previousRoi". I hope that it works reliably now... //assumes you have white background, black particles: run("Options...", "iterations=1 count=1 pad do=Nothing"); //the 'watershed' segmentation you mentioned run("Watershed"); //and now the operations for a no-merge dilation run("Invert"); run("Distance Map"); run("Find Maxima...", "noise=0 output=[Segmented Particles]"); run("Create Selection"); run("Select None"); close(); run("Restore Selection"); run("Make Inverse"); run("Set...", "value=255"); setThreshold(0, 5); // 5 pixels dilation (max. 254) run("Convert to Mask"); Michael ________________________________________________________________ On 17/04/2018 10:50, Robert Niestroj-Pahl wrote: > Hi Micheal, > > thanks for help. See my screenshot below > <http://imagej.1557.x6.nabble.com/file/t381965/Screen_Shot_2018-04-17_at_10.png> > > That is the Image I tried you macro on: > <http://imagej.1557.x6.nabble.com/file/t381965/S5104_MP_IMage_1_Dapi_500_ms_1g_20x.jpg> > > Robert -- ImageJ mailing list: http://imagej.nih.gov/ij/list.html |
Hi Michael,
now it works! Thank you! Robert -- Sent from: http://imagej.1557.x6.nabble.com/ -- ImageJ mailing list: http://imagej.nih.gov/ij/list.html |
Hi Robert,
There is an alternative simpler (and faster) yet not as accurate (in finding nuclear borders) solution as Landini's "Dilate no merge". 1. Duplicate the segmented nuclei image and do a Voronoi transformation on the second image (Process->Binary->Voronoi). Then threshold the resulting image with foreground between 1 and 255. This creates binary image of the Neighborhood (aka Voronoi's/Dirichlet's cells) of each nucleus: points in spaces closer to the center to each nucleus are white and correspondingly the borders between these neighborhoods are black . 2. Second step is to do the desired dilation (i.e. 5 px) on the first image of segmented nuclei. In the resulting image the nuclei are dilated but close spaced nuclei fuse. 3.In third step separate the fused dilated nuclei by doing a boolean conjunction between the two images.: Using Process-> Image calculator do a boolean "AND" (or you can simply multiply the two images) between the dilated image and the thresholded voronoi-image . Be sure that the background (i.e. background between nuclei and the lines between the cells in the Voronoi-image) in both images is black. Best wishes, Stoyan --- Assoc.Prof. Stoyan P. Pavlov, MD, PhD Departament of Anatomy, Histology and Embryology Medical University "Prof. Dr. Paraskev Stoyanov", Varna Prof. Marin Drinov Str.55 9002 Varna Bulgaria Tel: +359 (0) 52 - 677 - 052 e-mail: [hidden email] [hidden email] 2018-04-17 13:42 GMT+03:00 Robert Niestroj-Pahl <[hidden email]>: > Hi Michael, > now it works! Thank you! > > Robert > > > > -- > Sent from: http://imagej.1557.x6.nabble.com/ > > -- > ImageJ mailing list: http://imagej.nih.gov/ij/list.html > -- ImageJ mailing list: http://imagej.nih.gov/ij/list.html |
Free forum by Nabble | Edit this page |