From fe82ce111a0c4efc736d25758fda0996bb556811 Mon Sep 17 00:00:00 2001 From: Eugeniy Mikhailov Date: Wed, 12 Sep 2012 17:23:25 -0400 Subject: enable fitting negative beams too Lower bound for peak amplitude now is -inf, this is handy with subtracted images. --- fitgaussian2D.m | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'fitgaussian2D.m') diff --git a/fitgaussian2D.m b/fitgaussian2D.m index a6f3d10..02c9fa2 100644 --- a/fitgaussian2D.m +++ b/fitgaussian2D.m @@ -67,7 +67,7 @@ background = fp1D(4); [X,Y] = meshgrid(1:sizex,1:sizey); %Lower and upper limits for the 2D fit -LB = [1,1,1,1,0,-1.58,0]; +LB = [1,1,1,1,-inf,-1.58,0]; UB = [sizex,sizey,sizex*10,sizey*10,inf,1.58,inf]; % Here we do the 2D fit -- cgit v1.2.3