Code covered by the BSD License  

Highlights from
FRETSCAL

image thumbnail

FRETSCAL

by

 

For the FRET analysis of images of yeast cells labeled with YFP and CFP.

fgetseparation
function fgetseparation
%Version 4/3/09 The splash screen where you input the minumum separation between
%AOIs in an image.
global byedit fontpics separation h_getseparationfig darkgreen

x = .4; y = .4; w = .2; h = .2;
h_getseparationfig = figure('Color', darkgreen, 'units','normalized','ToolBar','none','NumberTitle','off','name','AOI separation','menubar','none','position',[ x y w h ] );
uicontrol( 'units', 'normalized', 'style', 'text', 'string', 'Minimum number of pixels between AOIs', 'position',[ .1 4/6 .8 1/4 ],'background','black','fore','white', 'fontsize', fontpics );
byedit   = uicontrol( h_getseparationfig, 'units', 'normalized', ...
    'style', 'edit', 'string', num2str( separation ), 'position', [ .35 .4 .3 .15 ], 'value', separation, 'background','white','fontsize', fontpics );
uicontrol( 'style','pushbutton', 'units', 'normalized',  'string','Done',...
    'position',[ 1/3 1/6 1/3 1/6 ], 'callback',@fgetseparation_callback, 'fontsize', fontpics);

function fgetseparation_callback( gcf, eventdata, handles )
global byedit separation h_getseparationfig progbarcol

limitstring = get( byedit, 'string' );
if isempty(limitstring == 1)
    separation = 10;
elseif str2double( limitstring ) <= 1
    separation =1;
else
    separation = round( str2double( limitstring ) );
end;
close(h_getseparationfig);
progbarcol = 'red';
fupdate;

Contact us