Skip to content

Commit

Permalink
fix: remove instruction step for file upload
Browse files Browse the repository at this point in the history
  • Loading branch information
tin900 committed Dec 11, 2023
1 parent 5ecc99f commit f3d77b5
Show file tree
Hide file tree
Showing 2 changed files with 11 additions and 16 deletions.
3 changes: 1 addition & 2 deletions R/server.R
Original file line number Diff line number Diff line change
Expand Up @@ -10,10 +10,9 @@ app_server <- function(input, output, session) {

steps <- shiny::reactive({
data.frame(
element = c(NA, "#file", "#sep", "#header", "#dependent_var_dropdown", "#independent_var_dropdown", "#input_mean", "#identifier_dropdown", "#statistical_test_dropdown"),
element = c(NA, "#sep", "#header", "#dependent_var_dropdown", "#independent_var_dropdown", "#input_mean", "#identifier_dropdown", "#statistical_test_dropdown"),
intro = c(
"Welcome to the Statistical Test App. Let's start by uploading a file.",
"This is where you upload your file.",
"Select the separator used in your file.",
"Check this if your file has a header.",
"Choose the dependent variable from this dropdown.",
Expand Down
24 changes: 10 additions & 14 deletions R/ui.R
Original file line number Diff line number Diff line change
Expand Up @@ -14,11 +14,7 @@ app_ui <- function() {
# Sidebar with a browse button for file upload
shiny::sidebarLayout(
shiny::sidebarPanel(
rintrojs::introBox(
shiny::fileInput("file", "Upload a file"),
data.step = 1,
data.intro = "This is where you upload your file."
),

# UI elements for separator and header
rintrojs::introBox(
Expand All @@ -27,68 +23,68 @@ app_ui <- function() {
Semicolon = ";",
Tab = "\t"),
selected = ","),
data.step = 2,
data.step = 1,
data.intro = "Select the separator used in your file."
),

rintrojs::introBox(
shiny::checkboxInput("header", "Header", TRUE),
data.step = 3,
data.step = 2,
data.intro = "Check this if your file has a header."
),

# Dropdown for choosing the dependent variable
rintrojs::introBox(
shiny::uiOutput("dependent_var_dropdown"),
data.step = 4,
data.step = 3,
data.intro = "Choose the dependent variable from this dropdown."
),

# Text below the dropdowns
rintrojs::introBox(
shiny::textOutput("dependent_var_text"),
data.step = 5,
data.step = 4,
data.intro = "This is the dependent variable text."
),

# Dropdown for choosing the independent variable
rintrojs::introBox(
shiny::uiOutput("independent_var_dropdown"),
data.step = 6,
data.step = 5,
data.intro = "Choose the independent variable from this dropdown."
),

rintrojs::introBox(
shiny::textOutput("independent_var_text"), # New output element for the independent variable text
data.step = 7,
data.step = 6,
data.intro = "This is the independent variable text."
),

# Input field for mean (hidden initially)
rintrojs::introBox(
shiny::uiOutput("input_mean"),
data.step = 8,
data.step = 7,
data.intro = "Enter the mean here."
),

# Dropdown for choosing the independent variable
rintrojs::introBox(
shiny::uiOutput("identifier_dropdown"),
data.step = 9,
data.step = 8,
data.intro = "Choose the identifier from this dropdown."
),

# New dropdown for selecting statistical test
rintrojs::introBox(
shiny::uiOutput("statistical_test_dropdown"),
data.step = 10,
data.step = 9,
data.intro = "Choose the statistical test from this dropdown."
),

# Area to display the test report
rintrojs::introBox(
shiny::verbatimTextOutput("test_report"),
data.step = 11,
data.step = 10,
data.intro = "This is the area to display the test report."
)
),
Expand Down

0 comments on commit f3d77b5

Please sign in to comment.