hhpdf: R tools for writing HH2: hhpdf, hhdev.off, hhcapture, hhcode,...

View source: R/hhpdf.R

hhpdfR Documentation

R tools for writing HH2: hhpdf, hhdev.off, hhcapture, hhcode, hhpng, hhlatex

Description

R tools for writing HH2: hhpdf, hhdev.off, hhcapture, hhcode, hhpng, hhlatex. These functions in the HH package are placeholders used by the scripts files. See details.

Usage

hhpdf(file, ...)

hhdev.off(...)

hhcapture(file, text, echo=TRUE, print.eval=TRUE)

hhcode(file, text)

hhpng(file, ...)

hhlatex(file="", ...)

Arguments

file

Output file name. Ignored.

text

Multi-line character string. It will be displayed on the console by hhcode, and will be executed and the resulting value displayed on the console by hhcapture.

...

Ignored.

echo, print.eval

See source.

Details

The files in HHscriptnames() contain R code for all examples and figures in the book. The examples can all be directly executed by the user. The code examples all use these functions.

The versions of these functions here are essentially placeholders. Functions hhpdf, hhpng, and hhdev.off are no-ops and return NULL. As a consequence, the code between them will execute and display on the default graphics device. Function hhcapture sources its text argument and prints the output to the console. Function hhcode prints its text argument to the console. Function hhlatex prints the latex source to the console and returns NULL.

While writing the book, these placeholder functions are replaced by more elaborate functions with the same names that write the graphs onto pdf or png files, the console output to text files, and the latex code to a file.

Author(s)

Richard M. Heiberger <rmh@temple.edu>


HH documentation built on May 29, 2024, 6:24 a.m.

Related to hhpdf in HH...