欢迎访问教育与发展人口神经科学研究基地!

loadding...
教育与发展人口神经科学研究基地

咨询电话:QQ:81274769

E-Prime实验设计

E-Prime实验设计 您的位置: 首页 > 课程库 > E-Prime实验设计
Inline 语句应用

Inline 语句应用

品牌:省级

咨询电话:QQ:81274769

Inline can help you to dsign a psychological experiment with the style you like!


Several useful E-Basic inline scripts are collected as follow, which will make your design more flexible and intelligent.

Random Display Time:

Stimulus.duration=random(500,1000)

Connect Eprime to ERP:

Open Port(write code before stimulus):

Stimulus.OnsetSignalEnabled=Ture

Stimulus.OnsetSignalPort=&H378

Close Port((write code after stimulus)):

Stimulus.OffsetSignalEnabled=Ture

Stimulus.OffsetSignalPort=&H378

Set Mark:

Stimulus.OnsetSignalData=c.GetAttrib("Code")

Multiple Choice:

if Stimulus.resp="1" or Stimulus.resp="3" then

Write Port &H378, c.GetAttrib("Stimulus.resp")

else

Wite Port &H378,2

end if

Exercise again or not:

1. According to the response by subject

if Stimulus.resp="A" then

goto Lable1

else

goto Label2

end if 

2.According to correct rate.

You should write 2 inline objects:

Inline1:  calculate the correct times in exercise

If stimulus.ACC = 1 then

n=n+1

End if

Inline 2: do formal experiment if correct rate >0.9

If (n/practicelist.size) < 0.9 then

n=0

Goto Label1

Else

Goto Label2

End if

(If you need more details, please click here: Video about practice design )

Subject rest or not:

dim a as Integer

a=c.GetAttrib("List1.sample")

if a mod 50=0 then

msgbox("It is time to rest, you have finished "&int(a/50)&"/10"&", Press SPACE to continue")

end if




标签: