Change value of states "active" to 1 and "rest" to -1

3 ビュー (過去 30 日間)
CalebJones
CalebJones 2019 年 9 月 25 日
コメント済み: CalebJones 2019 年 9 月 25 日
1.JPG
I have attached a mat file for your reference.

採用された回答

madhan ravi
madhan ravi 2019 年 9 月 25 日
stats.state(ismember(stats.state,'rest'),:) = '-1';
stats.state(ismember(stats.state,'active'),:)= '1'

その他の回答 (0 件)

カテゴリ

Help Center および File ExchangeResizing and Reshaping Matrices についてさらに検索

Community Treasure Hunt

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

Start Hunting!

Translated by