필터 지우기
필터 지우기

How random sample rows through many ranges of a matrix and delete from the original one and print in another one?

조회 수: 2 (최근 30일)
I generated a lot of outputs from a DFT rotine and put all of them in a single sheet and imported as a matrix to MATLAB, something like:
U n m erg
0 0,0833 0,0833 -2
0,050 0,08333 0,0833 -2
0,100 0,0833 0,0833 -2
0,150 0,0833 0,0833 -2
...
6 0,0833 0,0833 -2
...
20,00 0,0833 0,0833 -2
It goes from 0 to 20 for each test, so the whole matrix keeps repeating from 0 to 20 until I have almost 20k rows.
What I need is to random sample 40 rows from 0 to 6, then another 40 from 6 to 20, through the whole matrix. I want to able to sample and delete from the original one and print in another matrix.
Is it possible to automatize the whole process and/or is easier if I keep repeating the sampling manually?
Thank you.

답변 (0개)

카테고리

Help CenterFile Exchange에서 Correlation and Convolution에 대해 자세히 알아보기

제품

Community Treasure Hunt

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

Start Hunting!

Translated by