Can anyone help me with the water level tank (sltank) example available on Matlab?

What does yData(3:4) mean? it is available in flag==2 S-function code for the water level tank example available by writing in the matlab command: (sltanlk)

 Accepted Answer

There is user data "hidden" in the figure 'tankdemo'. The user data gets extracted into the variable 'yData' by the line
yData=get(tankHndlList(1),'YData');
yData(1) is the offset. yData(3:4) the height. The next lines use yData([3 4]), which means the same.

More Answers (0)

Categories

Find more on Block and Blockset Authoring in Help Center and File Exchange

Tags

Community Treasure Hunt

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

Start Hunting!