r2lUniv {r2lUniv}R Documentation

~ R to LaTeX Univariate Analyses ~ Overview ~

Description

r2lUniv performs some basic analyses, then generates a code to be included in a LaTeX document to print the analyses in a (so nice!) LaTeX way.

Package: r2lUniv2
Type: Package
Version: 0.4
Date: 2008-01-01
License: GPL (>= 2)

Usage

  r2lUniv(data, fileOutput = "", varName = NA, varNumber = NA, dirGraph = "", graphName = "V", ...)

Arguments

data Either a data.frame or a vector
fileOutput character; name of the output file to save the LaTeX summary. If empty, code is printed on screen.
varName character, single or vector; name of the data. If data is a data.frame, see r2lUniv.data.frame. If data is a vector, see r2lUniv.r2lBasicClasses.
varNumber numeric, single or vector; number the LaTeX summary. If data is a data.frame, see r2lUniv.data.frame. If data is a vector, see r2lUniv.r2lBasicClasses.
dirGraph character; directory used to save the graph generated by the analyses.
graphName character, single or vector; prefix of the graphs' names. If data is a data.frame, see r2lUniv.data.frame. If data is a vector, see r2lUniv.r2lBasicClasses.
... Can be classModification (see r2lUniv.data.frame) or limDiscrete (see r2lUniv.r2lBasicClasses).

Details

r2lUniv performs some basic analyses, then generates a code to be included in a LaTeX document to print the analyses in a (so nice!) LaTeX way.

r2lUniv performs the analyses automatically according to the data class. The classes defined by R are not precise enough for r2lUniv, so it is used some other class definition (classical statistics type definition) that are nominal, ordinal, discrete and continuous. This four classes are called r2lUniv basic classes. For more details, see r2lConcepts.

On these r2lUniv basic classes, r2lUniv performs some statistical analyses and generates a LaTeX summary that can be included in a LaTeX document. This summary is built up by methods r2lUniv.nominal, r2lUniv.ordinal, r2lUniv.discrete and r2lUniv.continuous

On the regular R classes (factor, logical, ordered, integer, numeric), r2lUniv first changes the class' data to the most adapted r2lUniv basic classes. Then it runs the corresponding method. The function that estimates "the most adapted" class is r2lFindClass. The methods called by r2lUniv on R classes are r2lUniv.factor, r2lUniv.logical, r2lUniv.ordered, r2lUniv.integer and r2lUniv.numeric

On a data.frame, r2lUniv sets the r2lUniv basic classes and runs the analyses on every column. More details in r2lUniv.data.frame.

To test this package quickly, running r2lGenerateLatexMain will create a compilable LaTeX document in which some LaTeX summary can be included.

Value

r2lUniv generates a LaTeX code and either prints it on screen or saves it in a file. It also generates several encapsulated postscript graphs, optionally in a different directory.

Classical usage

The use of r2lUniv goes through the following steps:
Step 1. Load the data (usually, a data.frame).
Step 2. Optionally, set some variables as ordered.
Step 3. Optionally, change the type of some variables (to force some discrete to be continuous, some logical to be ordered, ... ; see r2lModifyClasses for details.
Step 4. Run r2lUniv(dataFrame,"fileOut.tex") or r2lUniv(dataFrame,"fileOut.tex",classModification=listModif) if the type of some variables must change.

See examples of r2lUniv.data.frame and r2lUniv.r2lBasicClasses for an application.

r2lUniv, in real context...

Bob is working hardly on his Tetris (or on Minesweeper, depends). John, his boss, gets in his office:

Bob pouts, internally smiling, and starts his Tetris again. He knows that runnig r2lUniv on Friday 11th arround 12:30 will be soon enouth... As long as John does not know about r2lUniv, life is beautiful.

R to LaTeX, Bivariate Analyses

r2lBiv (R to LaTeX, Bivariate Analyses) is under construction. Any help will be welcomed!

Author

Christophe Genolini
christophe.genolini@free.fr
PSIGIAM: Paris Sud Innovation Group in Adolescent Mental Health
INSERM U669 / Maison de Solenn / Paris

English correction

Jean-Marc Chamot
jchamot@u-paris10.fr
Laboratoire "Sport & Culture" / "Sports & Culture" Laboratory
University of Paris 10 / Nanterre

References

LaTeX web site http://www.latex-project.org/

See Also

Sweave, latex, r2lConcepts, r2lUniv.data.frame, r2lUniv.r2lBasicClasses, r2lUniv.Rclasses

Examples

example(r2lUniv.r2lBasicClasses)
example(r2lUniv.data.frame)

[Package r2lUniv version 0.9 Index]