Number to a String lookup (val_p_raise_aggressor_pos)

Discuss how to create custom stats, reports and HUD profiles and share your creations.

Moderators: WhiteRider, kraada, Flag_Hippo, morny, Moderators

Number to a String lookup (val_p_raise_aggressor_pos)

Postby kimekii » Fri Jun 07, 2024 6:52 pm

I would like to display position name (CO,BTN) in the hands report instead of an number; just to make report slightly prettier.

hand column: p_raise_aggressor_pos
Code: Select all

hand stat: PF Aggressor
Code: Select all
Posts: 2
Joined: Wed Apr 19, 2023 5:27 am

Re: Number to a String lookup (val_p_raise_aggressor_pos)

Postby Flag_Hippo » Sun Jun 09, 2024 5:24 am

Set the 'Format Type:' of your custom statistic to 'Expression' and you can use an expression in this format:

Code: Select all
if( this = 0, 'BTN', if( this = 1, 'CO', 'x'))

You will need to nest additional IFs within the expression to account for the remaining positions.
Posts: 14800
Joined: Tue Jan 31, 2012 7:50 am

Return to Custom Stats, Reports and HUD Profiles

Who is online

Users browsing this forum: No registered users and 14 guests