-
Notifications
You must be signed in to change notification settings - Fork 0
/
mergeWindData.m
59 lines (54 loc) · 1.43 KB
/
mergeWindData.m
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
54
55
56
57
58
59
function [U, meanT, meanDir, stdU, stdV, stdW, stdT, Luz, Lvz, Lwz, zL, L,...
u_star, T_star, wT, uw, vw, Result_RA, Su, Sv, Sw, Suw,f] = mergeWindData(data)
% Initialize arrays
U = [];
meanT = [];
meanDir = [];
stdU = [];
stdV = [];
stdW = [];
stdT = [];
Luz = [];
Lvz = [];
Lwz = [];
zL = [];
L = [];
u_star = [];
T_star = [];
wT = [];
uw = [];
vw = [];
Result_RA = [];
Su = [];
Sv = [];
Sw = [];
Suw = [];
Ndata = length(data);
for ii=1:Ndata
load([data(ii).folder,'/',data(ii).name],'Wind')
% Concatenate fields along the 2nd dimension
U = [U, Wind.U];
meanT = [meanT, Wind.meanT];
meanDir = [meanDir, Wind.meanDir];
stdU = [stdU, Wind.stdU];
stdV = [stdV, Wind.stdV];
stdW = [stdW, Wind.stdW];
stdT = [stdT, Wind.stdT];
Luz = [Luz, Wind.Luz];
Lvz = [Lvz, Wind.Lvz];
Lwz = [Lwz, Wind.Lwz];
zL = [zL, Wind.zL];
L = [L, Wind.L];
u_star = [u_star, Wind.u_star];
T_star = [T_star, Wind.T_star];
wT = [wT, Wind.wT];
uw = [uw, Wind.uw];
vw = [vw, Wind.vw];
Result_RA = [Result_RA, Wind.Result_RA];
Su = [Su, Wind.Su];
Sv = [Sv, Wind.Sv];
Sw = [Sw, Wind.Sw];
Suw = [Suw, Wind.Suw];
end
f = Wind.f;
end