Link to home
Start Free TrialLog in
Avatar of skij
skijFlag for Canada

asked on

ASP.NET / C# / Math: Remove Extreme Numbers from Array

How can I automatically remove all extreme numbers from an array?

For example,
double[] y = {23.2542, 24.25356, 21.89, 25.345, 24.237, 29.2325, 1.52, 99.234, 26.234, 2.53342, 104.2343 };

Open in new window

These numbers are extreme compared to the other numbers in the array:
1.52,
99.234
2.53342
104.2343

A person can look at the numbers in the array and notice that those are extremes, however I would like to use ASP.NET/C# to identify and remove the extreme numbers.
ASKER CERTIFIED SOLUTION
Avatar of Stephen Calabrese
Stephen Calabrese

Link to home
membership
This solution is only available to members.
To access this solution, you must be a member of Experts Exchange.
Start Free Trial
Avatar of skij

ASKER

Thank you, Stephen.  I have posted a related question here:
Avatar of Stephen Calabrese
Stephen Calabrese

Hi skij, I don't see the realted question!