On one slide, show different images, loaded from a list

David McFarlane mcfarla9 at msu.edu
Thu Mar 11 23:47:26 UTC 2010


Vera,

Good.  I just needed better assurance that you had some experience 
with colon syntax, otherwise nothing else I add here will make 
sense.  And let me say first that making a number of pre-arranged 
combinations is a time-honored way of doing things (think back to the 
days of opto-mechanical slide projectors for stimulus presentation), 
so if you get that to work then more power to you.

In the meantime, I also tried the example VisualAttention.es that 
Susan mentioned.  I hope that program does not represent the quality 
of the other STEP offerings (especially since I have referred folks 
to STEP myself) -- First it has a mistake that causes a runtime error 
(though easily fixed), and then the structure seems awfully complex 
for what it needs to do.  It does indeed show a bit of using colon 
syntax to arrange stimuli at random spots in a circle, but then it 
only uses text stimuli, and because of a flaw that remains even in 
EP2 this may crash when you try using pictures in place of text.  Of 
course it may well be that I do not correctly understand the tasks 
here, so let me present the lesson and you tell me where I get it wrong.

Speaking of text vs. pictures, I need you to first work this out with 
text only (no pictures), and then later advance to pictures -- if you 
cannot get the structure to work with plain text, then nothing else 
matters.  Once again, we use the time-honored strategy of "divide and conquer".

So let's simplify this a little more for the sake of 
discussion.  Let's suppose you have only three spots on the screen, 
and you want to randomly assign some text samples to each of those 
three spots.  And to prepare for pictures later, we might as well use 
file names for our example text stimluli (but please, please, do 
*not* use actual picture files yet for this exercise!!).  We start 
with a stimuls Slide in our TrialProc, let's call it StimSlide, with 
three SlideText objects that contain the following (and looking ahead 
to putting our picture files in a subdirectory, as discussed in other threads):

material/[Stim1].png
material/[Stim2].png
material/[Stim3].png

Next, in our TrialList, we have a nested List plus three attributes 
(columns) called Stim1, Stim2, and Stim3, each containing a 
colon-syntax reference to the nested List, something like this (this 
may not line up well in your reader):

Weight  Nested    Procedure  Stim1     Stim2     Stim3
      1  StimList  TrialProc  [Stim:0]  [Stim:1]  [Stim:2]

Almost done.  Now in the nested StimList we add the attribute Stim 
and fill in our actual stimulus items, e.g.,
Stim
circle
square

And we set StimList to Random order.

So how does this all work?  E-Prime shuffles the StimList.  On each 
round, TrialList then picks three new items from StimList, and then 
those go right into the three locations in StimSlide.  See how simple 
that is once you get it all sorted out?  And not a line of code!  You 
just have to grasp the broader underlying concepts and principles of E-Prime.

As I have presented it this should still work for picture files.  If 
you were instead to use only text stimuli then you could leave out 
the extra columns in TrialList and use colon syntax directly in 
StimSlide (but as discussed in the earlier thread, this will fail for 
the special cases of images and sounds in Slides).  Also, you could 
replace "Stim:0" everywhere with simply "Stim", but when I use colon 
syntax I like to leave it in for clarity.

Whew!  You can see why I often have to put people off for awhile, 
because I do have other work to do to.  So give this a whirl if you 
like.  Now it is late here in the U.S. midwest, and I have to get 
home and get ready for tonight's episode of Survivor (US knockoff of 
Expedition Robinson).

-- David McFarlane, Professional Faultfinder
"You got to test that piece of software, You got to test it for yourself,
No one else can test it for you, You got to test it for yourself."
(Apologies to the Fairfield Four)


At 3/11/2010 01:53 PM Thursday, you wrote:
>Hi David,
>
>well about the "I need you to struggle a bit first so that the later
>lesson will "take" " I think I definitely have been struggling a lot
>already and trying every single solution I could think of (including
>scripts, including nested lists, including nested lists with colon
>syntax...). :-)
>
>For the colon syntax by the way, I first thought of this solution too
>(well after I tried the first solution in which I naively expected E-
>Prime to read out 9 different images out of one list (out of one
>column so to say) which is apparently not the case) so I wrote into my
>list that my images (all with the syntax [Image] as filename (and yes,
>I created an attribute "Image" too) should go to the attribute
>[ImageInNestedList:9] in the nested list (which of course also I
>created with an attribute ImageInNestedList). But the same problem
>here too: E-Prime only reads out 1 image out of this list (so one line
>at a time) and then replicates that image 9 times (so yep, I end up
>with 9 times the same image on the slide).
>
>So for the moment, the only solutions I see are:
>
>1. Define a certain number of combinations (let's say 200) and just
>write them into E-Prime.
>2. Write some kind of script
>3. Make let's say 200 different images (fixed with the 9 images).
>
>The last one is by the way the solution I am going to use for the
>moment (a collegue has some script to create 200 random images in no-
>time) as time is running out and we need a "quick and dirty" solution
>rapidly. However, I will keep on trying to get this right, because
>after the pilote-study, this whole test is supposed to communicate
>with our driving simulator (I am not programming this!) so that we can
>control some driving task with the secondary task.
>
>So I still need to find a solution!!!
>
>:-)
>
>
>
>On Mar 11, 3:12 pm, dkmcf <mcfar... at msu.edu> wrote:
> > Vera,
> >
> > Wow, what a discussion this sparked!  I think E-Prime can do what you
> > want in a quite straightforward way using nested Lists without any
> > inline code.  As hinted at the thread that you cited (http://
> > groups.google.com/group/e-prime/browse_thread/thread/
> > 58e3ae402de68442 ), the key is "colon syntax".  So if you do not
> > already have this working, here is another homework assignment for
> > you:  Go to the index in the User's Guide that came with E-Prime and
> > look up "colon syntax", then follow that to the appropriate tutorials
> > and work through all of those.  That might give you enough ideas to
> > figure it out.  But if you remain stuck after that, then refresh this
> > thread some time next week and I will post more details on this
> > approach (I need you to struggle a bit first so that the later lesson
> > will "take").
> >
> > And don't forget PST Web Support, they like to take these sorts of
> > questions athttp://support.pstnet.com/e%2Dprime/support/login.aspand
> > they strive to respond to all requests in 24-48 hours (although
> > reported response time is currently more like 5 days).  If you do
> > contact Web Support then please report back here with the results.
> >
> > -- David McFarlane, Professional Faultfinder
> >
> > On Mar 10, 11:45 am, Vera <vera.d... at googlemail.com> wrote:
> >
> > > I sure hope I will get some help here! I am trying to construct a
> > > visual search task in which participants have to find let's say a
> > > "yellow triangle" within "blue triangles" and "yellow triangles".
> >
> > > For this, I created a list with different conditions (like number of
> > > items on the grid, target present or not) and I was actually counting
> > > on using a slide with (let's say) 9 images, on which I would each of
> > > the 9 images randomly from a nested list.
> >
> > > So I made my nested list with images (.png's) and I of course made
> > > sure to have the image-objects on the slide point first to the
> > > procedure list and then to the nested list (I think I read about all
> > > the messages concerning this topic, including this 
> onehttp://groups.google.com/group/e-prime/browse_thread/thread/84c742b85...
> > > (thanks a lot for the work-around, it was a good thing for me to see
> > > if I did it right, which I did, but it still will not load the right
> > > pictures).
> >
> > > So the problem is: It seems that the "point to the nested list
> > > function" is working, but then it seems impossible to load 9 DIFFERENT
> > > images (it will show me 9 times the same image, at least therewith
> > > confirming that it points to the correct nested list).
> >
> > > And I tried every option I could think of (like putting the 9 images
> > > in one line of the nested list, but then I get other errors). :-( I am
> > > now believing that I should maybe really write to the developers,
> > > simply because this "functionality" seems to be absent.
> >
> > > Now I will probably have to code it (which is were the real problem
> > > starts, because I am an absolute no-programmer ;-) ) and the institute
> > > where I am currently working actually bought E-Prime because it should
> > > be more or less "programming-free" (well ok, I understand you cannot
> > > rule it out completely, but the thing I described above should be
> > > possible in my opinion).
> >
> > > I really hope some of you guys have some creative solution for me!
> >
> > > With kind regards,
> >
> > > Vera
>
>--
>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.

-- 
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