Drexel dragonThe Math ForumDonate to the Math Forum

Search All of the Math Forum:

Views expressed in these public forums are not endorsed by Drexel University or The Math Forum.

Math Forum » Discussions » Software » comp.soft-sys.matlab

Topic: Another vectorising problem
Replies: 4   Last Post: Aug 9, 1996 12:23 PM

Advanced Search

Back to Topic List Back to Topic List Jump to Tree View Jump to Tree View   Messages: [ Previous | Next ]
O. Haas

Posts: 5
Registered: 12/7/04
Another vectorising problem
Posted: Aug 7, 1996 6:23 AM
  Click to see the message monospaced in plain text Plain Text   Click to reply to this topic Reply

Hi I have a vector of numbers (ideally real number but interger will do)
and I want to find elements that are 'close' to each others, i.e. +/-x%

For example from:
IN= [ 4 1 90 30 20 12 32 21]

I want to determine the integer that are in the range a +/- 2


OUT =[30 32 20 21]

ideally I would like all the elements of a vector to be
different by a margin of at least +/-5 (for example)

so that IN -> OUT=[4 -1 90 30 20 12 35 25]

thanks in advance


Point your RSS reader here for a feed of the latest messages in this topic.

[Privacy Policy] [Terms of Use]

© The Math Forum 1994-2015. All Rights Reserved.