Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
plh
 
Posts: n/a
Default Can I randomise the order of a number of rows?

Hello Excel Gurus,
I have a spreadsheet containing a column of 100 items. I want to change from the
original ordered state to a randomized state. One way would be to create a
randomized column of numbers from 1 to 100 in an adjacent column, such that no
number is repeated, then order the two columns by that list. Is there a way to
do that? If I use RANDBETWEEN(1,100)I am certain to have a lot of numbers
repeated. Is there a way around that?
Thank You,
-plh


--
I keep hitting "Esc" -- but I'm still here!
  #2   Report Post  
Niek Otten
 
Posts: n/a
Default Can I randomise the order of a number of rows?

What's the problem with numbers being repeated? They are still random,
aren't they?
You won't get the same order next time.

--
Kind regards,

Niek Otten

"plh" wrote in message
...
Hello Excel Gurus,
I have a spreadsheet containing a column of 100 items. I want to change
from the
original ordered state to a randomized state. One way would be to create a
randomized column of numbers from 1 to 100 in an adjacent column, such
that no
number is repeated, then order the two columns by that list. Is there a
way to
do that? If I use RANDBETWEEN(1,100)I am certain to have a lot of numbers
repeated. Is there a way around that?
Thank You,
-plh


--
I keep hitting "Esc" -- but I'm still here!



  #3   Report Post  
Peo Sjoblom
 
Posts: n/a
Default Can I randomise the order of a number of rows?

Assume your values are in A1:A100, in B1 put

=RAND()

copy down to B100, select both columns and do datasort and sort by column
B, delete column B


--

Regards,

Peo Sjoblom

"plh" wrote in message
...
Hello Excel Gurus,
I have a spreadsheet containing a column of 100 items. I want to change

from the
original ordered state to a randomized state. One way would be to create a
randomized column of numbers from 1 to 100 in an adjacent column, such

that no
number is repeated, then order the two columns by that list. Is there a

way to
do that? If I use RANDBETWEEN(1,100)I am certain to have a lot of numbers
repeated. Is there a way around that?
Thank You,
-plh


--
I keep hitting "Esc" -- but I'm still here!



  #4   Report Post  
Max
 
Posts: n/a
Default Can I randomise the order of a number of rows?

Another play ..
Assuming items to be shuffled in A1:A100
Put in B1: =RAND()
Put in C1: =INDEX(A:A,RANK(B73,$B$1:$B$100))
Select B1:C1, copy down to C100
Col C returns a random shuffle of items in col A
Just press F9 to generate a new shuffle
--
Rgds
Max
xl 97
---
Singapore, GMT+8
xdemechanik
http://savefile.com/projects/236895
--
"plh" wrote in message
...
Hello Excel Gurus,
I have a spreadsheet containing a column of 100 items. I want to change

from the
original ordered state to a randomized state. One way would be to create a
randomized column of numbers from 1 to 100 in an adjacent column, such

that no
number is repeated, then order the two columns by that list. Is there a

way to
do that? If I use RANDBETWEEN(1,100)I am certain to have a lot of numbers
repeated. Is there a way around that?
Thank You,
-plh


--
I keep hitting "Esc" -- but I'm still here!



  #5   Report Post  
Max
 
Posts: n/a
Default Can I randomise the order of a number of rows?

Oops, pasted the formula from the wrong cell ..

Line:
Put in C1: =INDEX(A:A,RANK(B73,$B$1:$B$100))


should be:
Put in C1:=INDEX(A:A,RANK(B1,$B$1:$B$100))

--
Rgds
Max
xl 97
---
Singapore, GMT+8
xdemechanik
http://savefile.com/projects/236895
--




  #6   Report Post  
plh
 
Posts: n/a
Default Can I randomise the order of a number of rows?

Hello Max,
Thank you, that works swimmingly!
I figured "B73" was an error, translated the whole thing to the correct position
on the form, and ended with: =INDEX($C$14:$C$113,RANK($E14,$E$14:$E$113))
-plh

In article , Max says...

Another play ..
Assuming items to be shuffled in A1:A100
Put in B1: =RAND()
Put in C1: =INDEX(A:A,RANK(B73,$B$1:$B$100))
Select B1:C1, copy down to C100
Col C returns a random shuffle of items in col A
Just press F9 to generate a new shuffle
--
Rgds
Max
xl 97
---
Singapore, GMT+8
xdemechanik
http://savefile.com/projects/236895
--
"plh" wrote in message
...
Hello Excel Gurus,
I have a spreadsheet containing a column of 100 items. I want to change

from the
original ordered state to a randomized state. One way would be to create a
randomized column of numbers from 1 to 100 in an adjacent column, such

that no
number is repeated, then order the two columns by that list. Is there a

way to
do that? If I use RANDBETWEEN(1,100)I am certain to have a lot of numbers
repeated. Is there a way around that?
Thank You,
-plh


--
I keep hitting "Esc" -- but I'm still here!





--
I keep hitting "Esc" -- but I'm still here!
  #7   Report Post  
Max
 
Posts: n/a
Default Can I randomise the order of a number of rows?

You're welcome !
Thanks for the feedback ..
--
Rgds
Max
xl 97
---
Singapore, GMT+8
xdemechanik
http://savefile.com/projects/236895
--
"plh" wrote in message
...
Hello Max,
Thank you, that works swimmingly!
I figured "B73" was an error, translated the whole thing to the correct

position
on the form, and ended with: =INDEX($C$14:$C$113,RANK($E14,$E$14:$E$113))
-plh



Reply
Thread Tools Search this Thread
Search this Thread:

Advanced Search
Display Modes

Posting Rules

Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are On
Pingbacks are On
Refbacks are On


Similar Threads
Thread Thread Starter Forum Replies Last Post
sort rows in alphabetical order and move the corresponding data lianeanddave Excel Worksheet Functions 3 August 26th 05 04:43 PM
formula to use when number of rows changes dynamically confused Excel Worksheet Functions 3 August 17th 05 03:55 PM
Insert a number of rows based on a value in a cell on active row iRocco Excel Discussion (Misc queries) 1 August 11th 05 06:18 AM
Insert a number of rows based on a value in a cell on active row iRocco Excel Worksheet Functions 0 August 10th 05 08:46 PM
how, in excel, can i generate a number, eg consecutive order nos Verity55 Excel Discussion (Misc queries) 1 June 24th 05 11:42 AM


All times are GMT +1. The time now is 01:26 PM.

Powered by vBulletin® Copyright ©2000 - 2025, Jelsoft Enterprises Ltd.
Copyright ©2004-2025 ExcelBanter.
The comments are property of their posters.
 

About Us

"It's about Microsoft Excel"