Problem in randomization

Edward Carney carne006 at umn.edu
Fri Apr 19 15:54:39 UTC 2002


A technique that I've used is to generate external text file lists that
are in an order that you find sufficiently free of clumping.  (It's
curious, isn't it?  True random processes and pseudorandom generators
produce clustering that humans find to be too "orderly" for their tastes
or their experimental needs.)  You may create several of these random
orders and choose one randomly for each participant.

The simplest way is to do this heuristically--you generate a random order
and check it (visually or with a program).  If it looks okay, you keep
it; if it doesn't meet your criteria, you generate lists until you find
one that does.

One simple way to do this is to use Excel.  Set up one column with the
various condition replications.  Set up a column next to it with the RAND
function in each cell.  Then use F9 (Calculate all worksheets) to generate
new random numbers.  Each time you do, sort on the "RandBetween" column
and your items will appear in a "random" order.  When you generate a
random order you're happy with, transfer the randomized items into a
template with all the necessary columns/column names for the E-Prime List
object (Weight, Procedure, etc.) and their data.

You can record a macro to do the randomizing.  Here's mine with the
RandBetween function in Column B:

Sub Macro1()
'
' Macro1 Macro
' Macro recorded 04/19/2002
'
'
    Columns("A:B").Select
    Calculate
    Selection.Sort Key1:=Range("B1"), Order1:=xlAscending, _
Header:=xlGuess, OrderCustom:=1, MatchCase:=False, _
Orientation:=xlTopToBottom
End Sub

Save the Excel file as a Tab-delimited (CSV) file.  This is a file that is
readable by E-Prime.  You then use the option in E-Prime that permits you
to load an external text file into a List object.  You can either generate
a separate ES file for each randomization or have in-line code that
permits you to type the name of the text file into a dialog box and load
it yourself with E-Basic code.

You can also write a program to generate the randomizations.  I've done
this in PERL, but it's doable in AWK, too.

Regards,

Edward Carney
Research Associate
Dept. of Communication Disorders, U of Minnesota

On Fri, 19 Apr 2002, Ice Tsui wrote:

> Hello,
>
> I am a new user of the Eprime.  I have one question to ask about the
> randomization in Eprime.  In my experiment, there are totally 4 different
> kinds of trials, combining together to form a block with 100 trials with each
> kind of trials appear for 25 times.
>
> I found that the randomized events sometimes repeat one kind of trials too
> frequently.  Is there any way to reduce the number of times that one kind of
> trial repeats sequentially?
>
> Thank you very much!!
>
> Best,
> Ice
>
> ______________________________________________________________________
> Tsui Sum Yin Ice
> Mobile: 93221306
> Email: icetsui at graduate.hku.hk
> ______________________________________________________________________
>
>
>



More information about the Eprime mailing list