필터 지우기
필터 지우기

Getting a subfunction to return a value as a logical

조회 수: 3 (최근 30일)
D
D 2011년 11월 5일
My sub-function is called from my main function as such...
[m,n] = funk(a,b)
I need m to return as a logical not a double. At the end of the sub-function I use logical(m), but it still returns as a double in the main function. how do I get it to return into the main function as a logical? Thanks

채택된 답변

D
D 2011년 11월 5일
Ok, silly mistake, easy fix.
m = logical(m)

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 Whos에 대해 자세히 알아보기

Community Treasure Hunt

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

Start Hunting!

Translated by