-
Notifications
You must be signed in to change notification settings - Fork 0
/
simres_package.R
61 lines (53 loc) · 2.25 KB
/
simres_package.R
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
# pkgdown::build_site()
#' simres: Simulation and resampling techniques
#'
#' Functions and datasets used in the books:
#'
#' * [Técnicas de Simulación y Remuestreo](https://rubenfcasal.github.io/simbook)
#'
#' * [Técnicas de Remuestreo](https://rubenfcasal.github.io/book_remuestreo)
#'
#' For more information visit <https://rubenfcasal.github.io/simres.html>.
#' @keywords simulation bootstrap Monte-Carlo
#' @name simres-package
#' @aliases simres
#' @docType package
#' @import graphics
#' @import stats
#' @importFrom utils flush.console
#' @importFrom grDevices dev.interactive devAskNewPage dev.flush dev.hold
#' @references
#' Cao R., Fernández-Casal R. (2021). *[Técnicas de Remuestreo](https://rubenfcasal.github.io/book_remuestreo)*, ([github](https://github.com/rubenfcasal/book_remuestreo)).
#'
#' Fernández-Casal R., Cao R., Costa J. (2023). *[Técnicas de Simulación y Remuestreo](https://rubenfcasal.github.io/simbook)*, segunda edición, ([github](https://github.com/rubenfcasal/simbook)).
#'
NULL
if(getRversion() >= "2.15.1")
utils::globalVariables(c(".rng"))
#' Microorganism lifetimes
#'
#' Lifespan of a sample of a particular population of microorganisms.
#' @name lifetimes
#' @docType data
#' @format A vector with 15 observations of the time to death event.
#' @source Unknown.
#' @keywords datasets
#' @examples
#' hist(lifetimes)
NULL
# lifetimes <- c(0.143, 0.182, 0.256, 0.26, 0.27, 0.437, 0.509, 0.611, 0.712,
# 1.04, 1.09, 1.15, 1.46, 1.88, 2.08)
# usethis::use_data(lifetimes)
#--------------------------------------------------------------------
.onAttach <- function(libname, pkgname){
#--------------------------------------------------------------------
# pkg.info <- utils::packageDescription(pkgname, libname, fields = c("Title", "Version", "Date"))
pkg.info <- drop( read.dcf( file = system.file("DESCRIPTION", package = "simres"),
fields = c("Title", "Version", "Date") ))
packageStartupMessage(
paste0(" simres: ", pkg.info["Title"], ",\n"),
paste0(" version ", pkg.info["Version"], " (built on ", pkg.info["Date"], ").\n"),
" Copyright (C) R. Fernandez-Casal 2022.\n",
" Type `help(simres)` for an overview of the package or\n",
" visit https://rubenfcasal.github.io/simres.\n")
}