How can I convert more column vector into cell array
조회 수: 6 (최근 30일)
이전 댓글 표시
Hi
I want to use my imported data for NARX model. Because I want to train my network with two or more vsriables, I have to have a cell array format like this [8,875836;1] [11,025640;1] [9,46135;1] My question is how can I convert more variables to this format?
Thanks, Roland
댓글 수: 0
채택된 답변
추가 답변 (1개)
Wayne King
2014년 2월 6일
편집: Wayne King
2014년 2월 6일
Maybe you need to be more precise
x = randn(1000,1);
x = {x};
Or let's assume you have the column vectors in a matrix
x = randn(1000,10);
x = mat2cell(x,1000,ones(10,1));
The above will put the ten column vectors into a 1x10 cell array.
참고 항목
카테고리
Help Center 및 File Exchange에서 Data Type Conversion에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!