Versions Compared

Key

  • This line was added.
  • This line was removed.
  • Formatting was changed.

Applies to:  

Status
colourGreen
titleCelonis 4.2
 
Status
colourGreen
titleCelonis 4.3
 
Status
colourGreen
titleCelonis 4.4
 


Description

Transfer columns to the R server, execute a script and which has the same length as the input columns.

Syntax


Code Block
languagetext
themeDJango
RCALL(table.column AS input_name(, table.column AS input_name)*, r_script)


  • table.column: Column(s) to be transferred to the R server
  • input_name: Name under which the column will be accessible in the R script
  • r_script: R script to be called

RCALL expects the R script to return a column which has the same length as the input columns.

Examples


In this example a column is multiplied by 2 via an R script.



Panel
titleQuery
Column1
Query
Code Block
languagetext
themeDJango
TABLE (
RCALL("Table1"."Column1" AS STRC, 'STRC * 2')
,



Column2
Code Block
languagetext
themeDJango
"Table1"."Column1"
)




Panel
titleInput
Table1


Column1 : INT
0
1
2
3
4




Panel
titleOutput
Result
Column1 : RCALLColumn2 : RCALL

0.0

0

2.0

1

4.0

2

6.0

3

8.0

4






Execute RCALL for an alternative way to calculate the QNORM.


Panel
titleQuery
Column1


Code Block
languagetext
themeDJango
RCALL ("Table1"."Column1" AS column1, 'qnorm(column1)')




Panel
titleInput
Table1


Column1 : FLOAT
1.0E-7
1.0E-5
0.001
0.05
0.15
0.25
0.35
0.45
0.55
0.65
0.75
0.85
0.95
0.999
0.99999
0.9999999




Panel
titleOutput
Result


Column1 : FLOAT
-5.199337582192817
-4.2648907939228256
-3.090232306167813
-1.6448536269514726
-1.0364333894937894
-0.6744897501960817
-0.3853204664075676
-0.125661346855074
0.12566134685507413
0.3853204664075676
0.6744897501960817
1.0364333894937894
1.6448536269514715
3.090232306167813
4.26489079392384
5.199337582290662