{"id":57,"date":"2014-02-07T02:14:05","date_gmt":"2014-02-07T00:14:05","guid":{"rendered":"http:\/\/dekarlab.de\/wp\/?p=57"},"modified":"2020-05-23T15:38:17","modified_gmt":"2020-05-23T13:38:17","slug":"two-scenarios-of-usage-for-pentahor-integration-plugin","status":"publish","type":"post","link":"https:\/\/dekarlab.de\/wp\/?p=57","title":{"rendered":"Two use cases for Pentaho\/R Integration plugin"},"content":{"rendered":"<p>NOTE: This plugin is an old and open source version and is not the same as <b><a href=\"http:\/\/wiki.pentaho.com\/display\/EAI\/R+script+executor\">R script executor<\/a><\/b>, which is available from Pentaho.<\/p>\n<p>R Script Plugin supports two use cases:<\/p>\n<ol>\n<li>Execute R code for every row in the table<\/li>\n<li>Execute R code for whole table and aggregate the result<\/li>\n<\/ol>\n<p>Pentaho\/R Integration Plugin can be downloaded here:\u00a0<b><a href=\"https:\/\/dekarlab.de\/wp\/?p=100\">Downloads<\/a><\/b><\/p>\n<p><!--more--><\/p>\n<p>Two demostrate the usage we develop the following transformation:<br \/>\n<img decoding=\"async\" alt=\"\" src=\"http:\/\/dekarlab.de\/img\/execute_r_script_transformation.jpg\" \/><\/p>\n<p>Schematically these two use cases are shown on the figures below.<\/p>\n<table>\n<tr>\n<td>\n<b>Case 1<\/b><br \/>\n<img decoding=\"async\" style=\"width:150px\" alt=\"\" src=\"http:\/\/dekarlab.de\/img\/pentahor_1case.gif\" \/>\n<\/td>\n<td>\n<b>Case 2<\/b><br \/>\n<img decoding=\"async\" style=\"width:150px\" alt=\"\" src=\"http:\/\/dekarlab.de\/img\/pentahor_2case.gif\" \/>\n<\/td>\n<\/tr>\n<\/table>\n<p>The inputs and outputs and R code for two use cases are demonstrated on the image below.<\/p>\n<p><img decoding=\"async\" alt=\"\" src=\"http:\/\/dekarlab.de\/img\/pentahor_two_cases.gif\" \/><\/p>\n<p>In the first case we calculate the sum for every row, for example, c=a+b=1+2=3.<br \/>\nIn the second case we calculate the average of vector a=(1, 1.56, 3) and vector b=(2, 1.57, 4) and then calculate the sum: c=mean(a) + mean(b) = 1.85333 + 2.52333 = 4.37666<\/p>\n","protected":false},"excerpt":{"rendered":"<p>NOTE: This plugin is an old and open source version and is not the same as R script executor, which is available from Pentaho. R Script Plugin supports two use cases: Execute R code for every row in the table Execute R code for whole table and aggregate the result Pentaho\/R Integration Plugin can be downloaded here:\u00a0Downloads<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"open","ping_status":"closed","sticky":false,"template":"","format":"standard","meta":{"_bbp_topic_count":0,"_bbp_reply_count":0,"_bbp_total_topic_count":0,"_bbp_total_reply_count":0,"_bbp_voice_count":0,"_bbp_anonymous_reply_count":0,"_bbp_topic_count_hidden":0,"_bbp_reply_count_hidden":0,"_bbp_forum_subforum_count":0},"categories":[25,10],"tags":[57,41],"_links":{"self":[{"href":"https:\/\/dekarlab.de\/wp\/index.php?rest_route=\/wp\/v2\/posts\/57"}],"collection":[{"href":"https:\/\/dekarlab.de\/wp\/index.php?rest_route=\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/dekarlab.de\/wp\/index.php?rest_route=\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/dekarlab.de\/wp\/index.php?rest_route=\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/dekarlab.de\/wp\/index.php?rest_route=%2Fwp%2Fv2%2Fcomments&post=57"}],"version-history":[{"count":16,"href":"https:\/\/dekarlab.de\/wp\/index.php?rest_route=\/wp\/v2\/posts\/57\/revisions"}],"predecessor-version":[{"id":306,"href":"https:\/\/dekarlab.de\/wp\/index.php?rest_route=\/wp\/v2\/posts\/57\/revisions\/306"}],"wp:attachment":[{"href":"https:\/\/dekarlab.de\/wp\/index.php?rest_route=%2Fwp%2Fv2%2Fmedia&parent=57"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/dekarlab.de\/wp\/index.php?rest_route=%2Fwp%2Fv2%2Fcategories&post=57"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/dekarlab.de\/wp\/index.php?rest_route=%2Fwp%2Fv2%2Ftags&post=57"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}