R/RcppExports.R

Defines functions runifC duplicatedInt

Documented in duplicatedInt runifC

# Generated by using Rcpp::compileAttributes() -> do not edit by hand
# Generator token: 10BE3573-1514-4C36-9D1C-5A225CD40393

#' @title
#' Rcpp duplicated on integers using Rcpp Sugar
#' @description
#' \code{.duplicatedInt} does same as \code{duplicated} in R, but only on integers, and faster.
#' It uses Rcpp sugar
#'
#' @param x Integer Vector
#' @return
#' A logical vector, as per \code{duplicated}
#'
#' @rdname duplicated
duplicatedInt <- function(x) {
    .Call(`_SpaDES_tools_duplicatedInt`, x)
}

#' @title
#' Rcpp Sugar version of runif
#' @description
#' Slightly faster than runif, and used a lot
#'
#' @param N Integer Vector
#' @export
#' @return
#' A vector of uniform random numbers as per \code{runif}
#'
#' @rdname rcpp-extras
runifC <- function(N) {
    .Call(`_SpaDES_tools_runifC`, N)
}

Try the SpaDES.tools package in your browser

Any scripts or data that you put into this service are public.

SpaDES.tools documentation built on Nov. 11, 2023, 1:07 a.m.