필터 지우기
필터 지우기

Function not returning full matrix

조회 수: 1 (최근 30일)
Rafael
Rafael 2017년 12월 8일
댓글: Rafael 2017년 12월 11일
I have a matrix around 20,000 by 20 and when I use this codes it only returns 1000 by 20. I'm sure the problem has to be on the for loop I just don't know how to get this function to show me the whole matrix.
function ....
i=length(data_2);
for i=1:data_2
fprintf...
.....
end
end
  댓글 수: 13
Rafael
Rafael 2017년 12월 8일
Yes, I understand you were just giving me an example. I did have something inside that, but it is not returning on top of the columns. I copy you exact code for fprintf.
The order is from 10 13 7 up to row 20,000 for rows and columns is from 1 to 20. These codes returned it as 39 3 41 etc.
Rafael
Rafael 2017년 12월 9일
The table is something like this, It goes from column 1 to 20 and row 1 to 20,000.
1 2 3 4 5 6 ... 20
10 13 17 43 76 42... 23
.
.
.
20,000
What I explained is that when I run the code you provided me, it returns those numbers in a different order like this,
1 2 3 4 5 6 ... 20
39 3 41 43 9 56... 1
.
.
.
18,390

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

채택된 답변

Rafael
Rafael 2017년 12월 10일
Okay, now when I do which cssm is working. It tells me where it is saved.
  댓글 수: 5
Rafael
Rafael 2017년 12월 10일
Okay, I changed it. Now when I run cssm(data,colh) it returns the matrix from column 1 to 20 and row 1 to 101. Organized.
Rafael
Rafael 2017년 12월 11일
It returned the strings and the data which looks organized like in the original. However, it return it horizontally which doesn't fit in the command windows. It return and error.

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

추가 답변 (0개)

카테고리

Help CenterFile Exchange에서 Logical에 대해 자세히 알아보기

Community Treasure Hunt

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

Start Hunting!

Translated by