+ Reply to Thread
Results 1 to 2 of 2

Partially randomized numbers

  1. #1
    Forum Contributor
    Join Date
    09-13-2011
    Location
    United States
    MS-Off Ver
    Excel 2007
    Posts
    111

    Smile Partially randomized numbers

    Hi All,

    I want to make a VB Script that will allow me to partially randomize numbers. What I mean by this is, I want the script to spit out values, which are defined by a range, and who's frequency is dependent on a standard curve, or probability curve.

    For Instance:
    range 1-100
    values 1-10, 5% of the time
    values 11-90, 20% of the time
    values 91-100, 75% of the time

    Thanks!

  2. #2
    Forum Expert shg's Avatar
    Join Date
    06-20-2007
    Location
    The Great State of Texas
    MS-Off Ver
    2010, 2019
    Posts
    40,689

    Re: Partially randomized numbers

    How about just a formula?

    =CHOOSE(MATCH(RAND(), {0,5,25}%), randbetween(1,10), randbetween(11,90), randbetween(91,100))

    RANDBETWEEN requires the Analysis Toolpak in Excel 2003.
    Entia non sunt multiplicanda sine necessitate

+ Reply to Thread

Thread Information

Users Browsing this Thread

There are currently 1 users browsing this thread. (0 members and 1 guests)

Bookmarks

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts

Search Engine Friendly URLs by vBSEO 3.6.0 RC 1