Info

La pregunta está cerrada. Vuélvala a abrir para editarla o responderla.

What is correct variables of H for this code?

1 visualización (últimos 30 días)
Tu Nguyen
Tu Nguyen el 21 de Mzo. de 2022
Cerrada: Cris LaPierre el 21 de Mzo. de 2022
Hi all, this is the code of my professor, what is the correct function of H, I tried many times but the code did not run
load Midterm_Dataset-2
l = 2710
Z = (H(1:l*10));
X = reshape(Z,[l, 10]);[![enter image description here][5]][5]
RV = X*X'/length(X)
%eigen decomposition
[U,D,V] = svd(RV);
figure
stem(diag(D))
title('eigenvalues')
%projection
figure
for i = 1:12
xx0 = V(:,i).*Z(1:l);
subplot(4,3,i)
plot(-xx0)
strr = sprintf('principal component: %d', i);
title(strr)
end
sig = 0;
for i = 11:length(V)
sig = sig + V(:,i).*Z(1:l);
end
figure
plot(sig)
title('Emg data?')
figure
subplot(121)
plot(V(:,11).*Z(1:l))
title('Principal component 11, emg?')
subplot(122)
plot(V(:,12).*Z(1:l))
title('Principal component 12, emg?')

Respuestas (0)

La pregunta está cerrada.

Productos


Versión

R2020b

Community Treasure Hunt

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

Start Hunting!

Translated by