Hello everyone, I need your help.
I have a csv file which contain 100 lines of data with 3 values in each line. When i did csvread function and assigned it a name it resulted in a 100X3 matrix . I want to break data in 2 X3 matrices. I want to save all the set of 50 ( 2X3 matrices) as a variable. Please suggest me some solutions.???

 채택된 답변

KSSV
KSSV 2020년 10월 23일
편집: KSSV 2020년 10월 23일

0 개 추천

A = rand(100,3) ;
[r,c] = size(A);
p = 100/2; % this gives 50
out = permute(reshape(A',[c,r/p,p]),[2,1,3]);

댓글 수: 3

Thanks Brother.It worked
KSSV
KSSV 2020년 10월 23일
Thanks is accepting/ voting the answer.. :)
Sure will do that .. :-)

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

추가 답변 (0개)

카테고리

도움말 센터 및 File Exchange에서 Logical에 대해 자세히 알아보기

태그

질문:

2020년 10월 23일

댓글:

2020년 10월 24일

Community Treasure Hunt

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

Start Hunting!

Translated by