Skip to content

Commit

Permalink
Loaders: fix in Monitor setting for ILL data (time, mon)
Browse files Browse the repository at this point in the history
  • Loading branch information
farhi committed Oct 14, 2015
1 parent 0f4a363 commit 2d2c231
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions Scripts/load/load_ill_tas.m
Original file line number Diff line number Diff line change
Expand Up @@ -146,17 +146,20 @@
if ~isempty(index_kfix), KFIX = get(a, index_kfix{1}); end

% get the monitor
if isfield(a.Data, 'PARAM') && isfield(a.Data.PARAM, 'TI') && ~isempty(index_ti)
if isfield(a.Data, 'PARAM') && isfield(a.Data.PARAM, 'TI') ...
&& isempty(index_m12) && ~isempty(index_ti)
mon_is_time = index_ti;
else
mon_is_time = 0;
end

if ~isempty(index_m12)
[dummy, index]=max(sum(a.Signal(:,index_m12)));
index_m12 = index_m12(index);
end

if ~isempty(index_m12) || mon_is_time
if (~isempty(index_m12) && any(columns{index_m12} <= 0)) || mon_is_time % invalid monitor, use TIME
if (~isempty(index_m12) && any(index_m12 <= 0)) || mon_is_time % invalid monitor, use TIME
[dummy, index]=max(sum(a.Signal(:,index_ti)));
index_m12 = index_ti(index);
end
Expand Down

0 comments on commit 2d2c231

Please sign in to comment.