-
Notifications
You must be signed in to change notification settings - Fork 12
/
Copy pathui.R
executable file
·87 lines (70 loc) · 3.86 KB
/
ui.R
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
# ui.R
suppressPackageStartupMessages(c(
library(shinythemes),
library(shiny),
library(tm),
library(stringr),
library(markdown),
library(stylo)))
shinyUI(navbarPage(h4("Coursera: Data Science Capstone Project"),
theme = shinytheme("cosmo"),
############################### ~~~~~~~~1~~~~~~~~ ##############################
## Tab 1 - Prediction
tabPanel("Next Word Predictor",
fluidRow(
column(3),
column(6,
tags$div(textInput("input_str",
label = h4("Enter your text below followed by SPACEBAR:"),
value = ),
tags$span(style="color:grey",("Bad words are censored with *")),
br(),
tags$hr(),
h4("The predicted next word:"),
tags$span(style="color:darkred",
tags$strong(tags$h3(textOutput("text2")))),
br(),
tags$hr(),
h4("TEXT you have entered [with suggested word completion]:"),
tags$em(tags$h4(textOutput("text1"))),
align="center")
),
column(3)
)
),
############################### ~~~~~~~~2~~~~~~~~ ##############################
## Tab 2 - About
tabPanel("About",
fluidRow(
column(2,
p("")),
column(8,
includeMarkdown("./about/about.md")),
column(2,
p(""))
)
),
############################### ~~~~~~~~F~~~~~~~~ ##############################
## Footer
tags$hr(),
tags$br(),
tags$span(style="color:grey",
tags$footer(("© 2016 - "),
tags$a(
href="https://www.linkedin.com/in/eGyaan",
target="_blank",
"Gyaan GM."),
tags$br(),
("Built using"), tags$a(
href="http://www.r-project.org/",
target="_blank",
"R"),
("&"), tags$a(
href="http://shiny.rstudio.com",
target="_blank",
"Shiny."),
align = "center"),
tags$br()
)
)
)