Hello,
I have a question regarding the logfile. The way the data after the experiment is displayed in the excel sheet is very confusing, since numbers and text are mixed together and not clearly linked together
In an earlier version of the experiment we used our own logfile codes in the offline version that worked well.
Examples are:
#End_Routine
save practice data
PractiseFile.write(’%s,%s,%s,%s,%s,%s,%s,%s,%s,%s,%s,%s,%s,\n’ %(Angebot1,Angebot2,Angebot3,self,pool,right1,right2,right3,right4,Player_1_value.getRating(),Player_2_value.getRating(),Player_3_value.getRating(),Player_4_value.getRating())) # all as strings
or
save Trial data
Extralogfile.write(’%s,%s,%s,%s,%s,%s,%s,%s,%s,%s,%s,%s,%s,%s,%s,%s,%s,%s,%s,%s\n’ %(Blocknummer,Angebot1,Angebot2,Angebot3,Eigengebot,punishsource,punishment_1,punishment_2,punishment_3,punishready,rating_3.getRT(),choose_punish_pool.getRT(),punish_1.getRT(),punish_2.getRT(),punish_3.getRT(),trialtimegreatbutton,Trialnummer,expInfo[‘participant’],expInfo[‘condition’],expInfo[‘date’])) # all as strings
Totallogfile.write(’%s,%s,%s,%s,%s,%s,%s,%s,%s,%s,%s,%s,%s,%s,%s,%s,%s,%s,%s,%s\n’ %(Blocknummer,Angebot1,Angebot2,Angebot3,Eigengebot,punishsource,punishment_1,punishment_2,punishment_3,punishready,rating_3.getRT(),choose_punish_pool.getRT(),punish_1.getRT(),punish_2.getRT(),punish_3.getRT(),trialtimegreatbutton,Trialnummer,expInfo[‘participant’],expInfo[‘condition’],expInfo[‘date’])) # all as strings
How can I change this “.write” code from Python into a Javascript code?
I’d be happy if someone could help out with this.