'How to use two objects in a single row in FlexDashboard?
I have a column with a chart in FlexDashboard. I would like to put a download button under the chart, but it's showing just the top of the buttom.
My code:
renderPlotly({
ggplotly(
juros %>%
filter(data %in% as.Date(input$datas_juros),
tipo == input$tipo_juros) %>%
ggplot(aes(x = anos, y = valor, color = as.factor(data))) +
geom_line() +
geom_point() +
labs(y = "(%)", x = "Anos", color = "",
title = "Estrutura a Termo da Taxa de Juros") +
scale_x_continuous(breaks = seq(0.5, 10.5, 0.5)) +
scale_color_manual(values = unname(colors)) +
theme(panel.background = element_rect(fill = "white", colour = "white"),
axis.line = element_line(colour = "black", linetype = "dashed"),
axis.line.x.bottom = element_line(colour = "black"),
panel.grid.major = element_blank(),
plot.title = element_text(size = 12, face = "bold"),
panel.grid.minor = element_blank(),
plot.margin = margin(5, 5, 15, 5))
) %>%
config(displayModeBar = FALSE) %>%
style(hoverinfo = "y")
})
renderUI({
juros %>%
filter(data %in% as.Date(input$datas_juros),
tipo == input$tipo_juros) %>%
select(-c(tipo, data)) %>%
download_this(
output_name = paste("ETTJ -", input$tipo_juros),
output_extension = ".xlsx",
button_label = "Download do arquivo em Excel",
button_type = "success",
has_icon = TRUE,
icon = "fa fa-save")
})
This green bar is my download button. If I click there, I can download the data, but how can I move this button to show it completely?
Sources
This article follows the attribution requirements of Stack Overflow and is licensed under CC BY-SA 3.0.
Source: Stack Overflow
| Solution | Source |
|---|

