Search icon
Arrow left icon
All Products
Best Sellers
New Releases
Books
Videos
Audiobooks
Learning Hub
Newsletters
Free Learning
Arrow right icon
Learning Predictive Analytics with R

You're reading from  Learning Predictive Analytics with R

Product type Book
Published in Sep 2015
Publisher Packt
ISBN-13 9781782169352
Pages 332 pages
Edition 1st Edition
Languages
Author (1):
Eric Mayor Eric Mayor
Profile icon Eric Mayor

Table of Contents (23) Chapters

Learning Predictive Analytics with R
Credits
About the Author
About the Reviewers
www.PacktPub.com
Preface
Setting GNU R for Predictive Analytics Visualizing and Manipulating Data Using R Data Visualization with Lattice Cluster Analysis Agglomerative Clustering Using hclust() Dimensionality Reduction with Principal Component Analysis Exploring Association Rules with Apriori Probability Distributions, Covariance, and Correlation Linear Regression Classification with k-Nearest Neighbors and Naïve Bayes Classification Trees Multilevel Analyses Text Analytics with R Cross-validation and Bootstrapping Using Caret and Exporting Predictive Models Using PMML Exercises and Solutions Further Reading and References Index

Installing the packages containing the required functions


Let's start by installing the different packages.

Installing C4.5

J48 is the implementation of C4.5 in Weka. It is readily available to R users through the RWeka package. Let's start by downloading and installing RWeka:

install.packages("RWeka"); library(RWeka)

This should work fine if the Java version (32 or 64 bit) matches the version of R that you are running. If the JAVA_HOME cannot be determined from the Registry error occurs, please install the correct Java version as explained at http://www.r-statistics.com/2012/08/how-to-load-the-rjava-package-after-the-error-java_home-cannot-be-determined-from-the-registry/. The package discussed is the rJava package, but the advice given should work just fine for issues with RWeka too.

Installing C5.0

C5.0 is included in the C50 package, which we will install and load:

install.packages("C50"); library(C50)

Installing CART

The rpart() function of the rpart package allows us to run CART in R. Let's...

lock icon The rest of the chapter is locked
Register for a free Packt account to unlock a world of extra content!
A free Packt account unlocks extra newsletters, articles, discounted offers, and much more. Start advancing your knowledge today.
Unlock this book and the full library FREE for 7 days
Get unlimited access to 7000+ expert-authored eBooks and videos courses covering every tech area you can think of
Renews at $15.99/month. Cancel anytime}