Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Qlik Open Lakehouse is Now Generally Available! Discover the key highlights and partner resources here.
cancel
Showing results for 
Search instead for 
Did you mean: 
peterkumar
Contributor III
Contributor III

Correlations - PyTools.Pearson

Hello - 

I am new to Qlik Python SSE and am very excited that I can do a time series forecasting with Facebook Prophet.  

Now I am trying to do Correlations - similar to 'PyTools.Pearson('10;12;14', '1;2;3').  

My question is - what chart do I use for it?  A Scatter Plot?  but that needs to measures and one dimension.  I am trying to use a 'Text & Image' chart - but get no output.  

Please suggest.

Thanks!!

Labels (2)
1 Solution

Accepted Solutions
anushree1
Specialist II
Specialist II

Plz chk the attched  , Also the KPI Chart Must appear not sure what the issue is here.

In the attchment I have created a Dummy Dimension Valuelist('Value'), I suppose it must be ok as it does not show up in the chart

 

View solution in original post

3 Replies
anushree1
Specialist II
Specialist II

Plz chk the attched  , Also the KPI Chart Must appear not sure what the issue is here.

In the attchment I have created a Dummy Dimension Valuelist('Value'), I suppose it must be ok as it does not show up in the chart

 

peterkumar
Contributor III
Contributor III
Author

Thanks Anushree!  

Using a KPI worked.  Since I am currently experimenting, the following code worked fine - =PyTools.Correlation('10;12;14','200;20;2', 'kendall')

You have some interesting code in your file - just curious - what are the Transactions and Test tables supposed to do?

Thanks again!!


Transactions:
Load
TransLineID,
TransID,
mod(TransID,26)+1 as Num,
Pick(Ceil(3*Rand1),'A','B','C') as Dim1,
Pick(Ceil(6*Rand1),'a','b','c','d','e','f') as Dim2,
Pick(Ceil(3*Rand()),'X','Y','Z') as Dim3,
Round(1000*Rand()*Rand()*Rand1) as Expression1,
Round( 10*Rand()*Rand()*Rand1) as Expression2,
Round(Rand()*Rand1,0.00001) as Expression3;
Load
Rand() as Rand1,
IterNo() as TransLineID,
RecNo() as TransID
Autogenerate 1000
While Rand()<=0.5 or IterNo()=1;

Comment Field Dim1 With "This is a field comment";

Test:
LOAD @1 as Metric,
RowNo() as Rownum
Resident Transactions;

anushree1
Specialist II
Specialist II

Test table is something I was trying so there is nothing on it .

Rest of the code is the auto generated code which appears when you click on CTRL+0+0 on Edit script window