Readonly: Operands to the || and && operators must be convertable to logical scalar values. is eqal3, 153
조회 수: 1 (최근 30일)
이전 댓글 표시

Hi, Can any one have idea, how to resolve it. This is freqently appearing when I run my code.
댓글 수: 0
답변 (1개)
Aravind Ravikumar
2019년 6월 20일
You get this when one or both operands are arrays. E.g.,
>> [1 2 3] && [4 5 6]
Operands to the || and && operators must be convertible to logical scalar values.
Check the two expressions or variables you are using for the || or && operation. You are using them as scalars but they are not.
댓글 수: 2
Aravind Ravikumar
2019년 6월 20일
The only way I can imagine the error being genereted is cause of z_c(k,1).size(1,x) not being a scalar. Could you maybe try logging that before the if statements? Also, could you try using z_c(k).size(x) instead?
참고 항목
카테고리
Help Center 및 File Exchange에서 EEG/MEG/ECoG에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!
