Running examples in 'multinma-Ex.R' failed
The error most likely occurred in:

> ### Name: example_pso_mlnmr
> ### Title: Example plaque psoriasis ML-NMR
> ### Aliases: example_pso_mlnmr
> ### Keywords: examples
> 
> ### ** Examples
> 
> # Set up plaque psoriasis network combining IPD and AgD
> library(dplyr)

Attaching package: 'dplyr'

The following objects are masked from 'package:stats':

    filter, lag

The following objects are masked from 'package:base':

    intersect, setdiff, setequal, union

> pso_ipd <- filter(plaque_psoriasis_ipd,
+                   studyc %in% c("UNCOVER-1", "UNCOVER-2", "UNCOVER-3"))
> 
> pso_agd <- filter(plaque_psoriasis_agd,
+                   studyc == "FIXTURE")
> 
> head(pso_ipd)
     studyc      trtc_long    trtc trtn pasi75 pasi90 pasi100 age  bmi pasi_w0
1 UNCOVER-1 Ixekizumab Q2W IXE_Q2W    2      0      0       0  34 32.2    18.2
2 UNCOVER-1 Ixekizumab Q2W IXE_Q2W    2      1      0       0  64 41.9    23.4
3 UNCOVER-1 Ixekizumab Q2W IXE_Q2W    2      1      1       0  42 26.2    12.8
4 UNCOVER-1 Ixekizumab Q2W IXE_Q2W    2      0      0       0  45 52.9    36.0
5 UNCOVER-1 Ixekizumab Q2W IXE_Q2W    2      1      0       0  67 22.9    20.9
6 UNCOVER-1 Ixekizumab Q2W IXE_Q2W    2      1      1       1  57 22.4    18.2
   male bsa weight durnpso prevsys   psa
1  TRUE  18   98.1     6.7    TRUE  TRUE
2  TRUE  33  129.6    14.5   FALSE  TRUE
3  TRUE  33   78.0    26.5    TRUE FALSE
4 FALSE  50  139.9    25.0    TRUE  TRUE
5 FALSE  35   54.2    11.9    TRUE FALSE
6  TRUE  29   67.5    15.2    TRUE FALSE
> head(pso_agd)
   studyc          trtc_long    trtc trtn pasi75_r pasi75_n pasi90_r pasi90_n
1 FIXTURE         Etanercept     ETN    4      142      323       67      323
2 FIXTURE            Placebo     PBO    1       16      324        5      324
3 FIXTURE Secukinumab 150 mg SEC_150    5      219      327      137      327
4 FIXTURE Secukinumab 300 mg SEC_300    6      249      323      175      323
  pasi100_r pasi100_n sample_size_w0 age_mean age_sd bmi_mean bmi_sd
1        14       323            326     43.8   13.0     28.7    5.9
2         0       324            326     44.1   12.6     27.9    6.1
3        47       327            327     45.4   12.9     28.4    5.9
4        78       323            327     44.5   13.2     28.4    6.4
  pasi_w0_mean pasi_w0_sd male bsa_mean bsa_sd weight_mean weight_sd
1         23.2        9.8 71.2     33.6   18.0        84.6      20.5
2         24.1       10.5 72.7     35.2   19.1        82.0      20.4
3         23.7       10.5 72.2     34.5   19.4        83.6      20.8
4         23.9        9.9 68.5     34.3   19.2        83.0      21.6
  durnpso_mean durnpso_sd prevsys  psa
1         16.4       12.0    65.6 13.5
2         16.6       11.6    62.6 15.0
3         17.3       12.2    64.8 15.0
4         15.8       12.3    63.0 15.3
> 
> pso_ipd <- pso_ipd %>%
+   mutate(# Variable transformations
+     bsa = bsa / 100,
+     prevsys = as.numeric(prevsys),
+     psa = as.numeric(psa),
+     weight = weight / 10,
+     durnpso = durnpso / 10,
+     # Treatment classes
+     trtclass = case_when(trtn == 1 ~ "Placebo",
+                          trtn %in% c(2, 3, 5, 6) ~ "IL blocker",
+                          trtn == 4 ~ "TNFa blocker"),
+     # Check complete cases for covariates of interest
+     complete = complete.cases(durnpso, prevsys, bsa, weight, psa)
+   )
> 
> pso_agd <- pso_agd %>%
+   mutate(
+     # Variable transformations
+     bsa_mean = bsa_mean / 100,
+     bsa_sd = bsa_sd / 100,
+     prevsys = prevsys / 100,
+     psa = psa / 100,
+     weight_mean = weight_mean / 10,
+     weight_sd = weight_sd / 10,
+     durnpso_mean = durnpso_mean / 10,
+     durnpso_sd = durnpso_sd / 10,
+     # Treatment classes
+     trtclass = case_when(trtn == 1 ~ "Placebo",
+                          trtn %in% c(2, 3, 5, 6) ~ "IL blocker",
+                          trtn == 4 ~ "TNFa blocker")
+   )
> 
> # Exclude small number of individuals with missing covariates
> pso_ipd <- filter(pso_ipd, complete)
> 
> pso_net <- combine_network(
+   set_ipd(pso_ipd,
+           study = studyc,
+           trt = trtc,
+           r = pasi75,
+           trt_class = trtclass),
+   set_agd_arm(pso_agd,
+               study = studyc,
+               trt = trtc,
+               r = pasi75_r,
+               n = pasi75_n,
+               trt_class = trtclass)
+ )
Error in library.dynam(lib, package, package.lib) : 
  DLL 'purrr' not found: maybe not installed for this architecture?
Calls: combine_network ... get_default_trt_ref -> loadNamespace -> library.dynam
Execution halted