r_helpers module¶
TERMPORARILY DISABLED UNTIL A SERVICE IN DAPLA LAB WITH R AND PYTHON FOR VSCODE EXISTS.
This module contains utility functions for R-related tasks in the SSB Dash Framework.
- hb_method(data, p_c, p_u, p_a, id_field_name='id', x_1_field_name='x1', x_2_field_name='x2')¶
Runs the Hb method from the R package Kostra.
- Parameters:
data (
DataFrame) – The data to run the method onp_c (
int) – The value of pCp_u (
float) – The value of pUp_a (
float) – The value of pAid_field_name (
str) – The name of the id fieldx_1_field_name (
str) – The name of the first x fieldx_2_field_name (
str) – The name of the second x field
- Return type:
DataFrame- Returns:
The result of the method
- th_error(data, id_field_name, x_1_field_name, x_2_field_name)¶
Runs the ThError method from the R package Kostra.
- Parameters:
data (
DataFrame) – The data to run the method onid_field_name (
str) – The name of the id fieldx_1_field_name (
str) – The name of the first x fieldx_2_field_name (
str) – The name of the second x field
- Return type:
DataFrame- Returns:
The result of the method