Shiny

Using external tooltip JS library with networkD3 and Shiny

萝らか妹 提交于 2020-02-08 07:22:03
问题 I'm trying to display the value variables of nodes and links in a networkD3 forceNetwork diagram as tooltips. To do this, I am using Shiny with htmlwidgets and the external JS library Tippy. Here is what I have so far: library(shiny) library(htmlwidgets) library(networkD3) fn <- forceNetwork( Links = MisLinks, Nodes = MisNodes, Source = "source", Target = "target", Value = "value", NodeID = "name", Group = "group", opacity = input$opacity) tippyJS <- 'tippy(".node")' server <- function(input,

addlegend R Leaflet-based-on-user-input

柔情痞子 提交于 2020-02-08 02:31:07
问题 I am using Shiny's varSelectInput function to display a map with R Leaflet from spatialpolygondataframe, so that by selecting a variable of the object the map of the corresponding variable is drawn and I changed its color. For this I have generated a reactive object of the ColorBin function of R leaflet from conditional varSelectInput. All this when rendering the map works correctly and consequently the map is painted, updating the color and the title of the legend. However, when deploying

Problems with adding formula to Markdown in Shiny

牧云@^-^@ 提交于 2020-02-07 06:16:12
问题 I want to add text in a tabPanel which contains some formula. The ui looks like this: library(markdown) library(shiny) shinyUI(fluidPage( titlePanel("Test"), sidebarLayout( sidebarPanel( ), mainPanel( tabsetPanel( tabPanel('Text', includeMarkdown("post.rmd")) ) ) ) ) ) And the markdown file looks like this: This is a text test. ### Equations There are inline equations such as $y_i = \alpha + \beta x_i + e_i$. And displayed formulas: $$\frac{1}{1+\exp(-x)}$$ When I run this, I do not get the

Problems with adding formula to Markdown in Shiny

拟墨画扇 提交于 2020-02-07 06:14:07
问题 I want to add text in a tabPanel which contains some formula. The ui looks like this: library(markdown) library(shiny) shinyUI(fluidPage( titlePanel("Test"), sidebarLayout( sidebarPanel( ), mainPanel( tabsetPanel( tabPanel('Text', includeMarkdown("post.rmd")) ) ) ) ) ) And the markdown file looks like this: This is a text test. ### Equations There are inline equations such as $y_i = \alpha + \beta x_i + e_i$. And displayed formulas: $$\frac{1}{1+\exp(-x)}$$ When I run this, I do not get the

R Shiny Layouts

安稳与你 提交于 2020-02-07 05:45:29
问题 In my shiny dashboard, I am currently plotting 1 bar graph above, and 4 pie charts below, as follows: fluidRow( column(12, plotOutput("bar1"))), fluidRow( column(3, plotOutput("pie")), column(3, plotOutput("pie2")), column(3, plotOutput("pie3")), column(3, plotOutput("pie4"))) How would I go about plotting the bar chart alongside the 4 pie charts, with the pie charts arranged in a square? Effectively the bar chart would be column(6,... and all of the pie charts would be column(3,... but I

Auto-resize textAreaInput created through renderUI

瘦欲@ 提交于 2020-02-06 07:29:27
问题 I'm trying to get my textAreaInput s to resize so that they display the entire area's contents by default. Following this, auto-resize textAreaInput in shiny R, I can get one to work with a textAreaInput created under ui (as in, the textAreaInput resizes appropriately). I can't get it to work (as in, the textAreaInput does not resize) when creating the textAreaInput as part of renderUI , let alone as part of a module. I'm happy to make use of shinyjs if it's helpful. The underlying problem

ggplot's transparent background changes after ShinyApp resizing

蓝咒 提交于 2020-02-05 03:31:07
问题 The following code shows 2 ggplot2 -plots in a shinydashboard . The plot backgrounds should always be transparent , even after resizing . The plots show correctly when starting the app, but as soon as the screen is resized, or the siderbar closed, the background changes to white again. Why is that and how can I prevent that? When closing the sidebar, the background changes to white and after reopening the sidebar, the plots switch to transparent again. But when resizing the window, its not

re-hide conditional shiny output once it has been rendered

核能气质少年 提交于 2020-02-04 23:01:32
问题 I need some help as to how to re-hide a shiny output once it has been rendered. Below I have provided a reproducible example to explain my question. I want text 2.2 to only be shown if Option 1 and B are selected, and text 1 to only show when option 2 is selected. I have done this by including conditionalPanel() with the conditions set accordingly. This works, however, once the text has been rendered this text will not disappear when the input changes. I want text 2.2 to disappear if the user

re-hide conditional shiny output once it has been rendered

自作多情 提交于 2020-02-04 23:00:04
问题 I need some help as to how to re-hide a shiny output once it has been rendered. Below I have provided a reproducible example to explain my question. I want text 2.2 to only be shown if Option 1 and B are selected, and text 1 to only show when option 2 is selected. I have done this by including conditionalPanel() with the conditions set accordingly. This works, however, once the text has been rendered this text will not disappear when the input changes. I want text 2.2 to disappear if the user