Language Model Action Set
Calculating Error Rates with Specified ID and Text Column Names Specified
This example is not available for the CAS programming language.
Calculating Error Rates with Specified ID and Text Column Names Specified
This example is not available for the Lua programming language.
Calculating Error Rates with Specified ID and Text Column Names Specified
This section contains Python code. For more information about coding in Python, see Getting Started with SAS Viya for Python and SAS Viya: System Programming Guide.
The following code shows how to specify the names of the ID column or the text column (or both) in the input tables:
tableId = {"name": "hypothesis_id_column_name"},
tableText = {"name": "hypothesis_text_column_name"},
reference = {"name": "reference_table_name"},
referenceId = {"name": "reference_id_column_name"},
referenceText = {"name": "reference_text_column_name"},
)
By default, the calculateErrorRate action looks for the ID information in the first column and the text information in the second column in both input tables (which you specify in the table and reference parameters). However, if the input tables have a different order of columns, you might need to modify the values of the tableId and tableText parameters to fit the ID column and the text column you want to use in the input hypothesis table and you might need to modify the values of the referenceId and referenceText parameters to fit the ID column and the text column you want to use in the input reference table.
Calculating Error Rates with Specified ID and Text Column Names Specified
This example is not available for the R programming language.