-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathremoveExcessmKate.m
More file actions
53 lines (43 loc) · 1.04 KB
/
removeExcessmKate.m
File metadata and controls
53 lines (43 loc) · 1.04 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
function removeExcessmKate(A,B)
%%
% channelinputs = '(mKate|EGFP|CFP|DIC)';
channelstoinput = {'mKate','EGFP','CFP','DIC'};
% channelstoinput = {'_mKate','_EGFP','_CFP','DIC'};
channelinputs = '(';
for i=1:length(channelstoinput)
if i ==1
channelinputs = strcat(channelinputs,channelstoinput{i});
elseif i < length(channelstoinput)
channelinputs = strcat(channelinputs,'|',channelstoinput{i});
else
channelinputs = strcat(channelinputs,'|',channelstoinput{i},')');
end
end
cd (strcat(A,B));
cd ('flatfield_corrected')
%%
folderlist = dir('*_s*');
folderlist.name;
for folder = {folderlist.name}
cd(folder{1})
for i = 1:length(channelstoinput)
mkdir(strcat(channelstoinput{i},'_flat'))
end
mkdir('tiffs');
cd('mKate_flat')
filelist = dir('*CFP*')
if ~isempty(filelist)
delete(filelist.name);
end
filelist = dir('*EGFP*')
if ~isempty(filelist)
delete(filelist.name);
end
filelist = dir('*DIC*')
if ~isempty(filelist)
delete(filelist.name);
end
stophere=1;
cd ..
cd ..
end