datos_xp <- read_excel("C:/Users/admin/Downloads/Dataset Sancarlos (1).xlsx")
#View(datos_xp)
data<-data.frame(datos_xp$Fecha, datos_xp$Variedad, datos_xp$`Severidad RN`, datos_xp$`Reaccion RN`, datos_xp$Cluster, datos_xp$Hacienda)
datos1 <- data%>%
na.omit() %>%
group_by(datos_xp.Fecha, datos_xp.Variedad, datos_xp.Hacienda) %>%
summarise_at(vars(datos_xp..Severidad.RN.),
list(Severidad = mean))
t.ev<- datos1$datos_xp.Fecha
Variedad <- datos1$datos_xp.Variedad
Severidad <- datos1$Severidad/100
Hacienda<- datos1$datos_xp.Hacienda
sup.caf1<-data.frame(t.ev,Variedad,Severidad, Hacienda)
sup.caf<- sup.caf1 %>%
filter(Variedad == "CC01-1940" & Hacienda == "BALLESTEROS") %>%
mutate(time = 1:n())
sd(sup.caf$Severidad)
## [1] 0.05218414
f_lin <- fit_lin(
time = sup.caf$time,
y = sup.caf$Severidad
)
f_lin
## Results of fitting population models
##
## Stats:
## CCC r_squared RSE
## Monomolecular 0.4179 0.2642 0.0512
## Gompertz 0.4058 0.2545 0.2203
## Logistic 0.3874 0.2402 0.6202
## Exponential 0.3815 0.2357 0.5726
##
## Infection rate:
## Estimate Std.error Lower Upper
## Monomolecular -0.003540725 0.001137248 -0.005874166 -0.005874166
## Gompertz -0.014843730 0.004888641 -0.024874393 -0.024874393
## Logistic -0.040216772 0.013765265 -0.068460762 -0.068460762
## Exponential -0.036676047 0.012709016 -0.062752794 -0.062752794
##
## Initial inoculum:
## Estimate Linearized lin.SE Lower Upper
## Monomolecular 0.1374964 0.1479160 0.01953288 0.10222681 0.1713804
## Gompertz 0.1324240 -0.7039617 0.08396517 0.09054925 0.1823572
## Logistic 0.1295927 -1.9045644 0.23642618 0.08396374 0.1947466
## Exponential 0.1284160 -2.0524804 0.21828452 0.08205519 0.2009704
plot_lin <- plot_fit(f_lin,
point_size = 2,
line_size = 1,
)
# Default plots
plot_lin
#ggsave("cc03154.png")