<p><div><div><div><div data-width="100" data-show-faces="false" data-send="true" data-layout="button_count" data-height="21" data-href="https://www.r-bloggers.com/cas-rpm-installing-running-rattle-in-rstudio/"></div></div><div></div></div><div></div></div>
<div>
(This article was first published on <strong><a href="http://trinostics.blogspot.com/2017/04/cas-rpm-installing-running-rattle-in.html"> triKnowBits</a></strong>, and kindly contributed to <a rel="nofollow" href="https://www.r-bloggers.com/">R-bloggers)</a> </div>
<p>At the <a target="_blank" rel="nofollow" href="http://www.casact.org/calendar/index.cfm?fa=eventView&id=1453">Ratemaking and Product Management</a> (RPM) seminar of the <a target="_blank" rel="nofollow" href="http://www.casact.org/">Casualty Actuarial Society</a> (CAS) in San Diego last month, Linda Brobeck, Peggy Brinkmann, and yours truly gave a concurrent session on a machine learning technique called <a target="_blank" rel="nofollow" href="https://en.wikipedia.org/wiki/Decision_tree_learning">decision tree analysis</a>. See the DSPA-2 session — and other sessions — at <a target="_blank" rel="nofollow" href="http://www.casact.org/education/rpm/2017/index.cfm?fa=presentations">this link</a>. Technical issues precluded showing the video of  installing and running Rattle within RStudio. Thus this post.</p>
<p>As Peggy notes, installing and running Rattle takes only three “commands” in R:
<div><span>  install.packages(“rattle”, dependencies=c(‘Depends’, “Suggests”))</span></div>
<div><span>  library(rattle)</span></div>
<p><span>  rattle()</span></p>
<p>Although not necessary, the “Suggests” option above can avoid Rattle’s annoying requests for more packages as you click through its GUI; the downside is the time to download and install about 900 packages. Below (“Read more >>”) is a link to a video of me running through the three lines above:<br><a target="_blank" rel="nofollow" href="https://drive.google.com/file/d/0B82rVboXnsUgd1FhRFl0MFRHRUU/view?usp=sharing"></a><br><a name="more"></a><a target="_blank" rel="nofollow" href="https://drive.google.com/file/d/0B82rVboXnsUgd1FhRFl0MFRHRUU/view?usp=sharing">download/install Rattle</a>
<div></div>
<p>
<div>For those whose IT departments restrict installing R and RStudio on company equipment, this presentation used the software on a USB drive. The first minute or so of the video shows me setting up the shortcut on the USB drive so RStudio runs without a bunch of confusing questions, especially for a newbie. If you have R and RStudio installed on your computer already, you can fast forward through the first minute. </div>
<div></div>
<div></div>
<div>Peggy put her three lines of code into a script called ‘Rattle.R’. That’s the file I double-click around the 1:10 mark. You can see the three lines of the script in the upper left pane of RStudio. </div>
<div></div>
<div>I run the first line starting at 8:17 am, which finishes at 9:32 am (the 1:42 mark in the video). Plenty of time to read the newspaper.</div>
<div></div>
<div>Then I run the second line which, despite the “Depends” and “Suggests” settings above, has to download and install yet another package, GTK+. (There are reasons why that’s necessary, but not important right now.) That takes just a few minutes.</div>
<div></div>
<div>Then I run the third line, which fires up the Rattle user interface (GUI). It’s a little hard to see, but the Rattle GUI shows up as another process running in the taskbar.</div>
<div></div>
<div>At this point you can start using rattle/rpart per Peggy’s presentation. The links to our three presentations are reproduced here for convenience:</div>
<div>   <a target="_blank" rel="nofollow" href="http://www.casact.org/education/rpm/2017/presentations/DSPA-2_1.pdf">Linda Brobeck</a></div>
<div>   <a target="_blank" rel="nofollow" href="http://www.casact.org/education/rpm/2017/presentations/DSPA-2_2.pdf">Peggy Brinkmann</a></div>
<div>   <a target="_blank" rel="nofollow" href="http://www.casact.org/education/rpm/2017/presentations/DSPA-2_3.pdf">Dan Murphy</a></div>
<div></div>
<p>
<div>Contact me if questions.</div>
<p>
<div>
<div>To <strong>leave a comment</strong> for the author, please follow the link and comment on their blog: <strong><a href="http://trinostics.blogspot.com/2017/04/cas-rpm-installing-running-rattle-in.html"> triKnowBits</a></strong>.</div>
<hr>
<a rel="nofollow" href="https://www.r-bloggers.com/">R-bloggers.com</a> offers <strong><a rel="nofollow" href="https://feedburner.google.com/fb/a/mailverify?uri=RBloggers">daily e-mail updates</a></strong> about <a title="The R Project for Statistical Computing" rel="nofollow" href="https://www.r-project.org/">R</a> news and <a title="R tutorials" rel="nofollow" href="https://www.r-bloggers.com/search/tutorial">tutorials</a> on topics such as: <a title="Data science" rel="nofollow" href="https://www.r-bloggers.com/search/data%20science">Data science</a>, <a title="Big Data" rel="nofollow" href="https://www.r-bloggers.com/search/Big%20Data">Big Data, <a title="R jobs" rel="nofollow" href="https://www.r-users.com/">R jobs</a>, visualization (<a title="ggplot and ggplot2 tutorials" rel="nofollow" href="https://www.r-bloggers.com/search/ggplot2">ggplot2</a>, <a title="Boxplots using lattice and ggplot2 tutorials" rel="nofollow" href="https://www.r-bloggers.com/search/boxplot">Boxplots</a>, <a title="Maps and gis" rel="nofollow" href="https://www.r-bloggers.com/search/map">maps</a>, <a title="Animation in R" rel="nofollow" href="https://www.r-bloggers.com/search/animation">animation</a>), programming (<a title="RStudio IDE for R" rel="nofollow" href="https://www.r-bloggers.com/search/RStudio">RStudio</a>, <a title="Sweave and literate programming" rel="nofollow" href="https://www.r-bloggers.com/search/sweave">Sweave</a>, <a title="LaTeX in R" rel="nofollow" href="https://www.r-bloggers.com/search/LaTeX">LaTeX</a>, <a title="SQL and databases" rel="nofollow" href="https://www.r-bloggers.com/search/SQL">SQL</a>, <a title="Eclipse IDE for R" rel="nofollow" href="https://www.r-bloggers.com/search/eclipse">Eclipse</a>, <a title="git and github, Version Control System" rel="nofollow" href="https://www.r-bloggers.com/search/git">git</a>, <a title="Large data in R using Hadoop" rel="nofollow" href="https://www.r-bloggers.com/search/hadoop">hadoop</a>, <a title="Web Scraping of google, facebook, yahoo, twitter and more using R" rel="nofollow" href="https://www.r-bloggers.com/search/Web+Scraping">Web Scraping</a>) statistics (<a title="Regressions and ANOVA analysis tutorials" rel="nofollow" href="https://www.r-bloggers.com/search/regression">regression</a>, <a title="principal component analysis tutorial" rel="nofollow" href="https://www.r-bloggers.com/search/PCA">PCA</a>, <a title="Time series" rel="nofollow" href="https://www.r-bloggers.com/search/time+series">time series</a>, <a title="finance trading" rel="nofollow" href="https://www.r-bloggers.com/search/trading">trading</a>) and more...
<img height="1" alt="" width="1" src="http://feeds.feedburner.com/~r/RBloggers/~4/zLD9LDXb1Vw"></a></div>