Get started with an accelerated introduction to the R ecosystem, programming language, and tools including R script and RStudio. Utilizing many examples and projects, this book teaches you how to get data into R and how to work with that data using R. Once grounded in the fundamentals, the rest of Practical R 4 dives into specific projects and examples starting with running and analyzing a survey using R and LimeSurvey. Next, you'll carry out advanced statistical analysis using R and MouselabWeb. Then, youll see how R can work for you without statistics, including how R can be used to automate data formatting, manipulation, reporting, and custom functions. The final part of this book discusses using R on a server; youll build a script with R that can run an RStudio Server and monitor a report source for changes to alert the user when something has changed. This project includes both regular email alerting and push notification. And, finally, youll use R to create a customized daily rundown report of a person's most important information such as a weather report, daily calendar, to-do's and more. This demonstrates how to automate such a process so that every morning, the user navigates to the same web page and gets the updated report. What You Will Learn Set up and run an R script, including installation on a new machine and downloading and configuring R Turn any machine into a powerful data analytics platform accessible from anywhere with RStudio Server Write basic R scripts and modify existing scripts to suit your own needs Create basic HTML reports in R, inserting information as needed Build a basic R package and distribute it Who This Book Is For Some prior exposure to statistics, programming, and maybe SAS is recommended but not required. Table of Contents About the Author Acknowledgments Introduction Chapter 1: Getting Up and Running with R What Is R What R Is Not The R Landscape How R Is Installed and Used Installation on Windows Installation on macOS Installation on Linux How to Write a Basic R Script Hello World Wrapping It All Up Chapter 2: Feed the Beast: Getting Data into R The Data Object Playing with a Built-in Dataset Getting Data into R Typing in Data or Piping It In Reading Data in from Text and Excel Files Reading in Microsoft Excel Data Reading Data in from a Database Server Web Scraping Data Saving R Data Saving to Another Application Chapter 3: Project 1: Launching, Analyzing, and Reporting a Survey Using R and LimeSurvey The Project: A Customer Satisfaction Survey Regarding a New Product Introducing LimeSurvey Installing LimeSurvey on a LAMP Getting the Data into RStudio Getting Advanced: Linear Regression Chapter 4: Project 2: Advanced Statistical Analysis Using R and MouselabWEB Introducing MouselabWEB Our Example: Pro- or Anti-Cat Downloading the Data Crunching the Numbers Viewing and Formatting Does the Time Spent Viewing a Box Predict Which Choice the Person Will Make? Do People Open Certain Boxes Later Than Others? Do Cat Lovers Avoid Looking at Anti-Cat Information? Conclusion Future-Proofing: R Packages Chapter 5: R in Everyday Life Data Formatting String Manipulation Variable Magic Sorting and Filtering Data Calculation and Structure Conversions and Calculations If-else or ifelse For While Functions to Create Data Reshaping Recoding Writing Our Own Recode Function Data Reporting Using RMarkdown! Conclusion Chapter 6: Project 3: The R Form Mailer Packages and Packages of Email Sending Gmail Setup: Google Developer Console and API Access RStudio Project: Mailer Sending Your First Email Message Securing Communications The sodium Package The gpg Package The R Form Mailer Useful Email Services Chapter 7: Project 4: The R Powered Presentation The Setup Methods of Getting Data Computing Needs Getting and Analyzing the Data Creating the PowerPoint Presentation The Flow of the Presentation Chapter 8: R Anywhere The Basics: What We’re Doing, and Where We’re Doing It Software R RStudio – Server Shiny Server R Packages Hardware or Cloud Use Scenarios Command Line via SSH Web Browser via RStudio Server Web Page via Shiny Server R Anywhere Ideas Chapter 9: Project 5: The Change Alert! Detecting Change – Sources, Situations, and Solutions Typical R Data Formats: Tracking a Data Frame Tracking API Data Tracking Web Page Schedules, Interruptions, and Resuscitations Scheduling with Cron or Later Function Building a Redundant Script Notification and Acknowledgment In the R console Email/Text Push a Status File to a Web Server Pushover The ChangeAlert Script – Tracking What’s Hot, and When Email Tops 130,000,000,000! ChangeAlert-JSON.R ChangeAlert-Rendered.R Conclusion Chapter 10: Project 6: The R Personal Assistant Planning Part 1: Choosing Your Sources Planning Part 2: Choosing Your Format Plain Text HTML/PDF Data Frame/Graphs Bringing It Together: The Daily Briefing R Script Packages You’ll Need Weather from OpenWeatherMap.Org Stock Quotes from quantmod/tidyquant Packages News Headlines from NewsAPI.org Daily Inspiration Quote from TheySaidSo.com Calendar Information from Google Calendar Plain Text Output The HTML Markdown Version Distribution Options Pull Methods Push Methods Conclusion Index Get started with an accelerated introduction to the R ecosystem, programming language, and tools including R script and RStudio. Utilizing many examples and projects, this book teaches you how to get data into R and how to work with that data using R. Once grounded in the fundamentals, the rest of Practical R 4 dives into specific projects and examples starting with running and analyzing a survey using R and LimeSurvey. Next, you'll carry out advanced statistical analysis using R and MouselabWeb. Then, you'll see how R can work for you without statistics, including how R can be used to automate data formatting, manipulation, reporting, and custom functions. The final part of this book discusses using R on a server; you'll build a script with R that can run an RStudio Server and monitor a report source for changes to alert the user when something has changed. This project includes both regular email alerting and push notification. And, finally, you'll use R to create a customized daily rundown report of a person's most important information such as a weather report, daily calendar, to-do's and more. This demonstrates how to automate such a process so that every morning, the user navigates to the same web page and gets the updated report. What You Will Learn Set up and run an R script, including installation on a new machine and downloading and configuring R Turn any machine into a powerful data analytics platform accessible from anywhere with RStudio Server Write basic R scripts and modify existing scripts to suit your own needs Create basic HTML reports in R, inserting information as needed Build a basic R package and distribute it Who This Book Is For Some prior exposure to statistics, programming, and maybe SAS is recommended but not required Get Started With An Accelerated Introduction To The R Ecosystem, Programming Language, And Tools Including R Script And Rstudio. This Book Teaches You How To Get Data Into R And How To Work With That Data Using R. Once Grounded In The Fundamentals, The Rest Of Practical R 4 Dives Into Specific Projects And Examples Starting With Running And Analyzing A Survey Using R And Limesurvey. Next, You'll Carry Out Advanced Statistical Analysis Using R And Mouselab Web. Then, You’ll See How R Can Work For You Without Statistics, Including How R Can Be Used To Automate Data Formatting, Manipulation, Reporting, And Custom Functions. The Final Part Of This Book Discusses Using R On A Server; You’ll Build A Script With R That Can Run An Rstudio Server And Monitor A Report Source For Changes To Alert The User When Something Has Changed. This Project Includes Both Regular Email Alerting And Push Notification. And, Finally, You’ll Use R To Create A Customized Daily Rundown Report Of A Person's Most Important Information Such As A Weather Report, Daily Calendar, To-do's And More. This Demonstrates How To Automate Such A Process So That Every Morning, The User Navigates To The Same Web Page And Gets The Updated Report. What You Will Learn Set Up And Run An R Script, Including Installation On A New Machine And Downloading And Configuring R Turn Any Machine Into A Powerful Data Analytics Platform Accessible From Anywhere With Rstudio Server Write Basic R Scripts And Modify Existing Scripts To Suit Your Own Needs Create Basic Html Reports In R, Inserting Information As Needed Build A Basic R Package And Distribute It Who This Book Is For Some Prior Exposure To Statistics, Programming, And Maybe Sas Is Recommended But Not Required. Get started with an accelerated introduction to the R ecosystem, programming language, and tools including R script and RStudio. Utilizing many examples and projects, this book teaches you how to get data into R and how to work with that data using R. Once grounded in the fundamentals, the rest of __Practical R 4__ dives into specific projects and examples starting with running and analyzing a survey using R and LimeSurvey. Next, you'll carry out advanced statistical analysis using R and MouselabWeb. Then, youll see how R can work for you without statistics, including how R can be used to automate data formatting, manipulation, reporting, and custom functions. **What You Will Learn** - Set up and run an R script, including installation on a new machine and downloading and configuring R - Turn any machine into a powerful data analytics platform accessible from anywhere with RStudio Server - Write basic R scripts and modify existing scripts to suit your own needs - Create basic HTML reports in R, inserting information as needed **Who This Book Is For**