Reply
 
LinkBack Thread Tools Search this Thread Display Modes
  #1   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 4
Default Random Numbers with certain numbers more common than others

I need to get a random distribution of numbers to simulate a series of events
that will occur between 44%-72% of the time on a weekly basis over the course
of a year. The high and low ends of this range will occur much less often
than the middle of the range, and I want the random numbers to refelct this.

To explain by example, say a person is flipping a coin, but the coin is
rigged to be heads slightly more often than tails, say on average 55% of the
time. You toss this coin 100 times every week, some weeks it will be heads
56% of the time, others 70% of the time, others 45%. However, most of the
weeks the percentage of heads will be between 50% and 60% of the time, and
less frequently it will be heads in the 44-49% or 61-72% ranges.

Is there a way to set up RANDBETWEEN so that it gives random numbers but
they are weighted to return some numbers more frequently than others, i.e.,
it returns 52-60 70% of the time and 44-51 or 59-72 the remaining 30% of the
time?

Thanks for your help. Hope this wasn't too long.
  #2   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 1,549
Default Random Numbers with certain numbers more common than others


The free "Special Randoms" workbook may come close to what you want.
It can create four different sets of random numbers, among them
random numbers that average a specified amount. You enter...
the range (min and max) the Average and the set size.
Numbers are generated in a new workbook.
Download from the Products page at my website - no registration required...
http://www.realezsites.com/bus/primitivesoftware
Your comments and suggestions about the program welcomed.
--
Jim Cone
Portland, Oregon USA
(Excel Add-ins / Excel Programming)




"Steve Kasher"

wrote in message
I need to get a random distribution of numbers to simulate a series of events
that will occur between 44%-72% of the time on a weekly basis over the course
of a year. The high and low ends of this range will occur much less often
than the middle of the range, and I want the random numbers to refelct this.

To explain by example, say a person is flipping a coin, but the coin is
rigged to be heads slightly more often than tails, say on average 55% of the
time. You toss this coin 100 times every week, some weeks it will be heads
56% of the time, others 70% of the time, others 45%. However, most of the
weeks the percentage of heads will be between 50% and 60% of the time, and
less frequently it will be heads in the 44-49% or 61-72% ranges.

Is there a way to set up RANDBETWEEN so that it gives random numbers but
they are weighted to return some numbers more frequently than others, i.e.,
it returns 52-60 70% of the time and 44-51 or 59-72 the remaining 30% of the
time?

Thanks for your help. Hope this wasn't too long.
  #3   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 4
Default Random Numbers with certain numbers more common than others

Thanks, I'll give it a try and let you know how it goes.

"Jim Cone" wrote:


The free "Special Randoms" workbook may come close to what you want.
It can create four different sets of random numbers, among them
random numbers that average a specified amount. You enter...
the range (min and max) the Average and the set size.
Numbers are generated in a new workbook.
Download from the Products page at my website - no registration required...
http://www.realezsites.com/bus/primitivesoftware
Your comments and suggestions about the program welcomed.
--
Jim Cone
Portland, Oregon USA
(Excel Add-ins / Excel Programming)




"Steve Kasher"

wrote in message
I need to get a random distribution of numbers to simulate a series of events
that will occur between 44%-72% of the time on a weekly basis over the course
of a year. The high and low ends of this range will occur much less often
than the middle of the range, and I want the random numbers to refelct this.

To explain by example, say a person is flipping a coin, but the coin is
rigged to be heads slightly more often than tails, say on average 55% of the
time. You toss this coin 100 times every week, some weeks it will be heads
56% of the time, others 70% of the time, others 45%. However, most of the
weeks the percentage of heads will be between 50% and 60% of the time, and
less frequently it will be heads in the 44-49% or 61-72% ranges.

Is there a way to set up RANDBETWEEN so that it gives random numbers but
they are weighted to return some numbers more frequently than others, i.e.,
it returns 52-60 70% of the time and 44-51 or 59-72 the remaining 30% of the
time?

Thanks for your help. Hope this wasn't too long.

  #4   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 1
Default Random Numbers with certain numbers more common than others

You could load up a column with the items repeating as often as you want to
weight them, then just pick a random number between one and the last row
containing data and INDEX into that row. For example, if you wanted your
weighted coin to produce 55% heads and 45% tails, then in some column (say
Column C for this example), put H in the first 55 rows and T in the next 45
rows. Then use this formula to "flip" the coin...

=INDEX(C1:C100,RANDBETWEEN(1,100))

Just load up Column C with whatever you are selecting between, repeat the
numbers you want to occur move frequently whatever number of times that will
give you the percentage weighting you want and adjust the range and top end
of the (max row number) of the RANDBETWEEN function to match.

Rick


"Steve Kasher" wrote in message
...
I need to get a random distribution of numbers to simulate a series of
events
that will occur between 44%-72% of the time on a weekly basis over the
course
of a year. The high and low ends of this range will occur much less
often
than the middle of the range, and I want the random numbers to refelct
this.

To explain by example, say a person is flipping a coin, but the coin is
rigged to be heads slightly more often than tails, say on average 55% of
the
time. You toss this coin 100 times every week, some weeks it will be
heads
56% of the time, others 70% of the time, others 45%. However, most of the
weeks the percentage of heads will be between 50% and 60% of the time, and
less frequently it will be heads in the 44-49% or 61-72% ranges.

Is there a way to set up RANDBETWEEN so that it gives random numbers but
they are weighted to return some numbers more frequently than others,
i.e.,
it returns 52-60 70% of the time and 44-51 or 59-72 the remaining 30% of
the
time?

Thanks for your help. Hope this wasn't too long.


  #5   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 4
Default Random Numbers with certain numbers more common than others

Rick, thanks, looks like your solution does exactly what I was looking for!

"Rick Rothstein (MVP - VB)" wrote:

You could load up a column with the items repeating as often as you want to
weight them, then just pick a random number between one and the last row
containing data and INDEX into that row. For example, if you wanted your
weighted coin to produce 55% heads and 45% tails, then in some column (say
Column C for this example), put H in the first 55 rows and T in the next 45
rows. Then use this formula to "flip" the coin...

=INDEX(C1:C100,RANDBETWEEN(1,100))

Just load up Column C with whatever you are selecting between, repeat the
numbers you want to occur move frequently whatever number of times that will
give you the percentage weighting you want and adjust the range and top end
of the (max row number) of the RANDBETWEEN function to match.

Rick


"Steve Kasher" wrote in message
...
I need to get a random distribution of numbers to simulate a series of
events
that will occur between 44%-72% of the time on a weekly basis over the
course
of a year. The high and low ends of this range will occur much less
often
than the middle of the range, and I want the random numbers to refelct
this.

To explain by example, say a person is flipping a coin, but the coin is
rigged to be heads slightly more often than tails, say on average 55% of
the
time. You toss this coin 100 times every week, some weeks it will be
heads
56% of the time, others 70% of the time, others 45%. However, most of the
weeks the percentage of heads will be between 50% and 60% of the time, and
less frequently it will be heads in the 44-49% or 61-72% ranges.

Is there a way to set up RANDBETWEEN so that it gives random numbers but
they are weighted to return some numbers more frequently than others,
i.e.,
it returns 52-60 70% of the time and 44-51 or 59-72 the remaining 30% of
the
time?

Thanks for your help. Hope this wasn't too long.





  #6   Report Post  
Posted to microsoft.public.excel.worksheet.functions
external usenet poster
 
Posts: 806
Default Random Numbers with certain numbers more common than others

Hello Steve,

I suggest to use my UDF
http://www.sulprobil.com/html/redw.html
or
http://www.sulprobil.com/html/histogrm.html
which have been programmed exactly for this purpose.

Regards,
Bernd
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
getting numbers divisible by 4 from random numbers in ascending order ramana Excel Worksheet Functions 6 June 19th 07 06:41 PM
How to select top six numbers from a of range of random numbers Jack M Taylor Excel Worksheet Functions 4 January 30th 07 09:18 PM
I want random numbers generated without repeating numbers Johncobb Excel Worksheet Functions 2 September 7th 06 04:52 PM
Can Excel pick random numbers from 1-300 and not repeat numbers? Julian Excel Discussion (Misc queries) 1 June 7th 06 07:17 AM
Non-random numbers generated by excel's data analysis random gener Allie Excel Worksheet Functions 10 September 17th 05 06:19 AM


All times are GMT +1. The time now is 07:49 AM.

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"