Borrar filtros
Borrar filtros

how to extract certain data points from a long array based on certain criteria

2 visualizaciones (últimos 30 días)
veh_velo = [0,0,1,3,7,9,11,15,18,20,19,19...]; accel_pedal = [0,0,2,4,6,9,10,11,12,13,13..]; I want to extract all maximum accel_pedal values whenever veh_velo goes from 0 to 10

Respuesta aceptada

Paolo
Paolo el 16 de Ag. de 2018
Editada: Paolo el 16 de Ag. de 2018
veh_velo = [0,0,1,3,7,9,11,15,18,20,19,19];
accel_pedal = [0,0,2,4,6,9,10,11,12,13,13];
accel_pedal(veh_velo >= 0 & veh_velo<=10)

Más respuestas (0)

Categorías

Más información sobre Matrix Indexing en Help Center y File Exchange.

Etiquetas

Productos


Versión

R2014a

Community Treasure Hunt

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

Start Hunting!

Translated by