I -have- searched for a previous post regarding this problem, but came
up with nothing all that useful.
Problem: I need to generate a random item from a list.
I.E.: A1 = alpha
A2 = beta
A3 = gamma
etc.
B1 = RANDOM choice of alpha, beta, or gammaAny help?--
capnsean
------------------------------------------------------------------------
capnsean's Profile: www.excelforum.com/member.php...oamp;userid=25049
View this thread: www.excelforum.com/showthread...hreadid=508969How about: [B1] = OFFSET(A1,RANDBETWEEN(0,2),0)
You'll need to change the quot;2quot; to be the last row of the list you're picking from.
Bill
---------------------------
capnsean wrote:
gt; I -have- searched for a previous post regarding this problem, but came
gt; up with nothing all that useful.
gt;
gt; Problem: I need to generate a random item from a list.
gt;
gt; I.E.: A1 = alpha
gt; A2 = beta
gt; A3 = gamma
gt; etc.
gt;
gt; B1 = RANDOM choice of alpha, beta, or gamma
gt;
gt;
gt; Any help?
gt;
gt;
Hi,
Let's suppose that the list of items (e.g., alpha, beta, gamma, .....) are
in A1:A100. Enter the formula in B1 and auto fill the formula down to the
last row.
=RAND()
In C1 enter the formula
=INDEX($A$1:$A$100,RANK(B1,$B$1:$B$100))
Every time you hit F9 the formula will generate a new random selection from
your list.
Regards,
B. R. Ramachandran
quot;capnseanquot; wrote:
gt;
gt; I -have- searched for a previous post regarding this problem, but came
gt; up with nothing all that useful.
gt;
gt; Problem: I need to generate a random item from a list.
gt;
gt; I.E.: A1 = alpha
gt; A2 = beta
gt; A3 = gamma
gt; etc.
gt;
gt; B1 = RANDOM choice of alpha, beta, or gamma
gt;
gt;
gt; Any help?
gt;
gt;
gt; --
gt; capnsean
gt; ------------------------------------------------------------------------
gt; capnsean's Profile: www.excelforum.com/member.php...oamp;userid=25049
gt; View this thread: www.excelforum.com/showthread...hreadid=508969
gt;
gt;
On Mon, 6 Feb 2006 10:27:17 -0600, capnsean
gt; wrote:
gt;
gt; I -have- searched for a previous post regarding this problem, but came
gt; up with nothing all that useful.
gt;
gt; Problem: I need to generate a random item from a list.
gt;
gt; I.E.: A1 = alpha
gt; A2 = beta
gt; A3 = gamma
gt; etc.
gt;
gt; B1 = RANDOM choice of alpha, beta, or gamma
gt;
gt;
gt; Any help?Try: B1 = OFFSET(A1,INT(3*RAND()),0)
--
Jay.
(remove dashes for legal email address)
- Mar 09 Fri 2007 20:36
Random Item
close
全站熱搜
留言列表
發表留言