Hi, Maybe this is more a programming questions than a specific R-project question, but maybe there is someone who can point me in the right direction. I have a picture of cirkels which I took with a digital camera. Now I want to use the diameter of the cirkels on the picture for analysis in R. I can use pixmap to import the picture, but how do I find the outside cirkels and calculate the diameter? I pointed out that I can use the edci package, but then I need to preprocess the data to reduce the points, otherwise it takes a long time, and my computer crashes. If you want to see such a picture, I cropped a larger one, and highlighted the cirkel which is of interest. In a real world, this is a plate with 36 cirkels, which all should be measured. www.users.skynet.be/fa244930/fotos/outlined.jpg Thanks for your time Bart [[alternative HTML version deleted]]
Hi, Maybe this is more a programming questions than a specific R-project question, but maybe there is someone who can point me in the right direction. I have a picture of cirkels which I took with a digital camera. Now I want to use the diameter of the cirkels on the picture for analysis in R. I can use pixmap to import the picture, but how do I find the outside cirkels and calculate the diameter? I pointed out that I can use the edci package, but then I need to preprocess the data to reduce the points, otherwise it takes a long time, and my computer crashes. If you want to see such a picture, I cropped a larger one, and highlighted the cirkel which is of interest. In a real world, this is a plate with 36 cirkels, which all should be measured. www.users.skynet.be/fa244930/fotos/outlined.jpg Thanks for your time Bart [[alternative HTML version deleted]]
On 8/23/07, Bart Joosen <Bartjoosen at hotmail.com> wrote:> Maybe this is more a programming questions than a specific R-project question, but maybe there is someone who can point me in the right direction. > > I have a picture of cirkels which I took with a digital camera. > Now I want to use the diameter of the cirkels on the picture for analysis in R. > I can use pixmap to import the picture, but how do I find the outside cirkels and calculate the diameter? > I pointed out that I can use the edci package, but then I need to preprocess the data to reduce the points, otherwise it takes a long time, and my computer crashes. > > If you want to see such a picture, I cropped a larger one, and highlighted the cirkel which is of interest. > In a real world, this is a plate with 36 cirkels, which all should be measured. > www.users.skynet.be/fa244930/fotos/outlined.jpgYou mean the diameter measured in number of pixels? Paul
Hi Bart, If you only have 36 circles, the fastest way would be to use some image processing software and measure the circles "by hand". One option is to use ImageJ, which you can download here http://rsb.info.nih.gov/ij/ Julian Bart Joosen wrote:> Hi, > > Maybe this is more a programming questions than a specific R-project question, but maybe there is someone who can point me in the right direction. > > I have a picture of cirkels which I took with a digital camera. > Now I want to use the diameter of the cirkels on the picture for analysis in R. > I can use pixmap to import the picture, but how do I find the outside cirkels and calculate the diameter? > I pointed out that I can use the edci package, but then I need to preprocess the data to reduce the points, otherwise it takes a long time, and my computer crashes. > > If you want to see such a picture, I cropped a larger one, and highlighted the cirkel which is of interest. > In a real world, this is a plate with 36 cirkels, which all should be measured. > www.users.skynet.be/fa244930/fotos/outlined.jpg > > > Thanks for your time > > Bart > [[alternative HTML version deleted]] > > ______________________________________________ > R-help at stat.math.ethz.ch mailing list > https://stat.ethz.ch/mailman/listinfo/r-help > PLEASE do read the posting guide http://www.R-project.org/posting-guide.html > and provide commented, minimal, self-contained, reproducible code. > >
Hello Bart! I took your picture and analysed it with ImageJ. You can do a particle analysis with the image which measures the required diameter. I used the "Find Edges" method Process->Find Edges and then adjusted the Brightness/Contrast/maximum Image->Adjust->Brightness/Contrast. After this i converted the image to 8-bit Image->Type->8-bit and thresholded the image Image->Adjust->Threshold until i've got closed circles in red. In the Analyse->Set Scale and Analyse->Set Measurements dialog I selected the attributes to measure (Ferrets Diameter or Bounding Rectangle! You have to adjust the appropriate scale!). I then did a particle analysis which excluded particles < 1000 Analyse->Analyse Particles. If you select the option "Add to Manager" all measured Particles are added to a "Region of Interest Manager" ROI in which you can select and measure your Particles seperately, if you wish. You can also fit a Ellipse to the selected Particle in Edit->Selection->Fit Ellipse and then measure the Particle. If you want to see a Particle measurement in Action see my application which uses ImageJ and R and the Flash tutorial in which i demonstrate a Particle measurement which is analog to the ImageJ application. http://www.uni-bielefeld.de/biologie/Oekosystembiologie/bio7app/flashindex/index.html http://www.uni-bielefeld.de/biologie/Oekosystembiologie/bio7app/flashindex/index.html I highly recommend you to use a new version of ImageJ because of this capabilities, downloadable at http://rsb.info.nih.gov/ij/ http://rsb.info.nih.gov/ij/ I hope this information is a help for you. With kind regards Marcel -- View this message in context: http://www.nabble.com/Calculating-diameters-of-cirkels-in-a-picture.-tf4319669.html#a12307704 Sent from the R help mailing list archive at Nabble.com.