<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Re: add python script to Qlick sense in Integration, Extension &amp; APIs</title>
    <link>https://community.qlik.com/t5/Integration-Extension-APIs/add-python-script-to-Qlick-sense/m-p/1705043#M14649</link>
    <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;I have the same query.&lt;/P&gt;&lt;P&gt;&lt;a href="https://community.qlik.com/t5/user/viewprofilepage/user-id/46628"&gt;@sunny_talwar&lt;/a&gt;&amp;nbsp; can you please help us out.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Varun&lt;/P&gt;</description>
    <pubDate>Tue, 26 May 2020 06:55:55 GMT</pubDate>
    <dc:creator>Varun1</dc:creator>
    <dc:date>2020-05-26T06:55:55Z</dc:date>
    <item>
      <title>add python script to Qlick sense</title>
      <link>https://community.qlik.com/t5/Integration-Extension-APIs/add-python-script-to-Qlick-sense/m-p/1700419#M14648</link>
      <description>&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;I'm new to Qlick sens, I'm trying to add a python script to Qlick sense.&lt;/P&gt;&lt;P&gt;i want to make an app that allows to impute missing data to xlsx file using sickit learn imputers and then make data visualization , my python code looks&amp;nbsp; like:&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;LI-CODE lang="python"&gt;# features selection then,
imputer=  IterativeImputer(random_state=0, estimator= 
                         ExtraTreesRegressor(n_estimators=10, random_state=0))
imputed_data=imputer.fit_transform(dataset_to_impute)&lt;/LI-CODE&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;&amp;nbsp;i have seen these examples:&lt;/P&gt;&lt;P&gt;&lt;A href="https://github.com/qlik-oss/server-side-extension/tree/master/examples/python" target="_blank" rel="noopener"&gt;https://github.com/qlik-oss/server-side-extension/tree/master/examples/python&lt;/A&gt;&lt;/P&gt;&lt;P&gt;but i didn't know how to do it in my case!&lt;/P&gt;&lt;P&gt;Please, can anyone help?&lt;/P&gt;</description>
      <pubDate>Sat, 16 Nov 2024 02:28:52 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Integration-Extension-APIs/add-python-script-to-Qlick-sense/m-p/1700419#M14648</guid>
      <dc:creator>asma-sm</dc:creator>
      <dc:date>2024-11-16T02:28:52Z</dc:date>
    </item>
    <item>
      <title>Re: add python script to Qlick sense</title>
      <link>https://community.qlik.com/t5/Integration-Extension-APIs/add-python-script-to-Qlick-sense/m-p/1705043#M14649</link>
      <description>&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;I have the same query.&lt;/P&gt;&lt;P&gt;&lt;a href="https://community.qlik.com/t5/user/viewprofilepage/user-id/46628"&gt;@sunny_talwar&lt;/a&gt;&amp;nbsp; can you please help us out.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Varun&lt;/P&gt;</description>
      <pubDate>Tue, 26 May 2020 06:55:55 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Integration-Extension-APIs/add-python-script-to-Qlick-sense/m-p/1705043#M14649</guid>
      <dc:creator>Varun1</dc:creator>
      <dc:date>2020-05-26T06:55:55Z</dc:date>
    </item>
    <item>
      <title>Re: add python script to Qlick sense</title>
      <link>https://community.qlik.com/t5/Integration-Extension-APIs/add-python-script-to-Qlick-sense/m-p/1706763#M14650</link>
      <description>&lt;P&gt;Hello, I'm back again!&lt;/P&gt;&lt;P&gt;So, to integrate python script to Qlick Sense you can use &lt;STRONG&gt;server-side extension&lt;/STRONG&gt; (SSE) it exposes&amp;nbsp; Qlik data to an external scripting/programming language (python in our case) through remote procedure calls (RPCs).&lt;/P&gt;&lt;P&gt;Here we are going to passe DATA to python in a request (it is which is an iterator object made of multiple bundled rows)&lt;/P&gt;&lt;OL&gt;&lt;LI&gt;install these packages: grpcio, pandas and scikit-learn&lt;BR /&gt;pip install grpcio&lt;BR /&gt;pip install pandas&lt;BR /&gt;python -m pip install grpcio-tools&lt;BR /&gt;pip install scikit-learn&lt;/LI&gt;&lt;LI&gt;Edit your Settings.ini file, in windows you can find it in :&lt;BR /&gt;C:\Users\nameOfUser\Documents\Qlik\Sense&lt;/LI&gt;&lt;LI&gt;Add the following line to the Settings files,&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;SSEPlugin = Imputer,localhost:50051&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;(the port's number is in "__main.py" line 242,you can change it)&lt;/LI&gt;&lt;LI&gt;&amp;nbsp;Use the files in my git repo:&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &lt;A href="https://github.com/asmaalegat/Qlick_data_imputation_example" target="_blank" rel="noopener"&gt;https://github.com/asmaalegat/Qlick_data_imputation_example&lt;/A&gt;&lt;SPAN&gt;&amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp; &amp;nbsp;&lt;/SPAN&gt;(I reused files from &lt;A href="https://github.com/danielpilla/qlik-python-sse-nfl-playbyplay-predictions" target="_self"&gt;https://github.com/danielpilla/qlik-python-sse-nfl-playbyplay-predictions&lt;/A&gt;&lt;SPAN&gt;&amp;nbsp;)&lt;/SPAN&gt;&lt;/LI&gt;&lt;LI&gt;Add the the application (qvf file) to the directory of qlick sense apps&lt;/LI&gt;&lt;LI&gt;&amp;nbsp;Close qlick sense and run&amp;nbsp; &amp;nbsp;python script in cmd:&lt;BR /&gt;python __main__.py&lt;/LI&gt;&lt;LI&gt;launch Qlick Sense app&lt;/LI&gt;&lt;/OL&gt;&lt;P&gt;To add other functions or customize your application according to your need you can edit&lt;BR /&gt;the two files:&lt;/P&gt;&lt;UL&gt;&lt;LI&gt;"functions.json" (it defines the metadata associated with each custom function )&lt;BR /&gt;&lt;BR /&gt;&lt;/LI&gt;&lt;LI&gt;"__main__.py" you can edit the function "impute" or add other functions (don't forget to&lt;BR /&gt;add it to the json file)&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;Custom functions&amp;nbsp; are callable from the Qlik Sense front-end.&lt;BR /&gt;In the example I made i called the function "impute" to recuperate my data with imputed data by adding&lt;BR /&gt;an expression in your Qlick app :&lt;BR /&gt;pluginName.funtionName(col1,col2,col_n)&amp;nbsp; &amp;nbsp;// your function's parameters&lt;BR /&gt;in the example expression is added to "imputed data" table's columns:&lt;BR /&gt;Imputer.Impute(Age,High,Weight)&lt;/P&gt;&lt;P&gt;To understand well how the SSE works and each function in python's code you can read this article&lt;BR /&gt;&lt;A href="https://www.axisgroup.com/data-industry-insights-blog/qlik-sense-server-side-extensions-part-13-architecture-environment" target="_blank" rel="noopener"&gt;https://www.axisgroup.com/data-industry-insights-blog/qlik-sense-server-side-extensions-part-13-architecture-environment&lt;/A&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Sat, 30 May 2020 15:35:28 GMT</pubDate>
      <guid>https://community.qlik.com/t5/Integration-Extension-APIs/add-python-script-to-Qlick-sense/m-p/1706763#M14650</guid>
      <dc:creator>asma-sm</dc:creator>
      <dc:date>2020-05-30T15:35:28Z</dc:date>
    </item>
  </channel>
</rss>

