Or you could just toss a coin for each patient.If the first coin is biased towards head, or the second coin is biased towards tail, then the patient is more likely to get placebo, and vice versa.
If you are concerned that your coin may be balanced, toss it twice.
If you get HH or TT toss twice more (repeatedly if needs be).
If you get HT then assign them to the placebo group, if you get TH assign them to the treatment group.
Did you notice that I said "coin" not "coins"?Or you could just toss a coin for each patient.If the first coin is biased towards head, or the second coin is biased towards tail, then the patient is more likely to get placebo, and vice versa.
If you are concerned that your coin may be balanced, toss it twice.
If you get HH or TT toss twice more (repeatedly if needs be).
If you get HT then assign them to the placebo group, if you get TH assign them to the treatment group.
as far as I am concerned a set of 2-digit integers generated by Excel RAND is indeed adequately random, but you still need to filter out duplicates.No you don't.
but it's easy with a random number table because one third will be divisible by 3, one third by 2 but not 3, and one third not divisible by 2 or 3.More generally, you can split them into n sub groups by finding the remainder when you divide by n
I'm sorry for missing the first sentences.Did you notice that I said "coin" not "coins"?Or you could just toss a coin for each patient.If the first coin is biased towards head, or the second coin is biased towards tail, then the patient is more likely to get placebo, and vice versa.
If you are concerned that your coin may be balanced, toss it twice.
If you get HH or TT toss twice more (repeatedly if needs be).
If you get HT then assign them to the placebo group, if you get TH assign them to the treatment group.
It's not me you are arguing with
"John von Neumann invented a simple algorithm to fix simple bias and reduce correlation. It considers two bits at a time (non-overlapping), taking one of three actions: when two successive bits are equal, they are discarded; a sequence of 1,0 becomes a 1; and a sequence of 0,1 becomes a zero. It thus represents a falling edge with a 1, and a rising edge with a 0. This eliminates simple bias, and is easy to implement as a computer program or in digital logic. This technique works no matter how the bits have been generated."
From
https://en.wikipedia.org/wiki/Hardware_random_number_generator#Software_whitening
What would happen if the coin has a strong tendency to flip from the last toss?Then it would be cheating to use it.
Put random numbers into the next column and then sort both columns by the random numberAs Mrs Beeton said, "first catch your rabbit..."
no, just put random numbers in tte h2nd column.Put random numbers into the next column and then sort both columns by the random numberAs Mrs Beeton said, "first catch your rabbit..."
Slightly off the subject (as always) when cooking with my chef son, he once told me to "Just....." and I asked "what exactly do you mean by "just" to which he replied "study and practice for 20 years, then just...." So, to construct 100 random numbers, start with a random number table, then just.....
and as far as I am concerned a set of 2-digit integers generated by Excel RAND is indeed adequately random,
However, Quantum Mechanics presents some evidence that probability is something inherently found in nature. So the answer to your problem is simple. Go down to the Physics lab and get their experimental set up of an electron being fired through some slits and impacting on a screen at the end. Draw a score board on the screen (like a darts board) and have a few games of quantum darts to generate some random numbers.Newest experiment shows that quantum jump can be sensed before actually occuring. It can even be canceled. It's not instantaneous.
Common problem: I need to traceably randomise 100 patients for a clinical trial. So as they are recruited, I assign each one a random number from 00 to 99, then, say, give the trial drug to those with odd numbers and the placebo to the evens.How do I generate those random numbers?While it would be possible to select 100 individuals randomly there is no way to achieve an accurate representation of the population of a country or of the Earth with just 100 individuals so random can not actually be achieved
A. Take two 10-sided dice, one numbered 0 to 9 and the other, 00 to 90. Roll the dice and there's a random two-digit integer for each patient, with a 1 in 100 chance of it being any value from 00 to 99.
B. put 100 counters in a hat, give it a good shake, draw one at a time and discard it: same probability of it being any value from 00 to 99.
What is the probability that I will assign a given number to two patients? In case A, almost 1. In case B, zero.
In case A I cannot guess what the next number will be, so that's really random. In case B, my guess will become more accurate as the numbers are assigned, and I know exactly what the 100th number will be, so it's not quite as random.
It all depends on what you mean by "random".
While it would be possible to select 100 individuals randomly there is no way to achieve an accurate representation of the population of a country or of the Earth with just 100 individuals so random can not actually be achievedIt's more like rounding error, representing population with less bit of information, rather than impossibility to get randomness.
While it would be possible to select 100 individuals randomly there is no way to achieve an accurate representation of the population of a country or of the Earth with just 100 individuals so random can not actually be achievedIt's more like rounding error, representing population with less bit of information, rather than impossibility to get randomness.
Will whoever is keeping a tally of the things Europa doesn't understand please add this one to the list, thanks.While it would be possible to select 100 individuals randomly there is no way to achieve an accurate representation of the population of a country or of the Earth with just 100 individuals so random can not actually be achievedIt's more like rounding error, representing population with less bit of information, rather than impossibility to get randomness.
Again there are too many human variables to represent the population with just 100 people. There are 195 countries in the World so this study would leave out entire groups
While it would be possible to select 100 individuals randomly there is no way to achieve an accurate representation of the population of a country or of the Earth with just 100 individuals so random can not actually be achievedTry reading the first line of the question.
A few weeks ago I was doing a Monte-Carlo simulation (yes, that is a thing!), and needed to generate a lot of random sequences; I was using EXCEL to generate them.
See: https://en.wikipedia.org/wiki/Monte_Carlo_method
There were a number of methods on the web that would generate random numbers "with replacement", but I wanted to do it "without replacement".
- If you are running a clinical trial, you can't give two different patients the same bottle of medicine
- And you don't want any bottles left over at the end
- And you don't want to allocate more people to one arm of the trial than the other
- What you want is a random permutation:
- Randomly assign 100 people to 100 bottles of medicine; once you have assigned a bottle to a person, that bottle is removed from consideration.
- It also works in the opposite direction: once you have assigned a person to a bottle, that person is removed from consideration.
I found a method on the web that is pretty much what bored chemist suggested, generating a random permutation:
- Generate a row of random numbers (however many you need): EXCEL has a RND() function.
- Lookup the list of random numbers and pick the nth largest, using the "LARGE()" function
- Find the index of that entry using the "MATCH()" function
- It seems rather roundabout, but it works well.
- I wanted to generate a hundred random permutations: Just copy the equations 100 times
- I wanted to run the simulation many times with different inputs: Every time you click "Calculate", it generates a new simulation and graphs the results...
This is the method I used: https://superuser.com/questions/972507/can-i-produce-a-row-in-excel-which-is-random-permutation-of-another-row
But I think Alan only wanted to generate 1 random permutation.
Apparently, EXCEL in Microsoft365 has a new RANDARRAY function that can be used to randomly permute a list by coupling it with the SORTBY function:
https://www.ablebits.com/office-addins-blog/2020/07/15/excel-randarray-function-generate-random-numbers/
I thought several ideas had already been presented. Are you looking for some improvement, refinement or continued discussion?I'm looking for a refinement that doesn't include trollish conspiracy theorists.
which was to note that there are different interpretations of "random" within a closed set, some of which may permit (or even guarantee) duplicates.Noted.
As usual, the discussion has moved way off the original point, which was to note that there are different interpretations of "random" within a closed set, some of which may permit (or even guarantee) duplicates.OK. Well then let's briefly discuss the notion of "random" again.
A random variable X is a measurable function X : Ω → E from a set of possible outcomes Ω to a measurable space E. The technical axiomatic definition requires Ω to be a sample space of a probability triple ( Ω , F , P ).
The probability that X takes on a value in a measurable set S ⊆ E is written as
P ( X ∈ S ) = P ( { ω ∈ Ω ∣ X ( ω ) ∈ S } )[Based on Wikipedia entry for "Random variable"