Find centralized, trusted content and collaborate around the technologies you use most.
Teams
Q&A for work
Connect and share knowledge within a single location that is structured and easy to search.
でセルを作成します
s = cell(4,4);
今私は2つのエントリを編集したい:
s{1,1:2} = ?? //what do I write here?
私は次のことを試しました: s{1,1:2} = {A,B}; s{1,1:2} = {A;B}; s{1,1:2} = {{A},{B}}; しかし、どれも機能しません。
「この代入の右辺の値が少なすぎて、左辺を満たすことができません。」
これどうやってするの?
前もって感謝します!
使用する
s(1,1:2) = {A,B};
例:
>> s(1,1:3) = {'first','second','third'} s = 'first' 'second' 'third' [] [] [] [] [] [] [] [] [] [] [] [] [] >> A=12 A = 12 >> B=4 B = 4 >> s(1,1:2) = {A,B} s = [12] [4] 'third' [] [] [] [] [] [] [] [] [] [] [] [] []