XLConnect 0.1-8

Mirai Solutions GmbH (http://www.mirai-solutions.com) is pleased to announce the availability of XLConnect 0.1-8 on CRAN.

The most prominent new features/extensions are an improved package vignette which provides more information and examples to get people started with the package. A new type conversion mechanism was introduced which allows users to pre-specify column types/classes and even force conversions between types (e.g. from character to numeric) when reading in data using readNamedRegion or readWorksheet. Instead of relying completely on cell types (which is the default mechanism), this allows to specify column classes of the data to be read in upfront. Possible type conversion issues will be reported back to the user/developer via warnings referring to the actual cell that is causing problems. Another new feature that was introduced is the function xlcEdit. It allows to edit plain data.frames in an Excel file editor (e.g. MS Excel). Changes will be applied to the underlying data object after closing the editor. Note that this functionality is only available under Windows and Mac OS X. For more information please see the reference manual.

A summary of news in XLConnect 0.1-8 can be found in the NEWS file on CRAN.

The following is a simple example showing the type conversion mechanism introduced with XLConnect 0.1-8:

# Load the XLConnect package
require(XLConnect)

# conversion xlsx file from demoFiles subfolder of package XLConnect
excelFile <- system.file("demoFiles/conversion.xlsx", package = "XLConnect")

# Load workbook
wb <- loadWorkbook(excelFile)

# Read named region 'conversion' with pre-specified column types
# Note: in the worksheet all data was entered as strings!
# forceConversion = TRUE is used to force conversion from String
# into the less generic data types numeric, POSIXt & logical
df <- readNamedRegion(wb, name = "conversion", header = TRUE,
		colTypes = c("numeric", "POSIXt", "logical"),
		forceConversion = TRUE,
		dateTimeFormat = "%Y-%m-%d %H:%M:%S")

# print classes
print(sapply(df, class))

XLConnect is a comprehensive and cross-platform R package for manipulating Microsoft Excel files from within R. XLConnect differs from other related R packages in that it is completely cross-platform and as such runs under Windows, Unix/Linux and Mac (32- and 64-bit). Moreover, it does not require any installation of Microsoft Excel or any other special drivers to be able to read & write Excel files. The only requirement is a recent version of a Java Runtime Environment (JRE).

The package can easily be installed from CRAN via install.packages("XLConnect"). In order to get started have a look at the package vignette, the numerous demos available via demo(package = "XLConnect") or browse through the comprehensive reference manual.

We are always happy to hear from you! For general feedback write us an email to xlconnect@mirai-solutions.com. If you find any bugs or hope to see some currently missing features in the future, just send us an email to xlconnect-bugs@mirai-solutions.com. You may also want to check out our XLConnect FAQ.

About these ads

About Mirai Solutions

Mirai Solutions is an independent consulting company with broad expertise in statistics, finance and IT. Together with our customers, we design and implement smart sustainable solutions ranging from small-scale software components or prototypes to enterprise-wide applications and platforms, positioning your organization for long-term success. Our interdisciplinary team can help you cover all aspects in developing the tools and processes you need to interpret complex statistical data and transform them into better business decisions. Be it highly customized and specialized advisory services and risk management solutions for financial services institutions, or more general statistical or IT consulting, or training courses on related topics, Mirai offers the appropriate services for all cases. At Mirai, we pride ourselves in the high level of customer satisfaction among all our existing clients.
This entry was posted in R, Uncategorized, XLConnect. Bookmark the permalink.

6 Responses to XLConnect 0.1-8

  1. Pingback: The R-Podcast Episode 6: Importing Data from External Sources » The R-Podcast

  2. beatsnpeace says:

    Thank you for a great package… One small question: Is there a way, currently using XLCOnnect, to change the color of a worksheet?

  3. beatsnpeace says:

    Thank you for a great package… One small question: Is there a way, currently, using XLCOnnect, to change to color of a spreadsheet, inside a workbook? Usually, one is able to do so, by right clicking on the name of the sheet, and choose color.

    Cheers

Leave a Reply

Fill in your details below or click an icon to log in:

WordPress.com Logo

You are commenting using your WordPress.com account. Log Out / Change )

Twitter picture

You are commenting using your Twitter account. Log Out / Change )

Facebook photo

You are commenting using your Facebook account. Log Out / Change )

Google+ photo

You are commenting using your Google+ account. Log Out / Change )

Connecting to %s