Designing UI. Mine mine-cetinkaya-rundel

Similar documents
HTML: Parsing Library

HTML: Parsing Library

QUICK REFERENCE GUIDE

Oliver Pott HTML XML. new reference. Markt+Technik Verlag

CPET 499/ITC 250 Web Systems. Topics

Evaluation of alignment methods for HTML parallel text 1

HTML TAG SUMMARY HTML REFERENCE 18 TAG/ATTRIBUTE DESCRIPTION PAGE REFERENCES TAG/ATTRIBUTE DESCRIPTION PAGE REFERENCES MOST TAGS

Canvas & Brush Reference. Source: stock.xchng, Maarten Uilenbroek

Static Webpage Development

The [HTML] Element p. 61 The [HEAD] Element p. 62 The [TITLE] Element p. 63 The [BODY] Element p. 66 HTML Elements p. 66 Core Attributes p.

Index. CSS directive, # (octothorpe), intrapage links, 26

5-Sep-16 Copyright 2016 by GemTalk Systems LLC 1

HTML Cheat Sheet for Beginners

<page> 1 Document Summary Document Information <page> 2 Document Structure Text Formatting <page> 3 Links Images <page> 4

Certified HTML5 Developer VS-1029

COPYRIGHTED MATERIAL. Contents. Chapter 1: Creating Structured Documents 1

HTML Markup for Accessibility You Never Knew About

Web development using PHP & MySQL with HTML5, CSS, JavaScript

Wireframe :: tistory wireframe tistory.

ROLE OF WEB BROWSING LAYOUT ENGINE EVALUATION IN DEVELOPMENT

Programming of web-based systems Introduction to HTML5

"utf-8";

Certified HTML Designer VS-1027

BUILDING WEB APPLICATIONS IN R WITH SHINY. Welcome to the course!

Cascading Style Sheet

Chapter 2:- Introduction to XHTML. Compiled By:- Sanjay Patel Assistant Professor, SVBIT.

Table-Based Web Pages

COPYRIGHTED MATERIAL. Contents. Introduction. Chapter 1: Structuring Documents for the Web 1

@namespace url( /* set default namespace to HTML */ /* bidi */

Name Related Elements Type Default Depr. DTD Comment

HTML CS 4640 Programming Languages for Web Applications

Structure Bars. Tag Bar

WML2.0 TUTORIAL. The XHTML Basic defined by the W3C is a proper subset of XHTML, which is a reformulation of HTML in XML.

SilkTest 2009 R2. Rules for Object Recognition

Techno Expert Solutions An institute for specialized studies!

Creating and Setting Up the Initial Content

Bye Bye. Warning! HTML5 The Future of HTML. Saturday, October 9, All of this may change! The spec is still in development!

HTML5. The Future of HTML. Washington University in St. Louis R. Scott Granneman

HTML BEGINNING TAGS. HTML Structure <html> <head> <title> </title> </head> <body> Web page content </body> </html>

MSEP Partner Portal JSON Feed Standards

HTML and CSS COURSE SYLLABUS

BACKGROUND. HTTP is a 2-phase protocol used by most web applications and all web browsers. The response is usually an HTML document

Deccansoft Software Services

Symbols INDEX. !important rule, rule, , 146, , rule,

Silk Test Object Recognition with the Classic Agent

Understanding this structure is pretty straightforward, but nonetheless crucial to working with HTML, CSS, and JavaScript.

Basics of Web Design, 3 rd Edition Instructor Materials Chapter 2 Test Bank

HTML Summary. All of the following are containers. Structure. Italics Bold. Line Break. Horizontal Rule. Non-break (hard) space.

Internet publishing HTML (XHTML) language. Petr Zámostný room: A-72a phone.:

Summary 4/5. (contains info about the html)

Electronic Books. Lecture 6 Ing. Miloslav Nič Ph.D. letní semestr BI-XML Miloslav Nič, 2011

UNIT II Dynamic HTML and web designing

Web Development & Design Foundations with HTML5 & CSS3 Instructor Materials Chapter 2 Test Bank

CHAPTER 7 USER INTERFACE MODEL

Beginning Web Programming with HTML, XHTML, and CSS. Second Edition. Jon Duckett

A HTML document has two sections 1) HEAD section and 2) BODY section A HTML file is saved with.html or.htm extension

HTML+ CSS PRINCIPLES. Getting started with web design the right way

GESTIONE DEL BACKGROUND. Programmazione Web 1

HTML Hyper Text Markup Language

MODULE 2 HTML 5 FUNDAMENTALS. HyperText. > Douglas Engelbart ( )

HTML. HTML is now very well standardized, but sites are still not getting it right. HTML tags adaptation

WEB DESIGNING COURSE SYLLABUS

INTRODUCTION TO HTML5! HTML5 Page Structure!

Appendix A. XHTML 1.1 Module Reference

Web Designing HTML5 NOTES

Review of HTML. Chapter Pearson. Fundamentals of Web Development. Randy Connolly and Ricardo Hoar

Interactive Apps with Shiny INFO 201

Web Development and Design Foundations with HTML5 8th Edition

Advanced Web Programming C2. Basic Web Technologies

BASICS OF WEB DESIGN CHAPTER 2 HTML BASICS KEY CONCEPTS

The Hypertext Markup Language (HTML) Part II. Hamid Zarrabi-Zadeh Web Programming Fall 2013

Programmazione Web a.a. 2017/2018 HTML5

1/6/ :28 AM Approved New Course (First Version) CS 50A Course Outline as of Fall 2014

Chapter 1 Self Test. LATIHAN BAB 1. tjetjeprb{at}gmail{dot}com. webdesign/favorites.html :// / / / that houses that information. structure?

CHAPTER 2 MARKUP LANGUAGES: XHTML 1.0

COMP519: Web Programming Lecture 4: HTML (Part 3)

Creating Web Pages Using HTML

Web Programming Week 2 Semester Byron Fisher 2018

Go.Web Style Guide. Oct. 16, Hackensack Ave Hackensack, NJ GoAmerica, Inc. All rights reserved.

PIC 40A. Lecture 4b: New elements in HTML5. Copyright 2011 Jukka Virtanen UCLA 1 04/09/14

HTML. Based mostly on

HTML. HTML Evolution

Skill Area 323: Design and Develop Website. Multimedia and Web Design (MWD)

CSC Web Programming. Introduction to HTML

Learning Objectives. Review html Learn to write a basic webpage in html Understand what the basic building blocks of html are

Html basics Course Outline

!Accessibility Issues Found

Web Programming and Design. MPT Senior Cycle Tutor: Tamara Week 1

Style-Guidelines. Release 0.1

MPT Web Design. Week 1: Introduction to HTML and Web Design

OVERVIEW. How tables are structured. Table headers. Cell spanning (rows and columns) Table captions. Row and column groups

Web Site Design and Development Lecture 3. CS 0134 Fall 2018 Tues and Thurs 1:00 2:15PM

recall: a Web page is a text document that contains additional formatting information in the HyperText Markup Language (HTML)

More about HTML. Digging in a little deeper

HTML5. HTML5 Introduction. Form Input Types. Semantic Elements. Form Attributes. Form Elements. Month Number Range Search Tel Url Time Week

13.8 How to specify alternate text

2.1 Origins and Evolution of HTML

Announcements. Paper due this Wednesday

CSC 121 Computers and Scientific Thinking

Tables & Lists. Organized Data. R. Scott Granneman. Jans Carton

Transcription:

Designing UI Mine Çetinkaya-Rundel @minebocek mine-cetinkaya-rundel mine@stat.duke.edu

- Web application UI is ultimately HTML/CSS/JavaScript - Let R users write user interfaces using a simple, familiar-looking API - but no limits for advanced users

Interface builder functions

> names(tags) [1] "a" "abbr" "address" "area" "article" [6] "aside" "audio" "b" "base" "bdi" [11] "bdo" "blockquote" "body" "br" "button" [16] "canvas" "caption" "cite" "code" "col" [21] "colgroup" "command" "data" "datalist" "dd" [26] "del" "details" "dfn" "div" "dl" [31] "dt" "em" "embed" "eventsource" "fieldset" [36] "figcaption" "figure" "footer" "form" "h1" [41] "h2" "h3" "h4" "h5" "h6" [46] "head" "header" "hgroup" "hr" "html" [51] "i" "iframe" <i> some text "img" </i> "input" "ins" [56] "kbd" "keygen" "label" "legend" "li" [61] "link" "mark" "map" "menu" "meta" [66] "meter" "nav" "noscript" "object" "ol" [71] "optgroup" "option" "output" "p" "param" [76] "pre" "progress" "q" "ruby" "rp" [81] "rt" "s" "samp" "script" "section" [86] "select" "small" "source" "span" "strong" [91] "style" "sub" "summary" "sup" "table" [96] "tbody" "td" "textarea" "tfoot" "th" [101] "thead" "time" "title" "tr" "track" [106] "u" "ul" "var" "video" "wbr" tags

tag HTML > tags$b("this is my first app") <b>this is my first app</b>

Header tags library(shiny) # Define UI with tags ui <- fluidpage( tags$h1("first level heading"), tags$h2("second level heading"), tags$h3("third level heading") ) # Define server fn that does nothing :) server <- function(input, output) {} # Create the app object shinyapp(ui = ui, server = server)

Linked text library(shiny) # Define UI with tags ui <- fluidpage( tags$h1("awesome title"), tags$br(), # line break tags$a("this app is built with Shiny.", href = "http:// shiny.rstudio.com/") ) # Define server fn that does nothing :) server <- function(input, output) {} # Create the app object shinyapp(ui = ui, server = server)

Nested tags library(shiny) # Define UI with tags ui <- fluidpage( tags$p("lorem ipsum", tags$em("dolor"), "sit amet,", tags$b("consectetur"), "adipiscing elit.") ) # Define server fn that does nothing :) server <- function(input, output) {} # Create the app object shinyapp(ui = ui, server = server)

tags$p(...) tags$h1(...) tags$h2(...) tags$h3(...) tags$h4(...) tags$h5(...) tags$h6(...) p(...) h1(...) h2(...) h3(...) h4(...) h5(...) h6(...) Common tags tags$a(...) tags$br(...) tags$div(...) tags$span(...) tags$pre(...) tags$code(...) tags$img(...) tags$strong(...) tags$em(...) tags$hr(...) a(...) br(...) div(...) span(...) pre(...) code(...) img(...) strong(...) em(...) hr(...)

Common tags > tags$a("anchor text") <a>anchor text</a> > a("anchor text") <a>anchor text</a> > tags$br() <br/> > br() <br/> > tags$code("monospace text") <code>monospace text</code> > code("monospace text") <code>monospace text</code> > tags$h1("first level header") <h1>first level header</h1> > h1("first level header") <h1>first level header</h1>

HTML > HTML("Hello world, <br/> and then a line break.") Hello world, <br/> and then a line break.

Let s build a movie browser app! movies-apps/data/movies.rdata Data from IMDB and Rotten Tomatoes on random sample of 651 movies released in the US between 1970 and 2014

Your turn - Start with movies-apps/movies.r. - Add some helper text to the app using tags that let your users know how to navigate the app.

Tabs

mainpanel( tabsetpanel(type = "tabs", tabpanel("plot", plotoutput("plot")), tabpanel("summary", tableoutput("summary")), tabpanel("data", DT::dataTableOutput("data")), tabpanel("reference", tags$p("there data were obtained from", tags$a("imdb", href = "http://www.imdb.com/"), "and", tags$a("rotten Tomatoes", href = "https:// www.rottentomatoes.com/"),."), tags$p("the data represent", nrow(movies), "randomly sampled movies released between 1972 to 2014 in the United States.") ) ) tabpanel()

mainpanel( tabsetpanel(type = "tabs", tabpanel("plot", plotoutput("plot")), tabpanel("summary", tableoutput("summary")), tabpanel("data", DT::dataTableOutput("data")), tabpanel("reference", tags$p("there data were obtained from", tags$a("imdb", href = "http://www.imdb.com/"), "and", tags$a("rotten Tomatoes", href = "https:// www.rottentomatoes.com/"),."), tags$p("the data represent", nrow(movies), "randomly sampled movies released between 1972 to 2014 in the United States.") ) ) tabpanel()

mainpanel( tabsetpanel(type = "tabs", tabpanel("plot", plotoutput("plot")), tabpanel("summary", tableoutput("summary")), tabpanel("data", DT::dataTableOutput("data")), tabpanel("reference", tags$p("there data were obtained from", tags$a("imdb", href = "http://www.imdb.com/"), "and", tags$a("rotten Tomatoes", href = "https:// www.rottentomatoes.com/"),."), tags$p("the data represent", nrow(movies), "randomly sampled movies released between 1972 to 2014 in the United States.") ) ) tabpanel()

movies_subset <- reactive({ movies %>% filter(title_type %in% input$type) }) Tabs and reactivity

mainpanel( navlistpanel(tabpanel("plot", plotoutput("plot")), tabpanel("summary", tableoutput("summary")), tabpanel("data", DT::dataTableOutput("data")), tabpanel("reference", tags$p("there data were obtained from", tags$a("imdb", href = "http://www.imdb.com/"), "and", tags$a("rotten Tomatoes", href = "https:// www.rottentomatoes.com/"),."), tags$p("the data represent", nrow(movies), "randomly sampled movies released between 1972 to 2014 in the United States.") ) ) navlistpanel()

Your turn - Continue working on movies-apps/movies.r. - Split the app into two tabs: one for plot and the other for data table. - Stretch goal: Add another tab for summary statistics and references.

shinythemes

library(shiny) library(shinythemes) shinythemes ui <- fluidpage( themeselector(), )

Your turn - Continue working on movies-apps/movies.r. - Add the theme selector, browse various themes, and pick a theme and apply it. - Don t forget to remove the selector once you re done picking a theme.