Shiny

How do I display missing values in my sentiment analysis app

白昼怎懂夜的黑 提交于 2021-01-29 22:37:31
问题 Please, I have developed an app in shiny that can analyze sentiments in texts. However, when I do not fill all the text fields, and run the analysis, I get an error message. Here is my app code: if(interactive()){ library(shiny) library(shinycustomloader) library(shinycssloaders) library(shinythemes) library(SentimentAnalysis) library(textclean) library(reactable) library(tm) options(spinner.color="#3498db", spinner.color.background="#ffffff", spinner.size=1) ui<-navbarPage(strong("Mavis

How do I display missing values in my sentiment analysis app

流过昼夜 提交于 2021-01-29 22:34:57
问题 Please, I have developed an app in shiny that can analyze sentiments in texts. However, when I do not fill all the text fields, and run the analysis, I get an error message. Here is my app code: if(interactive()){ library(shiny) library(shinycustomloader) library(shinycssloaders) library(shinythemes) library(SentimentAnalysis) library(textclean) library(reactable) library(tm) options(spinner.color="#3498db", spinner.color.background="#ffffff", spinner.size=1) ui<-navbarPage(strong("Mavis

Conditional css styling in R shiny app on selectizeInput (based on input from colourInput)

醉酒当歌 提交于 2021-01-29 21:42:07
问题 Following on from this example can anyone please tell me if it's possible to update the colours of my selectizeInput based on input from the colourInput . ## load iris dataset data(iris) cats <- levels(iris$Species) ## colourInput ---- create list of shiny inputs for UI ids <- paste0("col", seq(3)) cols <- c("red", "blue", "yellow") foo <- function(x) {colourInput(ids[x], cats[x], cols[x])} my_input <- lapply(seq(ids), foo) ## css styling for selectizeInput menu CSS <- function(values, colors

Map creation by leaflet + shiny. Updating will return the map to its initial location

折月煮酒 提交于 2021-01-29 21:41:39
问题 I asked a question on the following page, but I will post it again. In shiny + leaflet, setview is updated every time render is executed. I want to prevent this We are currently creating maps using shiny and leaflet. The shp file is projected on the map. shp file → https://drive.google.com/file/d/1ji2J0vwEE9y8F0kNujmMoKPrf1IWZ7-x/view?usp=sharing I want to show / hide this shp file by setting the size of the area and the length of the circumference with sliderInput etc. The sample code is as

R shiny updateSelectInput choices for one dropdown menu with choices from another (ie one is a subcategory of the other)

无人久伴 提交于 2021-01-29 18:06:09
问题 I have a table of data MegaP2 with Organ type, separated into Lung and Skin , and then various cell types all of which come from either lung or skin. I have tried to make the available choices in the Cell Lines dropdown box reflect only those that come from the selected Organ in the first dropdown box. If I select Skin or Lung it gives the relevant cell lines perfectly, but then if I try to select the other organ type it then further restricts the cell lines to only those in both organs

Dynamic tabs and checkbox group in R shiny with renderUI

别说谁变了你拦得住时间么 提交于 2021-01-29 16:49:49
问题 I am trying to make a dynamic UI in which some tabPanel and checkboxGroup are created dynamically depending on the data. Below an example data frame: df <- data.frame( "Group" = c("Group A", "Group B", "Group A", "Group A", "Group B"), "Name" = c("Bob", "Paul", "Peter", "Emma", "John"), "Value" = seq(1,10, length.out=5), stringsAsFactors = F ) df Group Name Value 1 Group A Bob 1.00 2 Group B Paul 3.25 3 Group A Peter 5.50 4 Group A Emma 7.75 5 Group B Jhon 10.00 I managed to create two

How do I display missing values in my sentiment analysis app

限于喜欢 提交于 2021-01-29 16:40:56
问题 Please, I have developed an app in shiny that can analyze sentiments in texts. However, when I do not fill all the text fields, and run the analysis, I get an error message. Here is my app code: if(interactive()){ library(shiny) library(shinycustomloader) library(shinycssloaders) library(shinythemes) library(SentimentAnalysis) library(textclean) library(reactable) library(tm) options(spinner.color="#3498db", spinner.color.background="#ffffff", spinner.size=1) ui<-navbarPage(strong("Mavis

How to execute a function in the Shiny server depending on the inputId value of radioButtons?

纵然是瞬间 提交于 2021-01-29 15:57:55
问题 I am trying to pass an R script to Shiny, the whole script are functions. My goal is to have radiobottons in the sidebar, to know what function to execute and in the main panel a button to initialize the funtion, the signs of life of the function that is being executed and the description of the function. The description of the function if I get it to show, but I can not execute the function library(shiny) setwd("F:/Aplication PM10") source("Functions.R") ui <- fluidPage( titlePanel(

How to dynamically style a pickerInput menu in Shiny

流过昼夜 提交于 2021-01-29 15:27:24
问题 I would like to update the colours of my pickerInput based on input from the colourInput in the below example. This questions follows on from this question and replicating this with pickerInput instead of selectizeInput . This works great with selectizeInput : ## load iris dataset data(iris) cats <- levels(iris$Species) ## colourInput ---- create list of shiny inputs for UI ids <- paste0("col", seq(3)) cols <- c("red", "blue", "yellow") foo <- function(x) {colourInput(ids[x], cats[x], cols[x]

Shiny Application for Linear Regression with dynamic variable dropdown based on user upload

人盡茶涼 提交于 2021-01-29 15:25:52
问题 As the title describes, I'm simply trying to create a shiny application that allows the user to generate linear regression plots based on an imported csv file. After importing the file the dropdown for the variables of interest should be dynamically updated. As the code below shows, I'm able to accomplish that with mtcars but I'm not able to do the same with an imported files that would have different dependent and independent variables . Thank you for your help data(mtcars) cols <- sort