Skip to content

Commit

Permalink
removed shinyMatrix dependency
Browse files Browse the repository at this point in the history
  • Loading branch information
TGuillerme committed Oct 1, 2019
1 parent b3631e3 commit 9d9bb3c
Show file tree
Hide file tree
Showing 3 changed files with 12 additions and 13 deletions.
4 changes: 2 additions & 2 deletions rsconnect/shinyapps.io/tguillerme/moms.dcf
Original file line number Diff line number Diff line change
Expand Up @@ -5,6 +5,6 @@ account: tguillerme
server: shinyapps.io
hostUrl: https://api.shinyapps.io/v1
appId: 1266739
bundleId: 2457444
bundleId: 2457620
url: https://tguillerme.shinyapps.io/moms/
when: 1569894609.90622
when: 1569901005.09365
9 changes: 4 additions & 5 deletions server.R
Original file line number Diff line number Diff line change
@@ -1,5 +1,4 @@
library(shiny)
library(shinyMatrix)
library(dispRity)
library(moms)

Expand Down Expand Up @@ -32,10 +31,10 @@ shinyServer(
shiny::updateNumericInput(session, "n_elements", max = nrow(space), value = nrow(space))
}

## Update the matrix input
if(input$space_type == "User") {
shinyMatrix::updateMatrixInput(session, "cor.matrix", value = diag(input$n_dimensions))
}
# ## Update the matrix input
# if(input$space_type == "User") {
# shinyMatrix::updateMatrixInput(session, "cor.matrix", value = diag(input$n_dimensions))
# }

## Return error
if(class(space) == "character") {
Expand Down
12 changes: 6 additions & 6 deletions ui.R
Original file line number Diff line number Diff line change
Expand Up @@ -102,17 +102,17 @@ shinyUI(fluidPage(
),

## Correlation - input$correlation
selectInput("correlation", label = h5("Dimensions correlation"), choices = list("Uncorrelated", "Matrix", "Vector", "Upload"), selected = "Uncorrelated"),
selectInput("correlation", label = h5("Dimensions correlation"), choices = list("Uncorrelated", "Vector", "Upload"), selected = "Uncorrelated"),
conditionalPanel(condition = "input.correlation == \"Vector\"",
textInput("correlation_value_vector", label = "Correlations", value = "0.1,0.2,0.3"),
## Parameters
helpText("Enter the correlation between each axis as the lower diagonal of a correlation matrix (separated by a comma). For example, for three dimensions D1, D2, D3, D4 enter 0.1,0.2,0.3,0.4,0.5,0.6 for a correlation of respectively 0.1 for D1 and D2; 0.2 for D1,D3; 0.3 for D1,D4;, 0.4 for D2,D3; 0.5 for D2,D4; and 0.6 for D3,D4.")
),
conditionalPanel(condition = "input.correlation == \"Matrix\"",
shinyMatrix::matrixInput(inputId = "cor.matrix", value = diag(3), class = "numeric"),
## Parameters
helpText("Enter the correlation value between each axis. The upper triangle and the diagonal are ignored. Note that this input option is ignored if using more than 15 dimensions.")
),
# conditionalPanel(condition = "input.correlation == \"Matrix\"",
# shinyMatrix::matrixInput(inputId = "cor.matrix", value = diag(3), class = "numeric"),
# ## Parameters
# helpText("Enter the correlation value between each axis. The upper triangle and the diagonal are ignored. Note that this input option is ignored if using more than 15 dimensions.")
# ),
conditionalPanel(condition = "input.correlation == \"Upload\"",
## Parameters
fileInput("correlation_value_csv", label = "Select a matrix in csv format."),
Expand Down

0 comments on commit 9d9bb3c

Please sign in to comment.