Changeset 77 for an2_data_read.m


Ignore:
Timestamp:
Feb 5, 2009, 10:16:41 AM (10 years ago)
Author:
tjniskan
Message:
  • Fixed a strange bug related to resizing Aedes window in Matlab

R2008a (and possibly R2008b and R2009a).

  • Fixed bugs of Voxel TimeSeries? and Overlay Control figure

handles not being properly destroyed on exit.

  • Changed default values for reading VNMR files (now Fast Read is on

by default, output precision is single and data is oriented using
PROCPAR.orient)

  • Fixed a bug in the calculate SNR -plugin
  • Made a temporary workaround for controlling the output in the "View

ROI statistics" -table. A proper GUI implementation will (hopefully) follow
shortly. The output can be controlled by using Aedes preferences. For
example setpref('Aedes','StatPrintDirs?','TXYZV') will print in the
output Total, X-dir, Y-dir, Z-dir and V-dir statistics.

M an2_revision.m
M an2_data_read.m
M an2_resviewer.m
M aedes.m
M an2_res2table.m
M plugins/calculate_snr.m
M an2_readfid.m
M an2_readfidprefs.m
M an2_roi_stats.m

File:
1 edited

Legend:

Unmodified
Added
Removed
  • an2_data_read.m

    r75 r77  
    289289    end
    290290  catch
    291         DATA=[];
    292         error('An error occurred while reading procpar file!')
    293   end
     291    DATA=[];
     292    error('An error occurred while reading procpar file!')
     293  end
     294 
     295  %% Fallback defaults for reading VNMR files
     296  ReadfidReturn = 1;
     297  ReadfidDCcorrection = 'off';
     298  ReadfidZeropadding = 'auto';
     299  ReadfidSorting = 'on';
     300  ReadfidFastRead = 'on';
     301  ReadfidPrecision = 'single';
     302  OrientImages = 'on';
     303  RemoveEPIphaseIm = 'off';
    294304 
    295305  %% Get defaults for Return
    296306  if ispref('Aedes','ReadfidReturn')
    297         ReadfidReturn = getpref('Aedes','ReadfidReturn');
    298   else
    299         ReadfidReturn = 1;
     307    ReadfidReturn = getpref('Aedes','ReadfidReturn');
    300308  end
    301309
    302310  %% Get defaults for DC correction
    303311  if ispref('Aedes','ReadfidDCcorrection')
    304         if getpref('Aedes','ReadfidDCcorrection')
    305           ReadfidDCcorrection = 'on';
    306         else
    307           ReadfidDCcorrection = 'off';
    308         end
    309   else
    310         ReadfidDCcorrection = 'off';
     312    if getpref('Aedes','ReadfidDCcorrection')
     313      ReadfidDCcorrection = 'on';
     314    else
     315      ReadfidDCcorrection = 'off';
     316    end
    311317  end
    312318
    313319  %% Get defaults for Zeropadding
    314320  if ispref('Aedes','ReadfidZeropadding')
    315         if getpref('Aedes','ReadfidZeropadding')==0
    316           ReadfidZeropadding = 'off';
    317         elseif getpref('Aedes','ReadfidZeropadding')==1
    318           ReadfidZeropadding = 'on';
    319         elseif getpref('Aedes','ReadfidZeropadding')==2
    320           ReadfidZeropadding = 'auto';
    321         else
    322           ReadfidZeropadding = 'auto';
    323         end
    324   else
    325         ReadfidZeropadding = 'auto';
     321    if getpref('Aedes','ReadfidZeropadding')==0
     322      ReadfidZeropadding = 'off';
     323    elseif getpref('Aedes','ReadfidZeropadding')==1
     324      ReadfidZeropadding = 'on';
     325    elseif getpref('Aedes','ReadfidZeropadding')==2
     326      ReadfidZeropadding = 'auto';
     327    else
     328      ReadfidZeropadding = 'auto';
     329    end
    326330  end
    327331
    328332  %% Get defaults for Sorting
    329333  if ispref('Aedes','ReadfidSorting')
    330         if getpref('Aedes','ReadfidSorting')
    331           ReadfidSorting = 'on';
    332         else
    333           ReadfidSorting = 'off';
    334         end
    335   else
    336         ReadfidSorting = 'on';
    337   end
    338 
     334    if getpref('Aedes','ReadfidSorting')
     335      ReadfidSorting = 'on';
     336    else
     337      ReadfidSorting = 'off';
     338    end
     339  end
     340 
    339341  %% Get defaults for FastRead
    340342  if ispref('Aedes','ReadfidFastRead')
    341         if getpref('Aedes','ReadfidFastRead')
    342           ReadfidFastRead = 'on';
    343         else
    344           ReadfidFastRead = 'off';
    345         end
    346   else
    347         ReadfidFastRead = 'off';
     343    if getpref('Aedes','ReadfidFastRead')
     344      ReadfidFastRead = 'on';
     345    else
     346      ReadfidFastRead = 'off';
     347    end
    348348  end
    349349 
    350350  %% Get defaults for Precision
    351351  if ispref('Aedes','ReadfidPrecision')
    352         if strcmpi(getpref('Aedes','ReadfidPrecision'),'single')
    353           ReadfidPrecision = 'single';
    354         else
    355           ReadfidPrecision = 'double';
    356         end
    357   else
    358         ReadfidPrecision = 'double';
     352    if strcmpi(getpref('Aedes','ReadfidPrecision'),'single')
     353      ReadfidPrecision = 'single';
     354    else
     355      ReadfidPrecision = 'double';
     356    end
    359357  end
    360358 
Note: See TracChangeset for help on using the changeset viewer.

Powered by Trac 1.0.9.Copyright © Juha-Pekka Niskanen 2008