From f9aef54fa002b6003166ce72bc81c92b332afe26 Mon Sep 17 00:00:00 2001 From: marcelcosta Date: Wed, 25 Jan 2023 17:04:00 +0100 Subject: [PATCH] Corregir ntumors as.numeric. --- invivos/app.R | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/invivos/app.R b/invivos/app.R index 6e16165..6e49c60 100755 --- a/invivos/app.R +++ b/invivos/app.R @@ -290,7 +290,7 @@ server <- function(input, output) { content = function(file){ ncages<-input$ncages nrat_cage<-5 - id_tumors<-c("L","R") + id_tumors<-c("L","R")[input$ntumors] # timepoint<-c(7,10,13,16,19,22,25) if (!is.null(input$file_sizes)){ @@ -320,11 +320,12 @@ server <- function(input, output) { # dtemplate["ID animal"]<-gsub("[LR]","",dtemplate$`ID animal`) # dtemplate[,5:ncol(dtemplate)]<-"" }else{ + template<-data.frame( - Cage=rep(LETTERS[1:ncages], each=nrat_cage*input$ntumors), + Cage=rep(LETTERS[1:ncages], each=nrat_cage*as.numeric(input$ntumors)), Date="", DayPostInoc="", - Animal=rep(1:(nrat_cage*ncages), each=input$ntumors), + Animal=rep(1:(nrat_cage*ncages), each=as.numeric(input$ntumors)), Group="", Side=rep(id_tumors, nrat_cage*ncages), Weight="",