Skip to content

Commit

Permalink
Fixed bug when importing fluorescence data
Browse files Browse the repository at this point in the history
  • Loading branch information
sebromano authored Sep 4, 2017
1 parent 751832e commit 06686dc
Showing 1 changed file with 22 additions and 1 deletion.
23 changes: 22 additions & 1 deletion Toolbox software/FindAssemblies.m
Original file line number Diff line number Diff line change
Expand Up @@ -14,11 +14,32 @@
filenameALL_CELLS=[filenameRASTER(1:cutName-1) '_ALL_CELLS.mat'];
outputFile=[filenameRASTER(1:cutName-1) '_CLUSTERS.mat'];
end

dataRaster=load(filenameRASTER);
if exist(filenameALL_CELLS, 'file') == 2
dataAllCells=load(filenameALL_CELLS);
else
if isfield(dataRaster,'dataAllCells')
if isfield(dataRaster.dataAllCells,'avg')
dataAllCells.avg=dataRaster.dataAllCells.avg;
else
disp('Error: Field dataAllCells.avg missing in imported fluorescence file. See "Imported Fluorescence Data File" in Box 2 of tutorial. Quitting program.')
end
if isfield(dataRaster.dataAllCells,'cell_per')
dataAllCells.cell_per=dataRaster.dataAllCells.cell_per;
else
disp('Error: Field dataAllCells.cell_per missing in imported fluorescence file. See "Imported Fluorescence Data File" in Box 2 of tutorial. Quitting program.')
end
if isfield(dataRaster.dataAllCells,'cell')
dataAllCells.cell=dataRaster.dataAllCells.cell;
else
disp('Error: Field dataAllCells.cell missing in imported fluorescence file. See "Imported Fluorescence Data File" in Box 2 of tutorial. Quitting program.')
end
else
disp('Error: Variable dataAllCells missing in imported fluorescence file. See "Imported Fluorescence Data File" in Box 2 of tutorial. Quitting program.')
end
end

dataRaster=load(filenameRASTER);
raster=dataRaster.raster;
deltaFoF=dataRaster.deltaFoF;
movements=dataRaster.movements;
Expand Down

0 comments on commit 06686dc

Please sign in to comment.