In this tutorial, we will demonstrate how to easily generate random numbers in Excel. In three easy ways, you can use the RAND() function to generate random numbers with different parameters and customize how many numbers you want to generate.
Step-by-step Guide to Generate Random Numbers In Excel
USING RAND()
- Start by inputting the formula =RAND() in the cell.
- Press ENTER and it will immediately show a random number.
- Drag down the formula to increase the range that you want.
To ensure that the random numbers in the cells don’t change:
- Copy the cells
- On the first cell, press RIGHT CLICK
- Select PASTE OPTION, choose VALUES
This will delete the original formula and retain the values you copied.
Examples
Producing random decimal numbers in the hundreds. In the above example, RAND() always generates decimal numbers from 0 to 1, but you can modify this by changing the formula. To do this, add *100 to the formula to produce random numbers in the hundreds.
Generating random decimal numbers in between the bottom and top values. In the same example, we want to generate decimal numbers in between the bottom and top values. If you have 10000 as the bottom value and 20000 as the top value, you modify the formula by changing it to =10000+10000*RAND() (the top value should be the difference of the two values).
Producing random decimal numbers between 50 and 80. To do this, change the formula to =50+30*RAND() (the difference between 50 and 80 is 30, so this will serve as the top value) and press ENTER.
USING RANDBETWEEN
- Input the formula =RANDBETWEEN( in the cell.
- To generate random numbers between a set of parameters, input the bottom number as the lowest value and the top number as the highest value (For example, =RANDBETWEEN(10000, 20000) will generate random numbers between 10000 and 20000).
- Close the formula with a ).
USING RANDARRAY
- Select the range of cells where you want to display the random numbers.
- Type =RANDARRAY in the formula bar
- Enter the number of rows and columns you want.
- Specify the minimum and maximum value of each number in the array.
- Choose between INTEGERS (TRUE) or DECIMALS (FALSE) in the array.
- Press ENTER.
Conclusion
Generating random numbers in Excel is an easy and convenient process. With the use of the RAND(), RANDBETWEEN, and RANDARRAY functions, you can quickly generate random numbers with specific parameters and manipulate them as needed. Excel offers a straightforward way to generate and view random numbers, making it an optimal choice for those needing to create random numbers.