Creating a script to take the medain of a row across multiple columns?
Forums
Hello -
I am new to IDEA, and was hoping someone could assist me. I have files in a similar format as below. What I need to do is take the median of Amt1 - Amt5 for each value in the Text column. I created the median field using the excel function and was hoping I would be able to do the same in IDEA.
I've been able to compute the median for individual columns, but have not yet figured out a way to do it across a row.
Thank you in advance.
Thanks Brian. This is
Thanks Brian. This is actually working very nicely. It works great if there are an odd number of fields being used. The only issue I've seen is when there is an even number. The macro pulls the lowest of the two median numbers. For example 1, 3, 7, 9. In this scenario the macro will return 3 as the median instead of 5.
Hi Phil,
Hi Phil,
In this instance you would probably need a script to do this on. Do you always have 5 fields or could the number of fields be variable?
Thanks
Brian