transfer from old repo
This commit is contained in:
parent
cfa4a5f9cc
commit
277e2b8cf3
1111 changed files with 83736 additions and 0 deletions
24
1 PA Decline/calibration plot.R
Normal file
24
1 PA Decline/calibration plot.R
Normal file
|
|
@ -0,0 +1,24 @@
|
|||
# calibration plot
|
||||
|
||||
|
||||
ds <- openxlsx2::read_xlsx("1 PA Decline/Fra DDV/calibration_imp.xlsx")
|
||||
|
||||
p <- ds |> split(ds$model) |>
|
||||
purrr::imap(\(.x,.i){
|
||||
.x |> predtools::calibration_plot(obs="y",pred="pred")|>
|
||||
purrr::pluck("calibration_plot")+
|
||||
ggplot2::ggtitle(.i)+
|
||||
ggplot2::scale_x_continuous(breaks=seq(0,1,.25),limits=c(0,1))+
|
||||
ggplot2::scale_y_continuous(breaks=seq(0,1,.25),limits=c(-.1,1.1))
|
||||
}) |>
|
||||
patchwork::wrap_plots(ncol=2)
|
||||
|
||||
|
||||
ggplot2::ggsave(filename = "1 PA Decline/calibration_imp.pdf",
|
||||
plot=p,
|
||||
units = "mm",
|
||||
width = 200,
|
||||
height = 100,
|
||||
# pointsize = 30,
|
||||
dpi = 1200)
|
||||
|
||||
Loading…
Reference in a new issue