Solucionar bug firstoper.
This commit is contained in:
+7
-6
@@ -496,9 +496,9 @@ server <- function(input, output) {
|
||||
|
||||
firstoper<- filter(table, !is.na(substr(Observations,1,1)) & substr(Observations,1,1) == "*") %>%
|
||||
pull(DayPostInoc) %>% min(na.rm = T)
|
||||
print(firstoper)
|
||||
if (firstoper == Inf){firstoper<-c()}
|
||||
|
||||
if (input$operated == TRUE & nrow(firstoper) > 0){
|
||||
if (input$operated == TRUE & length(firstoper) > 0){
|
||||
table<-table %>% filter(DayPostInoc < firstoper)
|
||||
}else{
|
||||
deadmice<-filter(table, !is.na(substr(Observations,1,1)) & substr(Observations,1,1) == "+") %>%
|
||||
@@ -569,9 +569,9 @@ server <- function(input, output) {
|
||||
}else{
|
||||
firstoper<- filter(table, !is.na(substr(Observations,1,1)) & substr(Observations,1,1) == "*") %>%
|
||||
pull(DayPostInoc) %>% min(na.rm = T)
|
||||
print(firstoper)
|
||||
if (firstoper == Inf){firstoper<-c()}
|
||||
|
||||
if (input$operated == TRUE & nrow(firstoper) > 0){
|
||||
if (input$operated == TRUE & length(firstoper) > 0){
|
||||
table<-table %>% filter(DayPostInoc < firstoper)
|
||||
}else{
|
||||
deadmice<-filter(table, !is.na(substr(Observations,1,1)) & substr(Observations,1,1) == "+") %>%
|
||||
@@ -601,8 +601,9 @@ server <- function(input, output) {
|
||||
if (input$vacc == "Sí"){
|
||||
firstoper<- filter(table, !is.na(substr(Observations,1,1)) & substr(Observations,1,1) == "*") %>%
|
||||
select(DayPostInoc, Side) %>% unique() %>%
|
||||
group_by(Side) %>% summarise(FirstOper=min(DayPostInoc))
|
||||
if (input$operated == TRUE & nrow(firstoper) > 0){
|
||||
if (firstoper == Inf){firstoper<-c()}
|
||||
|
||||
if (input$operated == TRUE & length(firstoper) > 0){
|
||||
for (i in 1:nrow(firstoper)){
|
||||
table<-table %>% filter(DayPostInoc < firstoper$FirstOper[i] | Side != firstoper$Side[i])
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user