Rondomized Responses

Anne-Wil liwenna at gmail.com
Tue Jul 17 22:55:42 UTC 2012


Hi Newbie,

I believe the problem lies with this line: Encoding2List.SetAttrib i, 
"IntegrationResp", response

You're very close when you suspect 'i'. Note the 'i' in the above mentioned 
line? What it does is write the response that is given (response) into the 
attribute "integrationResp" of the list called "Encoding2List" at the i'th 
level. So.... during trial1 of the EncodingList1 'i'= 1, and the response 
is therefore written to the first (ith) level of Encoding2List. Since 
Encodinglist is, at that point, already randomized, the response is coded 
into the same listlevel (= info for a single trial) as the randomly chosen 
stimulusword for the i'th trial of that second list. Therefore the 
responses appear in the same order as given in the first round, whereas the 
stimuluswords do not. 

If the first list is not in a random order, than you could set the 
secondlist to sequential order too and randomize it with an inline AFTER 
the responses in the first round have been coded into the attribute 
"integrationresp". However, it is unlikely that your first round is not 
randomized and if I understand your code correctly, there is even a third 
round. 

So... instead.... I think you could store the responses given into an array 
that consists of two columns and as many rows as you have trials in a 
round, but this requires a bit more code. I'll ramble something down that 
is NOT tested and might therefore not work at all (and will need some 
modifications from your side anyways - but I got this impression that you 
know your way around code and this might be just the push that gets you on 
track again). 

****
Dim StoreResponseArray (numberoftrials -1, 2) as string
****
^ that one defines the array as having a numberoftrials-1 number of levels 
and 2 (or 3... columns) and it should be on the usertab of the 
scriptwindow; the -1 thingy is because level 0 is also taken into account 
and you would then end up with an 'empty' trial later on. The 'bonus' 
0-column won't pose a problem. 

Then, starting from the code you provided, I'd end up with:

****
IntegrationString = Integration.RESP
IntegrationString = ReplaceString(IntegrationString, "{SPACE}", " ")
IntegrationString = ReplaceString(IntegrationString, "{SHIFT}", "")
IntegrationString = ReplaceString(IntegrationString, "{ENTER}", " ")
IntegrationString = ReplaceString(IntegrationString, "{,}", ",")
IntegrationString = ReplaceString(IntegrationString, "{.}", ".")
IntegrationString = ReplaceString(IntegrationString, "{F1}", "")
IntegrationString = ReplaceString(IntegrationString, "{!}", "")
IntegrationString = ReplaceString(IntegrationString, "{'}", "")
IntegrationString = ReplaceString(IntegrationString, "{(}", "")
IntegrationString = ReplaceString(IntegrationString, "{)}", "")
IntegrationString = ReplaceString(IntegrationString, "{/}", "")
IntegrationString = ReplaceString(IntegrationString, "{?}", "")
IntegrationString = ReplaceString(IntegrationString, "{:}", "")
IntegrationString = ReplaceString(IntegrationString, "{;}", "")
c.SetAttribAtSource "IntegrationResp", IntegrationString

For i = 1 to numberoftrials
StoreResponseArray (i-1,2) = Encoding1List.GetAttrib(i, "IntegrationResp")
StoreResponseArray (i-1,1) = Encoding1List.GetAttrib(i, "STIMULUSATTRIBUTE")
Next i

****

^ this code goes after EncodingList1. Following this code, the 
StoreResponseArray contains all the stimuluswords in the 1th collumn (which 
might actually be the second because it starts counting at 0, but that on a 
side note) while the values of integrationresp are now stored in the second 
(third...) column. It has again a -1 construction; as opposed to the 
previous one (where you should just give in 49 if you have 50 trials etc) 
this "i-1" construction should be kept in the code (due to the i = 1 to 
numberoftrials thing). 

The array can than be randomized, which will result in the order of the 
levels getting randomized, but the pairs between the two columns remaining 
together, after which you can use the info to (re)fill the encoding2list, 
and after that randomize it's order:

*********
RandomizeArray StoreResponseArray

For i = 1 to numberoftrials

Encoding2List.SetAttrib i, "STIMULUSWORDS", StoreResponseArray (i-1, 1)

Encoding2List.SetAttrib i, "IntegrationResp", StoreResponseArray (i-1, 2)
 
next i

Encoding2List.random  (<= pretty sure this is not the right command - but 
got no e-prime at hand to check what it should be, some line that tells 
e-prime to randomize that list)

Encoding2List.reset

***

I think that that should work....  now the previous given answer should be 
in the Encoding2List at the same level as the stimulus it was given to. 

Good luck! Please let me know if/when you got it to work (and also if not 
:) ).

Best,

liw

On Tuesday, 17 July 2012 22:02:18 UTC+2, newbie wrote:
>
> Hi all,I'm currently working on a research about involuntary memory and we 
> have been using Eprime to present picture-sound pairs.
> The participants are asked to look at the picture and hear the sound, and 
> type a sentence that comes to their mind. 
> They go through this process twice, and the order of picture-sound pairs 
> are different in two lists, so that we can make sure the "memory" is not 
> affected by the order. When they see and listen to the sound for the second 
> time, they're asked to modify their sentences from the first round and we 
> present the response from the first round as well (so that they can see 
> what they typed initially and modify if they want)
>
> However, the problem is that the responses they typed for the first list 
> appear in the same order in the next list while the picture-sound pairs are 
> in a different order. 
> So for example, if Participant A typed "dog" for his first answer during 
> the first round, "dog" would appear as the previous answer for his first 
> picture-sound pairing for the second round even if the picture-sound pair 
> that's presented to him would be a different pair from the first experiment.
>
>
>
> The code for this is,
> *
> First list*
>
> IntegrationString = Integration.RESP
> IntegrationString = ReplaceString(IntegrationString, "{SPACE}", " ")
> IntegrationString = ReplaceString(IntegrationString, "{SHIFT}", "")
> IntegrationString = ReplaceString(IntegrationString, "{ENTER}", " ")
> IntegrationString = ReplaceString(IntegrationString, "{,}", ",")
> IntegrationString = ReplaceString(IntegrationString, "{.}", ".")
> IntegrationString = ReplaceString(IntegrationString, "{F1}", "")
> IntegrationString = ReplaceString(IntegrationString, "{!}", "")
> IntegrationString = ReplaceString(IntegrationString, "{'}", "")
> IntegrationString = ReplaceString(IntegrationString, "{(}", "")
> IntegrationString = ReplaceString(IntegrationString, "{)}", "")
> IntegrationString = ReplaceString(IntegrationString, "{/}", "")
> IntegrationString = ReplaceString(IntegrationString, "{?}", "")
> IntegrationString = ReplaceString(IntegrationString, "{:}", "")
> IntegrationString = ReplaceString(IntegrationString, "{;}", "")
> c.SetAttribAtSource "IntegrationResp", IntegrationString
>
> For i = 1 to Encoding1List.Size
> response = Encoding1List.GetAttrib(i, "IntegrationResp")
> Encoding2List.SetAttrib i, "IntegrationResp", response
> Next i
>
>
> *Second list*
>
> Integration2String = Integration2.RESP
> Integration2String = ReplaceString(Integration2String, "{SPACE}", " ")
> Integration2String = ReplaceString(Integration2String, "{SHIFT}", "")
> Integration2String = ReplaceString(Integration2String, "{ENTER}", " ")
> Integration2String = ReplaceString(Integration2String, "{,}", ",")
> Integration2String = ReplaceString(Integration2String, "{.}", ".")
> Integration2String = ReplaceString(Integration2String, "{F1}", "")
> Integration2String = ReplaceString(Integration2String, "{!}", "")
> Integration2String = ReplaceString(Integration2String, "{'}", "")
> Integration2String = ReplaceString(Integration2String, "{(}", "")
> Integration2String = ReplaceString(Integration2String, "{)}", "")
> Integration2String = ReplaceString(Integration2String, "{/}", "")
> Integration2String = ReplaceString(Integration2String, "{?}", "")
> Integration2String = ReplaceString(Integration2String, "{:}", "")
> Integration2String = ReplaceString(Integration2String, "{;}", "")
>
> c.SetAttribAtSource "Integration2Resp", Integration2String
>
>
> For i = 1 to Encoding2List.Size
> response = Encoding2List.GetAttrib(i, "IntegrationResp")
> Encoding3List.SetAttrib i, "IntegrationResp", response
> Next i
>
>
>
>
> I feel like the problem would be resolved if I correct my "i= _____" but 
> I've been keep failing to make the right modification for the code.
> It will be great if you could let me know how I would be able to fix it!
>
> Thank you so much
>
>

-- 
You received this message because you are subscribed to the Google Groups "E-Prime" group.
To view this discussion on the web visit https://groups.google.com/d/msg/e-prime/-/c-s6vRt5L0wJ.
To post to this group, send email to e-prime at googlegroups.com.
To unsubscribe from this group, send email to e-prime+unsubscribe at googlegroups.com.
For more options, visit this group at http://groups.google.com/group/e-prime?hl=en.

-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://listserv.linguistlist.org/pipermail/eprime/attachments/20120717/ed557821/attachment.htm>


More information about the Eprime mailing list