More than one prediction using TreeBagger?

7 ビュー (過去 30 日間)
andrea
andrea 2012 年 9 月 29 日
Hi, I'm using TreeBagger to predict an audio genre of a track.
here there's some code I've used for this aim: nTrees = 500; forest = TreeBagger(nTrees,FeaturesNames,datafile2.Genre,'oobvarimp','on','oobpred','on'); [oobP, oobS] = oobPredict(forest); [conf, classorder] = confusionmat(datafile2.Genre,oobP);
[... ... ] after the computation of the features: arrayT = arrayFeatures';
prediction = char(predict(forest,arrayT));
% write my prediction on a file
fwrite(predictionFile,num2str(prediction));
fprintf(predictionFile,'\n');
so there's one prediction for each file.
I'd like to know, as my title says, if there's the possibility of more than one prediction per track. For example I can use an audio track with speech and music consecutive, and I'd like an answer with more than one genre, based on the statistical of the treeBagger.
is there this possibility?
thanks

回答 (0 件)

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by