📄 icstutorial.html
字号:
set(s,'LineStyle','none')
title('Cropped Spatial Autocorrelation Function for First Image')
%%
% These cropped SACFs are fit to a 2D Gaussian:
%%
%
% $$r\left(\xi,\eta\right) \ = g\left(0,0\right)\ e^{ -\frac{\xi^{2}+\eta^{2}}{\omega_{o}^{2}}} + g_{\infty}$$
%
%%
% which can be accomplished by:
a = gaussfit(ICS2DCorrCrop,'2d',0.1,'n');
%%
% returing the fit parameters in |a|.
% Recall that 0.1 is the pixel size set in the simulation above, and the |'n'| refers to no whitenoise
% (there would be whitenoise with real data). We can now plot
% the fitted Gaussian as well as the raw correlation function for the first
% image:
plotgaussfit(a(1,1:6),ICS2DCorrCrop(:,:,1),0.1,'n')
%%
% Finally, we can calculate the average cluster density using the
% amplitudes of the fitted Gaussians:
particlesPerBeamArea = 1/(mean(a(:,1)))
beamArea = pi*mean(a(:,2))*mean(a(:,3))
density = particlesPerBeamArea/beamArea
%%
% |density| should be close to the 10 particles/um^2 which we set in the
% simulation.
%% TEMPORAL ICS (TICS)
% We can extract diffusion coefficients and flow rates using TICS. First,
% we calculate
% the temporal autocorrelation function (TACF) for our diffusion
% simulation, given 1 second time sampling
GtDiff = tics(imageSeriesDiff,1);
%%
% For samples undergoing 2D diffusion, the TACF has the following
% analytical form:
%%
%
% $$ r \left( 0,0,\tau \right) \ = g \left(0,0,0\right) \ \left(1+ \frac{\tau}{\tau_{d}}\right)^{-1} + g_{\infty}$$
%
%%
% Let's fits the first 20 lags of the temporal autocorrelation function to
% the 2D diffusion model
diffCoeff = difffit(GtDiff(1:20,1),GtDiff(1:20,2));
%%
% The diffusion coefficient can be calculated from the fitted parameter in
% |diffCoeff| and the beam waist of the laser:
%%
%
% $$D = \frac{\langle\omega_{0}\rangle^{2}}{4\tau_{d}}$$
%
%%
% Or, in MATLAB:
w = mean(a(:,2))
D = w^2/(4*diffCoeff(2))
%%
% The beam radius, |w|, should be close to the set value, 0.4.
% The diffusion coefficient |D|, should be close to the set value 0.01.
%% SPATIO-TEMPORAL ICS (STICS)
% STICS measures the velocity of flowing particles. Let's generates an image series with 5 particles/um^2 immobile, 5 particles/um^2 flowing with direction "down-left"
% i.e., x component 0.0707 um/s, y component -0.0707 um/s. The pixel size
% will be 0.06, and the time resolution 0.1 seconds.
%
% This gives a total speed of sqrt(2(0.0707^2)) = 0.1 um/s.
imageSeriesFlow = simul8tr(256,256,100,[5 5],'none',[0 0],[1 1],0.06,0.1,'g',0.4,0,12,[0 0],[0.0707 0],[-0.0707 0],[0 0],0,0);
%%
% The function |velocity| performs the STICS analysis:
[Vx,Vy] = velocity(imageSeriesFlow,0.1,0.06,'y',20,'n');
%%
% where the analysis was performed up to lag 20, |'y'| denotes immobile
% filtering, with time resolution 0.1s and pixel size 0.06 um.
% |'n'| denotes no whitenoise (there would be with real data). When
% prompted, select end of the "linear" region of the plot. Because this
% simulation has high S/N and temporal coherence, the plot should be linear over the range displayed. Just click somewhere on the right hand
% side (i.e., high tau) of the plot. |Vx| and
% |Vy| will be calculated, and should agree with the set velocity components of 0.071 and -0.071. The magnitude
% of the velocity measured by STICS is given by |V|:
V = sqrt(Vx^2+Vy^2)
%%
% |V| should be close to the set speed, 0.1um/s
% Let's compare this result with TICS. As with diffusion, we calculate
% the TACF, given 0.1 second temporal sampling:
GtFlow = tics(imageSeriesFlow,0.1);
%%
% For samples undergoing 2D flow, the TACF has the following analytical
% form:
%%
%
% $$r \left(0,0,\tau \right) \ \ =g \left(0,0,0\right)\ \ e^{-\left(\frac{\tau}{\tau_{f}}\right)^{2}} + g_{\infty}.$$
%
%%
% We can fit the first 60 lags of the simulation TACF to this model:
flowCoeff = flowfit(GtFlow(1:60,1),GtFlow(1:60,2));
%%
% The flow speed can be calculated from this fit:
%%
%
% $$\left|v\right| = \frac{\langle\omega_{0}\rangle}{\tau_{f}}$$
%
%%
% Or, in MATLAB:
v = w/flowCoeff(2)
%%
% |v| should be close to |V|, the speed recovered from the STICS analysis.
% Finally, we can calculate the % immobile:
percentImmobile = flowCoeff(3)/(flowCoeff(1)+flowCoeff(3))*100
%%
% |percentImmobile| should be close to 50, the value set in the simulation.
%% IMAGE SERIES IMPORTING AND MANIPULATION
%
% *Importing Image Series*
%
% A 16-bit Fluoview TIFF image series can be imported using |rd_img16|:
%
% |image_data=rd_img16(filename)|;
%
% where |filename| a string which contains the filename to load. (e.g.,
% |'C:\MyData\ImageSeries.tif'|.) Similary, |rd_imgser| can load 8-bit RAW files:
%
% |image_data=rd_imgser(filename,sizex,sizey,numimg)|;
%
% where |sizex| and |sizey| are the dimensions of an image, and |numimg| is
% the number of images in the series.
%
% If the file is a Fluoview TIFF and the image series was collected on an Olympus
% microscope, |FluoInfo| can extract data collection
% parameters from the file header:
%
% |[XDim,YDim,TDim, PMTVoltage, PMTOffset, PMTGain, LaserPower] = FluoInfo(filename);|
%
% where |XDim| and |YDim| are the pixel sizes, in um, in the X and Y directions,
% and |TDim| is the time between images, in seconds. |PMTVoltage|,
% |PMTOffset|, and |PMTGain|, give the PMT settings, and |LaserPower| is
% the laser intensity, in percent.
%
% *Correcting for Background Noise*
%
% Background intensity counts can be subtracted from an image series using
% |wnCorr|:
%
% |imageSeriesCorrected = wnCorr(imageSeries);|
%
% You will be prompted to select a background region. Its mean will
% be subtracted from the image series.
%
% *Cropping a Region for Analysis*
%
% An image series can be cropped to select a region of interest using
% |serimcrop|:
%
% |croppedImageSeries = serimcrop(imageSeries);|
%
% You will be prompted to interactively select the region of interest.
%% REFERENCES
%
% *Image correlation Spectroscopy (ICS)*
%
% [1] Petersen, N., P. Hoddelius, P. Wiseman, O. Seger, and K. Magnusson. 1993. Quantitation of
% membrane receptor distributions by image correlation spectroscopy: concept and application.
% Biophys. J. 65:1135-46. http://www.biophysj.org/cgi/content/abstract/65/3/1135
%
% [2] Wiseman, P., and N. Petersen. 1999. Image correlation spectroscopy. II. optimization for ultrasensitive
% detection of preexisting platelet-derived growth factor-beta receptor oligomers on
% intact cells. Biophys. J. 76:963-77. http://www.biophysj.org/cgi/content/abstract/76/2/963
%
% [3] Costantino, S., J. W. Comeau, D. L. Kolin, and P. W. Wiseman. 2005. Accuracy and dynamic
% range of spatial image correlation and cross-correlation spectroscopy. Biophys. J. 89:1251-1260.
% http://www.biophysj.org/cgi/content/abstract/89/2/1251
%
% *Temporal Image Correlation Spectroscopy (TICS)*
%
% [4] Wiseman, P., J. Squier, M. Ellisman, and K. Wilson. 2000. Two-photon image correlation
% spectroscopy and image cross-correlation spectroscopy. J. Microsc. 200:14-25.
% http://www.blackwell-synergy.com/doi/abs/10.1046/j.1365-2818.2000.00736.x
% and correction: http://www.blackwell-synergy.com/doi/full/10.1046/j.0022-2720.2001.001013.x
%
% [5] Kolin, D. L., S. Costantino, and P. W. Wiseman. 2006. Sampling Effects, Noise, and Photobleaching
% in Temporal Image Correlation Spectroscopy. Biophys. J. 90:628-639. http://www.biophysj.org/cgi/content/abstract/90/2/628
%
% *Spatio-temporal Image Correlation Spectroscopy (STICS)*
%
% [6] Hebert, B., S. Costantino, and P. W. Wiseman. 2005. Spatiotemporal image correlation spectroscopy
% (STICS) theory, verification, and application to protein velocity mapping in living
% CHO cells. Biophys. J. 88:3601-3614. http://www.biophysj.org/cgi/content/abstract/88/5/3601
%
% *MATLAB Documentation*
%
% Getting started in MATLAB:
% http://www.mathworks.com/access/helpdesk/help/techdoc/learn_matlab/learn_matlab.html##### SOURCE END #####--> </body></html>
⌨️ 快捷键说明
复制代码
Ctrl + C
搜索代码
Ctrl + F
全屏模式
F11
切换主题
Ctrl + Shift + D
显示快捷键
?
增大字号
Ctrl + =
减小字号
Ctrl + -