matlab - Showing Variable's Value on Message Box -


this simple problem, have been trying times, not working.

i have code:

[s,h]=silhouette(cobat,g,'sqeuclidean')  ms = mean(s)  z = [cobat s]; 

i want show ms value on message box. message box going this, 'the result [here ms value placed]'

any idea?

you following way:

h = msgbox(['the result ' num2str(ms)], 'title of message box') 

with num2str convert numerical result string, , square brackets concatenate "the result " result display in message box.


Comments

Popular posts from this blog

user interface - Python attempting to create a simple gui, getting "AttributeError: 'MainMenu' object has no attribute 'intro_screen'" -

jquery - Common JavaScript snippet to share files on Google Drive, Dropbox, Box.net or SkyDrive -

Android Gson.fromJson error -