diff --git a/@dynaload/write.m b/@dynaload/write.m index d6ecfcfc9dbdc9c2d5fa006e4a8e52e95aba5fe5..ab05dc0a14d16714eff39e4b3db773e3b0c23e2c 100644 --- a/@dynaload/write.m +++ b/@dynaload/write.m @@ -132,20 +132,20 @@ for k = keys(self) for m = fieldnames(s)' value = s.(char(m)); if islogical(value) - format = '%d'; + theFormat = '%d'; elseif iscell(value) - format = '%s'; + theFormat = '%s'; elseif isa(value,'char') - format = '%s'; + theFormat = '%s'; % else isa(value,'uint8') - % format = '%u'; + % theFormat = '%u'; elseif isa(value,'integer') - format = '%d'; + theFormat = '%d'; % format %g is used for scientific format 1e36 and %8.8g to write 99999.999 elseif isa(value,'single') - format = '%8.8g'; + theFormat = '%8.8g'; elseif isa(value,'double') - format = '%8.8g'; + theFormat = '%8.8g'; else error('dynaload.write: undefine %s value for member %s', .... char(value), m); @@ -167,7 +167,7 @@ for k = keys(self) else % use strtrim to remove blank (format %8.8g) % ------------------------------------------ - str = strcat(str, strtrim(sprintf(strcat(format, ';'), value))); + str = strcat(str, strtrim(sprintf(strcat(theFormat, ';'), value))); end end end diff --git a/@tsg_nc/save.m b/@tsg_nc/save.m index d04dee69cd14517a7061a659da45f8fd6da7aef0..8e187fa97edf38bbb36272ede218014ca6ec653a 100644 --- a/@tsg_nc/save.m +++ b/@tsg_nc/save.m @@ -55,17 +55,17 @@ for i=1:self.size; for j=1:nb; switch type{j} case 'char' - format = '%s'; + theFormat = '%s'; case 'byte' - format = '%u'; + theFormat = '%u'; case 'integer' - format = '%d'; + theFormat = '%d'; case 'float' - format = '%f'; + theFormat = '%f'; case 'double' - format = '%lf'; + theFormat = '%lf'; otherwise - format = '%s'; + theFormat = '%s'; end switch j @@ -80,7 +80,7 @@ for i=1:self.size; if isempty(value) str = [str, ';']; else - str = [str, sprintf(strcat(format, ';'), value)]; + str = [str, sprintf(strcat(theFormat, ';'), value)]; end end end diff --git a/@tsg_nc/tsg_nc.m b/@tsg_nc/tsg_nc.m index adc0f424a80e674849ac267cd99188932fd3128a..afc0895a7162d1bd4fff108a65254d8cc5ebc2bd 100644 --- a/@tsg_nc/tsg_nc.m +++ b/@tsg_nc/tsg_nc.m @@ -67,11 +67,11 @@ types = textscan(hdr{1}{2},'%s','delimiter',';'); % generate one line format % ------------------------ -format = repmat('%s', 1, numel(members{1})); +theFormat = repmat('%s', 1, numel(members{1})); % read end of file % ---------------- -values = textscan(fid, format, 'delimiter',';'); +values = textscan(fid, theFormat, 'delimiter',';'); % put header and members line to a hash, for next time when saving file % --------------------------------------------------------------------- diff --git a/@tsg_nc/tsg_platform.csv b/@tsg_nc/tsg_platform.csv index f201947b876904d81c032e269ff9bb77a53ff3ba..081613c46bf4783c3f1911f51755de45df2a2117 100644 --- a/@tsg_nc/tsg_platform.csv +++ b/@tsg_nc/tsg_platform.csv @@ -1,8 +1,6 @@ -% tsg_platform.csv: 15 members & 3 lines with data; VERSION = 1.4000 +% tsg_platform.csv: 15 members & 1 lines with data; VERSION = 1.4200 % % id;PLATFORM_NAME;SHIP_CALL_SIGN;SHIP_MMSI;PROJECT_NAME;TYPE_TSG;NUMBER_TSG;TYPE_TINT;NUMBER_TINT;SAMPLING_PERIOD;SSPS_DEPH;SSPS_DEPH_MIN;SSPS_DEPH_MAX;SSTP_DEPH;SSTP_DEPH_MIN;SSTP_DEPH_MAX;DATE_TSG;endl char;char;char;char;char;char;char;char;char;integer;integer;float;float;float;float;float;float;float -#;toucan;;;;;;;;;5;4.000000;6.000000;NaN;NaN;NaN;;# -#;FleurAustrale;;;;;;;;;0;NaN;NaN;NaN;NaN;NaN;;# -#;"MN TOUCAN";;;;;;;;;5;4.000000;6.000000;NaN;NaN;NaN;;# +#;CMA/CGM MATISSE;EGVL5;N/A;SO-SSS;SBE21;N/A;SBE38;N/A;5;0;NaN;NaN;NaN;NaN;NaN;NaN;# diff --git a/compiler/Windows (x86)/tsgqc.prj b/compiler/Windows (x86)/tsgqc.prj index 39030bdb8e2ab121ad8f9c24ba6dc38e429fa91b..0046efa26b74c709171cc5af3ccabc3ad3058a7c 100644 --- a/compiler/Windows (x86)/tsgqc.prj +++ b/compiler/Windows (x86)/tsgqc.prj @@ -1,60 +1,84 @@ +<?xml version="1.0" encoding="UTF-8"?> <deployment-project plugin="plugin.ezdeploy" plugin-version="1.0"> - <configuration build-checksum="2815060340" file="C:\svn\tsg-qc\trunk\compiler\Windows (x86)\tsgqc.prj" location="C:\svn\tsg-qc\trunk\compiler\Windows (x86)" name="tsgqc" preferred-package-location="C:\svn\tsg-qc\trunk\compiler\Windows (x86)\tsgqc\for_redistribution" preferred-package-type="package.type.exe" target="target.ezdeploy.standalone" target-name="MATLAB Compiler for Standalone Applications"> + <configuration target="target.ezdeploy.standalone" target-name="MATLAB Compiler for Standalone Applications" name="tsgqc" location="C:\svn\tsg-qc\trunk\compiler\Windows (x86)" file="C:\svn\tsg-qc\trunk\compiler\Windows (x86)\tsgqc.prj" preferred-package-type="package.type.exe" build-checksum="3510833430" preferred-package-location="C:\svn\tsg-qc\trunk\compiler\Windows (x86)\tsgqc\for_redistribution"> <param.appname>tsgqc</param.appname> - <param.icon /> - <param.icons /> - <param.version>1.42</param.version> <param.authnamewatermark>Jacques Grelet</param.authnamewatermark> <param.email>Jacques.Grelet@ird.fr</param.email> <param.company>IRD</param.company> + <param.icon /> + <param.icons /> <param.summary>TSGQC standalone application. A tool for interactive quality control of sea surface temperature and salinity</param.summary> <param.description>TSGQC is a software for interactive analysis and validation of underway SST / SSS (Sea Surface Temperature and Sea Surface Salinity) measurements from a SeaBird Thermosalinograph (TSG). It has been developed under Matlab.</param.description> <param.screenshot>C:\svn\tsg-qc\trunk\tsg_icon\Thermo.jpg</param.screenshot> + <param.version>1.42</param.version> + <param.namespace>tsgqc</param.namespace> <param.guid /> <param.installpath.string>tsgqc</param.installpath.string> <param.installpath.combo>option.installpath.programfiles</param.installpath.combo> <param.logo /> <param.install.notes /> <param.intermediate>${PROJECT_ROOT}\tsgqc\for_testing</param.intermediate> - <param.files.only>${PROJECT_ROOT}\tsgqc\for_redistribution_files_only</param.files.only> <param.output>${PROJECT_ROOT}\tsgqc\for_redistribution</param.output> - <param.enable.clean.build>false</param.enable.clean.build> - <param.user.defined.mcr.options /> <param.embed.ctf>true</param.embed.ctf> - <param.server.ctf>${PROJECT_ROOT}\tsgqc\for_testing\.ctf</param.server.ctf> - <param.server.readme>${PROJECT_ROOT}\tsgqc\for_testing\readme.txt</param.server.readme> <param.target.type>subtarget.standalone</param.target.type> - <param.support.packages /> - <param.required.mcr.products /> + <param.classorg /> <param.web.mcr>true</param.web.mcr> <param.package.mcr>true</param.package.mcr> <param.no.mcr>false</param.no.mcr> <param.web.mcr.name>TSQQC_Installer_web</param.web.mcr.name> <param.package.mcr.name>TSGQC_AppInstaller_mcr</param.package.mcr.name> <param.no.mcr.name>MyAppInstaller_app</param.no.mcr.name> + <param.user.defined.mcr.options /> <param.windows.command.prompt>false</param.windows.command.prompt> + <param.user.only.registration>false</param.user.only.registration> + <param.mads.no.java>false</param.mads.no.java> + <param.mads.exclusive.mcr>false</param.mads.exclusive.mcr> + <param.net.framework>option.net.framework.default</param.net.framework> + <param.assembly.type>false</param.assembly.type> + <param.encryption.key.file /> + <param.net.enable.remoting>false</param.net.enable.remoting> + <param.net.tsa.enable>false</param.net.tsa.enable> + <param.net.tsa.assembly /> + <param.net.tsa.interface /> + <param.net.tsa.namespace>tsgqc</param.net.tsa.namespace> + <param.net.tsa.superclass /> + <param.net.tsa.metadata /> + <param.net.tsa.metadata.assembly>C:\Users\jgrelet\Documents\MATLAB</param.net.tsa.metadata.assembly> <param.create.log>false</param.create.log> <param.log.file /> <unset> + <param.authnamewatermark /> + <param.email /> + <param.company /> <param.icon /> <param.icons /> + <param.namespace /> <param.guid /> <param.logo /> <param.install.notes /> <param.intermediate /> - <param.files.only /> <param.output /> - <param.enable.clean.build /> - <param.user.defined.mcr.options /> <param.embed.ctf /> - <param.server.ctf /> - <param.server.readme /> <param.target.type /> - <param.support.packages /> - <param.required.mcr.products /> + <param.classorg /> <param.web.mcr /> <param.no.mcr /> <param.no.mcr.name /> + <param.user.defined.mcr.options /> + <param.user.only.registration /> + <param.mads.no.java /> + <param.mads.exclusive.mcr /> + <param.net.framework /> + <param.assembly.type /> + <param.encryption.key.file /> + <param.net.enable.remoting /> + <param.net.tsa.enable /> + <param.net.tsa.assembly /> + <param.net.tsa.interface /> + <param.net.tsa.namespace /> + <param.net.tsa.superclass /> + <param.net.tsa.metadata /> + <param.net.tsa.metadata.assembly /> <param.create.log /> <param.log.file /> </unset> @@ -437,13 +461,12 @@ </fileset.resources> <fileset.package /> <build-deliverables> - <file location="${PROJECT_ROOT}\tsgqc\for_testing" name="splash.png" optional="false">C:\svn\tsg-qc\trunk\compiler\Windows (x86)\tsgqc\for_testing\splash.png</file> - <file location="${PROJECT_ROOT}\tsgqc\for_testing" name="readme.txt" optional="true">C:\svn\tsg-qc\trunk\compiler\Windows (x86)\tsgqc\for_testing\readme.txt</file> - <file location="${PROJECT_ROOT}\tsgqc\for_testing" name="tsgqc.exe" optional="false">C:\svn\tsg-qc\trunk\compiler\Windows (x86)\tsgqc\for_testing\tsgqc.exe</file> + <file name="readme.txt" location="${PROJECT_ROOT}\tsgqc\for_testing" optional="true">C:\svn\tsg-qc\trunk\compiler\Windows (x86)\tsgqc\for_testing\readme.txt</file> + <file name="tsgqc.exe" location="${PROJECT_ROOT}\tsgqc\for_testing" optional="false">C:\svn\tsg-qc\trunk\compiler\Windows (x86)\tsgqc\for_testing\tsgqc.exe</file> </build-deliverables> <workflow /> <matlab> - <root>C:\Program Files (x86)\MATLAB\R2014b</root> + <root>C:\Program Files\MATLAB\R2013b</root> <toolboxes /> </matlab> <platform> @@ -456,10 +479,11 @@ <linux>false</linux> <solaris>false</solaris> <osver>6.1</osver> - <os32>true</os32> - <os64>false</os64> - <arch>win32</arch> + <os32>false</os32> + <os64>true</os64> + <arch>win64</arch> <matlab>true</matlab> </platform> </configuration> -</deployment-project> \ No newline at end of file +</deployment-project> + diff --git a/tsg_io/private/decodeficlabview.m b/tsg_io/private/decodeficlabview.m index 37252ccd2e05b5bef012774fe81f823abb8e45cc..d8d4474ec1e66c95d32dcfffa6915f92ba29f0ba 100644 --- a/tsg_io/private/decodeficlabview.m +++ b/tsg_io/private/decodeficlabview.m @@ -43,7 +43,7 @@ function [date, time, lat, lon, sst, sss, sssStd, cond, condRaw, sog, cog, flow] % Je cree ici la chaine de caractere decrivant le format utilise par % textscan. Modifie par jg avec repmat % -------------------------------------------------------------- - format = repmat(' %s', 1, nPara); + theFormat = repmat(' %s', 1, nPara); % textscan permet de lire a peu pres tout, memes les lignes % incompletes, plus courtes. @@ -53,7 +53,7 @@ function [date, time, lat, lon, sst, sss, sssStd, cond, condRaw, sog, cog, flow] % dans le cas de lignes incompletes textscan n'utilise pas % enptyValue mais une chaine de caracteres vide % ----------------------------------------------------------- - data = textscan(fid, format, 'delimiter', DELIMITER, 'emptyValue', NaN); + data = textscan(fid, theFormat, 'delimiter', DELIMITER, 'emptyValue', NaN); % Remplace les chaines de caracteres vides par des NaN % ---------------------------------------------------- diff --git a/tsg_io/readAsciiSample.m b/tsg_io/readAsciiSample.m index 6b870067580f255598b0cd1005d280b34ae656bf..53fda91aa97e48d037ee46114925a1a12f8c2824 100644 --- a/tsg_io/readAsciiSample.m +++ b/tsg_io/readAsciiSample.m @@ -91,20 +91,20 @@ end % %HEADER YEAR MNTH DAYX hh mm ss % 2 - The 6 Date and time parameters are read in %d % ------------------------------------------------------------- -format = '%d %d %d %d %d %d'; +theFormat = '%d %d %d %d %d %d'; for i = 7 : nHeader if isempty( strfind(char(header(i)), 'TYPE')) && ... isempty( strfind( char(header(i)), 'BOTTLE') ) && ... isempty( strfind( char(header(i)), 'ANALDATE') ); - format = [format ' %f']; + theFormat = [theFormat ' %f']; else - format = [format ' %s']; + theFormat = [theFormat ' %s']; end end % Read the data in a cell % ----------------------- -cellData = textscan( fid, format ); +cellData = textscan( fid, theFormat ); % Convert cell to a structure % --------------------------- diff --git a/tsg_io/readAsciiTsg.m b/tsg_io/readAsciiTsg.m index de3d134b60c22fbce963672f277e74e0c0594003..82aa34688d8c22c8cb4feaa9d00394ce1d586761 100644 --- a/tsg_io/readAsciiTsg.m +++ b/tsg_io/readAsciiTsg.m @@ -116,11 +116,11 @@ end % %HEADER YEAR MNTH DAYX hh mm ss % 2 - The 6 Date and time parametes are read in %d % ------------------------------------------------------------- -format = strcat('%d %d %d %d %d %d', repmat(' %f', 1, nHeader - 6)); +theFormat = strcat('%d %d %d %d %d %d', repmat(' %f', 1, nHeader - 6)); % Read the data in a cell % ----------------------- -cellData = textscan( fid, format ); +cellData = textscan( fid, theFormat ); % Convert cell to a structure % --------------------------- diff --git a/tsg_io/readTsgDataAstrolabe.m b/tsg_io/readTsgDataAstrolabe.m index bc2bad50690caac5cfa3f326db1efa46802e102b..e724bdca3f1620e4b2763be24a956d9bd2ee26f7 100644 --- a/tsg_io/readTsgDataAstrolabe.m +++ b/tsg_io/readTsgDataAstrolabe.m @@ -102,14 +102,14 @@ end % %HEADER YEAR MNTH DAYX hh mm ss % 2 - The 4 Date and time parametes are read in %d % ------------------------------------------------------------- -format = '%d %d %d %d'; +theFormat = '%d %d %d %d'; for i = 5 : nHeader - format = [format ' %f']; + theFormat = [theFormat ' %f']; end % Read the data in a cell % ----------------------- -cellData = textscan( fid, format ); +cellData = textscan( fid, theFormat ); % Convert cell to a structure % --------------------------- diff --git a/tsg_io/readTsgDataNuka.m b/tsg_io/readTsgDataNuka.m index 7fbdffaaf4e95b39a2d8514f9fdd5414efb1c4cb..f000630818b26594cf7a80458a45997843ee539e 100644 --- a/tsg_io/readTsgDataNuka.m +++ b/tsg_io/readTsgDataNuka.m @@ -54,11 +54,11 @@ fprintf('...reading %s : ', filename); % Columns are: % ? ship_name yyyy mm dd HHMM latx lonx ssjt ssps (sstp sstp_qc) % --------------------------------------------------------------------- -format = '%d %s %f %f %f %4c %f %f %f %f %f %d'; +theFormat = '%d %s %f %f %f %4c %f %f %f %f %f %d'; % Read the data in a cell % ----------------------- -cellData = textscan( fid, format ); +cellData = textscan( fid, theFormat ); % Check the file is for NUKA ship % ----------------------------------- diff --git a/tsg_io/readTsgDataOracle.m b/tsg_io/readTsgDataOracle.m index 0dedf1ac4b33edc4166c6f4ae6157ed79e432c55..b29a01676a812467571c05686ea9d1a035f6a79d 100644 --- a/tsg_io/readTsgDataOracle.m +++ b/tsg_io/readTsgDataOracle.m @@ -53,11 +53,11 @@ fprintf('...reading %s : ', filename); % Columns are: % yyyy/mm/dd HH:MM(:SS) latx lonx ssjt ssps ? % ------------------------------------------- -format = '%s %s %f %f %f %f %d'; +theFormat = '%s %s %f %f %f %f %d'; % Read the data in a cell % ----------------------- -cellData = textscan( fid, format ); +cellData = textscan( fid, theFormat ); nrecords=length(cellData{1}); % Fill TSG attributes (extracted from filename) diff --git a/tsg_io/readTsgDataSDF.m b/tsg_io/readTsgDataSDF.m index 1dabcca04c45918fae58bbd0512dfeda7be27a53..28fd33908f444fa38404f070ca0b3de44e43fb98 100644 --- a/tsg_io/readTsgDataSDF.m +++ b/tsg_io/readTsgDataSDF.m @@ -52,11 +52,11 @@ fprintf('...reading %s : ', filename); % Columns are: % ? call_sign cyc_mes yyyymmddHHMM 100*latx 100*lonx 100*ssjt 1000*ssps % --------------------------------------------------------------------- -format = '%s %s %s %s %d %d %d %d %d'; +theFormat = '%s %s %s %s %d %d %d %d %d'; % Read the data in a cell % ----------------------- -cellData = textscan( fid, format ); +cellData = textscan( fid, theFormat ); % Check the file is for a single ship/trip % ---------------------------------------- diff --git a/tsg_io/writeAsciiSample.m b/tsg_io/writeAsciiSample.m index 59f10a635555fc4e724911fed55882e5e65c37ad..c46f9e639580bbc318c328db884ccf9f451e82cd 100644 --- a/tsg_io/writeAsciiSample.m +++ b/tsg_io/writeAsciiSample.m @@ -57,9 +57,9 @@ if choice tsg_data = [year month day hour min fix(sec) tsg.LATX_EXT tsg.LONX_EXT ]; header = 'YEAR MNTH DAYX hh mi ss LATX_EXT LONX_EXT'; - format = '%04d %02d %02d %02d %02d %02d %12.7f %12.7f'; + theFormat = '%04d %02d %02d %02d %02d %02d %12.7f %12.7f'; for i = 1:nbRecords - data(i, :) = sprintf( format, tsg_data(i,:) ); + data(i, :) = sprintf( theFormat, tsg_data(i,:) ); end for i = 1 : length(colParaNo) diff --git a/tsg_io/writeAsciiTsg.m b/tsg_io/writeAsciiTsg.m index 9606a8d1be6884197a137f52327204af736a0647..fbb183626295f282f2546148b98229378f66416a 100644 --- a/tsg_io/writeAsciiTsg.m +++ b/tsg_io/writeAsciiTsg.m @@ -65,7 +65,7 @@ if choice tsg_data = [year month day hour min fix(sec) tsg.LATX mod(tsg.LONX+180,360)-180 ]; header = 'YEAR MNTH DAYX hh mi ss LATX LONX'; - format = '%04d %02d %02d %02d %02d %02d %12.7f %12.7f'; + theFormat = '%04d %02d %02d %02d %02d %02d %12.7f %12.7f'; for i = 1 : length(colParaNo) para = PARA{colParaNo(i)}; @@ -76,13 +76,13 @@ if choice if findstr( '_QC', para) tsg_data = [tsg_data double(tsg.(para))]; - format = [format ' %1d']; + theFormat = [theFormat ' %1d']; elseif findstr( '_FREQ', para) tsg_data = [tsg_data tsg.(para)]; - format = [format ' %f']; + theFormat = [theFormat ' %f']; else tsg_data = [tsg_data tsg.(para)]; - format = [format ' %6.3f']; + theFormat = [theFormat ' %6.3f']; end header = [header ' ' para]; @@ -115,7 +115,7 @@ if choice % -------------- fprintf( fid, '%%HEADER %s\n', header); - fprintf(fid, [format '\n'], tsg_data'); + fprintf(fid, [theFormat '\n'], tsg_data'); % Clear the Workspace % ------------------- diff --git a/tsg_tools/csv2btl.m b/tsg_tools/csv2btl.m index 75e825285f5dcef4391a600b3d8cb376301bcaa0..2842f0eaf6ec9d1631829776acc2164c7fc1d5d2 100644 --- a/tsg_tools/csv2btl.m +++ b/tsg_tools/csv2btl.m @@ -45,9 +45,9 @@ if ~isequal(file, 0) % Je cree ici la chaine de caractere decrivant le format utilise par % textscan % ---------------------------------------------------------------------- - format = []; + theFormat = []; for i = 1:NBELEMENT - format = [format ' %s']; + theFormat = [theFormat ' %s']; end % Ouverture du fichier en lecture '.CSV' @@ -98,7 +98,7 @@ if ~isequal(file, 0) % dans le cas de lignes incompletes textscan n'utilise pas % enptyValue mais une chaine de caracteres vide % ----------------------------------------------------------- - data = textscan(fid, format, 'delimiter', DELIMITER,... + data = textscan(fid, theFormat, 'delimiter', DELIMITER,... 'headerLines', 0 ,... 'treatAsEmpty', ' ',... 'emptyValue', NaN); @@ -268,9 +268,9 @@ if ~isequal(file, 0) % Cree un tableau de caracteres avec toutes les informations % ---------------------------------------------------------- bucket = [year month day hour min sec latitude longitude sss_buck code]; - format = '%04d %02d %02d %02d %02d %02d %12.7f %12.7f %6.3f %d'; + theFormat = '%04d %02d %02d %02d %02d %02d %12.7f %12.7f %6.3f %d'; for i = 1:nbRecords - bucketStr(i, :) = sprintf( format, bucket(i,:) ); + bucketStr(i, :) = sprintf( theFormat, bucket(i,:) ); end % Concatene le type et la date d'analyse diff --git a/tsg_tools/netcdf2tsgqc.m b/tsg_tools/netcdf2tsgqc.m index da8b96f30e8ba51b993a6cbf0038c2f9cf5f7708..7a54b3b200d6fd217027253e542913c89cef94a2 100644 --- a/tsg_tools/netcdf2tsgqc.m +++ b/tsg_tools/netcdf2tsgqc.m @@ -130,7 +130,7 @@ for i = 1 : nfiles %[year, month, day, hour, min, sec] = datevec( julianToDatenum(tsg.DAYD) ); tsg_data = [year month day hour min fix(sec) tsg.LATX mod(tsg.LONX+180,360)-180 ]; header = 'YEAR MNTH DAYX hh mi ss LATX LONX'; - format = '%04d %02d %02d %02d %02d %02d %12.7f %12.7f'; + theFormat = '%04d %02d %02d %02d %02d %02d %12.7f %12.7f'; % Boucle sur les paramètres à sauvegarder % --------------------------------------- @@ -154,10 +154,10 @@ for i = 1 : nfiles tsg.(para)(ind) = 0; end tsg_data = [tsg_data double(tsg.(para))]; - format = [format ' %1d']; + theFormat = [theFormat ' %1d']; else tsg_data = [tsg_data tsg.(para)]; - format = [format ' %6.3f']; + theFormat = [theFormat ' %6.3f']; end header = [header ' ' para]; @@ -187,7 +187,7 @@ for i = 1 : nfiles % Write the file % -------------- fprintf( fid, '%%HEADER %s\n', header); - fprintf( fid, [format '\n'], tsg_data'); + fprintf( fid, [theFormat '\n'], tsg_data'); % Everything OK % -------------