⭐ 欢迎来到虫虫下载站! | 📦 资源下载 📁 资源专辑 ℹ️ 关于我们
⭐ 虫虫下载站

📄 setcont.m

📁 toolbox of BVQX, This is the access between BV and matlab. It will help you to analysis data from BV
💻 M
字号:
function setcont(hfile, bc)
% BVQXfile::setcont  - override entire contents of object
%
% FORMAT:       setcont(obj, content)
%
% Input fields:
%
%       obj         non-ROOT BVQXfile object
%       content     1x1 content struct
%
% No output fields.

% Version:  v0.7b
% Build:    7082922
% Date:     Aug-29 2006, 10:29 PM CEST
% Author:   Jochen Weber, Brain Innovation, B.V., Maastricht, NL
% URL/Info: http://wiki.brainvoyager.com/BVQXtools

% argument check
if nargin ~= 2 || ...
    numel(hfile) ~= 1 || ...
    numel(bc) ~= 1 || ...
   ~isBVQXfile(hfile, true) || ...
    hfile.L == 1
    error( ...
        'BVQXfile:BadArgument', ...
        'Invalid object for assignment.' ...
    );
end

% get content first
cc = bvqxfile_getcont(hfile.L);
if numel(fieldnames(cc)) ~= numel(fieldnames(bc)) || ...
   ~all(strcmp(fieldnames(cc), fieldnames(cc)))
    error( ...
        'BVQXfile:BadArgument', ...
        'Mismatching fieldnames, content not set.' ...
    );
end

% assignment
try
    bvqxfile_setcont(hfile.L, bc);
catch
    rethrow(lasterror);
end

⌨️ 快捷键说明

复制代码 Ctrl + C
搜索代码 Ctrl + F
全屏模式 F11
切换主题 Ctrl + Shift + D
显示快捷键 ?
增大字号 Ctrl + =
减小字号 Ctrl + -