#' Get data limit by size
#'
#' @param credential the url create by function es.credential
#' @param size limit rows to extract
#'
#' @return sample data
#' @export
#' @examples
#' es.alldata(
#' credential = credential,
#' size = 100)
#'
es.alldata <- function(credential, size){
query <-
paste0('{
"size": ', size, ',
"query": {
"match_all": {}
}
}
}')
list_cont <- extract.query(es_credential = credential,
es_query = query)
data_extract <- list_cont$hits$hits$`_source`
return(data_extract)
}
Add the following code to your website.
For more information on customizing the embed code, read Embedding Snippets.