Description
The td_namedentity_finder_evaluator_mle
function invokes the NamedEntityFinderEvaluatorMap
and NamedEntityFinderEvaluatorReduce functions, which operate as a row and
a partition function, respectively. Each function takes a set of evaluating data and
generates the precision, recall, and F-measure values of a specified maximum entropy data model.
The function does not support regular-expression-based or dictionary-based models.
Usage
td_namedentity_finder_evaluator_mle ( newdata = NULL, text.column = NULL, model = NULL, newdata.sequence.column = NULL )
Arguments
newdata |
Required Argument. |
text.column |
Required Argument. |
model |
Required Argument. |
newdata.sequence.column |
Optional Argument. |
Value
Function returns an object of class "td_namedentity_finder_evaluator_mle"
which is a named list containing Teradata tbl object.
Named list member can be referenced directly with the "$" operator
using name: result.
Examples
# Get the current context/connection con <- td_get_context()$connection # Load example data. loadExampleData("namedentityfinderevaluator_example", "nermem_sports_test") loadExampleData("namedentityfindertrainer_example", "nermem_sports_train") # Create remote tibble objects. nermem_sports_train <- tbl(con, "nermem_sports_train") nermem_sports_test <- tbl(con, "nermem_sports_test") # Train a namedentity finder model on entity type: "LOCATION". # The trained model is stored in a binary file: "location.sports". td_nef_trainer_out <- td_namedentity_finder_trainer_mle(data = nermem_sports_train, text.column = "content", entity.type = "LOCATION", model.file = "location.sports" ) # Example: Use the model file: location.sports as the input model on the test # data: nermem_sports_test. td_nef_evaluator_out <- td_namedentity_finder_evaluator_mle(newdata = nermem_sports_test, text.column = "content", model = "location.sports" )