I have an array of size 180*10, and I want to find AUC score of values across rows by applying trapz function.How to make loop to integrate across rows?

 Réponse acceptée

Star Strider
Star Strider le 31 Août 2017

0 votes

From the documentation:
  • Q = trapz(_,dim) integrates along the dimension dim using any of the previous syntaxes.
So to integrate across rows, use 2 for ‘dim’.

1 commentaire

KALYAN ACHARJYA
KALYAN ACHARJYA le 1 Sep 2017
Modifié(e) : KALYAN ACHARJYA le 1 Sep 2017
%
X=[ 1 2 3 4 5 7....];
Result=trapz(X,2);
% Gives Integrate result
%

Connectez-vous pour commenter.

Plus de réponses (0)

Catégories

Community Treasure Hunt

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

Start Hunting!

Translated by