フィルターのクリア

how to change the logical type matrix into other type

1 回表示 (過去 30 日間)
SHUNSUKE YAMANAKA
SHUNSUKE YAMANAKA 2017 年 10 月 19 日
コメント済み: Stephen23 2017 年 10 月 19 日
Dear Sir or Madam,
I would like to change the logical type matrix into other type ( double , boolean...). But , I can't change it. Otherwise , I tried by using typecast command.
I'm pleased if you let me know.
Sincerely,
  1 件のコメント
Stephen23
Stephen23 2017 年 10 月 19 日
MATLAB does not have a booelan type.

サインインしてコメントする。

採用された回答

Stephen23
Stephen23 2017 年 10 月 19 日
編集済み: Stephen23 2017 年 10 月 19 日
double(M)
where M is your logical matrix. For example:
>> M = [true,false,true]
M =
1 0 1
>> double(M)
ans =
1 0 1

その他の回答 (0 件)

カテゴリ

Help Center および File Exchange数値型 についてさらに検索

Community Treasure Hunt

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

Start Hunting!