Learn R Programming

readxlsb (version 0.1.61)

read_xlsb: Read xlsb workbook

Description

Imports a region from an xlsb (binary) workbook

Usage

read_xlsb(path, sheet = NULL, range = NULL, col_names = TRUE, 
 col_types = NULL, na = "", trim_ws = TRUE, skip = 0, ...)

Arguments

path

Path to the xlsb workbook

sheet

Name or index of the sheet to read. If the sheet name is specified as part of the range, this parameter is ignored

range

A named range or a string representing an excel range (of the form Sheet!A1:D10) or a cellranger object

col_names

TRUE uses the first row as the column name, FALSE sets names to column.#, or a character vector

col_types

NULL to imply type from spreadsheet or one of ignore/logical/numeric/date/string per column

na

Single string or array of strings to interpret as missing

trim_ws

Trim whitespace from strings

skip

Number of rows to skip before reading data

...

Additional options. Pass debug = TRUE to return xlsb environment

Examples

Run this code
read_xlsb(path = system.file("extdata", "TestBook.xlsb", package = "readxlsb"), 
 range = "PORTFOLIO")
 
read_xlsb(path = system.file("extdata", "TestBook.xlsb", package = "readxlsb"), 
 range = "UNICODE_STR", col_names = FALSE)

Run the code above in your browser using DataLab