-
Notifications
You must be signed in to change notification settings - Fork 3
Expand file tree
/
Copy pathmnl_CreateTetbowStructures.m
More file actions
25 lines (24 loc) · 938 Bytes
/
mnl_CreateTetbowStructures.m
File metadata and controls
25 lines (24 loc) · 938 Bytes
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
function [Bow]=mnl_CreateTetbowStructures
%function to place all group data into a singular structure for further
%analysis
prompt='Enter the number of groups in your analysis';
nGroups=input(prompt,'d');
for i=1:nGroups
disp('Select Group')
%Specify the concentration
prompt='Enter Group Name/Concentration';
Bow(i).Concentration=input(prompt,'s');
% Load in the data
disp('Load in your chosen group')
[Wkspaces]=uipickfiles;
load(Wkspaces{1,1});
% Reconfigure into Bow
sNum=max(Data.SampleNum);%Find the total number of samples
for j=1:sNum
index=Data.SampleNum==i;%List of where the sample data is
a=find(index);%Positions of where in Index the sample is
st=min(a);ed=max(a);%Begining and end of sample
Bow(i).SampleNum(j).ColourData_Raw=Data.RawColourData(st:ed,:);
Bow(i).SampleNum(j).ColourData_Norm=Data.NormalisedColourData(st:ed,:);
end
end