12345678910111213141516171819202122232425262728293031323334353637 |
- %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
- % G.V. Anguelova %
- % 09-06-2022 %
- % create dummy variable voor test sinus met noise of alleen noise %
- %%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%%
- % Create a 15-by-250-by-18 array of random numbers.
- X = randn([1000,250,18]);
- x = -pi:0.1:pi; % met 0.1 lengte y is 63
- y = sin(x) *15; % *15 zodat het te onderscheiden is ook visueel van X (max(X) rond 3 a 4)
- % add sinus in de eerste 300 signalen
- X_sin = X;
- for i = 1:100
- X_sin(i,1:63,1) = X_sin(i,1:63,1) + y; % eerste epoch; eerste kanaal
- end
- for i = 101:200
- X_sin(i,1:63,2) = X_sin(i,1:63,2) + y; % 2e epoch; 2e kanaal
- end
- for i = 201:300
- X_sin(i,1:63,3) = X_sin(i,1:63,3) + y; % 3e epoch; 3e kanaal
- end
- % X_sin(4,1:63,4) = X_sin(4,1:63,4) + y; % 4e epoch; 4e kanaal
- % X_sin(5,1:63,4) = X_sin(5,1:63,5) + y; % 5e epoch; 5e kanaal
- % export X_sin naar PyCharm als input variabele
- % create output variabele
- A1 = ones(300,1);
- A2 = zeros(700,1);
- Y_sin = [A1; A2]; % onder elkaar
- % export to python
|