# Generated by using Rcpp::compileAttributes() -> do not edit by hand
# Generator token: 10BE3573-1514-4C36-9D1C-5A225CD40393
write_stdout <- function(text) {
.Call(`_reticulate_write_stdout`, text)
}
write_stderr <- function(text) {
.Call(`_reticulate_write_stderr`, text)
}
is_python3 <- function() {
.Call(`_reticulate_is_python3`)
}
#' Get or clear the last Python error encountered
#'
#' @return For `py_last_error()`, a list with the type, value,
#' and traceback for the last Python error encountered (can be
#' `NULL` if no error has yet been encountered).
#'
#' @export
py_last_error <- function() {
.Call(`_reticulate_py_last_error`)
}
#' @rdname py_last_error
#' @export
py_clear_last_error <- function() {
invisible(.Call(`_reticulate_py_clear_last_error`))
}
py_is_callable <- function(x) {
.Call(`_reticulate_py_is_callable`, x)
}
r_to_py_impl <- function(object, convert) {
.Call(`_reticulate_r_to_py_impl`, object, convert)
}
py_activate_virtualenv <- function(script) {
invisible(.Call(`_reticulate_py_activate_virtualenv`, script))
}
py_initialize <- function(python, libpython, pythonhome, virtualenv_activate, python3, interactive, numpy_load_error) {
invisible(.Call(`_reticulate_py_initialize`, python, libpython, pythonhome, virtualenv_activate, python3, interactive, numpy_load_error))
}
py_finalize <- function() {
invisible(.Call(`_reticulate_py_finalize`))
}
py_is_none <- function(x) {
.Call(`_reticulate_py_is_none`, x)
}
py_compare_impl <- function(a, b, op) {
.Call(`_reticulate_py_compare_impl`, a, b, op)
}
py_str_impl <- function(x) {
.Call(`_reticulate_py_str_impl`, x)
}
py_print <- function(x) {
invisible(.Call(`_reticulate_py_print`, x))
}
py_is_function <- function(x) {
.Call(`_reticulate_py_is_function`, x)
}
#' Check if a Python object is a null externalptr
#'
#' @param x Python object
#'
#' @return Logical indicating whether the object is a null externalptr
#'
#' @details When Python objects are serialized within a persisted R
#' environment (e.g. .RData file) they are deserialized into null
#' externalptr objects (since the Python session they were originally
#' connected to no longer exists). This function allows you to safely
#' check whether whether a Python object is a null externalptr.
#'
#' The `py_validate` function is a convenience function which calls
#' `py_is_null_xptr` and throws an error in the case that the xptr
#' is `NULL`.
#'
#' @export
py_is_null_xptr <- function(x) {
.Call(`_reticulate_py_is_null_xptr`, x)
}
#' @rdname py_is_null_xptr
#' @export
py_validate_xptr <- function(x) {
invisible(.Call(`_reticulate_py_validate_xptr`, x))
}
py_numpy_available_impl <- function() {
.Call(`_reticulate_py_numpy_available_impl`)
}
py_list_attributes_impl <- function(x) {
.Call(`_reticulate_py_list_attributes_impl`, x)
}
py_has_attr_impl <- function(x, name) {
.Call(`_reticulate_py_has_attr_impl`, x, name)
}
py_get_attr_impl <- function(x, name, silent = FALSE) {
.Call(`_reticulate_py_get_attr_impl`, x, name, silent)
}
py_set_attr_impl <- function(x, name, value) {
invisible(.Call(`_reticulate_py_set_attr_impl`, x, name, value))
}
py_get_attribute_types <- function(x, attributes) {
.Call(`_reticulate_py_get_attribute_types`, x, attributes)
}
py_ref_to_r_with_convert <- function(x, convert) {
.Call(`_reticulate_py_ref_to_r_with_convert`, x, convert)
}
py_ref_to_r <- function(x) {
.Call(`_reticulate_py_ref_to_r`, x)
}
py_call_impl <- function(x, args = NULL, keywords = NULL) {
.Call(`_reticulate_py_call_impl`, x, args, keywords)
}
py_dict_impl <- function(keys, items, convert) {
.Call(`_reticulate_py_dict_impl`, keys, items, convert)
}
py_dict_get_item <- function(dict, key) {
.Call(`_reticulate_py_dict_get_item`, dict, key)
}
py_dict_set_item <- function(dict, item, value) {
invisible(.Call(`_reticulate_py_dict_set_item`, dict, item, value))
}
py_dict_length <- function(dict) {
.Call(`_reticulate_py_dict_length`, dict)
}
py_dict_get_keys_as_str <- function(dict) {
.Call(`_reticulate_py_dict_get_keys_as_str`, dict)
}
py_tuple <- function(items, convert) {
.Call(`_reticulate_py_tuple`, items, convert)
}
py_tuple_length <- function(tuple) {
.Call(`_reticulate_py_tuple_length`, tuple)
}
py_module_import <- function(module, convert) {
.Call(`_reticulate_py_module_import`, module, convert)
}
py_module_proxy_import <- function(proxy) {
invisible(.Call(`_reticulate_py_module_proxy_import`, proxy))
}
py_list_submodules <- function(module) {
.Call(`_reticulate_py_list_submodules`, module)
}
py_iterate <- function(x, f) {
.Call(`_reticulate_py_iterate`, x, f)
}
py_iter_next <- function(iterator, completed) {
.Call(`_reticulate_py_iter_next`, iterator, completed)
}
py_run_string_impl <- function(code, local = FALSE, convert = TRUE) {
.Call(`_reticulate_py_run_string_impl`, code, local, convert)
}
py_run_file_impl <- function(file, local = FALSE, convert = TRUE) {
.Call(`_reticulate_py_run_file_impl`, file, local, convert)
}
py_eval_impl <- function(code, convert = TRUE) {
.Call(`_reticulate_py_eval_impl`, code, convert)
}
readline <- function(prompt) {
.Call(`_reticulate_readline`, prompt)
}
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.