Learn R Programming

xlsx (version 0.1.1)

Workbook: Functions to manipulate Excel 2007 workbooks.

Description

Functions to manipulate Excel 2007 workbooks.

Usage

createWorkbook()

loadWorkbook(file)

saveWorkbook(wb, file)

Arguments

file
the absolute path to the file which the data are to be read from.
wb
a workbook object as returned by createWorkbook or loadWorkbook.

Value

  • createWorkbook returns a java object reference pointing to an empty workbook object. loadWorkbook creates a java object reference corresponding to the file to load.

Details

createWorkbook creates an empty workbook object.

loadWorkbook loads a workbook from a file.

saveWorkbook saves an existing workook to an Excel 2007 file.

See Also

write.xlsx for writing a data.frame to an xlsx file. read.xlsx for reading the content of a xlsx worksheet into a data.frame. To extract worksheets and manipulate them, see Worksheet.

Examples

Run this code
wb <- createWorkbook()

# see all the available java methods that you can call
.jmethods(wb)

# for example
wb$getNumberOfSheets()   # no sheet yet!

Run the code above in your browser using DataLab