oTree Forum >

Displaying a particular variable when accessing previous rounds:

#1 by Gab21

Hi, I want to access a player variable (REPORT) choice in the previous rounds, but all I can is call the complete player object for the previous rounds which gives me this: "Player(REPORT=True, round_number=1, id_in_group=1)". I would prefer to only display True (player.REPORTA for round_number=1) but I haven't been able to figure it out. 

This is my html code:

<table>
{% for p in subsession.get_players %}
<tr>
<td>{{ p.id_in_subsession}}</td>
<td>{{ p.in_round(1)}}</td><td>{{ p.in_round(2)}}</td><td>{{ p.in_round(3)}}</td><td>{{ p.in_round(4)}}</td><td>{{ p.in_round(5)}}</td>
<td>{{ p.REPORT}}</td>
</tr>
{% endfor %}
</table>

Thanks!

Write a reply

Set forum username