How to plot ROI onto a DICOM Image?

5 visualizaciones (últimos 30 días)
Michael Liu
Michael Liu el 8 de Jun. de 2016
Respondida: Vyoma Shukla el 30 de Mzo. de 2020
Hi,
I have am using an Interactive DICOM 3D Viewer that allows me to view the axial, coronal and sagittal planes of a DICOM image. I am using roipoly to select a region of interest and I want to be able to save those co-ordinates on the specific slice of the CT. However as I scroll through the different slices in say the axial view the region of interest disappears. Any ideas on how to apply this?
Thanks
  1 comentario
Walter Roberson
Walter Roberson el 11 de Jun. de 2016
Which interactive DICOM 3D viewer are you using?

Iniciar sesión para comentar.

Respuestas (1)

Vyoma Shukla
Vyoma Shukla el 30 de Mzo. de 2020
Hi,
This might help you. I am loading each sagittal slice of my 3D DICOM dataset in a for loop. This code is for drawing an ellipse on the 67th slice and calculating mean and standard deviation of the ellipse. I checked against ImageJ and my calculated values are accurate. You can adapt this code to your data:
I1 = dicomread('I67');
info = dicominfo('I67');
cx = double(getfield(info,'Rows')); % find centre of image
cy = double(getfield(info,'Columns'));
diam = 0.05*cx; % ROI size
h_im = imshow(imadjust(I1));
e = imellipse(gca,[cx/2-(diam/2) cy/2-(diam/2) diam diam]); % this is interactive, may want to pause here
BW = createMask(e);
BW = int16(BW);
I1(BW==0)=[]; % remove background
BW(BW==0)=[];
I1 = imresize(I1, [size(BW,1) size(BW,2)]);
I2 = I1.*BW;
average = mean(I2);
stdev = std2(I2);

Categorías

Más información sobre DICOM Format en Help Center y File Exchange.

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by