MATLAB Answers

Colorbar not supported in Simulink "MATLAB function" surf plot

조회 수: 4(최근 30일)
I have a custom surf plot written into a "MATLAB function" in simulink environment and I add the 'colorbar' in the plot to see the color division.
However I get the following error, related to the "colorbar" command:
Function 'colorbar' not supported for code generation.
Function 'Beam/MATLAB Function' (#46.1201.1209), line 36, column 60:
Launch diagnostic report.
Component:MATLAB Function | Category:Coder error
How can I add a colobar to my simulink MATLAB function without get such error?

  댓글 수: 0

Sign in to comment.

채택된 답변

Ameer Hamza
Ameer Hamza 4 Jun 2020
편집: Ameer Hamza 4 Jun 2020
Add this line
in the MATLAB function block before the colorbar line.

  댓글 수: 2

Ameer Hamza
Ameer Hamza 4 Jun 2020
I am glad to be of help!

Sign in to comment.

추가 답변(0개)




Translated by