Hello everyone,
I have a vector HDA which is associated to different lists of angles.
For each list (a1, b1, … etc.) i need to convert all the values in radians and make the circular average together with the standard
deviation with the functions Circ_ang2rad, circ_mean and circ_std.
Then I print the values. Clearly, I don't know how to make a proper loop so if anybody is willing to help I would be most grateful!
It would be also nice to print the result with a 'name' associated to it so that one could understand which result refers to which angle.
a1 = Asn42OH3p(:,1); %List of angles from traiectory for Asn42b1 = Asp44O4p(:,1); %List of angles from traiectrory for Asp44...and so onHDA = [a1 b1 c1 d1 e1 f1 g1];for X = HDA; A_rad = circ_ang2rad(X); A_bar = circ_mean(A_rad); [s_A s0_A] = circ_std(A_rad); fprintf('X torsion'); fprintf('\n') fprintf('Mean resultant vector: \t%.2f \t%.2f\n', circ_rad2ang([A_bar])); end
Best Answer