I am unable to store values for every iteration, values are overwritten in each iteration.

조회 수: 1 (최근 30일)
how can i get all the values for frame. it is showing only the last value of numimgs ie., 1000. it is being overwritten. i tried using fr(:)=frame(:). but then it show error 'Unable to perform assignment because the left and right sides have a different number of elements'.
thanking in advance for help.

답변 (1개)

infinity
infinity 2019년 7월 25일
Hello,
Try this
fr{Fr} = frame(:);
  댓글 수: 5
karishma koshy
karishma koshy 2019년 7월 25일
편집: karishma koshy 2019년 7월 25일
Hello
I used frame(:) to get the transpose of it. Now I have FR in vertical direction. But it's getting overwritten and saves only the last iteration value ie., 25
Expected answer(in vertical direction 1 1 1 1 1 2 2 2 2 So on 25 25 25 25
Obtained result (in vertical direction) 25 25 25 25 25 25 So on
Thanking you in advance
infinity
infinity 2019년 7월 25일
Hello,
Since you have stored values of frame into "fr". Now, you want to show it like column vector ("fr"), you could simply change type of it by
obtained_result = cell2mat(fr)'

댓글을 달려면 로그인하십시오.

카테고리

Help CenterFile Exchange에서 Matched Filter and Ambiguity Function에 대해 자세히 알아보기

Community Treasure Hunt

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

Start Hunting!

Translated by