万本电子书0元读

万本电子书0元读

顶部广告

Learning Shiny电子书

售       价:¥

21人正在读 | 0人评论 6.2

作       者:Hernán G. Resnizky

出  版  社:Packt Publishing

出版时间:2015-10-16

字       数:155.2万

所属分类: 进口书 > 外文原版书 > 电脑/网络

温馨提示:数字商品不支持退换货,不提供源文件,不支持导出打印

为你推荐

  • 读书简介
  • 目录
  • 累计评论(0条)
  • 读书简介
  • 目录
  • 累计评论(0条)
Make the most of R’s dynamic capabilities and implement web applications with ShinyAbout This BookPresent interactive data visualizations in R within the Shiny frameworkConstruct web dashboards in a simple, intuitive, but fully flexible environmentApply your skills to create a real-world web application with this step-by-step guide Who This Book Is For If you are a data scientist who needs a platform to show your results to a broader audience in an attractive and visual way, or a web developer with no prior experience in R or Shiny, this is the book for you.What You Will LearnComprehend many useful functions, such as lapply and apply, to process data in RWrite and structure different files to create a basic dashboardDevelop graphics in R using popular graphical libraries such as ggplot2 and GoogleVisMount a dashboard on a Linux ServerIntegrate Shiny with non-R-native visualization, such as D3.jsDesign and build a web application In Detail R is nowadays one of the most used tools in data science. However, along with Shiny, it is also gaining territory in the web application world, due to its simplicity and flexibility. Shiny is a framework that enables the creation of interactive visualizations written entirely in R and can be displayed in almost any ordinary web browser. It is a package from RStudio, which is an IDE for R. From the fundamentals of R to the administration of multi-concurrent, fully customized web applications, this book explains how to achieve your desired web application in an easy and gradual way. You will start by learning about the fundamentals of R, and will move on to looking at simple and practical examples. These examples will enable you to grasp many useful tools that will assist you in solving the usual problems that can be faced when developing data visualizations. You will then walk through the integration of Shiny with R in general and view the different visualization possibilities out there. Finally, you will put your skills to the test and create your first web application!Style and approach This is a comprehensive, step-by-step guide that will allow you to learn and make full use of R and Shiny’s capabilities in a gradual way, together with clear, applied examples.
目录展开

Learning Shiny

Table of Contents

Learning Shiny

Credits

About the Author

Acknowledgements

About the Reviewers

www.PacktPub.com

Support files, eBooks, discount offers, and more

Why subscribe?

Free access for Packt account holders

Preface

What this book covers

What you need for this book

Who this book is for

Conventions

Reader feedback

Customer support

Downloading the example code

Downloading the color images of this book

Errata

Piracy

Questions

1. Introducing R, RStudio, and Shiny

About R

Installing R

A quick guide to R

About RStudio

Installing RStudio

A quick guide to RStudio

About Shiny

Installing and loading Shiny

Summary

2. First Steps towards Programming in R

Object-oriented programming concepts

Variables in R

Classes in depth

Vectors

Lists

Matrices and arrays

Data frames

Factors

Element selection

Selecting elements from vectors

Selecting elements from arrays

Selecting elements from lists

Selecting elements from data frames

Control structures in R

The if...else block

The while loop

The for loop

The switch statement

Reading data

Delimited data

Reading line by line

Reading a character set

Reading JSON

Reading XML

Reading databases – SQL

Reading data from external sources

Summary

3. An Introduction to Data Processing in R

Sorting elements

sort() versus order()

Basic summary functions

grep and regular expressions

A brief introduction to regular expressions

Sets

Shortcuts

Dot

Non-printable characters

Negation

Alternation

Quantifiers

Special quantifiers

Anchors

Expressions

Escapes

Examples

Example 1

Example 2

The lapply, vapply, sapply, and apply functions

Examples

plyr

The data.table package

reshape2

Summary

4. Shiny Structure – Reactivity Concepts

Shiny as a package

An introduction to server.R and UI.R

UI.R as a JavaScript/HTML wrapper

Including HTML within UI.R

The concept of reactivity

Reactive independent processes within an application

An introduction to global.R

Running a Shiny web application

An overview of simple examples

Example 1 – a general example of how render-like functions work

Example 2 – using reactive objects

Example 3 – Loading data outside reactive context

Example 4 – using global.R

Summary

5. Shiny in Depth – A Deep Dive into Shiny's World

UI.R

The structure

conditionalPanel() – Example 1

conditionalPanel() – Example 2

An example on the use of tabPanel() in tabsetPanel()

Inputs

Free inputs

Lists

Dates

Files

Buttons

submitButton() with conditionalPanel()

downloadButton() - an example

Optimal usage of server.R and global.R

Shiny options

Summary

6. Using R's Visualization Alternatives in Shiny

The graphics package

Barplot

Histograms

Boxplots

Pie charts

Points

Lines

Plotting options

Legends

Plotting a fully customized plot with the graphics package

Including a plot in a Shiny application

A walk around the googleVis package

googleVis in R

An overview of some functions

Candlesticks

Geolocalized visualizations

Treemaps

Motion chart

googleVis in Shiny

A small example of googleVis in Shiny

ggplot2 – first steps

ggplot's main logic – layers and aesthetics

Layers

Aesthetics

Some graphical tools in ggplot2

geom_point

geom_line

geom_bars

An applied example with multiple layers

ggplot and Shiny

Summary

7. Advanced Functions in Shiny

The validate() function

The isolate() function

The observe() function

The reactiveValues() function

Input updates

Summary

8. Shiny and HTML/JavaScript

The www directory

Creating UIs from plain HTML

The use of tags in UI.R

JavaScript

CSS

Other tags

Relating HTML/JavaScript and server.R

Summary

9. Interactive Graphics in Shiny

Interaction possibilities within R graphics

D3.js integration

What is D3?

networkD3

An introduction to htmlwidgets

D3BarChart.R

D3BarChart.js

D3BarChart.yaml

Summary

10. Sharing Applications

runGist/runGitHub/runUrl

shinyapps.io

Deploying applications on your own server

Installing R

Installing the RStudio server

Installing the Shiny package

run_as

listen

location

site_dir/app_dir

directory_index

Summary

11. From White Paper to a Full Application

Problem presentation

Conceptual design

Pre-application processing

Workclass

global.R coding

global.R

UI.R partial coding

UI.R

server.R coding

Gender bar chart

Age chart

Ethnic bar chart

Marital status

Education curve

Earnings chi-square test

Activity summary

UI.R completion

UI.R

Styling

Discovering insights in the application

Summary

Reference

Index

累计评论(0条) 0个书友正在讨论这本书 发表评论

发表评论

发表评论,分享你的想法吧!

买过这本书的人还买过

读了这本书的人还在读

回顶部