does anyone have the matlab code for removing the negative half of an sinosudal wave

1 次查看(过去 30 天)
i guess there would be an function but i dont know what it is...can anyone help

采纳的回答

the cyclist
the cyclist 2013-2-27
编辑:the cyclist 2013-2-27
If you just have values in a vector, then
s(s<0) = [];
will remove them (leaving you with a vector of shorter length), or
s(s<0) = 0;
will set the negative values to zero, or
s(s<0) = NaN;
will set them to NaN.
If you mean something else, please provide more detail.

更多回答(0 个)

类别

Help CenterFile Exchange 中查找有关 Spectral Measurements 的更多信息

Community Treasure Hunt

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

Start Hunting!

Translated by