Filter Player Report by note colour?

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

Moderators: WhiteRider, kraada, Flag_Hippo, morny, Moderators

Filter Player Report by note colour?

Postby 00gamblor00 » Sat Jun 14, 2014 2:15 pm

Hi,

Is there a way to add a filter to an all players report so that only players with a certain note colour are included?

Thanks
00gamblor00
 
Posts: 7
Joined: Thu Jul 03, 2008 6:03 am

Re: Filter Player Report by note colour?

Postby kraada » Sun Jun 15, 2014 10:19 am

Unfortunately there isn't an easy way to do this at this time.
kraada
Moderator
 
Posts: 54431
Joined: Wed Mar 05, 2008 2:32 am
Location: NY

Re: Filter Player Report by note colour?

Postby pasita » Mon Jun 16, 2014 3:30 pm

Seems to work at least in the default all player report, add to Expression Filters:

2 in (select id_color from notes where id_x=cash_hand_player_statistics.id_player)

where 2 means green, 8 is orange, for example. YMMV, run some checks if you plan to trust this for money's worth. Let me know if you find a problem.
pasita
 
Posts: 605
Joined: Tue May 06, 2008 4:05 pm

Re: Filter Player Report by note colour?

Postby expiat » Sun Nov 27, 2016 10:04 am

Hi, the expression that pasita wrote works perfecty, but if we want to exclude some colours like NOT 5 in then its not working..expression is valid but doesnt do anything!
Basicaaly i ask to exclude so to see the players that are uncoloured!!

Any way to solve it?

Thanks in advance!
expiat
 
Posts: 13
Joined: Sun Aug 25, 2013 11:06 am

Re: Filter Player Report by note colour?

Postby WhiteRider » Mon Nov 28, 2016 4:05 am

This works for me:

2 not in (select id_color from notes where id_x=cash_hand_player_statistics.id_player)
WhiteRider
Moderator
 
Posts: 53972
Joined: Sat Jan 19, 2008 7:06 pm
Location: UK

Re: Filter Player Report by note colour?

Postby noxee » Sun Nov 26, 2017 11:09 pm

WhiteRider wrote:This works for me:

2 not in (select id_color from notes where id_x=cash_hand_player_statistics.id_player)


Hi, how can I exclude 3 color code ?

Include seems work (10k hands to approx. 5k hands> seems fine) :
Code: Select all
1 in (select id_color from notes where id_x=tourney_hand_player_statistics.id_player)
OR 2 in (select id_color from notes where id_x=tourney_hand_player_statistics.id_player)
OR 6 in (select id_color from notes where id_x=tourney_hand_player_statistics.id_player)


But not exclude (10k hands to approx 15k hands > :shock: ) :
Code: Select all
1 not in (select id_color from notes where id_x=tourney_hand_player_statistics.id_player)
AND 2 not in (select id_color from notes where id_x=tourney_hand_player_statistics.id_player)
AND 6 not in (select id_color from notes where id_x=tourney_hand_player_statistics.id_player)


"Filter on Active Player" is untick for both filters
I use also basic filters : this month / 50€ BI / 2player only


Thanks
noxee
 
Posts: 16
Joined: Tue Feb 07, 2017 7:21 pm

Re: Filter Player Report by note colour?

Postby Flag_Hippo » Mon Nov 27, 2017 8:33 pm

'AND' will not work because a player cannot be yellow AND green AND Red e.t.c. If you change 'AND' to 'OR' that's problematic too because if you do NOT Yellow or NOT Green you will still get yellow and green players because yellow players are not green and vice versa. The easiest thing to do is filter for the colors you do want in your expression but if you want to create a filter expression for this you can do that with a custom column:

player_color=
Code: Select all
CASE WHEN (SELECT id_color FROM notes WHERE id_x = player.id_player) IS NULL THEN -1 ELSE (SELECT id_color FROM notes WHERE id_x = player.id_player) END

and then you can use a filter expression like this:
Code: Select all
player_color not in (-1,1,2,3)

where -1 means no color.
Flag_Hippo
Moderator
 
Posts: 14507
Joined: Tue Jan 31, 2012 7:50 am

Re: Filter Player Report by note colour?

Postby noxee » Fri Mar 23, 2018 1:47 pm

Hi,

Can I do that with PT4 : my winrate vs some type of players (using note color) when I have specifically hands ?

eg. my winrate vs recs when I push K8-K2 (HU 7-13deep)

Thanks.
noxee
 
Posts: 16
Joined: Tue Feb 07, 2017 7:21 pm

Re: Filter Player Report by note colour?

Postby Flag_Hippo » Sun Mar 25, 2018 3:11 pm

That would be more complex to filter for and is beyond my own knowledge.
Flag_Hippo
Moderator
 
Posts: 14507
Joined: Tue Jan 31, 2012 7:50 am

Re: Filter Player Report by note colour?

Postby noxee » Sun Mar 25, 2018 7:59 pm

Flag_Hippo wrote:That would be more complex to filter for and is beyond my own knowledge.


But it's really doable via PT4 ? Or only via PostgreSQL ?

Thx.
noxee
 
Posts: 16
Joined: Tue Feb 07, 2017 7:21 pm

Next

Return to Custom Stats, Reports and HUD Profiles

Who is online

Users browsing this forum: No registered users and 35 guests

cron