-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathserver.R
71 lines (55 loc) · 1.81 KB
/
server.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
# library(ggpubr)
# library(jpeg)
# img <- readJPEG("./images/logo.jpg")
server <- function(input, output, session) {
output$id.Histograma <-
renderPlot({
ggplot(data = df_Bolao) +
# background_image(img) +
geom_histogram(mapping = aes(x = Valor)) +
# ggtitle(label = "histograma das apostas") +
theme_minimal() +
scale_x_continuous(breaks = pretty(range(df_Bolao$Valor),
n = nclass.Sturges(df_Bolao$Valor),
min.n = 1),
lim = c(0, 1000))
})
# output$id.Logo <-
# renderImage({
# filename <-
# normalizePath(file.path('./images','logo.jpg'))
#
# list(src = filename,
# contentType = 'image/png'
# )
#
# }, deleteFile = FALSE)
output$id.wordCloud <-
renderPlot({
wordcloud(
words = df_Bolao$Nome,freq = df_Bolao$fatia
,min.freq = 20
,max.words = 100
,scale = c(3.0,.09)
,random.order = FALSE
,rot.per = 0.35
,colors = brewer.pal(8, "Dark2")
)
})
output$id.Tabela <-
renderReactable({
reactable(df_Bolao[,c("Nome","Valor")]
,columns = list(
Valor = colDef(align = "center"
,name = "Valor(R$)")
# ,Nome = colDef(footer = "Se não encontrou seu nome escreva para: [email protected]")
)
,resizable = T
,filterable = T
,sortable = T
,pagination = T
,showSortable = T
,striped = T
)
})
}