Learn R Programming

lazyWeave (version 2.2.0)

lazy.list: Lists in LaTeX

Description

Produce code for lists in LaTeX documents.

Usage

lazy.list(item, ordered=TRUE, counter=NULL, counterSet=1,
          title=NULL, 
          style=c("arabic", "Roman", "roman", "Alph", "alph"), 
          symbol=c("bullet", "circ", "blacksquare"),
          font, family, size)

Arguments

item
A vector with the items to be placed in the list.
ordered
Denotes if the list is ordered or bulleted.
counter
For future inclusion. Specifies what counter should be used for numbering. Currently not in use.
counterSet
The value to which counter should be set. In other words, the number for the first item in the list.
title
A title for the list
style
A character string denoting how the ordered list should be numbered. Options are "arabic", "roman", "Roman", "alph", "Alph".
symbol
A symbol for bulleted lists to be used as the bullet.
font
Font to be used in HTML documents. Defaults to the font set in the options.
family
Font family to be used in HTML documents. Defaults to the font family in the options.
size
Font size to be used in HTML documents. Defaults to the font family in the options.

Details

With style, the options produce the following and apply to both LaTeX and HTML: ll{ arabic Arabic numbers roman Lower case roman numerals (i, ii, iii, ...) Roman Upper case roman numerals (I, II, III, ...) alph Lower case alphabetic ordering (a, b, c, ...) Alph Upper case alphabetic ordering (A, B, C, ...) } The given options for symbol follow the HTML conventions, but when options("lazyReportFormat") is "latex", these options are translated into the appropriate equivalent.

Examples

Run this code
lazy.write(
  lazy.file.start(),
  lazy.text("In Boy Scouts, participants can earn several 
      ranks that denote the level of skill and accomplishment 
      they have developed.  These ranks are:"),
  lazy.list(c("Scout", "Tenderfoot", "Second Class", 
      "First Class", "Star", "Life", "Eagle"), style="Alph"),
  lazy.file.end(),
  OutFile="Example 1.tex")
  
unlink("Example 1.tex")

Run the code above in your browser using DataLab