Nice conditionals! The lines between the <% if %> <% else %> <% end %>  will be rendered accordingly so you could just write plain html 
<% if row.values[3] == 'm' %>
male
<% else %>
female
<% end %>