#' Read a numpy (python) data array into R
#'
#' @param rarrayname The multidimensional array
#' @param filename Filename for the numpy (.npy) file that will be produced
#' @export
#' @examples
#' \dontrun{
#' r_ecg <- read_numpy("digital_ecgs.npy")
#' }
write_numpy <- function(rarrayname, filename) {
## load the numpy object
np <-
reticulate::import("numpy", convert = T) #Python's number library
np$save(filename, rarrayname)
}
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.