install.packages("broadcast")Prerequisites & Installation
Prerequisites
First, a basic understanding of is important.
A very basic refresher for can be found in the Getting Started in R: Tinyverse Edition document.
Make sure you at least have basic knowledge of the following subjects in :
- Atomic types (logical, integer, double, complex, character, raw).
- The recursive type “list”.
- dimensional structures: vectors, matrices, arrays.
- common arithmetic operators (+, -, *, /, etc.), relational operators (==, !=, etc.), logical operators (&, |), and common bit-wise operations.
- vector recycling
Requirements
‘broadcast’ requires version 4.2.0 or later; you can download from https://cran.r-project.org/mirrors.html.
‘broadcast’ has only one dependency: ‘Rcpp’ version 1.0.14 or later. To install ‘Rcpp’, run install.packages("Rcpp") in .
Installation
To install the current version of ‘broadcast’ from CRAN, run the following code in :
It is possible that you may be asked if you want to install from sources that require compilation; select “Yes”; note that this requires ‘RTools’. You can download ‘RTools’ from https://cran.r-project.org/bin/windows/Rtools/.
To install the development version of ‘broadcast’ from GitHub, one may run the following code in :
remotes::install_github("https://github.com/tony-aw/broadcast")‘broadcast’ is not a large package per-sé, but it does contain a large amount of compiled code (‘C’ and ‘C++’ code). Compilation of the package may therefore be slow on some operating systems, especially Linux systems; please be patient. On an average PC running Windows 11, installation of the ‘broadcast’ package shouldn’t take more than just a few minutes.
If installation is too slow, one may try to speed up the installation using multi-threading, by running the following code before installing ‘broadcast’:
nthreads <- 8L # specify number of threads
Sys.setenv(MAKEFLAGS = paste0("-j", nthreads))
To attach the package - thus expose its functions to the namespace - please use the following:
library(broadcast)
To open the introduction help page of the ‘broadcast’ package, please use any of the following:
?broadcast::broadcast
?broadcast::broadcast_help
?broadcast::`broadcast-package`