MATLAB GUI editbox sequence

1 view (last 30 days)
Ahmer Ahmed
Ahmer Ahmed on 17 Apr 2018
Answered: Walter Roberson on 17 Apr 2018
How can I get input sequence using editbox in MATLAB GUI so that I may apply convolution commands on my sequences?
On MATLAB script, I am able to take two sequences using 'input' command and applying 'conv' command. But in MATLAB GUI, when I enter my sequence in editbox, i am getting below errors
Error using specgraph.stemseries/set Array must be numeric or logical.

Answers (1)

Walter Roberson
Walter Roberson on 17 Apr 2018
When you retrieve the String property of the edit box, you will get a character vector or possibly cell array of character vectors. . If that character vector represents numeric data then you need to convert from character to numeric. For scalar values you would use str2double. For non scalar the best thing to use depends on what representations you want to support.

Categories

Find more on Data Type Conversion in Help Center and File Exchange

Tags

Products

Community Treasure Hunt

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

Start Hunting!