# Load the built-in dictionary
dic <- read_dictionary()
# Look up translations for all substrings
x <- "lugal kur-ra-ke4"
df <- guess_substr_info(x, dic)
# Show rows that have a translation
df[df$translation != "", ]
# Use multiple dictionaries (ordered by reliability -> first match wins)
file1 <- system.file("extdata", "sumer-dictionary.txt", package = "sumer")
df <- guess_substr_info(x, file1)
Run the code above in your browser using DataLab