knitr::opts_chunk$set( collapse = TRUE, comment = "#>", eval = FALSE )
The polyglotr
package provides convenient functions to access the Linguee API and retrieve translations, examples, and external sources. This vignette demonstrates the usage of three key functions: linguee_external_sources()
, linguee_translation_examples()
, and linguee_word_translation()
.
library(polyglotr)
The linguee_external_sources()
function retrieves external sources using the Linguee Translation API. Here's an example usage:
external_sources <- linguee_external_sources("hello", src = "en", dst = "de") print(external_sources)
The linguee_translation_examples()
function provides translation examples using the Linguee Translation API. Here's an example usage:
translation_examples <- linguee_translation_examples("hello", src = "en", dst = "de") print(translation_examples)
The linguee_word_translation()
function translates a word using the Linguee Translation API. Here's an example usage:
word_translation <- linguee_word_translation("hello", source_language = "en", target_language = "de") print(word_translation)
Any scripts or data that you put into this service are public.
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.