crossvalidation.m

来自「GML_AdaBoost_Matlab_ Toolbox」· M 代码 · 共 30 行

M
30
字号
%   The algorithms implemented by Alexander Vezhnevets aka Vezhnick
%   <a>href="mailto:vezhnick@gmail.com">vezhnick@gmail.com</a>
%
%   Copyright (C) 2005, Vezhnevets Alexander
%   vezhnick@gmail.com
%   
%   This file is part of GML Matlab Toolbox
%   For conditions of distribution and use, see the accompanying License.txt file.
%
%   crossvalidation Implements the constructor for crossvalidation class
%~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
%
%    this = crossvalidation(folds)
%    ---------------------------------------------------------------------------------
%    Arguments:
%           folds - number of cross-validation folds
%    Return:
%           this - object of crossvalidation class
function this = crossvalidation(folds)

if( folds == 1)
  error('folds should be >= 2');
end

this.folds = folds;

this.CrossDataSets   = cell(folds, 1);
this.CrossLabelsSets = cell(folds, 1);

this=class(this, 'crossvalidation') ;

⌨️ 快捷键说明

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