# Difference between revisions of "Randomization in Excel"

Line 1: | Line 1: | ||

<onlyinclude>This article | <onlyinclude>This article discusses the advantages and disadvantages of randomizing using Excel and also gives a step-by-step guide on randomizing using Excel. </onlyinclude> | ||

== Read First == | == Read First == | ||

If [[Randomization in Stata | randomization using Stata]] is feasible, then it should always be the preferred option as[[Randomization in Stata | randomization in Stata]] is more easily reproducible. | If [[Randomization in Stata | randomization using Stata]] is feasible, then it should always be the preferred option as[[Randomization in Stata | randomization in Stata]] is more easily [[Reproducible Research | reproducible]]. | ||

== Reasons why Stata is always preferable to Excel == | == Reasons why Stata is always preferable to Excel == | ||

Here are | Here are some of the reasons : | ||

*Randomization done in Stata can be better documented through | *Randomization done in Stata can be better documented through files. Every step can be documented which makes it easier to reproduce the results. | ||

*Stata gives us the option of setting which version of Stata we use for randomization. This is useful when different researchers use different versions of Stata. | *[[Stata Coding Practices | Stata]] gives us the option of setting which version of Stata we use for randomization. This is useful when different researchers use different versions of Stata. | ||

*Better documentation and version control | *Better documentation and version control make randomization results in Stata consistent across various runs. | ||

== Advantages and Disadvantages of Randomizing using Excel == | == Advantages and Disadvantages of Randomizing using Excel == | ||

Stata might not be available in some cases. For those cases, the advantages and disadvantages of randomizing using Excel are as follows: | |||

===Advantages=== | ===Advantages=== | ||

Here are some of the advantages of randomizing using Excel : | Here are some of the advantages of randomizing using Excel : | ||

*Balance/stratification can be achieved during | *Balance/stratification can be achieved during randomization using Excel. | ||

*Randomization using Excel is simple to implement and produces a record. | *Randomization using Excel is simple to implement and produces a record. | ||

*Since Excel is widely used, it is commonly understood and used by project staff. | *Since Excel is widely used, it is commonly understood and used by project staff. | ||

Line 20: | Line 20: | ||

Some of the disadvantages of using Excel to randomize are as follows: | Some of the disadvantages of using Excel to randomize are as follows: | ||

*Excel is more mysterious to beneficiaries than public randomization(For example - drawing names from a hat, etc) | *Excel is more mysterious to beneficiaries than public randomization(For example - drawing names from a hat, etc) | ||

*Randomization in Excel is less replicable than [[Randomization in Stata]]. | *Randomization in Excel is less [[Reproducible Research | replicable]] than [[Randomization in Stata]]. | ||

*Since the randomization involves copying and pasting, it can be subject to human errors. | *Since the randomization involves copying and pasting, it can be subject to human errors. | ||

*It is also less flexible to changes in randomization plan. | *It is also less flexible to changes in the randomization plan. | ||

==Steps | ==Steps for Randomization in Excel == | ||

Here are the steps of doing | Here are the steps of doing successful ***randomization using Excel***: | ||

*The first thing that needs to be done is to define a randomization rule. For example = the lowest 50% will be treatment, the rest will be assigned to control, etc. | *The first thing that needs to be done is to define a randomization rule. For example = the lowest 50% will be treatment, the rest will be assigned to control, etc. |

## Revision as of 15:05, 7 July 2022

This article discusses the advantages and disadvantages of randomizing using Excel and also gives a step-by-step guide on randomizing using Excel.

## Read First

If randomization using Stata is feasible, then it should always be the preferred option as randomization in Stata is more easily reproducible.

## Reasons why Stata is always preferable to Excel

Here are some of the reasons :

- Randomization done in Stata can be better documented through files. Every step can be documented which makes it easier to reproduce the results.
- Stata gives us the option of setting which version of Stata we use for randomization. This is useful when different researchers use different versions of Stata.
- Better documentation and version control make randomization results in Stata consistent across various runs.

## Advantages and Disadvantages of Randomizing using Excel

Stata might not be available in some cases. For those cases, the advantages and disadvantages of randomizing using Excel are as follows:

### Advantages

Here are some of the advantages of randomizing using Excel :

- Balance/stratification can be achieved during randomization using Excel.
- Randomization using Excel is simple to implement and produces a record.
- Since Excel is widely used, it is commonly understood and used by project staff.

### Disadvantages

Some of the disadvantages of using Excel to randomize are as follows:

- Excel is more mysterious to beneficiaries than public randomization(For example - drawing names from a hat, etc)
- Randomization in Excel is less replicable than Randomization in Stata.
- Since the randomization involves copying and pasting, it can be subject to human errors.
- It is also less flexible to changes in the randomization plan.

## Steps for Randomization in Excel

Here are the steps of doing successful ***randomization using Excel***:

- The first thing that needs to be done is to define a randomization rule. For example = the lowest 50% will be treatment, the rest will be assigned to control, etc.
- Assign random numbers to each observation. While doing this, use "paste values" to stop recalculating the randomization.

`=rand()`

- Sort the random numbers from the lowest to the highest.
- Created an ordered serial number. If you need to balance the data, then first sort by the strata, then by the random values.
- Assign groups using either the
**mod****if** - Save the record.

## Back to Parent

This article is part of the topic Randomized Control Trials