Q&A
Ask and answer questions to make information more available to wider audiences.
Kaylee Jones @joneskaylee4   18, Aug 2023 12:00 AM
get the type of a variable
How to get the type of a variable in MATLAB?
answers 1
 
Answer 1
Chance Boorman @boormanchance   31, Aug 2023 10:31 AM
To get the type of variable we use the class function.

>> b = 2
>> a = 'Hi'
>> class(b)
ans =
double
>> class(a)
ans =
char