Add a MATLAB Function block to a Simulink® for label prediction. The MATLAB Function block accepts streaming data, and predicts the label and classification score using a trained, support
Products used: Statistics and Machine Learning Toolbox™, MATLAB® Coder™, Simulink®, and Computer Vision Toolbox™.
Generate code from a prediction function that has variable-sized input arguments. Specifically, the example creates a function that predicts labels based on a trained classification
Use a Stateflow® chart for label prediction. The example trains a discriminant analysis model for the Fisher iris data set by using fitcdiscr, and declares a function for code generation