Giter Club home page Giter Club logo

shiny's Introduction

shiny

CRAN R build status RStudio community

Easily build rich and productive interactive web apps in R — no HTML/CSS/JavaScript required.

Features

  • An intuitive and extensible reactive programming model which makes it easy to transform existing R code into a "live app" where outputs automatically react to new user input.
    • Compared to event-based programming, reactivity allows Shiny to do the minimum amount of work when input(s) change, and allows humans to more easily reason about complex MVC logic.
  • A prebuilt set of highly sophisticated, customizable, and easy-to-use widgets (e.g., plots, tables, sliders, dropdowns, date pickers, and more).
  • An attractive default look based on Bootstrap which can also be easily customized with the bslib package or avoided entirely with more direct R bindings to HTML/CSS/JavaScript.
  • Seamless integration with R Markdown, making it easy to embed numerous applications natively within a larger dynamic document.
  • Tools for improving and monitoring performance, including native support for async programming, caching, load testing, and more.
  • Modules: a framework for reducing code duplication and complexity.
  • An ability to bookmark application state and/or generate code to reproduce output(s).
  • A rich ecosystem of extension packages for more custom widgets, input validation, unit testing, and more.

Installation

To install the stable version from CRAN:

install.packages("shiny")

Getting Started

Once installed, load the library and run an example:

library(shiny)
# Launches an app, with the app's source code included
runExample("06_tabsets")
# Lists more prepackaged examples
runExample()

For more examples and inspiration, check out the Shiny User Gallery.

For help with learning fundamental Shiny programming concepts, check out the Mastering Shiny book and the Shiny Tutorial. The former is currently more up-to-date with modern Shiny features, whereas the latter takes a deeper, more visual, dive into fundamental concepts.

Join the conversation

If you want to chat about Shiny, meet other developers, or help us decide what to work on next, join us on Discord.

Getting Help

To ask a question about Shiny, please use the RStudio Community website.

For bug reports, please use the issue tracker and also keep in mind that by writing a good bug report, you're more likely to get help with your problem.

Contributing

We welcome contributions to the shiny package. Please see our CONTRIBUTING.md file for detailed guidelines of how to contribute.

License

The shiny package as a whole is licensed under the GPLv3. See the LICENSE file for more details.

R version support

Shiny is supported on the latest release version of R, as well as the previous four minor release versions of R. For example, if the latest release R version is 4.1, then that version is supported, as well as 4.0, 3.6, 3.5, and 3.4.

shiny's People

Contributors

alandipert avatar albertosantini avatar aliciaschep avatar andrewsali avatar bborgesr avatar colinfay avatar cpsievert avatar crtahlin avatar daattali avatar dmpe avatar dvg-p4 avatar gaborcsardi avatar gadenbuie avatar hadley avatar jcheng5 avatar jeffreyhorner avatar jjallaire avatar jmcphers avatar kevinushey avatar mine-cetinkaya-rundel avatar nathancday avatar nstrayer avatar nuno-agostinho avatar saurfang avatar schloerke avatar tmastny avatar tomjemmett avatar trestletech avatar wch avatar yihui avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

shiny's Issues

variable UI elements

This may be an issue, or more of a question about how to do something - it doesn't seem possible as I see it now.

I have an application that takes an input (a search term, for example), processes that input in the shinyServer() and returns output to the mainPanel().

Conceptually, I would like to further manipulate this output, by creating checkboxes/sliders/, based on the output - that can be modified, then reactively updating certain outputs. Normally (in R), I would do something like this:

for(element in as.character(elements)) {
element_id <- paste(element, 'id', sep = '_')
element_label <- paste('Change level of', element', ':')
sliderInput(element,
element_label,
value = as.numeric(outputData[element]),
min = 1,
max = 1000)
}

... this for-loop approach does not work - the only solution I have come up with is to hard-code a bunch of conditionalPanel()s, and activate the ones relevant to the given search/output in question, which compromises any sort of order I might desire to display these UI elements in.

Is there a way to deliver a variable number of UI elements based on the data held in the Output object that shinyUI() elements draw from?

BTW! ... thank you soooo much for developing this package. I have been waiting for exactly this sort of project for 3 years now. It may be new and have development to go, but what you have here is exceptional and I can't thank you enough :)

PS I have only been using this package since Sunday, so I may be missing something obvious. I'm also new to the sort of server-client communication structure (i.e., input$ and output$ vars)

tableOutput() returns error for data frame built using do.call('rbind', lapply(el_ids, as.data.frame))

ui.R:

library(shiny)
library(twitteR)

Define UI for miles per gallon application

shinyUI(pageWithSidebar(

Application title

headerPanel('FitnessTrack'),
sidebarPanel(
selectInput("subscriber", "Select Subscriber:",
choices = c("nutwition_log", "anotherAccount")),
numericInput("obs", "Number of observations to view:", 10)
),
mainPanel(
tableOutput("view")
)
))

server.R:

library(shiny)
library(twitteR)

Define server logic required to plot various variables against mpg

shinyServer(function(input, output) {

datasetInput <- reactive(function() {
userTweets <- userTimeline(input$subscriber)
do.call("rbind", lapply(userTweets, as.data.frame))
})

output$view <- reactiveTable(function() {
datasetInput()
})

})

...

when I call, "> runApp()", I would expect the, "tableOutput('view')", call to print the datasetInput data frame to the mainPanel() in the browser.

I can run the operations in the datasetInput() reactive function, from the usual R terminal and get the data frame I expect to see. I am curious why the tableOuput('view') call here is not working as I might expect it to, and print the same table to the browser.

I also checked that a hard-coded data frame would print to the browser and it did. I suspect, then, that tableOutput()'s failure has something unique to do with the "do.call()" call, but I really don't know... I've only been using the shiny package for a number of hours now - and am not a versed programmer.

PS I've been waiting 3 years for something like shiny. Thank you!

formatting for numericInput

I'm playing with a little app design that has something like this:

numericInput("id", "ID:", 10000000000),

Unfortunately, that default displays as 1e+10. The function should probably have some sort of formatting or number-type argument that disables scientific notation, potentially disables the decimal point for integers, etc.

Related, it'd be useful to be able to disable the stepping part of that widget, in cases where it's not relevant (ID numbers, phone numbers, etc.)

An alternative to this would be a filter to textInput that could be used to restrict input to a certain regular expression or similar.

Scrollbar in sidebar

It would be useful to have a scrollbar in the sidebar. Right now, when there are many options, you may have to scroll down to set an option, then scroll back up to see the result.

bug with headerPanel

when using headerPanel(a('Dashboard',href='http://x.com'))

the title get <a href="http://x.com">Dashboard</a> but not Dashboard

unable to load tcltk on installation

When I run install.packages("shiny"), I get this error:

Loading Tcl/Tk interface ... Error: .onLoad failed in loadNamespace() for 'tcltk', details:
    call: dyn.load(file, DLLpath = DLLpath, ...)
    error: unable to load shared object '/usr/lib/R/library/tcltk/libs/tcltk.so':
    libtk8.5.so: cannot open shared object file: No such file or directory

So I tried install.packages("tcltk2"), which gives me the same error. Is there a requirement for this package I am missing?

Arch Linux x86_64
R 2.15.2

support additional capabilities of jslider

Our slider control is based on the jslider component: https://github.com/egorkhmelev/jslider

There are several additional capabilities of this component which we should expose:

  1. Ability to input two values simultaneously as a range
  2. Non-linear scales (via the heterogeneity property)
  3. Tick labels (note we'd need to add code to do snapping to ticks since it doesn't do this by default)
  4. Additional display formats (e.g. currency)
  5. Custom input types (e.g. time -- this requires a custom calculate function)

fileInput button

Is a fully functional 'fileInput' button far away? The button works well locally but causes a crash on glimmer, I assume because it is still experimental.

If it isn't a priority at the moment I can probably make do with a simple 'paste your data' input option, but would prefer the upload option.

Thanks

Kevin

Here is the error log from the JavaScript error console:


file: Genepop_[KK_edit].gen [0%] shiny.js:1184
file: Genepop_[KK_edit].gen [83%] shiny.js:1184

Listening on port 44915
Error in switch(msg$method, init = { : EXPR must be a length 1 vector
Calls: runApp ... tryCatchList -> serviceApp -> service ->

Execution halted

edit: error information

Using Cairo on Linux

In Linux, some objects are not antialiased when you use png output. For example, the default point shape in ggplot2 (#16) is jagged-looking.

It would be really useful to have an option to use CairoPNG() from the Cairo package for output. (Note that this differs from doing png(type="cairo")).

See this gist for examples rendered in Linux, with pictures:
https://gist.github.com/4036319

Input validation

Need to give developers a way to specify what values are valid, at least for text boxes.

delay reactives inside hidden tabs?

It would be nice for reactives inside of hidden tabs in a tabset that depend on inputs in the active tab to not be called until the hidden tab is made active. This seems to happen for plots, but not for other things. I don't know from a design standpoint whether this would be a good default or not, but it would be nice to be able to specify somehow as an option.

head deduplication should not be line-oriented

Line-oriented deduplication can cause JavaScript code to be mangled, for example:

head(tags$script("
if (location.hash) {
  console.log(location.hash);
}
else {
  console.log('No hash');
}
"))

In this example, the latter close-brace will be stripped because an identical line appeared earlier.

We probably need a solution that operates on the direct-child level.

reactiveUI does not always correctly render sliders

When creating a sliderInput through reactiveUI the slider is not rendered properly unless another slider has already been created in ui.R.

(This was seen under Fedora Core 16 with both Firefox 16.0.2 and Google Chrome 23.0.1271.64)

How to reproduce:

ui.R

library(shiny)

shinyUI(pageWithSidebar(
  headerPanel("Reactive UI test"),
  sidebarPanel(
              uiOutput("reactiveSlider")
              ),
  mainPanel ()
  ))

server.R

library(shiny)

shinyServer( function(input, output)
  {
  output$reactiveSlider <- reactiveUI(function()
    {
    sliderInput("reactiveSlider", "Choose a value:", 
                 min=1, max=10, step=0.5, value=2, ticks=T)   
    })
  })

This results in reactiveSlider being rendered as a text input rather than a slider.
Simply adding a slider to ui.R, e.g.

sliderInput("dummySlider", "some value", min=0, max=100, value=10) 

is sufficient to solve the issue.
A temporary workaround is then to add an invisible slider to ui.R

conditionalPanel
   (
   condition = '0==1',
   sliderInput("dummyslider", "", min=0, max=1, value=0)
   )

It seems this somehow derives from missing CSS instances, but I can't really understand why.
Even in the first case FireBug reports http://localhost:8100/shared/slider/css/jquery.slider.min.css as being loaded.
When a second slider is added in ui.R a second instance of the CSS appears (same file, just a second instance).
A third instance is not added if adding other sliders in ui.R but a new instance of the CSS is loaded for every reactiveUI slider component. If you add a few reactiveUI sliders you can see them rendered as text inputs and then change into sliders one by one as the CSS files get loaded.

So I guess what happens is that if a slider is present in ui.R the slider CSS is loaded.
Reactive UI components then load the CSS if needed.

Note that if you just add two reactiveUI sliders and no slider in ui.R the problem reappears, but two instances of the CSS are loaded anyway.

runGist in Windows

When I try to share a shiny app using a Gist or run the example Gist on a Windows XP machine I get the following error:

shiny::runGist('3239667')
cygwin warning:
  MS-DOS style path detected: C:\DOCUME~1\knowlje\LOCALS~1\Temp\Rtmp0eRcpP\shinygist16181a2427d.tar.gz
  Preferred POSIX equivalent is: /cygdrive/c/DOCUME~1/knowlje/LOCALS~1/Temp/Rtmp0eRcpP/shinygist16181a2427d.tar.gz
  CYGWIN environment variable option "nodosfilewarning" turns off this warning.
  Consult the user's guide for more details about POSIX paths:
    http://cygwin.com/cygwin-ug-net/using.html#using-pathnames
Error in setwd(appDir) : cannot change working directory

I am wondering if you need RTools installed to be able to run from a Gist on Windows machines?

Plots in tabsets not rendered

Hello,

If one moves < tabPanel("Plot", plotOutput("plot"))> from the first position to the second or third in the list of arguments of tabsetPanel() function the histogram plot does not show up. Consequently. only one plot in the first position is allowed.

Thank you

Andrzej

mainPanel(
tabsetPanel(
tabPanel("Plot", plotOutput("plot")), # plot
tabPanel("Summary", verbatimTextOutput("summary")),
tabPanel("Table", tableOutput("table"))
)
)

sessionInfo()
R version 2.15.1 (2012-06-22)
Platform: x86_64-pc-mingw32/x64 (64-bit)

locale:
[1] LC_COLLATE=English_United States.1252 LC_CTYPE=English_United States.1252
[3] LC_MONETARY=English_United States.1252 LC_NUMERIC=C
[5] LC_TIME=English_United States.1252

attached base packages:
[1] stats graphics grDevices utils datasets methods base

other attached packages:
[1] shiny_0.1.2 xtable_1.7-0 RJSONIO_0.98-1 websockets_1.1.4 digest_0.5.2 caTools_1.13
[7] bitops_1.0-4.1

loaded via a namespace (and not attached):
[1] tools_2.15.1

Input variable length vector

After looking at the Twitter Bootstrap controls you are developing from/with, there are several I would probably use (e.g., accordian, tooltip)...one thing that is missing (as far as I can tell) is a method to input a vector of variable length. This is something I need for several input items to gsDesign...any method or workarounds would be welcome.

Make server code testable

Given a Shiny directory you should be able to pass a list of inputs and get back a list of output values, for automated testing purposes.

How do you use the selected sliderinput option as a variable?

I want to create a multi-tab multi-dataset package. As the different datasets are not overly related, I want the user to be able to select which they want to look at and for that to change what filtering options are available for them to then use.

So I want something like this,

selectInput("variable", "Variable:",
list(""Cylinders" = "cyl",
"Transmission" = "am"),

if (selectInput == "Transmission") {

sliderInput("integer", "Integer:",
min=0, max=1, value=0) },

else{

Decimal interval with step value
sliderInput("decimal", "Decimal:", 
            min = 0, max = 1, value = 1) }

how do I do a conditional in Shiny?

fileInput bypass submitButton behavior

Trying to use in the same ui a submitButton and a fileInput, it seems that when a file selection is done, the submitButton is not taken into account, that is to say, the output are processed immediatly.

Even if it could be taken as a bug, I think it should be more convenient to have an explicit event handling method for the submitButtton.
Something like a boolean which says if the last event was the press on this button (false if it was any other widget which was updated) ... But I don't know if it is possible with the shiny events policy...
It should also allow to use several buttons on the same ui.

Best regards,
Yann

reactiveTable should allow print options too

Current, options for print.xtable are ignored. I believe the fix is to change this code:

return(paste(capture.output(print(xtable(data, ...), 
            type = "html", html.table.attributes = paste("class=\"", 
                htmlEscape(classNames, TRUE), "\"", sep = ""))), 
            collapse = "\n"))

to

return(paste(capture.output(print(xtable(data, ...), 
            type = "html", html.table.attributes = paste("class=\"", 
                htmlEscape(classNames, TRUE), "\"", sep = ""), ...)), 
            collapse = "\n"))

In particular this change would allow reactiveTable(fn, include.rownames=FALSE) to work.

gsDesign interface attempt #1

Following is a simple, limited interface to the gsDesign R package (ui and server code below).
This requires the gsDesign package available at CRAN.
This project has been open source since its inception in 2006 and is NOT for profit.
I am trying to replace an interface developed in Qt so that it can be maintained and extended by an R programmer.
See http://biopharmnet.com/wiki/GsDesign_Package if you want to see the Qt interface.
Any comments on this are welcome!

Comments:

  1. shiny is VERY accessible for an R programmer who is a statistician (read: NOT a professional programmer!).
    ~8 hours to learn shiny and do the interface so far is not bad!
    This could make somewhat complex packages such as gsDesign easily accessible!
  2. I am running this using Chrome 21.0.1180.79 m, R 2.15.0 and a version of shiny downloaded on August 18, 2012.

Initial issues with the current interface:

  1. I don't understand why the plot subtab under the "Group Sequential Design" tab is not functioning.
    Also, if I want to use ggplot2, how do I get a plot to output (I pretty recent release of ggplot2)?
  2. Look at the sample size tab in the UI. It would be ideal if I could use radio buttons or tabs
    (instead of both) to get the functionality implemented here (I would prefer just tabs, but on the server side,
    I don't have access to which tab is selected, so I had to use a radio buttons; radio buttons, on the other hand,
    do not allow the dynamic ui side that tabs do).
  3. Supporting variable length vector input (issue #14) is needed for this application. In the timing tab,
    I need to have a vector of the length specified there...and will want increasing numbers in
    that vector between 0 and 1.
    This functionality will be used in two other instances in a more complete interface.
  4. One of the nice things about the current Qt interface is that I can compare multiple designs.
    This would require storing all of the parameters for each design, as well as some way to
    navigate between them.
  5. See the "Timing" input on the spending function tab. It would be nice to have control over
    input increments in numericInput.

ui.r

library(shiny)
library(gsDesign)
shinyUI(pageWithSidebar(

  # Application title
  headerPanel("gsDesign Explorer"),

  # Sidebar with a slider input for spending fn parameter and
  # time to evaluate spending function
  sidebarPanel(
    tabsetPanel(
      tabPanel("Sample Size",
               numericInput("alpha",label="alpha (1-sided):",value=.025,min=.00001,max=.39999),
               numericInput("Power",label="Power:",value=.9,min=.4,max=.999),
               radioButtons("dist",  "Endpoint type", list("User defined" = "User", "Binomial" = "Binomial")),
               tabsetPanel(
                 tabPanel("User input", 
                          numericInput(inputId="nfix",label="N for Fixed Design", value=1, min=1)),
                 tabPanel("Binomial", 
                          numericInput(inputId="p1",label="Control event rate", value=.15, min=.005,max=.995),
                          numericInput(inputId="p2",label="Experimental event rate", value=.1, min=.005,max=.995),
                          numericInput(inputId="delta0",label="H0 difference",value=0)))),                  
      tabPanel("Timing",
        numericInput(inputId="km1", label="Number of interim analyses", value=2, min=1)),
      tabPanel("Spending Functions",
        tabsetPanel(
          tabPanel("Upper spending",
            sliderInput(inputId="rho", label="Rho:", min = 0.1, max = 15.0, value = 4.0, step=.05),
            numericInput(inputId="t", label="Timing:", value=.5, min=0, max=1)),
          tabPanel("Lower spending",
            sliderInput(inputId="lrho", label="Rho:", min = 0.1, max = 15.0, value = 2.0, step=.05),
            numericInput(inputId="lt", label="Timing:", value=.5, min=0, max=1)))))
  ),
  # Show a plot of the generated distribution
  mainPanel(
    tabsetPanel(
      tabPanel("Upper spending",plotOutput("sfPlot")),
      tabPanel("Fixed design sample size",verbatimTextOutput("dist")),
      tabPanel("Group sequential design",
        tabsetPanel(
          tabPanel("Text",verbatimTextOutput("design")),
          tabPanel("Plot",plotOutput("plot"))
))))))

server.r

library(shiny)
library(ggplot2)
shinyServer(function(input, output){

  # Function that generates a plot of a spending function. The function
  # is wrapped in a call to reactivePlot to indicate that:
  #
  #  1) It is "reactive" and therefore should be automatically 
  #     re-executed when inputs change
  #  2) Its output type is a plot 
  #
  output$sfPlot <- reactivePlot(function(){
    # generate a power spending function
    tt <- (0:100)/100
    alpha <- input$alpha
    spend <- sfPower(alpha,input$t,input$rho)$spend
    plot(tt, sfPower(alpha,tt,input$rho)$spend,
         xlab="Timing", ylab="Spend", main="Power Spending Function", type="l")
    points(input$t,spend,cex=2)
    if (spend > alpha/2) delt <- -alpha/20
    else delt <- alpha/20
    text(input$t,spend+delt,as.character(round(spend,4)))
  })
  N <- reactive(function(){
                   switch(input$dist, 
                      "User" = input$nfix,
                      "Binomial" = nBinomial(p1=input$p1,p2=input$p2,delta0=input$delta0,alpha=input$alpha,beta=1-input$Power)
                   )})
  output$dist <- reactivePrint(function(){N()})
  output$design <- reactivePrint(function(){
    gsDesign(k=input$km1+1,n.fix=N(),sfu=sfPower,sfl=sfPower,sfupar=input$rho,sflpar=input$lrho,alpha=input$alpha,
             beta=1-input$Power)})
  output$plot <- reactivePlot(function(){
    plot(gsDesign(k=input$km1+1,n.fix=N(),sfu=sfPower,sfl=sfPower,sfupar=input$rho,sflpar=input$lrho,alpha=input$alpha,
                  beta=1-input$Power),base=TRUE)
  })
})

custom UI html not working (e.g. runExample("08_html"))

I've tried custom HTML UI with example 8 and also with my own bare bones example. I get the following:

runExample("08_html")

Listening on port 8100
Error: argument "handler" is missing, with no default

I'm using shiny 0.1.1, websockets 1.1.4 on R 2.15.1 on Mac OS X 10.6.8.

radioButtons does not listen to "selected"

When setting up radioButtons, for example:

radioButtons("first", "Plot Type 1", c("p"="p","l"="l","g"="g"), selected="g")

the buttons shown in the interface does not change to "g", but continues to default to the first item in the list.

singleton and tags$head are not really compatible with reactiveUI

singleton and tags$head are designed to execute while the page is rendering for the first time and don't currently work in reactiveUI mode. Would need to put explicit support within reactiveUI to fix tags$head, where reactiveUI output that resulted in stuff being written to the head could be pushed there. And for singleton, maybe calculate a hash for each singleton and make that part of the HTML of the page somehow. The init call back to the server could include a list of all singleton hashes that have been calculated so far, this could be stored in shinyapp.

can't re-use output items on different tabs

I've got an app where I'm displaying the same data different ways on different tags. Below the output graphs, I've got this trivial item:

h3(textOutput("n"))

defined by:

  output$n <- reactiveText(function() {
    paste("n =", nrow(this_dat()))
  })

Works great if I have a single tab. If I have two tabs, each of which have the above (but with different plotOutput objects), then the Javascript crashes because of the duplicate object names.

The workaround is to duplicate the above with n2. Not a big deal, once I figured out the problem, but it'd be great if there were some way to have the same output objects on multiple tabs without error. At a minimum, a better error message would be very helpful.

Thanks!

Non-ASCII characters in reactiveUI seem to break

In this example, neither output is rendered at all.

shinyUI(pageWithSidebar(
  headerPanel("Header Panel"),
  sidebarPanel(    
    uiOutput("choiceControl")),
  mainPanel(
    verbatimTextOutput("main"))
))
shinyServer(function(input, output) {  
  output$choiceControl <- reactiveUI(function() {
    choice.names <- c("λ=0.1","λ=0.5","λ=0.9")
    choice.values <- as.list(1:3)
    names(choice.values) <- choice.names
    selectInput("choice", "Choose λ", choice.values)
  })
  output$main <- reactivePrint(function() {
    "Main Panel"
  })
})

Empty data frames cause JSON errors

JSON unexpected character error when empty data frame is supplied to custom outputs.

When a data frame is supplied that has neither rows NOR columns.

render called instead of error?

workaround: check for empty data frames and supply a data frame with the correct columns but no rows.

Note: can we get documentation on how best to throw errors in both the R and javascript sides?

Thanks for this AWESOME tool. My life just got way better.

Feature request: tabs for input windows

Any chance you will create a capability to have tabs in the input window to allow a more complex input structure?
-I would love to consider re-writing gsDesignExplorer interface (http://biopharmnet.com/wiki/GsDesign_Package) using Shiny (previously done using Qt...but apparently Qt is not working with R for Windows?????).

Comment: it has been pretty easy to do a simple screen! Thanks!

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.