Uh oh!
There was an error while loading.Please reload this page.
- Notifications
You must be signed in to change notification settings - Fork51
R - TEAL on Local Machine (Error)#1086
-
I am using the following code to test on Rstudio on my local machine, but the get the following error library(teal) shinyApp(app$ui,app$server) Error: |
BetaWas this translation helpful?Give feedback.
All reactions
Replies: 5 comments 8 replies
-
Can I see sessionInfo()? If it's easier, you can wait until next week when we're done releasing everything. |
BetaWas this translation helpful?Give feedback.
All reactions
-
Here is the session info details. Thank you! |
BetaWas this translation helpful?Give feedback.
All reactions
-
As I suspected, you are using the latest release of install.packages("teal.slice",repos= c("https://insightsengineering.r-universe.dev", getOption("repos")))install.packages("teal",repos= c("https://insightsengineering.r-universe.dev", getOption("repos"))) And, you have to use the new way to define teal.data as@chlebowa has pointed out on different comment. |
BetaWas this translation helpful?Give feedback.
All reactions
Uh oh!
There was an error while loading.Please reload this page.
Uh oh!
There was an error while loading.Please reload this page.
-
Hi Donny, i have tried this as well and have the same error |
BetaWas this translation helpful?Give feedback.
All reactions
-
Apologies, I gave the wrong URL to get the Can you please reinstall and try it out again? |
BetaWas this translation helpful?Give feedback.
All reactions
-
Perfect. Works now. Thank you so much to you and to your team for your awesome work and presentations on TEAL package. |
BetaWas this translation helpful?Give feedback.
All reactions
👍 1🎉 1
-
Try this: |
BetaWas this translation helpful?Give feedback.
All reactions
-
Hello, I have tried the code you provided , I have the same error. Thank you |
BetaWas this translation helpful?Give feedback.
All reactions
-
Hello,using the following code to reproduce in locol machine but i see thiserror. [INFO] 2024-02-07 13:09:26.8288 pid:22628 token:[] teal.modules.clinicalInitializing tm_t_eventsError in choices_selected(c("ARM", "ARMCD"), "ARM") : could not find function "choices_selected"adsl <- tmc_ex_adsladae <- tmc_ex_adaeapp <- teal::init( data = cdisc_data("ADSL" = adsl, "ADAE" = adae ), modules = modules( tm_t_events( label = "Adverse Event Table", dataname = "ADAE", arm_var = choices_selected(c("ARM", "ARMCD"), "ARM"), llt = choices_selected( choices = variable_choices(adae, c("AETERM", "AEDECOD")), selected = c("AEDECOD") ), hlt = choices_selected( choices = variable_choices(adae, c("AEBODSYS", "AESOC")), selected = "AEBODSYS" ), add_total = TRUE, event_type = "adverse event" ) ))if (interactive()) { shinyApp(app$ui, app$server)} …On Tue, Feb 6, 2024 at 11:01 AM Dony Unardi ***@***.***> wrote: Apologies, I gave the wrong URL to get the main branch of teal. Your teal.slice version is correct. Can you please reinstall teal again using this code: install.packages("teal", repos = c("https://pharmaverse.r-universe.dev", getOption("repos"))) and try it out again? — Reply to this email directly, view it on GitHub <#1086 (reply in thread)>, or unsubscribe <https://github.com/notifications/unsubscribe-auth/BFYKYFRLRDW2JAI7OYSA7J3YSJ4YDAVCNFSM6AAAAABCXN3YUKVHI2DSMVQWIX3LMV43SRDJONRXK43TNFXW4Q3PNVWWK3TUHM4DGOBWG44DC> . You are receiving this because you were mentioned.Message ID: ***@***.*** com> |
BetaWas this translation helpful?Give feedback.
All reactions
Uh oh!
There was an error while loading.Please reload this page.
Uh oh!
There was an error while loading.Please reload this page.
-
Can you make sure that you have teal.transform and tmc from install.packages("teal",repos= c("https://pharmaverse.r-universe.dev", getOption("repos")))install.packages("teal.modules.clinical",repos= c("https://pharmaverse.r-universe.dev", getOption("repos"))) Again, apologies for this, we're in the middle of the release. |
BetaWas this translation helpful?Give feedback.
All reactions
-
I will wait until the release. I have been having issues with running allthe example code on the local machine.. sometimes the shiny app appears andcloses immediately and some errors due to functions being deprecated . Theydo run fine without any issues on the TEAL playground on posit cloud. I aminstalling from main.Thanks …On Wed, Feb 7, 2024 at 2:30 PM Dony Unardi ***@***.***> wrote: Can you make sure that you're installing teal.transform and tmc from main? install.packages("teal", repos = c("https://pharmaverse.r-universe.dev", getOption("repos"))) install.packages("teal.modules.clinical", repos = c("https://pharmaverse.r-universe.dev", getOption("repos"))) Again, apologies for this, we're in the middle of the release. — Reply to this email directly, view it on GitHub <#1086 (reply in thread)>, or unsubscribe <https://github.com/notifications/unsubscribe-auth/BFYKYFRVZRR2J5SG4SDBASTYSP6BRAVCNFSM6AAAAABCXN3YUKVHI2DSMVQWIX3LMV43SRDJONRXK43TNFXW4Q3PNVWWK3TUHM4DIMBQG4YTC> . You are receiving this because you were mentioned.Message ID: ***@***.*** com> |
BetaWas this translation helpful?Give feedback.
All reactions
Uh oh!
There was an error while loading.Please reload this page.
Uh oh!
There was an error while loading.Please reload this page.
-
Apologies that you are experiencing this. Although we are keeping a migration path for the old data APIs, the whole {teal} environment needs to use the CRAN releases(or development/ As@donyunardi suggested, installing packages from the I use the following snippet to make sure that my whole teal environment is up-to-date with development packages. c("teal","teal.data","teal.code","teal.slice","teal.logger","teal.widgets","teal.reporter","teal.transform","teal.modules.general","teal.modules.clinical","rtables","tern")|> install.packages(repos= c(pharmaverse="https://pharmaverse.r-universe.dev", getOption("repos") )) With this and the code snippet you shared above, I can run locally the All the examples imply that you are loading library(teal.modules.clinical)adsl<-tmc_ex_adsladae<-tmc_ex_adaeapp<-teal::init(data= cdisc_data("ADSL"=adsl,"ADAE"=adae ),modules= modules( tm_t_events(label="Adverse Event Table",dataname="ADAE",arm_var= choices_selected(c("ARM","ARMCD"),"ARM"),llt= choices_selected(choices= variable_choices(adae, c("AETERM","AEDECOD")),selected= c("AEDECOD") ),hlt= choices_selected(choices= variable_choices(adae, c("AEBODSYS","AESOC")),selected="AEBODSYS" ),add_total=TRUE,event_type="adverse event" ) ))if (interactive()) { shinyApp(app$ui,app$server)} |
BetaWas this translation helpful?Give feedback.
All reactions
-
Thank you. runs fine without errors, but i do see the following and theshinyapp flashes for a sec and closes immediately., not sure why..Listening onhttp://127.0.0.1:3038[INFO] 2024-02-08 07:44:58.3513pid:27528 token:[90831486] teal Initializingreporter_previewer_moduleWarning: Error in add_card_button_srv:Assertion on 'names(formals(card_fun))' failed: Must be a subset of{'card','comment'}, but has additional elements {'label'}. 3: runApp 2: print.shiny.appobj 1: <Anonymous> …On Thu, Feb 8, 2024 at 4:42 AM André Veríssimo ***@***.***> wrote: Apologies that you are experiencing this. Although we are keeping a migration path for the old data APIs, the whole {teal} environment needs to use the CRAN releases *(or development/main for those that are not yet on CRAN)*. As@donyunardi <https://github.com/donyunardi> said, installing all the packages from the pharmaverse.r-universe.dev repository should allow you to run that {teal} application and other examples without issues. I use the following snippet to make sure that my whole teal environment is up-to-date with development packages. c( "teal", "teal.data", "teal.code", "teal.slice", "teal.logger", "teal.widgets", "teal.reporter", "teal.transform", "teal.modules.general", "teal.modules.clinical", "rtables", "tern" ) |> install.packages( repos = c( pharmaverse = "https://pharmaverse.r-universe.dev", getOption("repos") ) ) With this and the code snippet you shared above, I can run locally the {teal} application *(added just 1 library call)* All the examples imply that you are loading {teal.modules.clinical} so it is fundamental as it will, in turn, load the choices_selected and variable_choices from {teal.transform}. library(teal.modules.clinical) adsl <- tmc_ex_adsladae <- tmc_ex_adae app <- teal::init( data = cdisc_data("ADSL" = adsl, "ADAE" = adae ), modules = modules( tm_t_events( label = "Adverse Event Table", dataname = "ADAE", arm_var = choices_selected(c("ARM", "ARMCD"), "ARM"), llt = choices_selected( choices = variable_choices(adae, c("AETERM", "AEDECOD")), selected = c("AEDECOD") ), hlt = choices_selected( choices = variable_choices(adae, c("AEBODSYS", "AESOC")), selected = "AEBODSYS" ), add_total = TRUE, event_type = "adverse event" ) ) ) if (interactive()) { shinyApp(app$ui, app$server) } image.png (view on web) <https://github.com/insightsengineering/teal/assets/211358/63130662-f32b-435b-9942-c222bf4a1591> — Reply to this email directly, view it on GitHub <#1086 (reply in thread)>, or unsubscribe <https://github.com/notifications/unsubscribe-auth/BFYKYFUBNPSWPNTK7DWDOY3YSTBZ3AVCNFSM6AAAAABCXN3YUKVHI2DSMVQWIX3LMV43SRDJONRXK43TNFXW4Q3PNVWWK3TUHM4DIMBXGA4DS> . You are receiving this because you were mentioned.Message ID: ***@***.*** com> |
BetaWas this translation helpful?Give feedback.
All reactions
👍 1
