Skip to main content
Announcements
Have questions about Qlik Connect? Join us live on April 10th, at 11 AM ET: SIGN UP NOW
cancel
Showing results for 
Search instead for 
Did you mean: 
suraj_qlik
Contributor II
Contributor II

Single filter for multiple fields

Hello Guys, 

I have 3 tables as shown:

KPI_1Correlation_1P_value_1
A0.40.07
B0.50.01
KPI_2Correlation_2P_value_2
A0.40.07
B0.50.01
KPI_3Correlation_3P_value_3
A0.40.07
B0.50.01

So I want a single correlation filter and single P_Value filter as below: if correlation1 or correlation_2 or correlation_3 >=0.8,"Good correlation", if correlation1 or correlation_2 or correlation_3 <=0.8,"Bad correlation" and similarly for P_value 1,2,3<=0.05,'"Significant" and P_value 1,2,3>0.05,'"Not Significant" 

Please help me. 

Labels (1)
1 Solution
3 Replies
JordyWegman
Partner - Master
Partner - Master

Hi,

You can create an IF formula to get this to work. You have already written out how the logic should work.

Jordy

Climber

Work smarter, not harder
Saravanan_Desingh

Try this,

tab1:
LOAD KPI_1 As KPI,* INLINE [
    KPI_1, Correlation_1, P_value_1
    A, 0.4, 0.07
    B, 0.5, 0.01
    C, 0.9, 0.01    
];

Left Join(tab1)
LOAD KPI_2 As KPI,* INLINE [
    KPI_2, Correlation_2, P_value_2
    A, 0.4, 0.07
    B, 0.5, 0.01
    C, 0.1, 0.01   
];

Left Join(tab1)
LOAD KPI_3 As KPI,* INLINE [
    KPI_3, Correlation_3, P_value_3
    A, 0.4, 0.07
    B, 0.5, 0.01
    C, 0.1, 0.01   
];

Left Join(tab1)
LOAD KPI,
 If(RangeMax(Correlation_1, Correlation_2, Correlation_3)>=0.8, 'Good correlation', 'Bad correlation') As Cor_Result,
 If(RangeMin(P_value_1, P_value_2, P_value_3)<=0.05, 'Significant', 'Not Significant') As Val_Result
Resident tab1;