correct answer depending on "group" startup information

Tobi tobias.fw at gmail.com
Wed Sep 16 09:56:42 UTC 2009


Thank you,

that works fine. Unfortunately, in my real experiment (this example
was kept simple due to comprehensiveness) I don't have 2 lines in my
list but 640. I guess there is an easier way than using 640*2 lines in
this InLine. If I understand correctly, "List1.SetAttrib 1" changes
the first line in the list and "List1.SetAttrib 2" changes the second
line.

That means, that the CorrAns value is replaced (see http://chilion.com/probl1.JPG
) no matter if [yes] or [no] was specified. In fact in my real
experiment I also have only two variables. Easiest would be to change
[yes] to let's say "D" and [no] to "F" if c.GetAttrib("group") = 1 and
the other way round if it's 2.

Is that possible?

Thanks already in advance!

Cheers,
Tobias

On 5 Sep., 23:08, Shin-Yi Fang <shinyi.f... at gmail.com> wrote:
> Hi,
>
> I think group is not really a variable. It  is an attribute. You will need
> getattrib function. The following script probably is what you need.
>
> if c.GetAttrib("group") = 1 then
>    List1.SetAttrib 1, "corrAns", "w"
>    List1.SetAttrib 2, "corrAns", "q"
> else
>    List1.SetAttrib 1, "corrAns", "q"
>    List1.SetAttrib 2, "corrAns", "w"
> end if
>
> Best,
>
> Shin-Yi
>
>    List1.SetAttrib 1 "corrAns")yes = "q" and no = "w"
>
>
>
> > if group = 2 then yes = "w" and no = "q"
> On Fri, Sep 4, 2009 at 6:10 PM, Tobi <tobias... at gmail.com> wrote:
>
> > To be more understandable, here are two screenshots, one of the list
> > and one of the InLine:
>
> >http://chilion.com/probl1.JPG
> >http://chilion.com/probl2.JPG
>
> > On 4 Sep., 19:40, Tobi <tobias... at gmail.com> wrote:
> > > Hi everyone,
>
> > > I have a question concerning the "group" variable than can be prompted
> > > for in the beginning of each session. I want to change the correct
> > > answer key according to this group variable (and change the key
> > > assignment as a consequence of corse).
>
> > > In a very easy example there might be a trials with a target or no
> > > target (blank). One group should answer with "w" for TARGET and "q"
> > > for BLANK, the other group the other way round:
>
> > > LIST:
>
> > > ID             Procedure   corrAns
> > > -------------------------------
> > > 1               blank           [no]
> > > 1               target  [yes]
>
> > > I used this InLineas the very first line:
>
> > > dim yes, no
> > > if group = 1 then yes = "q" and no = "w"
> > > if group = 2 then yes = "w" and no = "q"
>
> > > Unfortunately I get the error message "Unknown function "group"".
> > > What does that mean? I am not so familiar with Basic, so any help
> > > might be very cool.
> > > Maybe you have other suggestions to change key assignment by the help
> > > of startup information.
>
> > > Thanks a lot,
> > > Tobias
>
> --
> Ph.D. Student
> Department of Psychology
> University of Connecticut
> and
> Haskins Laboratories
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups "E-Prime" group.
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
-~----------~----~----~----~------~----~------~--~---



More information about the Eprime mailing list