Consulting

Results 1 to 3 of 3

Thread: Solved: Generating a 1 or 0 randomly with frequency l

  1. #1

    Solved: Generating a 1 or 0 randomly with frequency l

    I want to have excel create a random variable, where it equals 1 x% of the time, and 0 (1-X)% of the time. Is there a simple way to do this?

    Thanks again in advance.

  2. #2
    Administrator
    VP-Knowledge Base
    VBAX Grand Master mdmackillop's Avatar
    Joined
    May 2004
    Location
    Scotland
    Posts
    14,489
    Location
    This should give you a 60/40 split. Adjust to suit
    =IF(RAND()>0.6,1,0)
    MVP (Excel 2008-2010)

    Post a workbook with sample data and layout if you want a quicker solution.


    To help indent your macros try Smart Indent

    Please remember to mark threads 'Solved'

  3. #3
    Thanks a ton man!

Posting Permissions

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