I witnessed a demo, and was given the source code and data model. I watched the owner import and run the source code flawlessly. When I run the code the UI inputs and text all render perfectly, but the plot area shows an error:
Error in ||: invalid 'y' type in 'x || y'
The plot area is generated by:
- an RDS model
- a Data Frame
- the predict() object.
I believe the source of the error is in the predict() object.
Here is the code snippet. I think the error is generated in the 2nd to last line.
I currently have R 3.6 Win libraries installed. Any hints or suggestions? I'm thinking it's something obvious, but I'm just missing it.
output$modelos <- renderPlot({
input$action
isolate({
rfs <- readRDS("myRdsFile.rds")
d <- data.frame(age=input$age,
dnrage=input$dnrage,
newblbmpr=input$newblbmpr,
blblpr=input$blblpr,
wbcpr=input$wbcpr,
ancpr=input$ancpr,
hbpr=input$hbpr,
platepr=input$platepr,
cytogener=input$cytogener,
leuk2=input$leuk2,
donorgp=input$donorgp,
new3_condint=input$new3_condint,
mkstat=input$mkstat,
invivo_tcd=input$invivo_tcd,
graftypecat=input$graftypecat,
kps=input$kps,
mut_tp53=input$mut_tp53,
mut_cux1=input$mut_cux1,
mut_ppm1d=input$mut_ppm1d,
MutNum=input$MutNum)
a <- predict(rfs, d, na.action = "na.impute")
plot.survival.rfsrc(a, xlim = c(0,36), ylim = c(0, 1))
})
})