필터 지우기
필터 지우기

how loop output store

조회 수: 1 (최근 30일)
sonu
sonu 2013년 4월 18일
hi
i have loop output in terms of price after every loop i got the price value ...how can i see this price value in table form..in continuous manner store in one veritable...

채택된 답변

Iman Ansari
Iman Ansari 2013년 4월 18일
편집: Iman Ansari 2013년 4월 18일
Hi. What is the size of your price value in each loop:
for i=1:n
% if it is a number
output(i,1)=price;
% if it is a column vector
output(:,i)=price;
% if it is a row vector
output(i,:)=price;
% if it is a matrix or its size changes in each loop
output{i}=price;
end
  댓글 수: 1
sonu
sonu 2013년 4월 25일
THNX

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

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 Loops and Conditional Statements에 대해 자세히 알아보기

태그

Community Treasure Hunt

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

Start Hunting!

Translated by