bugfix: messed up order
This commit is contained in:
parent
fa769ec4b4
commit
c62cf45452
|
|
@ -12,10 +12,12 @@ function [pp2] = convert_particles_array_colmap(pp1,col1,col2)
|
||||||
nt = size(pp1,3);
|
nt = size(pp1,3);
|
||||||
pp2 = zeros(ncol2,np,nt);
|
pp2 = zeros(ncol2,np,nt);
|
||||||
|
|
||||||
col2keys = col2.keys;
|
[colvals,idx] = sort(cell2mat(col2.values));
|
||||||
|
colkeys = col2.keys;
|
||||||
|
colkeys = {colkeys{idx}};
|
||||||
for it=1:nt
|
for it=1:nt
|
||||||
for icol=1:ncol2
|
for icol=1:ncol2
|
||||||
key = col2keys{icol};
|
key = colkeys{icol};
|
||||||
if col1.isKey(key)
|
if col1.isKey(key)
|
||||||
pp2(icol,:,it) = pp1(col1(key),:,it);
|
pp2(icol,:,it) = pp1(col1(key),:,it);
|
||||||
end
|
end
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue