MATLAB: Testing/training set

codedata transfer from excel to matlabtesting/training

how do i divide my data into testing and training set??whats the easiest way to check whether a sample belongs to a particular class or set??? i have my data saved in excel….

Best Answer

it totally depends on type of dataset. One of the famous technique is Cross validation. Look at this picture for quick idea.
or simply divide 60% dataset for training and 40% for testing. or make it iterative as it is done in cross validation.