Home > vbmeg > external > mne > mne_write_cov_file.m

mne_write_cov_file

PURPOSE ^

SYNOPSIS ^

function mne_write_cov_file(fname,cov)

DESCRIPTION ^

   function mne_write_cov_file(name,cov)

   Write a complete fif file containing a covariance matrix

   fname    filename
   cov      the covariance matrix to write

CROSS-REFERENCE INFORMATION ^

This function calls: This function is called by:

SOURCE CODE ^

0001 function mne_write_cov_file(fname,cov)
0002 %
0003 %   function mne_write_cov_file(name,cov)
0004 %
0005 %   Write a complete fif file containing a covariance matrix
0006 %
0007 %   fname    filename
0008 %   cov      the covariance matrix to write
0009 %
0010 %
0011 
0012 %
0013 %   Author : Matti Hamalainen, MGH Martinos Center
0014 %   License : BSD 3-clause
0015 %
0016 %   Revision 1.3  2008/10/10 16:13:57  msh
0017 %   Added mne_ex_read_epochs. Fixed help text of mne_write_cov_file.m
0018 %
0019 %   Revision 1.2  2006/05/03 18:53:06  msh
0020 %   Approaching Matlab 6.5 backward compatibility
0021 %
0022 %   Revision 1.1  2006/04/29 12:44:10  msh
0023 %   Added covariance matrix writing routines.
0024 %
0025 %
0026 
0027 me='MNE:mne_write_cov_file';
0028 
0029 global FIFF;
0030 if isempty(FIFF)
0031    FIFF = fiff_define_constants();
0032 end
0033 
0034 fid = fiff_start_file(fname);
0035 
0036 try
0037     mne_write_cov(fid,cov);
0038 catch
0039     delete(fname);
0040     error(me,'%s',mne_omit_first_line(lasterr));
0041 end
0042     
0043 
0044 fiff_end_file(fid);
0045 
0046 return;
0047 
0048 
0049 end

Generated on Mon 22-May-2023 06:53:56 by m2html © 2005