Create new array with repeated values (error k must be less than or equal to N)
조회 수: 6 (최근 30일)
이전 댓글 표시
Trying to create a new array with repeated values .. I tried randperm but can not , as k must be less than or equal to N
clearvars;
clc
org_thick=[.125 .15 .25 .5 1];
new_thick=org_thick(randperm(numel(org_thick),8));
답변 (1개)
참고 항목
카테고리
Help Center 및 File Exchange에서 Workspace Variables and MAT-Files에 대해 자세히 알아보기
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!