Why it is 94? corss-validation for regression tree problem.
조회 수: 1 (최근 30일)
이전 댓글 표시
Hi,
Example shown on the page below.
load carsmall
X = [Acceleration Displacement Horsepower Weight]; % X is 100 by 4.
Mdl = fitrtree(X,MPG); % grow a regression tree using the entire data set.
CVMdl = crossval(Mdl); % cross-validate the regression tree using 10-fold cross-validation
As I looked into CVMdl (the RegressionPartitionedModel cross-validated model), it shows the observation number used in each fold is 94. Why is it 94 not 90? See screenshot below.
Since X is 100 by 4, showing there are 100 observations to start. To have 10 folds, it means they should divide X into 90 training data and 10 test data. So I couldn't figure out why it is 94 training data instead of 90.
Please help.
댓글 수: 0
답변 (0개)
참고 항목
카테고리
Help Center 및 File Exchange에서 Gaussian Process Regression에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!