0s autopkgtest [15:19:16]: starting date and time: 2025-03-15 15:19:16+0000 0s autopkgtest [15:19:16]: git checkout: 325255d2 Merge branch 'pin-any-arch' into 'ubuntu/production' 0s autopkgtest [15:19:16]: host juju-7f2275-prod-proposed-migration-environment-9; command line: /home/ubuntu/autopkgtest/runner/autopkgtest --output-dir /tmp/autopkgtest-work.3ohzxuil/out --timeout-copy=6000 --setup-commands 'ln -s /dev/null /etc/systemd/system/bluetooth.service; printf "http_proxy=http://squid.internal:3128\nhttps_proxy=http://squid.internal:3128\nno_proxy=127.0.0.1,127.0.1.1,login.ubuntu.com,localhost,localdomain,novalocal,internal,archive.ubuntu.com,ports.ubuntu.com,security.ubuntu.com,ddebs.ubuntu.com,changelogs.ubuntu.com,keyserver.ubuntu.com,launchpadlibrarian.net,launchpadcontent.net,launchpad.net,10.24.0.0/24,keystone.ps5.canonical.com,objectstorage.prodstack5.canonical.com,radosgw.ps5.canonical.com\n" >> /etc/environment' --apt-pocket=proposed=src:glibc --apt-upgrade r-cran-ordinal --timeout-short=300 --timeout-copy=20000 --timeout-build=20000 --env=ADT_TEST_TRIGGERS=glibc/2.41-1ubuntu2 -- lxd -r lxd-armhf-10.145.243.254 lxd-armhf-10.145.243.254:autopkgtest/ubuntu/plucky/armhf 23s autopkgtest [15:19:39]: testbed dpkg architecture: armhf 25s autopkgtest [15:19:41]: testbed apt version: 2.9.33 30s autopkgtest [15:19:46]: @@@@@@@@@@@@@@@@@@@@ test bed setup 32s autopkgtest [15:19:48]: testbed release detected to be: None 40s autopkgtest [15:19:56]: updating testbed package index (apt update) 43s Get:1 http://ftpmaster.internal/ubuntu plucky-proposed InRelease [126 kB] 43s Get:2 http://ftpmaster.internal/ubuntu plucky InRelease [257 kB] 43s Get:3 http://ftpmaster.internal/ubuntu plucky-updates InRelease [126 kB] 43s Get:4 http://ftpmaster.internal/ubuntu plucky-security InRelease [126 kB] 43s Get:5 http://ftpmaster.internal/ubuntu plucky-proposed/universe Sources [404 kB] 43s Get:6 http://ftpmaster.internal/ubuntu plucky-proposed/main Sources [101 kB] 43s Get:7 http://ftpmaster.internal/ubuntu plucky-proposed/multiverse Sources [15.8 kB] 43s Get:8 http://ftpmaster.internal/ubuntu plucky-proposed/main armhf Packages [81.0 kB] 43s Get:9 http://ftpmaster.internal/ubuntu plucky-proposed/main armhf c-n-f Metadata [1944 B] 43s Get:10 http://ftpmaster.internal/ubuntu plucky-proposed/restricted armhf c-n-f Metadata [116 B] 43s Get:11 http://ftpmaster.internal/ubuntu plucky-proposed/universe armhf Packages [326 kB] 43s Get:12 http://ftpmaster.internal/ubuntu plucky-proposed/universe armhf c-n-f Metadata [12.1 kB] 43s Get:13 http://ftpmaster.internal/ubuntu plucky-proposed/multiverse armhf Packages [3472 B] 43s Get:14 http://ftpmaster.internal/ubuntu plucky-proposed/multiverse armhf c-n-f Metadata [332 B] 43s Get:15 http://ftpmaster.internal/ubuntu plucky/multiverse Sources [299 kB] 43s Get:16 http://ftpmaster.internal/ubuntu plucky/universe Sources [21.0 MB] 45s Get:17 http://ftpmaster.internal/ubuntu plucky/main Sources [1400 kB] 45s Get:18 http://ftpmaster.internal/ubuntu plucky/main armhf Packages [1378 kB] 45s Get:19 http://ftpmaster.internal/ubuntu plucky/main armhf c-n-f Metadata [29.4 kB] 45s Get:20 http://ftpmaster.internal/ubuntu plucky/restricted armhf c-n-f Metadata [108 B] 45s Get:21 http://ftpmaster.internal/ubuntu plucky/universe armhf Packages [15.1 MB] 45s Get:22 http://ftpmaster.internal/ubuntu plucky/multiverse armhf Packages [172 kB] 48s Fetched 41.0 MB in 6s (7371 kB/s) 49s Reading package lists... 56s autopkgtest [15:20:12]: upgrading testbed (apt dist-upgrade and autopurge) 58s Reading package lists... 58s Building dependency tree... 58s Reading state information... 59s Calculating upgrade...Starting pkgProblemResolver with broken count: 0 59s Starting 2 pkgProblemResolver with broken count: 0 59s Done 60s Entering ResolveByKeep 60s 60s Calculating upgrade... 60s The following packages will be upgraded: 60s libc-bin libc6 locales python3-jinja2 sos strace 61s 6 upgraded, 0 newly installed, 0 to remove and 0 not upgraded. 61s Need to get 8642 kB of archives. 61s After this operation, 23.6 kB of additional disk space will be used. 61s Get:1 http://ftpmaster.internal/ubuntu plucky-proposed/main armhf libc6 armhf 2.41-1ubuntu2 [2932 kB] 61s Get:2 http://ftpmaster.internal/ubuntu plucky-proposed/main armhf libc-bin armhf 2.41-1ubuntu2 [545 kB] 61s Get:3 http://ftpmaster.internal/ubuntu plucky-proposed/main armhf locales all 2.41-1ubuntu2 [4246 kB] 61s Get:4 http://ftpmaster.internal/ubuntu plucky/main armhf strace armhf 6.13+ds-1ubuntu1 [445 kB] 61s Get:5 http://ftpmaster.internal/ubuntu plucky/main armhf python3-jinja2 all 3.1.5-2ubuntu1 [109 kB] 61s Get:6 http://ftpmaster.internal/ubuntu plucky/main armhf sos all 4.9.0-5 [365 kB] 62s Preconfiguring packages ... 62s Fetched 8642 kB in 1s (9855 kB/s) 62s (Reading database ... (Reading database ... 5% (Reading database ... 10% (Reading database ... 15% (Reading database ... 20% (Reading database ... 25% (Reading database ... 30% (Reading database ... 35% (Reading database ... 40% (Reading database ... 45% (Reading database ... 50% (Reading database ... 55% (Reading database ... 60% (Reading database ... 65% (Reading database ... 70% (Reading database ... 75% (Reading database ... 80% (Reading database ... 85% (Reading database ... 90% (Reading database ... 95% (Reading database ... 100% (Reading database ... 64655 files and directories currently installed.) 62s Preparing to unpack .../libc6_2.41-1ubuntu2_armhf.deb ... 62s Unpacking libc6:armhf (2.41-1ubuntu2) over (2.41-1ubuntu1) ... 62s Setting up libc6:armhf (2.41-1ubuntu2) ... 63s (Reading database ... (Reading database ... 5% (Reading database ... 10% (Reading database ... 15% (Reading database ... 20% (Reading database ... 25% (Reading database ... 30% (Reading database ... 35% (Reading database ... 40% (Reading database ... 45% (Reading database ... 50% (Reading database ... 55% (Reading database ... 60% (Reading database ... 65% (Reading database ... 70% (Reading database ... 75% (Reading database ... 80% (Reading database ... 85% (Reading database ... 90% (Reading database ... 95% (Reading database ... 100% (Reading database ... 64655 files and directories currently installed.) 63s Preparing to unpack .../libc-bin_2.41-1ubuntu2_armhf.deb ... 63s Unpacking libc-bin (2.41-1ubuntu2) over (2.41-1ubuntu1) ... 63s Setting up libc-bin (2.41-1ubuntu2) ... 63s (Reading database ... (Reading database ... 5% (Reading database ... 10% (Reading database ... 15% (Reading database ... 20% (Reading database ... 25% (Reading database ... 30% (Reading database ... 35% (Reading database ... 40% (Reading database ... 45% (Reading database ... 50% (Reading database ... 55% (Reading database ... 60% (Reading database ... 65% (Reading database ... 70% (Reading database ... 75% (Reading database ... 80% (Reading database ... 85% (Reading database ... 90% (Reading database ... 95% (Reading database ... 100% (Reading database ... 64655 files and directories currently installed.) 63s Preparing to unpack .../locales_2.41-1ubuntu2_all.deb ... 63s Unpacking locales (2.41-1ubuntu2) over (2.41-1ubuntu1) ... 63s Preparing to unpack .../strace_6.13+ds-1ubuntu1_armhf.deb ... 63s Unpacking strace (6.13+ds-1ubuntu1) over (6.11-0ubuntu1) ... 63s Preparing to unpack .../python3-jinja2_3.1.5-2ubuntu1_all.deb ... 63s Unpacking python3-jinja2 (3.1.5-2ubuntu1) over (3.1.5-2) ... 64s Preparing to unpack .../archives/sos_4.9.0-5_all.deb ... 64s Unpacking sos (4.9.0-5) over (4.9.0-4) ... 64s Setting up sos (4.9.0-5) ... 65s Setting up locales (2.41-1ubuntu2) ... 65s Generating locales (this might take a while)... 67s en_US.UTF-8... done 67s Generation complete. 67s Setting up python3-jinja2 (3.1.5-2ubuntu1) ... 68s Setting up strace (6.13+ds-1ubuntu1) ... 68s Processing triggers for man-db (2.13.0-1) ... 69s Processing triggers for systemd (257.3-1ubuntu3) ... 71s Reading package lists... 72s Building dependency tree... 72s Reading state information... 72s Starting pkgProblemResolver with broken count: 0 72s Starting 2 pkgProblemResolver with broken count: 0 72s Done 72s Solving dependencies... 73s 0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded. 76s autopkgtest [15:20:32]: rebooting testbed after setup commands that affected boot 120s autopkgtest [15:21:16]: testbed running kernel: Linux 6.8.0-52-generic #53~22.04.1-Ubuntu SMP PREEMPT_DYNAMIC Wed Jan 15 18:10:51 UTC 2 147s autopkgtest [15:21:43]: @@@@@@@@@@@@@@@@@@@@ apt-source r-cran-ordinal 159s Get:1 http://ftpmaster.internal/ubuntu plucky/universe r-cran-ordinal 2023.12-4.1-1 (dsc) [2258 B] 159s Get:2 http://ftpmaster.internal/ubuntu plucky/universe r-cran-ordinal 2023.12-4.1-1 (tar) [804 kB] 159s Get:3 http://ftpmaster.internal/ubuntu plucky/universe r-cran-ordinal 2023.12-4.1-1 (diff) [3132 B] 159s gpgv: Signature made Wed Oct 9 23:44:36 2024 UTC 159s gpgv: using RSA key 73471499CC60ED9EEE805946C5BD6C8F2295D502 159s gpgv: issuer "plessy@debian.org" 159s gpgv: Can't check signature: No public key 159s dpkg-source: warning: cannot verify inline signature for ./r-cran-ordinal_2023.12-4.1-1.dsc: no acceptable signature found 159s autopkgtest [15:21:55]: testing package r-cran-ordinal version 2023.12-4.1-1 161s autopkgtest [15:21:57]: build not needed 166s autopkgtest [15:22:02]: test run-unit-test: preparing testbed 169s Reading package lists... 169s Building dependency tree... 169s Reading state information... 170s Starting pkgProblemResolver with broken count: 0 170s Starting 2 pkgProblemResolver with broken count: 0 170s Done 170s The following NEW packages will be installed: 170s fontconfig fontconfig-config fonts-dejavu-core fonts-dejavu-mono libblas3 170s libcairo2 libdatrie1 libdeflate0 libfontconfig1 libfreetype6 libgfortran5 170s libgomp1 libgraphite2-3 libharfbuzz0b libice6 libjbig0 libjpeg-turbo8 170s libjpeg8 liblapack3 liblerc4 libnlopt0 libpango-1.0-0 libpangocairo-1.0-0 170s libpangoft2-1.0-0 libpaper-utils libpaper2 libpixman-1-0 libsharpyuv0 libsm6 170s libtcl8.6 libthai-data libthai0 libtiff6 libtk8.6 libwebp7 libxcb-render0 170s libxcb-shm0 libxft2 libxrender1 libxss1 libxt6t64 littler r-base-core 170s r-cran-boot r-cran-brio r-cran-callr r-cran-cli r-cran-crayon r-cran-desc 170s r-cran-diffobj r-cran-digest r-cran-evaluate r-cran-fs r-cran-glue 170s r-cran-jsonlite r-cran-lattice r-cran-lifecycle r-cran-littler r-cran-lme4 170s r-cran-magrittr r-cran-mass r-cran-matrix r-cran-minqa r-cran-nlme 170s r-cran-nloptr r-cran-nnet r-cran-numderiv r-cran-ordinal r-cran-pkgbuild 170s r-cran-pkgkitten r-cran-pkgload r-cran-praise r-cran-processx r-cran-ps 170s r-cran-r6 r-cran-rbibutils r-cran-rcpp r-cran-rcppeigen r-cran-rdpack 170s r-cran-reformulas r-cran-rlang r-cran-rprojroot r-cran-statmod 170s r-cran-testthat r-cran-ucminf r-cran-waldo r-cran-withr r-cran-xtable unzip 170s x11-common xdg-utils zip 171s 0 upgraded, 92 newly installed, 0 to remove and 0 not upgraded. 171s Need to get 69.6 MB of archives. 171s After this operation, 135 MB of additional disk space will be used. 171s Get:1 http://ftpmaster.internal/ubuntu plucky/main armhf libfreetype6 armhf 2.13.3+dfsg-1 [330 kB] 171s Get:2 http://ftpmaster.internal/ubuntu plucky/main armhf fonts-dejavu-mono all 2.37-8 [502 kB] 171s Get:3 http://ftpmaster.internal/ubuntu plucky/main armhf fonts-dejavu-core all 2.37-8 [835 kB] 172s Get:4 http://ftpmaster.internal/ubuntu plucky/main armhf fontconfig-config armhf 2.15.0-2ubuntu1 [37.5 kB] 172s Get:5 http://ftpmaster.internal/ubuntu plucky/main armhf libfontconfig1 armhf 2.15.0-2ubuntu1 [114 kB] 172s Get:6 http://ftpmaster.internal/ubuntu plucky/main armhf fontconfig armhf 2.15.0-2ubuntu1 [190 kB] 172s Get:7 http://ftpmaster.internal/ubuntu plucky/main armhf libblas3 armhf 3.12.1-2 [132 kB] 172s Get:8 http://ftpmaster.internal/ubuntu plucky/main armhf libpixman-1-0 armhf 0.44.0-3 [183 kB] 172s Get:9 http://ftpmaster.internal/ubuntu plucky/main armhf libxcb-render0 armhf 1.17.0-2 [15.3 kB] 172s Get:10 http://ftpmaster.internal/ubuntu plucky/main armhf libxcb-shm0 armhf 1.17.0-2 [5774 B] 172s Get:11 http://ftpmaster.internal/ubuntu plucky/main armhf libxrender1 armhf 1:0.9.10-1.1build1 [16.0 kB] 172s Get:12 http://ftpmaster.internal/ubuntu plucky/main armhf libcairo2 armhf 1.18.2-2 [484 kB] 173s Get:13 http://ftpmaster.internal/ubuntu plucky/main armhf libdatrie1 armhf 0.2.13-3build1 [15.7 kB] 173s Get:14 http://ftpmaster.internal/ubuntu plucky/main armhf libdeflate0 armhf 1.23-1 [38.5 kB] 173s Get:15 http://ftpmaster.internal/ubuntu plucky/main armhf libgfortran5 armhf 15-20250222-0ubuntu1 [330 kB] 173s Get:16 http://ftpmaster.internal/ubuntu plucky/main armhf libgomp1 armhf 15-20250222-0ubuntu1 [128 kB] 173s Get:17 http://ftpmaster.internal/ubuntu plucky/main armhf libgraphite2-3 armhf 1.3.14-2ubuntu1 [64.8 kB] 173s Get:18 http://ftpmaster.internal/ubuntu plucky/main armhf libharfbuzz0b armhf 10.2.0-1 [464 kB] 173s Get:19 http://ftpmaster.internal/ubuntu plucky/main armhf x11-common all 1:7.7+23ubuntu3 [21.7 kB] 173s Get:20 http://ftpmaster.internal/ubuntu plucky/main armhf libice6 armhf 2:1.1.1-1 [36.5 kB] 173s Get:21 http://ftpmaster.internal/ubuntu plucky/main armhf libjpeg-turbo8 armhf 2.1.5-3ubuntu2 [127 kB] 173s Get:22 http://ftpmaster.internal/ubuntu plucky/main armhf libjpeg8 armhf 8c-2ubuntu11 [2148 B] 174s Get:23 http://ftpmaster.internal/ubuntu plucky/main armhf liblapack3 armhf 3.12.1-2 [2091 kB] 175s Get:24 http://ftpmaster.internal/ubuntu plucky/main armhf liblerc4 armhf 4.0.0+ds-5ubuntu1 [160 kB] 175s Get:25 http://ftpmaster.internal/ubuntu plucky/main armhf libthai-data all 0.1.29-2build1 [158 kB] 175s Get:26 http://ftpmaster.internal/ubuntu plucky/main armhf libthai0 armhf 0.1.29-2build1 [15.2 kB] 175s Get:27 http://ftpmaster.internal/ubuntu plucky/main armhf libpango-1.0-0 armhf 1.56.2-1 [216 kB] 175s Get:28 http://ftpmaster.internal/ubuntu plucky/main armhf libpangoft2-1.0-0 armhf 1.56.2-1 [43.6 kB] 175s Get:29 http://ftpmaster.internal/ubuntu plucky/main armhf libpangocairo-1.0-0 armhf 1.56.2-1 [25.1 kB] 175s Get:30 http://ftpmaster.internal/ubuntu plucky/main armhf libpaper2 armhf 2.2.5-0.3 [16.3 kB] 175s Get:31 http://ftpmaster.internal/ubuntu plucky/main armhf libpaper-utils armhf 2.2.5-0.3 [14.2 kB] 175s Get:32 http://ftpmaster.internal/ubuntu plucky/main armhf libsharpyuv0 armhf 1.5.0-0.1 [16.4 kB] 175s Get:33 http://ftpmaster.internal/ubuntu plucky/main armhf libsm6 armhf 2:1.2.4-1 [15.1 kB] 175s Get:34 http://ftpmaster.internal/ubuntu plucky/main armhf libtcl8.6 armhf 8.6.16+dfsg-1 [909 kB] 176s Get:35 http://ftpmaster.internal/ubuntu plucky/main armhf libjbig0 armhf 2.1-6.1ubuntu2 [24.9 kB] 176s Get:36 http://ftpmaster.internal/ubuntu plucky/main armhf libwebp7 armhf 1.5.0-0.1 [188 kB] 176s Get:37 http://ftpmaster.internal/ubuntu plucky/main armhf libtiff6 armhf 4.5.1+git230720-4ubuntu4 [179 kB] 176s Get:38 http://ftpmaster.internal/ubuntu plucky/main armhf libxft2 armhf 2.3.6-1build1 [37.4 kB] 176s Get:39 http://ftpmaster.internal/ubuntu plucky/main armhf libxss1 armhf 1:1.2.3-1build3 [6500 B] 176s Get:40 http://ftpmaster.internal/ubuntu plucky/main armhf libtk8.6 armhf 8.6.16-1 [686 kB] 177s Get:41 http://ftpmaster.internal/ubuntu plucky/main armhf libxt6t64 armhf 1:1.2.1-1.2build1 [145 kB] 177s Get:42 http://ftpmaster.internal/ubuntu plucky/main armhf zip armhf 3.0-14ubuntu2 [164 kB] 177s Get:43 http://ftpmaster.internal/ubuntu plucky/main armhf unzip armhf 6.0-28ubuntu6 [167 kB] 177s Get:44 http://ftpmaster.internal/ubuntu plucky/main armhf xdg-utils all 1.2.1-2ubuntu1 [66.0 kB] 177s Get:45 http://ftpmaster.internal/ubuntu plucky/universe armhf r-base-core armhf 4.4.3-1 [28.2 MB] 190s Get:46 http://ftpmaster.internal/ubuntu plucky/universe armhf r-cran-littler armhf 0.3.20-2 [90.9 kB] 190s Get:47 http://ftpmaster.internal/ubuntu plucky/universe armhf littler all 0.3.20-2 [2554 B] 190s Get:48 http://ftpmaster.internal/ubuntu plucky/universe armhf r-cran-boot all 1.3-31-1 [635 kB] 191s Get:49 http://ftpmaster.internal/ubuntu plucky/universe armhf r-cran-brio armhf 1.1.5-1 [37.9 kB] 191s Get:50 http://ftpmaster.internal/ubuntu plucky/universe armhf r-cran-ps armhf 1.9.0-1 [403 kB] 191s Get:51 http://ftpmaster.internal/ubuntu plucky/universe armhf r-cran-r6 all 2.6.1-1 [101 kB] 191s Get:52 http://ftpmaster.internal/ubuntu plucky/universe armhf r-cran-processx armhf 3.8.6-1 [359 kB] 191s Get:53 http://ftpmaster.internal/ubuntu plucky/universe armhf r-cran-callr all 3.7.6-1 [458 kB] 191s Get:54 http://ftpmaster.internal/ubuntu plucky/universe armhf r-cran-cli armhf 3.6.4-1 [1377 kB] 191s Get:55 http://ftpmaster.internal/ubuntu plucky/universe armhf r-cran-crayon all 1.5.3-1 [165 kB] 191s Get:56 http://ftpmaster.internal/ubuntu plucky/universe armhf r-cran-desc all 1.4.3-1 [359 kB] 191s Get:57 http://ftpmaster.internal/ubuntu plucky/universe armhf r-cran-diffobj armhf 0.3.5-1 [1115 kB] 191s Get:58 http://ftpmaster.internal/ubuntu plucky/universe armhf r-cran-digest armhf 0.6.37-1 [207 kB] 191s Get:59 http://ftpmaster.internal/ubuntu plucky/universe armhf r-cran-evaluate all 1.0.3-1 [114 kB] 191s Get:60 http://ftpmaster.internal/ubuntu plucky/universe armhf r-cran-fs armhf 1.6.5+dfsg-1 [242 kB] 191s Get:61 http://ftpmaster.internal/ubuntu plucky/universe armhf r-cran-glue armhf 1.8.0-1 [162 kB] 191s Get:62 http://ftpmaster.internal/ubuntu plucky/universe armhf r-cran-jsonlite armhf 1.9.1+dfsg-1 [440 kB] 191s Get:63 http://ftpmaster.internal/ubuntu plucky/universe armhf r-cran-lattice armhf 0.22-6-1 [1363 kB] 191s Get:64 http://ftpmaster.internal/ubuntu plucky/universe armhf r-cran-rlang armhf 1.1.5-1 [1701 kB] 191s Get:65 http://ftpmaster.internal/ubuntu plucky/universe armhf r-cran-lifecycle all 1.0.4+dfsg-1 [110 kB] 191s Get:66 http://ftpmaster.internal/ubuntu plucky/universe armhf r-cran-matrix armhf 1.7-3-1 [4039 kB] 191s Get:67 http://ftpmaster.internal/ubuntu plucky/universe armhf r-cran-mass armhf 7.3-64-1 [1105 kB] 191s Get:68 http://ftpmaster.internal/ubuntu plucky/universe armhf r-cran-nlme armhf 3.1.167-1 [2306 kB] 191s Get:69 http://ftpmaster.internal/ubuntu plucky/universe armhf r-cran-pkgkitten all 0.2.4-1 [27.2 kB] 191s Get:70 http://ftpmaster.internal/ubuntu plucky/universe armhf r-cran-rcpp armhf 1.0.14-1 [1976 kB] 191s Get:71 http://ftpmaster.internal/ubuntu plucky/universe armhf r-cran-minqa armhf 1.2.8-1 [108 kB] 191s Get:72 http://ftpmaster.internal/ubuntu plucky/universe armhf libnlopt0 armhf 2.7.1-6ubuntu3 [154 kB] 191s Get:73 http://ftpmaster.internal/ubuntu plucky/universe armhf r-cran-nloptr armhf 2.1.1-1 [250 kB] 191s Get:74 http://ftpmaster.internal/ubuntu plucky/universe armhf r-cran-rbibutils armhf 2.3-1 [943 kB] 192s Get:75 http://ftpmaster.internal/ubuntu plucky/universe armhf r-cran-rdpack all 2.6.2-1syncable1 [756 kB] 192s Get:76 http://ftpmaster.internal/ubuntu plucky/universe armhf r-cran-reformulas all 0.4.0-1 [91.5 kB] 192s Get:77 http://ftpmaster.internal/ubuntu plucky/universe armhf r-cran-rcppeigen armhf 0.3.4.0.2-1 [1402 kB] 192s Get:78 http://ftpmaster.internal/ubuntu plucky/universe armhf r-cran-statmod armhf 1.5.0-1 [294 kB] 192s Get:79 http://ftpmaster.internal/ubuntu plucky/universe armhf r-cran-lme4 armhf 1.1-36-1 [4108 kB] 192s Get:80 http://ftpmaster.internal/ubuntu plucky/universe armhf r-cran-magrittr armhf 2.0.3-1 [154 kB] 192s Get:81 http://ftpmaster.internal/ubuntu plucky/universe armhf r-cran-nnet armhf 7.3-20-1 [111 kB] 192s Get:82 http://ftpmaster.internal/ubuntu plucky/universe armhf r-cran-numderiv all 2016.8-1.1-3 [115 kB] 192s Get:83 http://ftpmaster.internal/ubuntu plucky/universe armhf r-cran-ucminf armhf 1.2.2-1 [34.5 kB] 192s Get:84 http://ftpmaster.internal/ubuntu plucky/universe armhf r-cran-ordinal armhf 2023.12-4.1-1 [1265 kB] 193s Get:85 http://ftpmaster.internal/ubuntu plucky/universe armhf r-cran-pkgbuild all 1.4.6-1 [213 kB] 193s Get:86 http://ftpmaster.internal/ubuntu plucky/universe armhf r-cran-rprojroot all 2.0.4-2 [125 kB] 193s Get:87 http://ftpmaster.internal/ubuntu plucky/universe armhf r-cran-withr all 3.0.2+dfsg-1 [214 kB] 193s Get:88 http://ftpmaster.internal/ubuntu plucky/universe armhf r-cran-pkgload all 1.4.0-1 [247 kB] 193s Get:89 http://ftpmaster.internal/ubuntu plucky/universe armhf r-cran-praise all 1.0.0-4build1 [20.3 kB] 193s Get:90 http://ftpmaster.internal/ubuntu plucky/universe armhf r-cran-waldo all 0.6.1-2 [150 kB] 193s Get:91 http://ftpmaster.internal/ubuntu plucky/universe armhf r-cran-testthat armhf 3.2.3-1 [1633 kB] 193s Get:92 http://ftpmaster.internal/ubuntu plucky/universe armhf r-cran-xtable all 1:1.8-4-2 [689 kB] 193s Preconfiguring packages ... 193s Fetched 69.6 MB in 22s (3118 kB/s) 193s Selecting previously unselected package libfreetype6:armhf. 193s (Reading database ... (Reading database ... 5% (Reading database ... 10% (Reading database ... 15% (Reading database ... 20% (Reading database ... 25% (Reading database ... 30% (Reading database ... 35% (Reading database ... 40% (Reading database ... 45% (Reading database ... 50% (Reading database ... 55% (Reading database ... 60% (Reading database ... 65% (Reading database ... 70% (Reading database ... 75% (Reading database ... 80% (Reading database ... 85% (Reading database ... 90% (Reading database ... 95% (Reading database ... 100% (Reading database ... 64655 files and directories currently installed.) 193s Preparing to unpack .../00-libfreetype6_2.13.3+dfsg-1_armhf.deb ... 193s Unpacking libfreetype6:armhf (2.13.3+dfsg-1) ... 193s Selecting previously unselected package fonts-dejavu-mono. 193s Preparing to unpack .../01-fonts-dejavu-mono_2.37-8_all.deb ... 193s Unpacking fonts-dejavu-mono (2.37-8) ... 193s Selecting previously unselected package fonts-dejavu-core. 193s Preparing to unpack .../02-fonts-dejavu-core_2.37-8_all.deb ... 193s Unpacking fonts-dejavu-core (2.37-8) ... 194s Selecting previously unselected package fontconfig-config. 194s Preparing to unpack .../03-fontconfig-config_2.15.0-2ubuntu1_armhf.deb ... 194s Unpacking fontconfig-config (2.15.0-2ubuntu1) ... 194s Selecting previously unselected package libfontconfig1:armhf. 194s Preparing to unpack .../04-libfontconfig1_2.15.0-2ubuntu1_armhf.deb ... 194s Unpacking libfontconfig1:armhf (2.15.0-2ubuntu1) ... 194s Selecting previously unselected package fontconfig. 194s Preparing to unpack .../05-fontconfig_2.15.0-2ubuntu1_armhf.deb ... 194s Unpacking fontconfig (2.15.0-2ubuntu1) ... 194s Selecting previously unselected package libblas3:armhf. 194s Preparing to unpack .../06-libblas3_3.12.1-2_armhf.deb ... 194s Unpacking libblas3:armhf (3.12.1-2) ... 194s Selecting previously unselected package libpixman-1-0:armhf. 194s Preparing to unpack .../07-libpixman-1-0_0.44.0-3_armhf.deb ... 194s Unpacking libpixman-1-0:armhf (0.44.0-3) ... 194s Selecting previously unselected package libxcb-render0:armhf. 194s Preparing to unpack .../08-libxcb-render0_1.17.0-2_armhf.deb ... 194s Unpacking libxcb-render0:armhf (1.17.0-2) ... 194s Selecting previously unselected package libxcb-shm0:armhf. 194s Preparing to unpack .../09-libxcb-shm0_1.17.0-2_armhf.deb ... 194s Unpacking libxcb-shm0:armhf (1.17.0-2) ... 194s Selecting previously unselected package libxrender1:armhf. 194s Preparing to unpack .../10-libxrender1_1%3a0.9.10-1.1build1_armhf.deb ... 194s Unpacking libxrender1:armhf (1:0.9.10-1.1build1) ... 194s Selecting previously unselected package libcairo2:armhf. 194s Preparing to unpack .../11-libcairo2_1.18.2-2_armhf.deb ... 194s Unpacking libcairo2:armhf (1.18.2-2) ... 194s Selecting previously unselected package libdatrie1:armhf. 194s Preparing to unpack .../12-libdatrie1_0.2.13-3build1_armhf.deb ... 194s Unpacking libdatrie1:armhf (0.2.13-3build1) ... 194s Selecting previously unselected package libdeflate0:armhf. 194s Preparing to unpack .../13-libdeflate0_1.23-1_armhf.deb ... 194s Unpacking libdeflate0:armhf (1.23-1) ... 194s Selecting previously unselected package libgfortran5:armhf. 194s Preparing to unpack .../14-libgfortran5_15-20250222-0ubuntu1_armhf.deb ... 194s Unpacking libgfortran5:armhf (15-20250222-0ubuntu1) ... 194s Selecting previously unselected package libgomp1:armhf. 194s Preparing to unpack .../15-libgomp1_15-20250222-0ubuntu1_armhf.deb ... 194s Unpacking libgomp1:armhf (15-20250222-0ubuntu1) ... 194s Selecting previously unselected package libgraphite2-3:armhf. 194s Preparing to unpack .../16-libgraphite2-3_1.3.14-2ubuntu1_armhf.deb ... 194s Unpacking libgraphite2-3:armhf (1.3.14-2ubuntu1) ... 194s Selecting previously unselected package libharfbuzz0b:armhf. 194s Preparing to unpack .../17-libharfbuzz0b_10.2.0-1_armhf.deb ... 194s Unpacking libharfbuzz0b:armhf (10.2.0-1) ... 194s Selecting previously unselected package x11-common. 194s Preparing to unpack .../18-x11-common_1%3a7.7+23ubuntu3_all.deb ... 194s Unpacking x11-common (1:7.7+23ubuntu3) ... 194s Selecting previously unselected package libice6:armhf. 194s Preparing to unpack .../19-libice6_2%3a1.1.1-1_armhf.deb ... 194s Unpacking libice6:armhf (2:1.1.1-1) ... 194s Selecting previously unselected package libjpeg-turbo8:armhf. 194s Preparing to unpack .../20-libjpeg-turbo8_2.1.5-3ubuntu2_armhf.deb ... 194s Unpacking libjpeg-turbo8:armhf (2.1.5-3ubuntu2) ... 194s Selecting previously unselected package libjpeg8:armhf. 194s Preparing to unpack .../21-libjpeg8_8c-2ubuntu11_armhf.deb ... 194s Unpacking libjpeg8:armhf (8c-2ubuntu11) ... 194s Selecting previously unselected package liblapack3:armhf. 194s Preparing to unpack .../22-liblapack3_3.12.1-2_armhf.deb ... 194s Unpacking liblapack3:armhf (3.12.1-2) ... 194s Selecting previously unselected package liblerc4:armhf. 194s Preparing to unpack .../23-liblerc4_4.0.0+ds-5ubuntu1_armhf.deb ... 194s Unpacking liblerc4:armhf (4.0.0+ds-5ubuntu1) ... 194s Selecting previously unselected package libthai-data. 194s Preparing to unpack .../24-libthai-data_0.1.29-2build1_all.deb ... 194s Unpacking libthai-data (0.1.29-2build1) ... 195s Selecting previously unselected package libthai0:armhf. 195s Preparing to unpack .../25-libthai0_0.1.29-2build1_armhf.deb ... 195s Unpacking libthai0:armhf (0.1.29-2build1) ... 195s Selecting previously unselected package libpango-1.0-0:armhf. 195s Preparing to unpack .../26-libpango-1.0-0_1.56.2-1_armhf.deb ... 195s Unpacking libpango-1.0-0:armhf (1.56.2-1) ... 195s Selecting previously unselected package libpangoft2-1.0-0:armhf. 195s Preparing to unpack .../27-libpangoft2-1.0-0_1.56.2-1_armhf.deb ... 195s Unpacking libpangoft2-1.0-0:armhf (1.56.2-1) ... 195s Selecting previously unselected package libpangocairo-1.0-0:armhf. 195s Preparing to unpack .../28-libpangocairo-1.0-0_1.56.2-1_armhf.deb ... 195s Unpacking libpangocairo-1.0-0:armhf (1.56.2-1) ... 195s Selecting previously unselected package libpaper2:armhf. 195s Preparing to unpack .../29-libpaper2_2.2.5-0.3_armhf.deb ... 195s Unpacking libpaper2:armhf (2.2.5-0.3) ... 195s Selecting previously unselected package libpaper-utils. 195s Preparing to unpack .../30-libpaper-utils_2.2.5-0.3_armhf.deb ... 195s Unpacking libpaper-utils (2.2.5-0.3) ... 195s Selecting previously unselected package libsharpyuv0:armhf. 195s Preparing to unpack .../31-libsharpyuv0_1.5.0-0.1_armhf.deb ... 195s Unpacking libsharpyuv0:armhf (1.5.0-0.1) ... 195s Selecting previously unselected package libsm6:armhf. 195s Preparing to unpack .../32-libsm6_2%3a1.2.4-1_armhf.deb ... 195s Unpacking libsm6:armhf (2:1.2.4-1) ... 195s Selecting previously unselected package libtcl8.6:armhf. 195s Preparing to unpack .../33-libtcl8.6_8.6.16+dfsg-1_armhf.deb ... 195s Unpacking libtcl8.6:armhf (8.6.16+dfsg-1) ... 195s Selecting previously unselected package libjbig0:armhf. 195s Preparing to unpack .../34-libjbig0_2.1-6.1ubuntu2_armhf.deb ... 195s Unpacking libjbig0:armhf (2.1-6.1ubuntu2) ... 195s Selecting previously unselected package libwebp7:armhf. 195s Preparing to unpack .../35-libwebp7_1.5.0-0.1_armhf.deb ... 195s Unpacking libwebp7:armhf (1.5.0-0.1) ... 195s Selecting previously unselected package libtiff6:armhf. 195s Preparing to unpack .../36-libtiff6_4.5.1+git230720-4ubuntu4_armhf.deb ... 195s Unpacking libtiff6:armhf (4.5.1+git230720-4ubuntu4) ... 195s Selecting previously unselected package libxft2:armhf. 195s Preparing to unpack .../37-libxft2_2.3.6-1build1_armhf.deb ... 195s Unpacking libxft2:armhf (2.3.6-1build1) ... 195s Selecting previously unselected package libxss1:armhf. 195s Preparing to unpack .../38-libxss1_1%3a1.2.3-1build3_armhf.deb ... 195s Unpacking libxss1:armhf (1:1.2.3-1build3) ... 195s Selecting previously unselected package libtk8.6:armhf. 195s Preparing to unpack .../39-libtk8.6_8.6.16-1_armhf.deb ... 195s Unpacking libtk8.6:armhf (8.6.16-1) ... 195s Selecting previously unselected package libxt6t64:armhf. 195s Preparing to unpack .../40-libxt6t64_1%3a1.2.1-1.2build1_armhf.deb ... 195s Unpacking libxt6t64:armhf (1:1.2.1-1.2build1) ... 195s Selecting previously unselected package zip. 195s Preparing to unpack .../41-zip_3.0-14ubuntu2_armhf.deb ... 195s Unpacking zip (3.0-14ubuntu2) ... 195s Selecting previously unselected package unzip. 195s Preparing to unpack .../42-unzip_6.0-28ubuntu6_armhf.deb ... 195s Unpacking unzip (6.0-28ubuntu6) ... 195s Selecting previously unselected package xdg-utils. 195s Preparing to unpack .../43-xdg-utils_1.2.1-2ubuntu1_all.deb ... 195s Unpacking xdg-utils (1.2.1-2ubuntu1) ... 195s Selecting previously unselected package r-base-core. 195s Preparing to unpack .../44-r-base-core_4.4.3-1_armhf.deb ... 195s Unpacking r-base-core (4.4.3-1) ... 196s Selecting previously unselected package r-cran-littler. 196s Preparing to unpack .../45-r-cran-littler_0.3.20-2_armhf.deb ... 196s Unpacking r-cran-littler (0.3.20-2) ... 196s Selecting previously unselected package littler. 196s Preparing to unpack .../46-littler_0.3.20-2_all.deb ... 196s Unpacking littler (0.3.20-2) ... 196s Selecting previously unselected package r-cran-boot. 196s Preparing to unpack .../47-r-cran-boot_1.3-31-1_all.deb ... 196s Unpacking r-cran-boot (1.3-31-1) ... 196s Selecting previously unselected package r-cran-brio. 196s Preparing to unpack .../48-r-cran-brio_1.1.5-1_armhf.deb ... 196s Unpacking r-cran-brio (1.1.5-1) ... 196s Selecting previously unselected package r-cran-ps. 196s Preparing to unpack .../49-r-cran-ps_1.9.0-1_armhf.deb ... 196s Unpacking r-cran-ps (1.9.0-1) ... 196s Selecting previously unselected package r-cran-r6. 196s Preparing to unpack .../50-r-cran-r6_2.6.1-1_all.deb ... 196s Unpacking r-cran-r6 (2.6.1-1) ... 196s Selecting previously unselected package r-cran-processx. 196s Preparing to unpack .../51-r-cran-processx_3.8.6-1_armhf.deb ... 196s Unpacking r-cran-processx (3.8.6-1) ... 196s Selecting previously unselected package r-cran-callr. 196s Preparing to unpack .../52-r-cran-callr_3.7.6-1_all.deb ... 196s Unpacking r-cran-callr (3.7.6-1) ... 196s Selecting previously unselected package r-cran-cli. 196s Preparing to unpack .../53-r-cran-cli_3.6.4-1_armhf.deb ... 196s Unpacking r-cran-cli (3.6.4-1) ... 196s Selecting previously unselected package r-cran-crayon. 196s Preparing to unpack .../54-r-cran-crayon_1.5.3-1_all.deb ... 196s Unpacking r-cran-crayon (1.5.3-1) ... 196s Selecting previously unselected package r-cran-desc. 196s Preparing to unpack .../55-r-cran-desc_1.4.3-1_all.deb ... 196s Unpacking r-cran-desc (1.4.3-1) ... 196s Selecting previously unselected package r-cran-diffobj. 196s Preparing to unpack .../56-r-cran-diffobj_0.3.5-1_armhf.deb ... 196s Unpacking r-cran-diffobj (0.3.5-1) ... 196s Selecting previously unselected package r-cran-digest. 196s Preparing to unpack .../57-r-cran-digest_0.6.37-1_armhf.deb ... 196s Unpacking r-cran-digest (0.6.37-1) ... 196s Selecting previously unselected package r-cran-evaluate. 196s Preparing to unpack .../58-r-cran-evaluate_1.0.3-1_all.deb ... 196s Unpacking r-cran-evaluate (1.0.3-1) ... 196s Selecting previously unselected package r-cran-fs. 196s Preparing to unpack .../59-r-cran-fs_1.6.5+dfsg-1_armhf.deb ... 196s Unpacking r-cran-fs (1.6.5+dfsg-1) ... 196s Selecting previously unselected package r-cran-glue. 196s Preparing to unpack .../60-r-cran-glue_1.8.0-1_armhf.deb ... 196s Unpacking r-cran-glue (1.8.0-1) ... 196s Selecting previously unselected package r-cran-jsonlite. 196s Preparing to unpack .../61-r-cran-jsonlite_1.9.1+dfsg-1_armhf.deb ... 196s Unpacking r-cran-jsonlite (1.9.1+dfsg-1) ... 196s Selecting previously unselected package r-cran-lattice. 196s Preparing to unpack .../62-r-cran-lattice_0.22-6-1_armhf.deb ... 196s Unpacking r-cran-lattice (0.22-6-1) ... 196s Selecting previously unselected package r-cran-rlang. 196s Preparing to unpack .../63-r-cran-rlang_1.1.5-1_armhf.deb ... 196s Unpacking r-cran-rlang (1.1.5-1) ... 196s Selecting previously unselected package r-cran-lifecycle. 196s Preparing to unpack .../64-r-cran-lifecycle_1.0.4+dfsg-1_all.deb ... 196s Unpacking r-cran-lifecycle (1.0.4+dfsg-1) ... 197s Selecting previously unselected package r-cran-matrix. 197s Preparing to unpack .../65-r-cran-matrix_1.7-3-1_armhf.deb ... 197s Unpacking r-cran-matrix (1.7-3-1) ... 197s Selecting previously unselected package r-cran-mass. 197s Preparing to unpack .../66-r-cran-mass_7.3-64-1_armhf.deb ... 197s Unpacking r-cran-mass (7.3-64-1) ... 197s Selecting previously unselected package r-cran-nlme. 197s Preparing to unpack .../67-r-cran-nlme_3.1.167-1_armhf.deb ... 197s Unpacking r-cran-nlme (3.1.167-1) ... 197s Selecting previously unselected package r-cran-pkgkitten. 197s Preparing to unpack .../68-r-cran-pkgkitten_0.2.4-1_all.deb ... 197s Unpacking r-cran-pkgkitten (0.2.4-1) ... 197s Selecting previously unselected package r-cran-rcpp. 197s Preparing to unpack .../69-r-cran-rcpp_1.0.14-1_armhf.deb ... 197s Unpacking r-cran-rcpp (1.0.14-1) ... 197s Selecting previously unselected package r-cran-minqa. 197s Preparing to unpack .../70-r-cran-minqa_1.2.8-1_armhf.deb ... 197s Unpacking r-cran-minqa (1.2.8-1) ... 197s Selecting previously unselected package libnlopt0:armhf. 197s Preparing to unpack .../71-libnlopt0_2.7.1-6ubuntu3_armhf.deb ... 197s Unpacking libnlopt0:armhf (2.7.1-6ubuntu3) ... 197s Selecting previously unselected package r-cran-nloptr. 197s Preparing to unpack .../72-r-cran-nloptr_2.1.1-1_armhf.deb ... 197s Unpacking r-cran-nloptr (2.1.1-1) ... 197s Selecting previously unselected package r-cran-rbibutils. 197s Preparing to unpack .../73-r-cran-rbibutils_2.3-1_armhf.deb ... 197s Unpacking r-cran-rbibutils (2.3-1) ... 197s Selecting previously unselected package r-cran-rdpack. 197s Preparing to unpack .../74-r-cran-rdpack_2.6.2-1syncable1_all.deb ... 197s Unpacking r-cran-rdpack (2.6.2-1syncable1) ... 197s Selecting previously unselected package r-cran-reformulas. 197s Preparing to unpack .../75-r-cran-reformulas_0.4.0-1_all.deb ... 197s Unpacking r-cran-reformulas (0.4.0-1) ... 197s Selecting previously unselected package r-cran-rcppeigen. 197s Preparing to unpack .../76-r-cran-rcppeigen_0.3.4.0.2-1_armhf.deb ... 197s Unpacking r-cran-rcppeigen (0.3.4.0.2-1) ... 197s Selecting previously unselected package r-cran-statmod. 197s Preparing to unpack .../77-r-cran-statmod_1.5.0-1_armhf.deb ... 197s Unpacking r-cran-statmod (1.5.0-1) ... 197s Selecting previously unselected package r-cran-lme4. 197s Preparing to unpack .../78-r-cran-lme4_1.1-36-1_armhf.deb ... 197s Unpacking r-cran-lme4 (1.1-36-1) ... 197s Selecting previously unselected package r-cran-magrittr. 197s Preparing to unpack .../79-r-cran-magrittr_2.0.3-1_armhf.deb ... 197s Unpacking r-cran-magrittr (2.0.3-1) ... 198s Selecting previously unselected package r-cran-nnet. 198s Preparing to unpack .../80-r-cran-nnet_7.3-20-1_armhf.deb ... 198s Unpacking r-cran-nnet (7.3-20-1) ... 198s Selecting previously unselected package r-cran-numderiv. 198s Preparing to unpack .../81-r-cran-numderiv_2016.8-1.1-3_all.deb ... 198s Unpacking r-cran-numderiv (2016.8-1.1-3) ... 198s Selecting previously unselected package r-cran-ucminf. 198s Preparing to unpack .../82-r-cran-ucminf_1.2.2-1_armhf.deb ... 198s Unpacking r-cran-ucminf (1.2.2-1) ... 198s Selecting previously unselected package r-cran-ordinal. 198s Preparing to unpack .../83-r-cran-ordinal_2023.12-4.1-1_armhf.deb ... 198s Unpacking r-cran-ordinal (2023.12-4.1-1) ... 198s Selecting previously unselected package r-cran-pkgbuild. 198s Preparing to unpack .../84-r-cran-pkgbuild_1.4.6-1_all.deb ... 198s Unpacking r-cran-pkgbuild (1.4.6-1) ... 198s Selecting previously unselected package r-cran-rprojroot. 198s Preparing to unpack .../85-r-cran-rprojroot_2.0.4-2_all.deb ... 198s Unpacking r-cran-rprojroot (2.0.4-2) ... 198s Selecting previously unselected package r-cran-withr. 198s Preparing to unpack .../86-r-cran-withr_3.0.2+dfsg-1_all.deb ... 198s Unpacking r-cran-withr (3.0.2+dfsg-1) ... 198s Selecting previously unselected package r-cran-pkgload. 198s Preparing to unpack .../87-r-cran-pkgload_1.4.0-1_all.deb ... 198s Unpacking r-cran-pkgload (1.4.0-1) ... 198s Selecting previously unselected package r-cran-praise. 198s Preparing to unpack .../88-r-cran-praise_1.0.0-4build1_all.deb ... 198s Unpacking r-cran-praise (1.0.0-4build1) ... 198s Selecting previously unselected package r-cran-waldo. 198s Preparing to unpack .../89-r-cran-waldo_0.6.1-2_all.deb ... 198s Unpacking r-cran-waldo (0.6.1-2) ... 198s Selecting previously unselected package r-cran-testthat. 198s Preparing to unpack .../90-r-cran-testthat_3.2.3-1_armhf.deb ... 198s Unpacking r-cran-testthat (3.2.3-1) ... 198s Selecting previously unselected package r-cran-xtable. 198s Preparing to unpack .../91-r-cran-xtable_1%3a1.8-4-2_all.deb ... 198s Unpacking r-cran-xtable (1:1.8-4-2) ... 198s Setting up libgraphite2-3:armhf (1.3.14-2ubuntu1) ... 198s Setting up libpixman-1-0:armhf (0.44.0-3) ... 198s Setting up libsharpyuv0:armhf (1.5.0-0.1) ... 198s Setting up liblerc4:armhf (4.0.0+ds-5ubuntu1) ... 198s Setting up libxrender1:armhf (1:0.9.10-1.1build1) ... 198s Setting up libdatrie1:armhf (0.2.13-3build1) ... 198s Setting up libxcb-render0:armhf (1.17.0-2) ... 198s Setting up unzip (6.0-28ubuntu6) ... 198s Setting up x11-common (1:7.7+23ubuntu3) ... 199s Setting up libdeflate0:armhf (1.23-1) ... 199s Setting up libnlopt0:armhf (2.7.1-6ubuntu3) ... 199s Setting up libxcb-shm0:armhf (1.17.0-2) ... 199s Setting up libgomp1:armhf (15-20250222-0ubuntu1) ... 199s Setting up libjbig0:armhf (2.1-6.1ubuntu2) ... 199s Setting up zip (3.0-14ubuntu2) ... 199s Setting up libblas3:armhf (3.12.1-2) ... 199s update-alternatives: using /usr/lib/arm-linux-gnueabihf/blas/libblas.so.3 to provide /usr/lib/arm-linux-gnueabihf/libblas.so.3 (libblas.so.3-arm-linux-gnueabihf) in auto mode 199s Setting up libfreetype6:armhf (2.13.3+dfsg-1) ... 199s Setting up fonts-dejavu-mono (2.37-8) ... 199s Setting up libtcl8.6:armhf (8.6.16+dfsg-1) ... 199s Setting up fonts-dejavu-core (2.37-8) ... 199s Setting up libjpeg-turbo8:armhf (2.1.5-3ubuntu2) ... 199s Setting up libgfortran5:armhf (15-20250222-0ubuntu1) ... 199s Setting up libwebp7:armhf (1.5.0-0.1) ... 199s Setting up libharfbuzz0b:armhf (10.2.0-1) ... 199s Setting up libthai-data (0.1.29-2build1) ... 199s Setting up libxss1:armhf (1:1.2.3-1build3) ... 199s Setting up libpaper2:armhf (2.2.5-0.3) ... 199s Setting up xdg-utils (1.2.1-2ubuntu1) ... 199s update-alternatives: using /usr/bin/xdg-open to provide /usr/bin/open (open) in auto mode 199s Setting up libjpeg8:armhf (8c-2ubuntu11) ... 199s Setting up libice6:armhf (2:1.1.1-1) ... 199s Setting up liblapack3:armhf (3.12.1-2) ... 199s update-alternatives: using /usr/lib/arm-linux-gnueabihf/lapack/liblapack.so.3 to provide /usr/lib/arm-linux-gnueabihf/liblapack.so.3 (liblapack.so.3-arm-linux-gnueabihf) in auto mode 199s Setting up fontconfig-config (2.15.0-2ubuntu1) ... 199s Setting up libpaper-utils (2.2.5-0.3) ... 199s Setting up libthai0:armhf (0.1.29-2build1) ... 199s Setting up libtiff6:armhf (4.5.1+git230720-4ubuntu4) ... 199s Setting up libfontconfig1:armhf (2.15.0-2ubuntu1) ... 199s Setting up libsm6:armhf (2:1.2.4-1) ... 199s Setting up fontconfig (2.15.0-2ubuntu1) ... 201s Regenerating fonts cache... done. 201s Setting up libxft2:armhf (2.3.6-1build1) ... 201s Setting up libtk8.6:armhf (8.6.16-1) ... 201s Setting up libpango-1.0-0:armhf (1.56.2-1) ... 201s Setting up libcairo2:armhf (1.18.2-2) ... 201s Setting up libxt6t64:armhf (1:1.2.1-1.2build1) ... 201s Setting up libpangoft2-1.0-0:armhf (1.56.2-1) ... 201s Setting up libpangocairo-1.0-0:armhf (1.56.2-1) ... 201s Setting up r-base-core (4.4.3-1) ... 201s Creating config file /etc/R/Renviron with new version 201s Setting up r-cran-crayon (1.5.3-1) ... 201s Setting up r-cran-lattice (0.22-6-1) ... 201s Setting up r-cran-ps (1.9.0-1) ... 201s Setting up r-cran-nlme (3.1.167-1) ... 201s Setting up r-cran-statmod (1.5.0-1) ... 201s Setting up r-cran-nnet (7.3-20-1) ... 201s Setting up r-cran-r6 (2.6.1-1) ... 201s Setting up r-cran-pkgkitten (0.2.4-1) ... 201s Setting up r-cran-numderiv (2016.8-1.1-3) ... 201s Setting up r-cran-magrittr (2.0.3-1) ... 201s Setting up r-cran-littler (0.3.20-2) ... 201s Setting up r-cran-fs (1.6.5+dfsg-1) ... 201s Setting up r-cran-rcpp (1.0.14-1) ... 201s Setting up r-cran-brio (1.1.5-1) ... 201s Setting up r-cran-nloptr (2.1.1-1) ... 201s Setting up r-cran-boot (1.3-31-1) ... 201s Setting up r-cran-diffobj (0.3.5-1) ... 201s Setting up r-cran-rlang (1.1.5-1) ... 201s Setting up littler (0.3.20-2) ... 201s Setting up r-cran-withr (3.0.2+dfsg-1) ... 201s Setting up r-cran-processx (3.8.6-1) ... 201s Setting up r-cran-praise (1.0.0-4build1) ... 201s Setting up r-cran-digest (0.6.37-1) ... 201s Setting up r-cran-evaluate (1.0.3-1) ... 201s Setting up r-cran-mass (7.3-64-1) ... 201s Setting up r-cran-glue (1.8.0-1) ... 201s Setting up r-cran-xtable (1:1.8-4-2) ... 201s Setting up r-cran-cli (3.6.4-1) ... 201s Setting up r-cran-rbibutils (2.3-1) ... 201s Setting up r-cran-lifecycle (1.0.4+dfsg-1) ... 201s Setting up r-cran-rprojroot (2.0.4-2) ... 201s Setting up r-cran-jsonlite (1.9.1+dfsg-1) ... 201s Setting up r-cran-ucminf (1.2.2-1) ... 201s Setting up r-cran-waldo (0.6.1-2) ... 201s Setting up r-cran-matrix (1.7-3-1) ... 201s Setting up r-cran-rcppeigen (0.3.4.0.2-1) ... 201s Setting up r-cran-minqa (1.2.8-1) ... 201s Setting up r-cran-callr (3.7.6-1) ... 201s Setting up r-cran-ordinal (2023.12-4.1-1) ... 201s Setting up r-cran-desc (1.4.3-1) ... 201s Setting up r-cran-rdpack (2.6.2-1syncable1) ... 201s Setting up r-cran-pkgbuild (1.4.6-1) ... 201s Setting up r-cran-reformulas (0.4.0-1) ... 201s Setting up r-cran-pkgload (1.4.0-1) ... 201s Setting up r-cran-lme4 (1.1-36-1) ... 201s Setting up r-cran-testthat (3.2.3-1) ... 201s Processing triggers for libc-bin (2.41-1ubuntu2) ... 201s Processing triggers for man-db (2.13.0-1) ... 202s Processing triggers for install-info (7.1.1-1) ... 215s autopkgtest [15:22:51]: test run-unit-test: [----------------------- 218s BEGIN TEST anova.R 218s 218s R version 4.4.3 (2025-02-28) -- "Trophy Case" 218s Copyright (C) 2025 The R Foundation for Statistical Computing 218s Platform: arm-unknown-linux-gnueabihf (32-bit) 218s 218s R is free software and comes with ABSOLUTELY NO WARRANTY. 218s You are welcome to redistribute it under certain conditions. 218s Type 'license()' or 'licence()' for distribution details. 218s 218s R is a collaborative project with many contributors. 218s Type 'contributors()' for more information and 218s 'citation()' on how to cite R or R packages in publications. 218s 218s Type 'demo()' for some demos, 'help()' for on-line help, or 218s 'help.start()' for an HTML browser interface to help. 218s Type 'q()' to quit R. 218s 218s > library(ordinal) 219s > data(wine) 219s > 219s > fm1 <- clm(rating ~ temp, data=wine) 219s > fmm1 <- clmm(rating ~ temp + (1|judge), data=wine) 220s > 220s > ## These now give identical printed results: 220s > ## Previously the printed model names were messed up when anova.clmm 220s > ## were called. 220s > anova(fm1, fmm1) 220s Likelihood ratio tests of cumulative link models: 220s 220s formula: link: threshold: 220s fm1 rating ~ temp logit flexible 220s fmm1 rating ~ temp + (1 | judge) logit flexible 220s 220s no.par AIC logLik LR.stat df Pr(>Chisq) 220s fm1 5 194.03 -92.013 220s fmm1 6 189.48 -88.739 6.5492 1 0.01049 * 220s --- 220s Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1 220s > anova(fmm1, fm1) 220s Likelihood ratio tests of cumulative link models: 220s 220s formula: link: threshold: 220s fm1 rating ~ temp logit flexible 220s fmm1 rating ~ temp + (1 | judge) logit flexible 220s 220s no.par AIC logLik LR.stat df Pr(>Chisq) 220s fm1 5 194.03 -92.013 220s fmm1 6 189.48 -88.739 6.5492 1 0.01049 * 220s --- 220s Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1 220s > 220s > ## Testing if 'test' and 'type' arguments are ignored properly: 220s > fm1 <- clm(rating ~ temp + contact, data=wine) 220s > fm2 <- clm(rating ~ temp, data=wine) 220s 'test' argument ignored in anova.clm 220s 220s 'test' argument ignored in anova.clm 220s 220s > anova(fm1, fm2, test="Chi") 220s Likelihood ratio tests of cumulative link models: 220s 220s formula: link: threshold: 220s fm2 rating ~ temp logit flexible 220s fm1 rating ~ temp + contact logit flexible 220s 220s no.par AIC logLik LR.stat df Pr(>Chisq) 220s fm2 5 194.03 -92.013 220s fm1 6 184.98 -86.492 11.043 1 0.0008902 *** 220s --- 220s Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1 220s > anova(fm1, fm2, type="Chi") 220s Likelihood ratio tests of cumulative link models: 220s 220s formula: link: threshold: 220s fm2 rating ~ temp logit flexible 220s fm1 rating ~ temp + contact logit flexible 220s 220s no.par AIC logLik LR.stat df Pr(>Chisq) 220s fm2 5 194.03 -92.013 220s fm1 6 184.98 -86.492 11.043 1 0.0008902 *** 220s --- 220s Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1 220s > anova(fm1, fm2) 220s Likelihood ratio tests of cumulative link models: 220s 220s formula: link: threshold: 220s fm2 rating ~ temp logit flexible 220s fm1 rating ~ temp + contact logit flexible 220s 220s no.par AIC logLik LR.stat df Pr(>Chisq) 220s fm2 5 194.03 -92.013 220s fm1 6 184.98 -86.492 11.043 1 0.0008902 *** 220s --- 220s Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1 220s > ## calling anova.clmm 220s > anova(fmm1, fm1, test="Chi") 220s Likelihood ratio tests of cumulative link models: 220s 220s formula: link: threshold: 220s fmm1 rating ~ temp + (1 | judge) logit flexible 220s fm1 rating ~ temp + contact logit flexible 220s 220s no.par AIC logLik LR.stat df Pr(>Chisq) 220s fmm1 6 189.48 -88.739 220s fm1 6 184.98 -86.492 4.4938 0 220s > anova(fmm1, fm1, type="Chi") 220s Likelihood ratio tests of cumulative link models: 220s 220s formula: link: threshold: 220s fmm1 rating ~ temp + (1 | judge) logit flexible 220s fm1 rating ~ temp + contact logit flexible 220s 220s no.par AIC logLik LR.stat df Pr(>Chisq) 220s fmm1 6 189.48 -88.739 220s fm1 6 184.98 -86.492 4.4938 0 220s > 220s > 220s BEGIN TEST clm.fit.R 220s 220s R version 4.4.3 (2025-02-28) -- "Trophy Case" 220s Copyright (C) 2025 The R Foundation for Statistical Computing 220s Platform: arm-unknown-linux-gnueabihf (32-bit) 220s 220s R is free software and comes with ABSOLUTELY NO WARRANTY. 220s You are welcome to redistribute it under certain conditions. 220s Type 'license()' or 'licence()' for distribution details. 220s 220s R is a collaborative project with many contributors. 220s Type 'contributors()' for more information and 220s 'citation()' on how to cite R or R packages in publications. 220s 220s Type 'demo()' for some demos, 'help()' for on-line help, or 220s 'help.start()' for an HTML browser interface to help. 220s Type 'q()' to quit R. 220s 220s > library(ordinal) 221s > data(wine) 221s > 221s > ## clm.fit with nominal and scale effects: 221s > 221s > ## get simple model: 221s > fm1 <- clm(rating ~ temp, scale=~temp, nominal=~ contact, 221s + data=wine, method="design") 221s > str(fm1, give.attr=FALSE) 221s List of 23 221s $ y : Ord.factor w/ 5 levels "1"<"2"<"3"<"4"<..: 2 3 3 4 4 4 5 5 1 2 ... 221s $ y.levels : chr [1:5] "1" "2" "3" "4" ... 221s $ X : num [1:72, 1:2] 1 1 1 1 1 1 1 1 1 1 ... 221s $ offset : num [1:72] 0 0 0 0 0 0 0 0 0 0 ... 221s $ terms :Classes 'terms', 'formula' language rating ~ temp 221s $ contrasts :List of 1 221s ..$ temp: chr "contr.treatment" 221s $ xlevels :List of 1 221s ..$ temp: chr [1:2] "cold" "warm" 221s $ weights : num [1:72] 1 1 1 1 1 1 1 1 1 1 ... 221s $ S : num [1:72, 1:2] 1 1 1 1 1 1 1 1 1 1 ... 221s $ S.terms :Classes 'terms', 'formula' language ~temp 221s $ S.off : num [1:72] 0 0 0 0 0 0 0 0 0 0 ... 221s $ S.contrasts :List of 1 221s ..$ temp: chr "contr.treatment" 221s $ S.xlevels :List of 1 221s ..$ temp: chr [1:2] "cold" "warm" 221s $ NOM : num [1:72, 1:2] 1 1 1 1 1 1 1 1 1 1 ... 221s $ nom.terms :Classes 'terms', 'formula' language ~contact 221s $ nom.contrasts:List of 1 221s ..$ contact: chr "contr.treatment" 221s $ nom.xlevels :List of 1 221s ..$ contact: chr [1:2] "no" "yes" 221s $ doFit : logi TRUE 221s $ control :List of 11 221s ..$ method : chr "design" 221s ..$ sign.location: chr "negative" 221s ..$ sign.nominal : chr "positive" 221s ..$ convergence : chr "warn" 221s ..$ trace : int 0 221s ..$ maxIter : int 100 221s ..$ gradTol : num 1e-06 221s ..$ relTol : num 1e-06 221s ..$ tol : num 1.49e-08 221s ..$ maxLineIter : int 15 221s ..$ maxModIter : int 5 221s $ link : chr "logit" 221s $ threshold : chr "flexible" 221s $ start : NULL 221s $ formulas :List of 4 221s ..$ formula :Class 'formula' language rating ~ temp 221s ..$ scale :Class 'formula' language ~temp 221s ..$ nominal :Class 'formula' language ~contact 221s ..$ fullForm:Class 'formula' language rating ~ temp + temp + contact 221s > fm1$control$method <- "Newton" 221s > res <- clm.fit(fm1) 221s > names(res) 221s [1] "aliased" "alpha" "alpha.mat" "beta" 221s [5] "coefficients" "cond.H" "convergence" "df.residual" 221s [9] "edf" "fitted.values" "gradient" "Hessian" 221s [13] "logLik" "maxGradient" "message" "n" 221s [17] "niter" "nobs" "Theta" "tJac" 221s [21] "vcov" "zeta" 221s > res$Theta 221s contact 1|2 2|3 3|4 4|5 221s 1 no -1.357136 1.2482871 3.839568 5.114111 221s 2 yes -2.969353 -0.2819631 1.959306 3.923477 221s > 221s > ## construct some weights and offsets: 221s > set.seed(1) 221s > off1 <- runif(length(fm1$y)) 221s > set.seed(1) 221s > off2 <- rnorm(length(fm1$y)) 221s > set.seed(1) 221s > wet <- runif(length(fm1$y)) 221s > 221s > ## Fit various models: 221s > fit <- clm.fit(fm1$y, fm1$X, fm1$S, fm1$NOM, weights=wet) 221s Warning message: 221s Cannot assess if all thresholds are increasing 221s > Coef <- 221s + c(-0.905224120279548, 1.31043498891987, 3.34235590523008, 221s + 4.52389661722693, -3.03954652971192, -1.56922389038976, 221s + -1.75662549320839, -1.16845464236365, 2.52988580848393, 221s + -0.0261457032829033) 221s > stopifnot(all.equal(coef(fit), Coef, check.attributes=FALSE, tol=1e-6)) 221s > str(fit) 221s List of 20 221s $ aliased :List of 3 221s ..$ alpha: Named logi [1:8] FALSE FALSE FALSE FALSE FALSE FALSE ... 221s .. ..- attr(*, "names")= chr [1:8] "1|2.(Intercept)" "2|3.(Intercept)" "3|4.(Intercept)" "4|5.(Intercept)" ... 221s ..$ beta : Named logi FALSE 221s .. ..- attr(*, "names")= chr "tempwarm" 221s ..$ zeta : Named logi FALSE 221s .. ..- attr(*, "names")= chr "tempwarm" 221s $ alpha : Named num [1:8] -0.905 1.31 3.342 4.524 -3.04 ... 221s ..- attr(*, "names")= chr [1:8] "1|2.(Intercept)" "2|3.(Intercept)" "3|4.(Intercept)" "4|5.(Intercept)" ... 221s $ beta : Named num 2.53 221s ..- attr(*, "names")= chr "tempwarm" 221s $ coefficients : Named num [1:10] -0.905 1.31 3.342 4.524 -3.04 ... 221s ..- attr(*, "names")= chr [1:10] "1|2.(Intercept)" "2|3.(Intercept)" "3|4.(Intercept)" "4|5.(Intercept)" ... 221s $ cond.H : num 161 221s $ convergence :List of 3 221s ..$ code : int 0 221s ..$ messages : chr "successful convergence" 221s ..$ alg.message: chr "Absolute and relative convergence criteria were met" 221s $ df.residual : num 27 221s $ edf : int 10 221s $ fitted.values: num [1:72] 0.5 0.178 0.394 0.136 0.188 ... 221s Warning message: 221s Cannot assess if all thresholds are increasing 221s $ gradient : Named num [1:10] 7.85e-15 2.69e-13 2.68e-13 -5.17e-13 3.75e-16 ... 221s ..- attr(*, "names")= chr [1:10] "1|2.(Intercept)" "2|3.(Intercept)" "3|4.(Intercept)" "4|5.(Intercept)" ... 221s $ Hessian : num [1:10, 1:10] 2.488 -1.01 0 0 0.207 ... 221s ..- attr(*, "dimnames")=List of 2 221s .. ..$ : chr [1:10] "1|2.(Intercept)" "2|3.(Intercept)" "3|4.(Intercept)" "4|5.(Intercept)" ... 221s .. ..$ : chr [1:10] "1|2.(Intercept)" "2|3.(Intercept)" "3|4.(Intercept)" "4|5.(Intercept)" ... 221s $ logLik : num -44.9 221s $ maxGradient : num 8.91e-13 221s $ message : chr "Absolute and relative convergence criteria were met" 221s $ n : int 72 221s $ niter : Named num [1:2] 9 0 221s ..- attr(*, "names")= chr [1:2] "outer" "inner" 221s $ nobs : num 37 221s $ tJac : num [1:4, 1:4] 1 0 0 0 0 1 0 0 0 0 ... 221s ..- attr(*, "dimnames")=List of 2 221s .. ..$ : chr [1:4] "1|2" "2|3" "3|4" "4|5" 221s .. ..$ : chr [1:4] "1|2" "2|3" "3|4" "4|5" 221s $ vcov : num [1:10, 1:10] 0.5338 0.1835 0.0254 -0.0626 -0.511 ... 221s ..- attr(*, "dimnames")=List of 2 221s .. ..$ : chr [1:10] "1|2.(Intercept)" "2|3.(Intercept)" "3|4.(Intercept)" "4|5.(Intercept)" ... 221s .. ..$ : chr [1:10] "1|2.(Intercept)" "2|3.(Intercept)" "3|4.(Intercept)" "4|5.(Intercept)" ... 221s $ zeta : Named num -0.0261 221s ..- attr(*, "names")= chr "tempwarm" 221s - attr(*, "class")= chr "clm.fit" 221s > 221s > fit <- clm.fit(fm1$y, fm1$X, fm1$S, fm1$NOM, offset=off1) 221s > str(fit) 221s List of 20 221s $ aliased :List of 3 221s ..$ alpha: Named logi [1:8] FALSE FALSE FALSE FALSE FALSE FALSE ... 221s .. ..- attr(*, "names")= chr [1:8] "1|2.(Intercept)" "2|3.(Intercept)" "3|4.(Intercept)" "4|5.(Intercept)" ... 221s ..$ beta : Named logi FALSE 221s .. ..- attr(*, "names")= chr "tempwarm" 221s ..$ zeta : Named logi FALSE 221s .. ..- attr(*, "names")= chr "tempwarm" 221s $ alpha : Named num [1:8] -0.864 1.746 4.342 5.615 -1.567 ... 221s ..- attr(*, "names")= chr [1:8] "1|2.(Intercept)" "2|3.(Intercept)" "3|4.(Intercept)" "4|5.(Intercept)" ... 221s $ beta : Named num 2.7 221s ..- attr(*, "names")= chr "tempwarm" 221s $ coefficients : Named num [1:10] -0.864 1.746 4.342 5.615 -1.567 ... 221s ..- attr(*, "names")= chr [1:10] "1|2.(Intercept)" "2|3.(Intercept)" "3|4.(Intercept)" "4|5.(Intercept)" ... 221s $ cond.H : num 196 221s $ convergence :List of 3 221s ..$ code : int 0 221s ..$ messages : chr "successful convergence" 221s ..$ alg.message: chr "Absolute and relative convergence criteria were met" 221s $ df.residual : num 62 221s $ edf : int 10 221s $ fitted.values: num [1:72] 0.57 0.183 0.452 0.145 0.135 ... 221s $ gradient : Named num [1:10] 2.19e-09 6.14e-08 5.92e-08 -1.23e-07 4.69e-10 ... 221s ..- attr(*, "names")= chr [1:10] "1|2.(Intercept)" "2|3.(Intercept)" "3|4.(Intercept)" "4|5.(Intercept)" ... 221s $ Hessian : num [1:10, 1:10] 4.48 -1.89 0 0 1.02 ... 221s ..- attr(*, "dimnames")=List of 2 221s .. ..$ : chr [1:10] "1|2.(Intercept)" "2|3.(Intercept)" "3|4.(Intercept)" "4|5.(Intercept)" ... 221s .. ..$ : chr [1:10] "1|2.(Intercept)" "2|3.(Intercept)" "3|4.(Intercept)" "4|5.(Intercept)" ... 221s $ logLik : num -86.1 221s $ maxGradient : num 2.17e-07 221s $ message : chr "Absolute and relative convergence criteria were met" 221s $ n : int 72 221s $ niter : Named num [1:2] 8 0 221s ..- attr(*, "names")= chr [1:2] "outer" "inner" 221s $ nobs : num 72 221s $ tJac : num [1:4, 1:4] 1 0 0 0 0 1 0 0 0 0 ... 221s ..- attr(*, "dimnames")=List of 2 221s .. ..$ : chr [1:4] "1|2" "2|3" "3|4" "4|5" 221s .. ..$ : chr [1:4] "1|2" "2|3" "3|4" "4|5" 221s $ vcov : num [1:10, 1:10] 0.33117 0.09074 0.00108 -0.04015 -0.31468 ... 221s ..- attr(*, "dimnames")=List of 2 221s .. ..$ : chr [1:10] "1|2.(Intercept)" "2|3.(Intercept)" "3|4.(Intercept)" "4|5.(Intercept)" ... 221s .. ..$ : chr [1:10] "1|2.(Intercept)" "2|3.(Intercept)" "3|4.(Intercept)" "4|5.(Intercept)" ... 221s $ zeta : Named num 0.114 221s ..- attr(*, "names")= chr "tempwarm" 221s - attr(*, "class")= chr "clm.fit" 221s > 221s > fit <- clm.fit(fm1$y, fm1$X, fm1$S, fm1$NOM, offset=off1, 221s + S.offset=off2) 221s > str(fit) 221s List of 20 221s $ aliased :Warning message: 221s Cannot assess if all thresholds are increasing 221s List of 3 221s ..$ alpha: Named logi [1:8] FALSE FALSE FALSE FALSE FALSE FALSE ... 221s .. ..- attr(*, "names")= chr [1:8] "1|2.(Intercept)" "2|3.(Intercept)" "3|4.(Intercept)" "4|5.(Intercept)" ... 221s ..$ beta : Named logi FALSE 221s .. ..- attr(*, "names")= chr "tempwarm" 221s ..$ zeta : Named logi FALSE 221s .. ..- attr(*, "names")= chr "tempwarm" 221s $ alpha : Named num [1:8] -0.585 1.951 3.24 4.18 -6.481 ... 221s ..- attr(*, "names")= chr [1:8] "1|2.(Intercept)" "2|3.(Intercept)" "3|4.(Intercept)" "4|5.(Intercept)" ... 221s $ beta : Named num 2.12 221s ..- attr(*, "names")= chr "tempwarm" 221s $ coefficients : Named num [1:10] -0.585 1.951 3.24 4.18 -6.481 ... 221s ..- attr(*, "names")= chr [1:10] "1|2.(Intercept)" "2|3.(Intercept)" "3|4.(Intercept)" "4|5.(Intercept)" ... 221s $ cond.H : num 634 221s $ convergence :List of 3 221s ..$ code : int 0 221s ..$ messages : chr "successful convergence" 221s ..$ alg.message: chr "Absolute and relative convergence criteria were met" 221s $ df.residual : num 62 221s $ edf : int 10 221s $ fitted.values: num [1:72] 0.7899 0.1277 0.7 0.0888 0.1521 ... 221s $ gradient : Named num [1:10] 6.72e-12 8.06e-10 7.28e-10 -7.85e-10 1.15e-12 ... 221s ..- attr(*, "names")= chr [1:10] "1|2.(Intercept)" "2|3.(Intercept)" "3|4.(Intercept)" "4|5.(Intercept)" ... 221s $ Hessian : num [1:10, 1:10] 4.126 -1.006 0 0 0.079 ... 221s ..- attr(*, "dimnames")=List of 2 221s .. ..$ : chr [1:10] "1|2.(Intercept)" "2|3.(Intercept)" "3|4.(Intercept)" "4|5.(Intercept)" ... 221s .. ..$ : chr [1:10] "1|2.(Intercept)" "2|3.(Intercept)" "3|4.(Intercept)" "4|5.(Intercept)" ... 221s $ logLik : num -87.6 221s $ maxGradient : num 9.74e-10 221s $ message : chr "Absolute and relative convergence criteria were met" 221s $ n : int 72 221s $ niter : Named num [1:2] 13 0 221s ..- attr(*, "names")= chr [1:2] "outer" "inner" 221s $ nobs : num 72 221s $ tJac : num [1:4, 1:4] 1 0 0 0 0 1 0 0 0 0 ... 221s ..- attr(*, "dimnames")=List of 2 221s .. ..$ : chr [1:4] "1|2" "2|3" "3|4" "4|5" 221s .. ..$ : chr [1:4] "1|2" "2|3" "3|4" "4|5" 221s $ vcov : num [1:10, 1:10] 0.2616 0.0523 0.0345 0.0236 -0.2449 ... 221s ..- attr(*, "dimnames")=List of 2 221s .. ..$ : chr [1:10] "1|2.(Intercept)" "2|3.(Intercept)" "3|4.(Intercept)" "4|5.(Intercept)" ... 221s .. ..$ : chr [1:10] "1|2.(Intercept)" "2|3.(Intercept)" "3|4.(Intercept)" "4|5.(Intercept)" ... 221s $ zeta : Named num -0.502 221s ..- attr(*, "names")= chr "tempwarm" 221s - attr(*, "class")= chr "clm.fit" 221s > 221s > fit <- clm.fit(fm1$y, fm1$X, fm1$S) 221s > str(fit) 221s List of 21 221s $ aliased :List of 3 221s ..$ alpha: Named logi [1:4] FALSE FALSE FALSE FALSE 221s .. ..- attr(*, "names")= chr [1:4] "1|2" "2|3" "3|4" "4|5" 221s ..$ beta : Named logi FALSE 221s .. ..- attr(*, "names")= chr "tempwarm" 221s ..$ zeta : Named logi FALSE 221s .. ..- attr(*, "names")= chr "tempwarm" 221s $ alpha : Named num [1:4] -1.988 0.418 2.648 4.306 221s ..- attr(*, "names")= chr [1:4] "1|2" "2|3" "3|4" "4|5" 221s $ beta : Named num 2.51 221s ..- attr(*, "names")= chr "tempwarm" 221s $ coefficients : Named num [1:6] -1.988 0.418 2.648 4.306 2.512 ... 221s ..- attr(*, "names")= chr [1:6] "1|2" "2|3" "3|4" "4|5" ... 221s $ cond.H : num 80.6 221s $ convergence :List of 3 221s ..$ code : int 0 221s ..$ messages : chr "successful convergence" 221s ..$ alg.message: chr "Absolute and relative convergence criteria were met" 221s $ df.residual : num 66 221s $ edf : int 6 221s $ fitted.values: num [1:72] 0.4826 0.3308 0.3308 0.0528 0.2897 ... 221s $ gradient : Named num [1:6] 7.03e-09 6.91e-08 5.99e-07 -7.42e-07 2.76e-08 ... 221s ..- attr(*, "names")= chr [1:6] "1|2" "2|3" "3|4" "4|5" ... 221s $ Hessian : num [1:6, 1:6] 4.8066 -2.4889 0 0 -0.0926 ... 221s ..- attr(*, "dimnames")=List of 2 221s .. ..$ : chr [1:6] "1|2" "2|3" "3|4" "4|5" ... 221s .. ..$ : chr [1:6] "1|2" "2|3" "3|4" "4|5" ... 221s $ logLik : num -91.8 221s $ maxGradient : num 8.53e-07 221s $ message : chr "Absolute and relative convergence criteria were met" 221s $ n : int 72 221s $ niter : Named num [1:2] 8 0 221s ..- attr(*, "names")= chr [1:2] "outer" "inner" 221s $ nobs : num 72 221s $ Theta : num [1, 1:4] -1.988 0.418 2.648 4.306 221s ..- attr(*, "dimnames")=List of 2 221s .. ..$ : NULL 221s .. ..$ : chr [1:4] "1|2" "2|3" "3|4" "4|5" 221s $ tJac : num [1:4, 1:4] 1 0 0 0 0 1 0 0 0 0 ... 221s ..- attr(*, "dimnames")=List of 2 221s .. ..$ : chr [1:4] "1|2" "2|3" "3|4" "4|5" 221s .. ..$ : chr [1:4] "1|2" "2|3" "3|4" "4|5" 221s $ vcov : num [1:6, 1:6] 0.2481 0.0622 0.0179 -0.0253 0.0197 ... 221s ..- attr(*, "dimnames")=List of 2 221s .. ..$ : chr [1:6] "1|2" "2|3" "3|4" "4|5" ... 221s .. ..$ : chr [1:6] "1|2" "2|3" "3|4" "4|5" ... 221s $ zeta : Named num 0.176 221s ..- attr(*, "names")= chr "tempwarm" 221s - attr(*, "class")= chr "clm.fit" 221s > 221s > fit <- clm.fit(fm1$y, fm1$X) 221s > str(fit) 221s List of 20 221s $ aliased :List of 2 221s ..$ alpha: Named logi [1:4] FALSE FALSE FALSE FALSE 221s .. ..- attr(*, "names")= chr [1:4] "1|2" "2|3" "3|4" "4|5" 221s ..$ beta : Named logi FALSE 221s .. ..- attr(*, "names")= chr "tempwarm" 221s $ alpha : Named num [1:4] -1.936 0.435 2.432 3.827 221s ..- attr(*, "names")= chr [1:4] "1|2" "2|3" "3|4" "4|5" 221s $ beta : Named num 2.29 221s ..- attr(*, "names")= chr "tempwarm" 221s $ coefficients : Named num [1:5] -1.936 0.435 2.432 3.827 2.287 221s ..- attr(*, "names")= chr [1:5] "1|2" "2|3" "3|4" "4|5" ... 221s $ cond.H : num 16.8 221s $ convergence :List of 3 221s ..$ code : int 0 221s ..$ messages : chr "successful convergence" 221s ..$ alg.message: chr "Absolute and relative convergence criteria were met" 221s $ df.residual : num 67 221s $ edf : int 5 221s $ fitted.values: num [1:72] 0.481 0.3122 0.3122 0.0594 0.2871 ... 221s $ gradient : Named num [1:5] 4.07e-14 8.24e-14 -9.90e-14 6.66e-16 -2.22e-14 221s ..- attr(*, "names")= chr [1:5] "1|2" "2|3" "3|4" "4|5" ... 221s $ Hessian : num [1:5, 1:5] 4.8983 -2.499 0 0 -0.0854 ... 221s ..- attr(*, "dimnames")=List of 2 221s .. ..$ : chr [1:5] "1|2" "2|3" "3|4" "4|5" ... 221s .. ..$ : chr [1:5] "1|2" "2|3" "3|4" "4|5" ... 221s $ logLik : num -92 221s $ maxGradient : num 9.9e-14 221s $ message : chr "Absolute and relative convergence criteria were met" 221s $ n : int 72 221s $ niter : Named num [1:2] 6 0 221s ..- attr(*, "names")= chr [1:2] "outer" "inner" 221s $ nobs : num 72 221s $ Theta : num [1, 1:4] -1.936 0.435 2.432 3.827 221s ..- attr(*, "dimnames")=List of 2 221s .. ..$ : NULL 221s .. ..$ : chr [1:4] "1|2" "2|3" "3|4" "4|5" 221s $ tJac : num [1:4, 1:4] 1 0 0 0 0 1 0 0 0 0 ... 221s ..- attr(*, "dimnames")=List of 2 221s .. ..$ : chr [1:4] "1|2" "2|3" "3|4" "4|5" 221s .. ..$ : chr [1:4] "1|2" "2|3" "3|4" "4|5" 221s $ vcov : num [1:5, 1:5] 0.2345 0.0577 0.0505 0.0512 0.0537 ... 221s ..- attr(*, "dimnames")=List of 2 221s .. ..$ : chr [1:5] "1|2" "2|3" "3|4" "4|5" ... 221s .. ..$ : chr [1:5] "1|2" "2|3" "3|4" "4|5" ... 221s - attr(*, "class")= chr "clm.fit" 221s > 221s > fit <- clm.fit(fm1$y) 221s > coef(fit) 221s 1|2 2|3 3|4 4|5 221s -2.5952547 -0.5108256 1.0258529 2.2284771 221s > str(fit) 221s List of 19 221s $ aliased :List of 2 221s ..$ alpha: Named logi [1:4] FALSE FALSE FALSE FALSE 221s .. ..- attr(*, "names")= chr [1:4] "1|2" "2|3" "3|4" "4|5" 221s ..$ beta : Named logi(0) 221s .. ..- attr(*, "names")= chr(0) 221s $ alpha : Named num [1:4] -2.595 -0.511 1.026 2.228 221s ..- attr(*, "names")= chr [1:4] "1|2" "2|3" "3|4" "4|5" 221s $ coefficients : Named num [1:4] -2.595 -0.511 1.026 2.228 221s ..- attr(*, "names")= chr [1:4] "1|2" "2|3" "3|4" "4|5" 221s $ cond.H : num 8.38 221s $ convergence :List of 3 221s ..$ code : int 0 221s ..$ messages : chr "successful convergence" 221s ..$ alg.message: chr "Absolute and relative convergence criteria were met" 221s $ df.residual : num 68 221s $ edf : int 4 221s $ fitted.values: num [1:72] 0.306 0.361 0.361 0.167 0.167 ... 221s $ gradient : Named num [1:4] 7.23e-08 -5.51e-08 -1.72e-11 -4.86e-12 221s ..- attr(*, "names")= chr [1:4] "1|2" "2|3" "3|4" "4|5" 221s $ Hessian : num [1:4, 1:4] 5.31 -3.57 0 0 -3.57 ... 221s ..- attr(*, "dimnames")=List of 2 221s .. ..$ : chr [1:4] "1|2" "2|3" "3|4" "4|5" 221s .. ..$ : chr [1:4] "1|2" "2|3" "3|4" "4|5" 221s $ logLik : num -104 221s $ maxGradient : num 7.23e-08 221s $ message : chr "Absolute and relative convergence criteria were met" 221s $ n : int 72 221s $ niter : Named num [1:2] 5 0 221s ..- attr(*, "names")= chr [1:2] "outer" "inner" 221s $ nobs : num 72 221s $ Theta : num [1, 1:4] -2.595 -0.511 1.026 2.228 221s ..- attr(*, "dimnames")=List of 2 221s .. ..$ : NULL 221s .. ..$ : chr [1:4] "1|2" "2|3" "3|4" "4|5" 221s $ tJac : num [1:4, 1:4] 1 0 0 0 0 1 0 0 0 0 ... 221s ..- attr(*, "dimnames")=List of 2 221s .. ..$ : chr [1:4] "1|2" "2|3" "3|4" "4|5" 221s .. ..$ : chr [1:4] "1|2" "2|3" "3|4" "4|5" 221s $ vcov : num [1:4, 1:4] 0.2149 0.0398 0.0203 0.0165 0.0398 ... 221s ..- attr(*, "dimnames")=List of 2 221s .. ..$ : chr [1:4] "1|2" "2|3" "3|4" "4|5" 221s .. ..$ : chr [1:4] "1|2" "2|3" "3|4" "4|5" 221s - attr(*, "class")= chr "clm.fit" 221s > 221s > ## Remember: compare with corresponding .Rout file 221s > 221s BEGIN TEST clm.formula.R 221s 221s R version 4.4.3 (2025-02-28) -- "Trophy Case" 221s Copyright (C) 2025 The R Foundation for Statistical Computing 221s Platform: arm-unknown-linux-gnueabihf (32-bit) 221s 221s R is free software and comes with ABSOLUTELY NO WARRANTY. 221s You are welcome to redistribute it under certain conditions. 221s Type 'license()' or 'licence()' for distribution details. 221s 221s R is a collaborative project with many contributors. 221s Type 'contributors()' for more information and 221s 'citation()' on how to cite R or R packages in publications. 221s 221s Type 'demo()' for some demos, 'help()' for on-line help, or 221s 'help.start()' for an HTML browser interface to help. 221s Type 'q()' to quit R. 221s 221s > library(ordinal) 222s > ## library(devtools) 222s > ## r2path <- "/Users/rhbc/Documents/Rpackages/ordinal/pkg/ordinal" 222s > ## clean_dll(pkg = r2path) 222s > ## load_all(r2path) 222s > 222s > ################################# 222s > ## Appropriate evaluation of formulas: 222s > 222s > ## These fail and give appropriate error messages: 222s > ## fm1 <- clm(rating ~ contact, scale=temp, data=wine) 222s > ## fm1 <- clm(rating ~ contact, scale=~Temp, data=wine) 222s > ## fm1 <- clm(rating ~ contact, scale="temp", data=wine) 222s > ## sca <- "temp" 222s > ## fm1 <- clm(rating ~ contact, scale=sca, data=wine) 222s > ## sca <- as.formula(sca) 222s > ## sca <- as.formula(temp) 222s > ## sca <- with(wine, as.formula(temp)) 222s > 222s > ## These all work as intended with no warnings or errors: 222s > fm1 <- clm(rating ~ contact, scale="~temp", data=wine) 222s > fm1 <- clm(rating ~ contact, scale=~temp, data=wine) 222s > sca <- "~temp" 222s > fm1 <- clm(rating ~ contact, scale=sca, data=wine) 222s > sca <- as.formula("~temp") 222s > fm1 <- clm(rating ~ contact, scale=sca, data=wine) 222s > fm1 <- clm(rating ~ contact, scale=as.formula(~temp), data=wine) 223s > fm1 <- clm(rating ~ contact, scale=as.formula("~temp"), data=wine) 223s > 223s > ################################# 223s > ## can evaluate if 'formula' is a character: 223s > f <- "rating ~ contact + temp" 223s > clm(f, data=wine) 223s formula: rating ~ contact + temp 223s data: wine 223s 223s link threshold nobs logLik AIC niter max.grad cond.H 223s logit flexible 72 -86.49 184.98 6(0) 4.01e-12 2.7e+01 223s 223s Coefficients: 223s contactyes tempwarm 223s 1.528 2.503 223s 223s Threshold coefficients: 223s 1|2 2|3 3|4 4|5 223s -1.344 1.251 3.467 5.006 223s > clm(as.formula(f), data=wine) 223s formula: rating ~ contact + temp 223s data: wine 223s 223s link threshold nobs logLik AIC niter max.grad cond.H 223s logit flexible 72 -86.49 184.98 6(0) 4.01e-12 2.7e+01 223s 223s Coefficients: 223s contactyes tempwarm 223s 1.528 2.503 223s 223s Threshold coefficients: 223s 1|2 2|3 3|4 4|5 223s -1.344 1.251 3.467 5.006 223s > 223s > ################################# 223s > 223s > ### finding variables in the environment of the formula: 223s > makeform <- function() { 223s + f1 <- as.formula(rating ~ temp + contact) 223s + rating <- wine$rating 223s + temp <- wine$temp 223s + contact <- wine$contact 223s + f1 223s + } 223s > ## 'makeform' makes are formula object in the environment of the 223s > ## function makeform: 223s > f1 <- makeform() 223s > f1 # print 223s rating ~ temp + contact 223s 223s > class(f1) 223s [1] "formula" 223s > ## If we give the data, we can evaluate the model: 223s > fm1 <- clm(f1, data=wine) 223s > ## We can also evaluate the model because the data are available in 223s > ## the environment associated with the formula: 223s > fm1 <- clm(f1) 223s > ## For instance, the 'rating' variable is not found in the Global 223s > ## environment; we have to evaluate the 'name' of 'rating' in the 223s > ## appropriate environment: 223s > (try(rating, silent=TRUE)) 223s [1] "Error : object 'rating' not found\n" 223s attr(,"class") 223s [1] "try-error" 223s attr(,"condition") 223s 223s > eval(as.name("rating"), envir=environment(f1)) 223s [1] 2 3 3 4 4 4 5 5 1 2 1 3 2 3 5 4 2 3 3 2 5 5 4 4 3 2 3 2 3 2 5 3 2 3 4 3 3 3 223s [39] 3 3 3 2 3 2 2 4 5 4 1 1 2 2 2 3 2 3 2 2 2 3 3 3 3 4 1 2 3 2 3 2 4 4 223s Levels: 1 < 2 < 3 < 4 < 5 223s > ## If instead we generate the formula in the Global environment where 223s > ## the variables are not found, we cannot evaluate the model: 223s > f2 <- as.formula(rating ~ temp + contact) 223s > (try(fm2 <- clm(f2), silent=TRUE)) 223s [1] "Error in eval(predvars, data, env) : object 'rating' not found\n" 223s attr(,"class") 223s [1] "try-error" 223s attr(,"condition") 223s 223s > environment(f2) <- environment(f1) 223s > fm2 <- clm(f2) 223s > 223s > 223s > ################################# 223s > ## Use of formula-objects in location, scale and nominal: 223s > ## Bug-report from Llus Marco Almagro 223s > ## 5 May 2010 17:58 223s > f <- formula(rating ~ temp) 223s > fs <- formula( ~ contact) 223s > m2 <- clm(f, scale = fs, data = wine) 223s > summary(m2) 223s formula: rating ~ temp 223s scale: ~contact 223s data: wine 223s 223s link threshold nobs logLik AIC niter max.grad cond.H 223s logit flexible 72 -91.92 195.83 8(0) 1.57e-09 5.6e+01 223s 223s Coefficients: 223s Estimate Std. Error z value Pr(>|z|) 223s tempwarm 2.1690 0.5527 3.924 8.69e-05 *** 223s --- 223s Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1 223s 223s log-scale coefficients: 223s Estimate Std. Error z value Pr(>|z|) 223s contactyes -0.1222 0.2775 -0.44 0.66 223s 223s Threshold coefficients: 223s Estimate Std. Error z value 223s 1|2 -1.8957 0.4756 -3.986 223s 2|3 0.3668 0.3442 1.066 223s 3|4 2.2483 0.5932 3.790 223s 4|5 3.5393 0.8336 4.246 223s > 223s > ################################# 223s > ## Other ways to construct formulas: 223s > set.seed(12345) 223s > y <- factor(sample(1:4,20,replace=TRUE)) 223s > x <- rnorm(20) 223s > data <- data.frame(y=y,x=x) 223s > rm(x, y) 223s > fit <- clm(data$y ~ data$x) 223s > fit 223s formula: data$y ~ data$x 223s 223s link threshold nobs logLik AIC niter max.grad cond.H 223s logit flexible 20 -25.37 58.74 5(0) 2.68e-09 8.4e+00 223s 223s Coefficients: 223s data$x 223s 0.2527 223s 223s Threshold coefficients: 223s 1|2 2|3 3|4 223s -2.18234 0.06059 0.92746 223s > fit <- clm(data[,1] ~ data[,2]) 223s > fit 223s formula: data[, 1] ~ data[, 2] 223s 223s link threshold nobs logLik AIC niter max.grad cond.H 223s logit flexible 20 -25.37 58.74 5(0) 2.68e-09 8.4e+00 223s 223s Coefficients: 223s data[, 2] 223s 0.2527 223s 223s Threshold coefficients: 223s 1|2 2|3 3|4 223s -2.18234 0.06059 0.92746 223s > ## This previously failed, but now works: 223s > fit <- clm(data$y ~ data$x, ~data$x) 223s > fit 223s formula: data$y ~ data$x 223s scale: ~data$x 223s 223s link threshold nobs logLik AIC niter max.grad cond.H 223s logit flexible 20 -25.32 60.64 7(0) 1.86e-09 9.7e+00 223s 223s Coefficients: 223s data$x 223s 0.2477 223s 223s log-scale coefficients: 223s data$x 223s -0.1136 223s 223s Threshold coefficients: 223s 1|2 2|3 3|4 223s -2.16950 0.07039 0.91381 223s > 223s > ################################# 223s > ## Evaluation within other functions: 223s > ## date: January 18th 2012. 223s > ## 223s > ## The problem was raised by Stefan Herzog (stefan.herzog@unibas.ch) 223s > ## January 12th 2012 in trying to make clm work with glmulti. 223s > 223s > fun.clm <- function(formula, data) 223s + ### This only works because clm via eclm.model.frame is careful to 223s + ### evaluate the 'formula' in the parent environment such it is not the 223s + ### character "formula" that is attempted evaluated. 223s + clm(formula, data = data) 223s > 223s > fun2.clm <- function(formula, data, weights, subset) { 223s + ### This should be the safe way to ensure evaluation of clm in the 223s + ### right environment. 223s + mc <- match.call() 223s + mc[[1]] <- as.name("clm") 223s + eval.parent(mc) 223s + } 223s > 223s > fun.clm(rating ~ temp + contact, data=wine) ## works 223s formula: rating ~ temp + contact 223s data: data 223s 223s link threshold nobs logLik AIC niter max.grad cond.H 223s logit flexible 72 -86.49 184.98 6(0) 4.02e-12 2.7e+01 223s 223s Coefficients: 223s tempwarm contactyes 223s 2.503 1.528 223s 223s Threshold coefficients: 223s 1|2 2|3 3|4 4|5 223s -1.344 1.251 3.467 5.006 223s > fun2.clm(rating ~ temp + contact, data=wine) ## works 223s formula: rating ~ temp + contact 223s data: wine 223s 223s link threshold nobs logLik AIC niter max.grad cond.H 223s logit flexible 72 -86.49 184.98 6(0) 4.02e-12 2.7e+01 223s 223s Coefficients: 223s tempwarm contactyes 223s 2.503 1.528 223s 223s Threshold coefficients: 223s 1|2 2|3 3|4 4|5 223s -1.344 1.251 3.467 5.006 223s > 223s > form1 <- "rating ~ temp + contact" 223s > fun.clm(form1, data=wine) ## works 223s formula: rating ~ temp + contact 223s data: data 223s 223s link threshold nobs logLik AIC niter max.grad cond.H 223s logit flexible 72 -86.49 184.98 6(0) 4.02e-12 2.7e+01 223s 223s Coefficients: 223s tempwarm contactyes 223s 2.503 1.528 223s 223s Threshold coefficients: 223s 1|2 2|3 3|4 4|5 223s -1.344 1.251 3.467 5.006 223s > fun2.clm(form1, data=wine) ## works 223s formula: rating ~ temp + contact 223s data: wine 223s 223s link threshold nobs logLik AIC niter max.grad cond.H 223s logit flexible 72 -86.49 184.98 6(0) 4.02e-12 2.7e+01 223s 223s Coefficients: 223s tempwarm contactyes 223s 2.503 1.528 223s 223s Threshold coefficients: 223s 1|2 2|3 3|4 4|5 223s -1.344 1.251 3.467 5.006 223s > 223s > form2 <- formula(rating ~ temp + contact) 223s > fun.clm(form2, data=wine) ## works 223s formula: rating ~ temp + contact 223s data: data 223s 223s link threshold nobs logLik AIC niter max.grad cond.H 223s logit flexible 72 -86.49 184.98 6(0) 4.02e-12 2.7e+01 223s 223s Coefficients: 223s tempwarm contactyes 223s 2.503 1.528 223s 223s Threshold coefficients: 223s 1|2 2|3 3|4 4|5 223s -1.344 1.251 3.467 5.006 223s > fun2.clm(form2, data=wine) ## works 223s formula: rating ~ temp + contact 223s data: wine 223s 223s link threshold nobs logLik AIC niter max.grad cond.H 223s logit flexible 72 -86.49 184.98 6(0) 4.02e-12 2.7e+01 223s 223s Coefficients: 223s tempwarm contactyes 223s 2.503 1.528 223s 223s Threshold coefficients: 223s 1|2 2|3 3|4 4|5 223s -1.344 1.251 3.467 5.006 223s > ## Notice that clm is not able to get the name of the data (wine) 223s > ## correct when using fun.clm. 223s > 223s > ################################# 223s > ## Evaluation of long formulas: no line breaking in getFullForm: 223s > data(soup, package="ordinal") 223s > 223s > rhs <- paste(names(soup)[c(3, 5:12)], collapse=" + ") 223s > Location <- as.formula(paste("SURENESS ~ ", rhs, sep=" ")) 223s > Scale <- as.formula("~ PROD") 223s > 223s > fm5 <- clm(Location, scale=Scale, data=soup) 223s > summary(fm5) 223s formula: 223s SURENESS ~ PRODID + DAY + SOUPTYPE + SOUPFREQ + COLD + EASY + GENDER + AGEGROUP + LOCATION 223s scale: ~PROD 223s data: soup 223s 223s link threshold nobs logLik AIC niter max.grad cond.H 223s logit flexible 1847 -2651.65 5367.30 8(1) 4.65e-07 1.1e+04 223s 223s Coefficients: 223s Estimate Std. Error z value Pr(>|z|) 223s PRODID2 1.09324 0.14790 7.392 1.45e-13 *** 223s PRODID3 1.54233 0.21252 7.257 3.95e-13 *** 223s PRODID4 0.95602 0.18180 5.258 1.45e-07 *** 223s PRODID5 1.52404 0.20311 7.504 6.21e-14 *** 223s PRODID6 1.83964 0.21750 8.458 < 2e-16 *** 223s DAY2 -0.26999 0.10280 -2.626 0.00863 ** 223s SOUPTYPECanned -0.31340 0.11745 -2.668 0.00762 ** 223s SOUPTYPEDry-mix 0.22429 0.14295 1.569 0.11665 223s SOUPFREQ1-4/month -0.06459 0.10551 -0.612 0.54046 223s SOUPFREQ<1/month 0.03664 0.21310 0.172 0.86350 223s COLDYes 0.31373 0.14894 2.106 0.03517 * 223s EASY2 0.16689 0.55063 0.303 0.76182 223s EASY3 0.34765 0.50432 0.689 0.49061 223s EASY4 0.30008 0.48283 0.621 0.53428 223s EASY5 0.23492 0.47686 0.493 0.62226 223s EASY6 -0.03205 0.46993 -0.068 0.94562 223s EASY7 0.02823 0.46963 0.060 0.95208 223s EASY8 -0.04600 0.47066 -0.098 0.92215 223s EASY9 -0.04084 0.49595 -0.082 0.93437 223s EASY10 1.03641 0.60080 1.725 0.08452 . 223s GENDERFemale -0.05092 0.10738 -0.474 0.63534 223s AGEGROUP31-40 0.02098 0.14822 0.142 0.88745 223s AGEGROUP41-50 0.23712 0.15824 1.498 0.13401 223s AGEGROUP51-65 -0.13791 0.14393 -0.958 0.33798 223s LOCATIONRegion 2 -0.09641 0.13225 -0.729 0.46599 223s LOCATIONRegion 3 0.06062 0.11981 0.506 0.61290 223s --- 223s Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1 223s 223s log-scale coefficients: 223s Estimate Std. Error z value Pr(>|z|) 223s PRODTest 0.14545 0.06621 2.197 0.028 * 223s --- 223s Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1 223s 223s Threshold coefficients: 223s Estimate Std. Error z value 223s 1|2 -1.64700 0.49982 -3.295 223s 2|3 -0.58840 0.49681 -1.184 223s 3|4 -0.23496 0.49669 -0.473 223s 4|5 0.04394 0.49679 0.088 223s 5|6 0.78551 0.49869 1.575 223s > 223s > ################################# 223s > ## Check that "."-notation works in formula: 223s > ## December 25th 2014, RHBC 223s > data(wine) 223s > wine2 <- wine[c("rating", "contact", "temp")] 223s > str(wine2) 223s 'data.frame': 72 obs. of 3 variables: 223s $ rating : Ord.factor w/ 5 levels "1"<"2"<"3"<"4"<..: 2 3 3 4 4 4 5 5 1 2 ... 223s $ contact: Factor w/ 2 levels "no","yes": 1 1 2 2 1 1 2 2 1 1 ... 223s $ temp : Factor w/ 2 levels "cold","warm": 1 1 1 1 2 2 2 2 1 1 ... 223s > fm0 <- clm(rating ~ ., data=wine2) 223s > fm1 <- clm(rating ~ contact + temp, data=wine2) 223s > keep <- c("coefficients", "logLik", "info") 223s > fun <- function(x, y) stopifnot(isTRUE(all.equal(x, y))) 223s > mapply(fun, fm0[keep], fm1[keep]) 223s $coefficients 223s NULL 223s 223s $logLik 223s NULL 223s 223s $info 223s NULL 223s 223s > ################################# 223s > 223s BEGIN TEST clmm.R 223s 223s R version 4.4.3 (2025-02-28) -- "Trophy Case" 223s Copyright (C) 2025 The R Foundation for Statistical Computing 223s Platform: arm-unknown-linux-gnueabihf (32-bit) 223s 223s R is free software and comes with ABSOLUTELY NO WARRANTY. 223s You are welcome to redistribute it under certain conditions. 223s Type 'license()' or 'licence()' for distribution details. 223s 223s R is a collaborative project with many contributors. 223s Type 'contributors()' for more information and 223s 'citation()' on how to cite R or R packages in publications. 223s 223s Type 'demo()' for some demos, 'help()' for on-line help, or 223s 'help.start()' for an HTML browser interface to help. 223s Type 'q()' to quit R. 223s 223s > library(ordinal) 224s > data(wine) 224s > 224s > ################################# 224s > ## Estimation with a single simple RE term: 224s > ## Laplace: 224s > fmm1 <- clmm(rating ~ contact + temp + (1|judge), data=wine) 224s > summary(fmm1) 224s Cumulative Link Mixed Model fitted with the Laplace approximation 224s 224s formula: rating ~ contact + temp + (1 | judge) 224s data: wine 224s 224s link threshold nobs logLik AIC niter max.grad cond.H 224s logit flexible 72 -81.57 177.13 332(999) 1.04e-05 2.8e+01 224s 224s Random effects: 224s Groups Name Variance Std.Dev. 224s judge (Intercept) 1.279 1.131 224s Number of groups: judge 9 224s 224s Coefficients: 224s Estimate Std. Error z value Pr(>|z|) 224s contactyes 1.8349 0.5125 3.580 0.000344 *** 224s tempwarm 3.0630 0.5954 5.145 2.68e-07 *** 224s --- 224s Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1 224s 224s Threshold coefficients: 224s Estimate Std. Error z value 224s 1|2 -1.6237 0.6824 -2.379 224s 2|3 1.5134 0.6038 2.507 224s 3|4 4.2285 0.8090 5.227 224s 4|5 6.0888 0.9725 6.261 224s > ## GHQ: 224s > fmm.ghq <- clmm(rating ~ contact + temp + (1|judge), data=wine, 224s + nAGQ=-10) 224s > summary(fmm.ghq) 224s Cumulative Link Mixed Model fitted with the Gauss-Hermite 224s quadrature approximation with 10 quadrature points 224s 224s formula: rating ~ contact + temp + (1 | judge) 224s data: wine 224s 224s link threshold nobs logLik AIC niter max.grad cond.H 224s logit flexible 72 -81.53 177.06 304(3) 1.67e-05 2.8e+01 224s 224s Random effects: 224s Groups Name Variance Std.Dev. 224s judge (Intercept) 1.288 1.135 224s Number of groups: judge 9 224s 224s Coefficients: 224s Estimate Std. Error z value Pr(>|z|) 224s contactyes 1.8335 0.5122 3.580 0.000344 *** 224s tempwarm 3.0620 0.5951 5.145 2.67e-07 *** 224s --- 224s Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1 224s 224s Threshold coefficients: 224s Estimate Std. Error z value 224s 1|2 -1.6231 0.6829 -2.377 224s 2|3 1.5133 0.6045 2.503 224s 3|4 4.2277 0.8094 5.223 224s 4|5 6.0869 0.9726 6.258 224s > ## AGQ: 224s > fmm.agq <- clmm(rating ~ contact + temp + (1|judge), data=wine, 224s + nAGQ=10) 224s > summary(fmm.agq) 224s Cumulative Link Mixed Model fitted with the adaptive Gauss-Hermite 224s quadrature approximation with 10 quadrature points 224s 224s formula: rating ~ contact + temp + (1 | judge) 224s data: wine 224s 224s link threshold nobs logLik AIC niter max.grad cond.H 224s logit flexible 72 -81.53 177.06 304(915) 2.26e-05 2.8e+01 224s 224s Random effects: 224s Groups Name Variance Std.Dev. 224s judge (Intercept) 1.288 1.135 224s Number of groups: judge 9 224s 224s Coefficients: 224s Estimate Std. Error z value Pr(>|z|) 224s contactyes 1.8334 0.5122 3.580 0.000344 *** 224s tempwarm 3.0619 0.5951 5.145 2.67e-07 *** 224s --- 224s Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1 224s 224s Threshold coefficients: 224s Estimate Std. Error z value 224s 1|2 -1.6235 0.6834 -2.376 224s 2|3 1.5128 0.6044 2.503 224s 3|4 4.2271 0.8090 5.225 224s 4|5 6.0862 0.9719 6.262 224s > ## tests: 224s > ## Notice warning about Laplace with multiple REs when nAGQ != 1: 224s > fmm1 <- try(clmm(rating ~ contact + temp + (1|judge) + (1|bottle), 224s + data=wine, nAGQ=10)) 225s Error : Quadrature methods are not available with more than one random effects term 225s > stopifnot(inherits(fmm1, "try-error")) 225s > 225s > ################################# 225s > ## Estimation with several RE terms: 225s > data(soup, package="ordinal") 225s > fmm <- clmm(SURENESS ~ PROD + (1|RESP) + (1|PROD:RESP), data=soup, 225s + threshold="equidistant") 226s > summary(fmm) 226s Cumulative Link Mixed Model fitted with the Laplace approximation 226s 226s formula: SURENESS ~ PROD + (1 | RESP) + (1 | PROD:RESP) 226s data: soup 226s 226s link threshold nobs logLik AIC niter max.grad cond.H 226s logit equidistant 1847 -2766.32 5542.63 225(711) 9.82e-04 1.3e+02 226s 226s Random effects: 226s Groups Name Variance Std.Dev. 226s PROD:RESP (Intercept) 0.4070 0.6379 226s RESP (Intercept) 0.1308 0.3616 226s Number of groups: PROD:RESP 370, RESP 185 226s 226s Coefficients: 226s Estimate Std. Error z value Pr(>|z|) 226s PRODTest 1.2865 0.1156 11.12 <2e-16 *** 226s --- 226s Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1 226s 226s Threshold coefficients: 226s Estimate Std. Error z value 226s threshold.1 -1.35104 0.09526 -14.18 226s spacing 0.56472 0.01905 29.65 226s > 226s > ################################# 226s > 226s > ## Estimation with implicit intercept: 226s > fm1 <- clmm(rating ~ 1 + (1|judge), data = wine) 226s > fm2 <- clmm(rating ~ (1|judge), data = wine) 226s > fm3 <- clmm(rating ~ 0 + (1|judge), data = wine) 226s Warning message: 226s In getX(fullmf, fixedmf, contrasts) : an intercept is needed and assumed 226s > stopifnot(isTRUE(all.equal(coef(fm1), coef(fm2), tolerance=1e-5)), 226s + isTRUE(all.equal(coef(fm1), coef(fm3), tolerance=1e-5))) 226s > 226s BEGIN TEST clmm.control.R 227s 227s R version 4.4.3 (2025-02-28) -- "Trophy Case" 227s Copyright (C) 2025 The R Foundation for Statistical Computing 227s Platform: arm-unknown-linux-gnueabihf (32-bit) 227s 227s R is free software and comes with ABSOLUTELY NO WARRANTY. 227s You are welcome to redistribute it under certain conditions. 227s Type 'license()' or 'licence()' for distribution details. 227s 227s R is a collaborative project with many contributors. 227s Type 'contributors()' for more information and 227s 'citation()' on how to cite R or R packages in publications. 227s 227s Type 'demo()' for some demos, 'help()' for on-line help, or 227s 'help.start()' for an HTML browser interface to help. 227s Type 'q()' to quit R. 227s 227s > library(ordinal) 228s > data(wine) 228s > 228s > 228s > ### 3 options for specifying control arguments: 228s > ## 1) control is a simple list, e.g. list(trace=-1) 228s > ## 2) control is a call to clmm.control 228s > ## 3) control is an empty list; list() 228s > ## all in combination with extra control arguments. 228s > 228s > ordinal:::getCtrlArgs(clmm.control(), list(maxIter=200)) 228s $method 228s [1] "nlminb" 228s 228s $useMatrix 228s [1] FALSE 228s 228s $ctrl 228s $ctrl$trace 228s [1] 0 228s 228s $ctrl$maxIter 228s [1] 200 228s 228s $ctrl$gradTol 228s [1] 1e-04 228s 228s $ctrl$maxLineIter 228s [1] 50 228s 228s $ctrl$innerCtrl 228s [1] "warnOnly" 228s 228s 228s $optCtrl 228s $optCtrl$trace 228s [1] 0 228s 228s 228s $checkRanef 228s [1] "warn" 228s 228s > ordinal:::getCtrlArgs(list(), list(maxIter=200)) 228s $method 228s [1] "nlminb" 228s 228s $useMatrix 228s [1] FALSE 228s 228s $ctrl 228s $ctrl$trace 228s [1] 0 228s 228s $ctrl$maxIter 228s [1] 200 228s 228s $ctrl$gradTol 228s [1] 1e-04 228s 228s $ctrl$maxLineIter 228s [1] 50 228s 228s $ctrl$innerCtrl 228s [1] "warnOnly" 228s 228s 228s $optCtrl 228s $optCtrl$trace 228s [1] 0 228s 228s 228s $checkRanef 228s [1] "warn" 228s 228s > ordinal:::getCtrlArgs(list(), list(trace=-1)) 228s $method 228s [1] "nlminb" 228s 228s $useMatrix 228s [1] FALSE 228s 228s $ctrl 228s $ctrl$trace 228s [1] 1 228s 228s $ctrl$maxIter 228s [1] 50 228s 228s $ctrl$gradTol 228s [1] 1e-04 228s 228s $ctrl$maxLineIter 228s [1] 50 228s 228s $ctrl$innerCtrl 228s [1] "warnOnly" 228s 228s 228s $optCtrl 228s $optCtrl$trace 228s [1] 1 228s 228s 228s $checkRanef 228s [1] "warn" 228s 228s > ordinal:::getCtrlArgs(list(), list(trace=1)) 228s $method 228s [1] "nlminb" 228s 228s $useMatrix 228s [1] FALSE 228s 228s $ctrl 228s $ctrl$trace 228s [1] 0 228s 228s $ctrl$maxIter 228s [1] 50 228s 228s $ctrl$gradTol 228s [1] 1e-04 228s 228s $ctrl$maxLineIter 228s [1] 50 228s 228s $ctrl$innerCtrl 228s [1] "warnOnly" 228s 228s 228s $optCtrl 228s $optCtrl$trace 228s [1] 1 228s 228s 228s $checkRanef 228s [1] "warn" 228s 228s > ordinal:::getCtrlArgs(list(), list()) 228s $method 228s [1] "nlminb" 228s 228s $useMatrix 228s [1] FALSE 228s 228s $ctrl 228s $ctrl$trace 228s [1] 0 228s 228s $ctrl$maxIter 228s [1] 50 228s 228s $ctrl$gradTol 228s [1] 1e-04 228s 228s $ctrl$maxLineIter 228s [1] 50 228s 228s $ctrl$innerCtrl 228s [1] "warnOnly" 228s 228s 228s $optCtrl 228s $optCtrl$trace 228s [1] 0 228s 228s 228s $checkRanef 228s [1] "warn" 228s 228s > ordinal:::getCtrlArgs(list(maxIter=2), list()) 228s $method 228s [1] "nlminb" 228s 228s $useMatrix 228s [1] FALSE 228s 228s $ctrl 228s $ctrl$trace 228s [1] 0 228s 228s $ctrl$maxIter 228s [1] 2 228s 228s $ctrl$gradTol 228s [1] 1e-04 228s 228s $ctrl$maxLineIter 228s [1] 50 228s 228s $ctrl$innerCtrl 228s [1] "warnOnly" 228s 228s 228s $optCtrl 228s $optCtrl$trace 228s [1] 0 228s 228s 228s $checkRanef 228s [1] "warn" 228s 228s > 228s > ordinal:::getCtrlArgs(clmm.control(), list()) 228s $method 228s [1] "nlminb" 228s 228s $useMatrix 228s [1] FALSE 228s 228s $ctrl 228s $ctrl$trace 228s [1] 0 228s 228s $ctrl$maxIter 228s [1] 50 228s 228s $ctrl$gradTol 228s [1] 1e-04 228s 228s $ctrl$maxLineIter 228s [1] 50 228s 228s $ctrl$innerCtrl 228s [1] "warnOnly" 228s 228s 228s $optCtrl 228s $optCtrl$trace 228s [1] 0 228s 228s 228s $checkRanef 228s [1] "warn" 228s 228s > ordinal:::getCtrlArgs(clmm.control(maxIter=100), list(maxIter=200)) 228s $method 228s [1] "nlminb" 228s 228s $useMatrix 228s [1] FALSE 228s 228s $ctrl 228s $ctrl$trace 228s [1] 0 228s 228s $ctrl$maxIter 228s [1] 200 228s 228s $ctrl$gradTol 228s [1] 1e-04 228s 228s $ctrl$maxLineIter 228s [1] 50 228s 228s $ctrl$innerCtrl 228s [1] "warnOnly" 228s 228s 228s $optCtrl 228s $optCtrl$trace 228s [1] 0 228s 228s 228s $checkRanef 228s [1] "warn" 228s 228s > ordinal:::getCtrlArgs(clmm.control(maxIter=100), list(maxIter=200)) 228s $method 228s [1] "nlminb" 228s 228s $useMatrix 228s [1] FALSE 228s 228s $ctrl 228s $ctrl$trace 228s [1] 0 228s 228s $ctrl$maxIter 228s [1] 200 228s 228s $ctrl$gradTol 228s [1] 1e-04 228s 228s $ctrl$maxLineIter 228s [1] 50 228s 228s $ctrl$innerCtrl 228s [1] "warnOnly" 228s 228s 228s $optCtrl 228s $optCtrl$trace 228s [1] 0 228s 228s 228s $checkRanef 228s [1] "warn" 228s 228s > ordinal:::getCtrlArgs(clmm.control(), list(trace=1)) 228s $method 228s [1] "nlminb" 228s 228s $useMatrix 228s [1] FALSE 228s 228s $ctrl 228s $ctrl$trace 228s [1] 0 228s 228s $ctrl$maxIter 228s [1] 50 228s 228s $ctrl$gradTol 228s [1] 1e-04 228s 228s $ctrl$maxLineIter 228s [1] 50 228s 228s $ctrl$innerCtrl 228s [1] "warnOnly" 228s 228s 228s $optCtrl 228s $optCtrl$trace 228s [1] 1 228s 228s 228s $checkRanef 228s [1] "warn" 228s 228s > ordinal:::getCtrlArgs(clmm.control(), list(trace=-1)) 228s $method 228s [1] "nlminb" 228s 228s $useMatrix 228s [1] FALSE 228s 228s $ctrl 228s $ctrl$trace 228s [1] 1 228s 228s $ctrl$maxIter 228s [1] 50 228s 228s $ctrl$gradTol 228s [1] 1e-04 228s 228s $ctrl$maxLineIter 228s [1] 50 228s 228s $ctrl$innerCtrl 228s [1] "warnOnly" 228s 228s 228s $optCtrl 228s $optCtrl$trace 228s [1] 1 228s 228s 228s $checkRanef 228s [1] "warn" 228s 228s > ordinal:::getCtrlArgs(clmm.control(trace=1), list()) 228s $method 228s [1] "nlminb" 228s 228s $useMatrix 228s [1] FALSE 228s 228s $ctrl 228s $ctrl$trace 228s [1] 0 228s 228s $ctrl$maxIter 228s [1] 50 228s 228s $ctrl$gradTol 228s [1] 1e-04 228s 228s $ctrl$maxLineIter 228s [1] 50 228s 228s $ctrl$innerCtrl 228s [1] "warnOnly" 228s 228s 228s $optCtrl 228s $optCtrl$trace 228s [1] 1 228s 228s 228s $checkRanef 228s [1] "warn" 228s 228s > ordinal:::getCtrlArgs(clmm.control(trace=-1), list()) 228s $method 228s [1] "nlminb" 228s 228s $useMatrix 228s [1] FALSE 228s 228s $ctrl 228s $ctrl$trace 228s [1] 1 228s 228s $ctrl$maxIter 228s [1] 50 228s 228s $ctrl$gradTol 228s [1] 1e-04 228s 228s $ctrl$maxLineIter 228s [1] 50 228s 228s $ctrl$innerCtrl 228s [1] "warnOnly" 228s 228s 228s $optCtrl 228s $optCtrl$trace 228s [1] 1 228s 228s 228s $checkRanef 228s [1] "warn" 228s 228s > ordinal:::getCtrlArgs(clmm.control(trace=0), list()) 228s $method 228s [1] "nlminb" 228s 228s $useMatrix 228s [1] FALSE 228s 228s $ctrl 228s $ctrl$trace 228s [1] 0 228s 228s $ctrl$maxIter 228s [1] 50 228s 228s $ctrl$gradTol 228s [1] 1e-04 228s 228s $ctrl$maxLineIter 228s [1] 50 228s 228s $ctrl$innerCtrl 228s [1] "warnOnly" 228s 228s 228s $optCtrl 228s $optCtrl$trace 228s [1] 0 228s 228s 228s $checkRanef 228s [1] "warn" 228s 228s > ## Don't specify trace twice - surprising behavior might occur: 228s > ordinal:::getCtrlArgs(clmm.control(trace=1), list(trace=-1)) 228s $method 228s [1] "nlminb" 228s 228s $useMatrix 228s [1] FALSE 228s 228s $ctrl 228s $ctrl$trace 228s [1] 1 228s 228s $ctrl$maxIter 228s [1] 50 228s 228s $ctrl$gradTol 228s [1] 1e-04 228s 228s $ctrl$maxLineIter 228s [1] 50 228s 228s $ctrl$innerCtrl 228s [1] "warnOnly" 228s 228s 228s $optCtrl 228s $optCtrl$trace 228s [1] 1 228s 228s 228s $checkRanef 228s [1] "warn" 228s 228s > ordinal:::getCtrlArgs(clmm.control(trace=-1), list(trace=1)) 228s $method 228s [1] "nlminb" 228s 228s $useMatrix 228s [1] FALSE 228s 228s $ctrl 228s $ctrl$trace 228s [1] 1 228s 228s $ctrl$maxIter 228s [1] 50 228s 228s $ctrl$gradTol 228s [1] 1e-04 228s 228s $ctrl$maxLineIter 228s [1] 50 228s 228s $ctrl$innerCtrl 228s [1] "warnOnly" 228s 228s 228s $optCtrl 228s $optCtrl$trace 228s [1] 1 228s 228s 228s $checkRanef 228s [1] "warn" 228s 228s > 228s BEGIN TEST clmm.formula.R 228s 228s R version 4.4.3 (2025-02-28) -- "Trophy Case" 228s Copyright (C) 2025 The R Foundation for Statistical Computing 228s Platform: arm-unknown-linux-gnueabihf (32-bit) 228s 228s R is free software and comes with ABSOLUTELY NO WARRANTY. 228s You are welcome to redistribute it under certain conditions. 228s Type 'license()' or 'licence()' for distribution details. 228s 228s R is a collaborative project with many contributors. 228s Type 'contributors()' for more information and 228s 'citation()' on how to cite R or R packages in publications. 228s 228s Type 'demo()' for some demos, 'help()' for on-line help, or 228s 'help.start()' for an HTML browser interface to help. 228s Type 'q()' to quit R. 228s 228s > library(ordinal) 229s > data(wine) 229s > 229s > ################################# 229s > ## Appropriate evaluation of formulas: 229s > 229s > ## These all work as intended with no warnings or errors: 229s > fm1 <- clmm(rating ~ contact + (1|judge), data=wine) 229s > fm1 229s Cumulative Link Mixed Model fitted with the Laplace approximation 229s 229s formula: rating ~ contact + (1 | judge) 229s data: wine 229s 229s link threshold nobs logLik AIC niter max.grad 229s logit flexible 72 -98.80 209.59 228(686) 3.67e-06 229s 229s Random effects: 229s Groups Name Variance Std.Dev. 229s judge (Intercept) 0.4428 0.6654 229s Number of groups: judge 9 229s 229s Coefficients: 229s contactyes 229s 1.3 229s 229s Thresholds: 229s 1|2 2|3 3|4 4|5 229s -2.28331 0.04325 1.86062 3.20298 229s > fm1 <- clmm("rating ~ contact + (1|judge)", data=wine) 229s > fm1 229s Cumulative Link Mixed Model fitted with the Laplace approximation 229s 229s formula: rating ~ contact + (1 | judge) 229s data: wine 229s 229s link threshold nobs logLik AIC niter max.grad 229s logit flexible 72 -98.80 209.59 228(686) 3.67e-06 229s 229s Random effects: 229s Groups Name Variance Std.Dev. 229s judge (Intercept) 0.4428 0.6654 229s Number of groups: judge 9 229s 229s Coefficients: 229s contactyes 229s 1.3 229s 229s Thresholds: 229s 1|2 2|3 3|4 4|5 229s -2.28331 0.04325 1.86062 3.20298 229s > fm1 <- clmm(as.formula("rating ~ contact + (1|judge)"), data=wine) 229s > fm1 229s Cumulative Link Mixed Model fitted with the Laplace approximation 229s 229s formula: rating ~ contact + (1 | judge) 229s data: wine 229s 229s link threshold nobs logLik AIC niter max.grad 229s logit flexible 72 -98.80 209.59 228(686) 3.67e-06 229s 229s Random effects: 229s Groups Name Variance Std.Dev. 229s judge (Intercept) 0.4428 0.6654 229s Number of groups: judge 9 229s 229s Coefficients: 229s contactyes 229s 1.3 229s 229s Thresholds: 229s 1|2 2|3 3|4 4|5 229s -2.28331 0.04325 1.86062 3.20298 229s > fm1 <- clmm(as.formula(rating ~ contact + (1|judge)), data=wine) 229s > fm1 229s Cumulative Link Mixed Model fitted with the Laplace approximation 229s 229s formula: rating ~ contact + (1 | judge) 229s data: wine 229s 229s link threshold nobs logLik AIC niter max.grad 229s logit flexible 72 -98.80 209.59 228(686) 3.67e-06 229s 229s Random effects: 229s Groups Name Variance Std.Dev. 229s judge (Intercept) 0.4428 0.6654 229s Number of groups: judge 9 229s 229s Coefficients: 229s contactyes 229s 1.3 229s 229s Thresholds: 229s 1|2 2|3 3|4 4|5 229s -2.28331 0.04325 1.86062 3.20298 229s > 229s > ################################# 229s > 229s > ### finding variables in the environment of the formula: 229s > makeform <- function() { 229s + f1 <- as.formula(rating ~ temp + contact + (1|judge)) 229s + rating <- wine$rating 229s + temp <- wine$temp 229s + contact <- wine$contact 229s + judge <- wine$judge 229s + f1 229s + } 229s > ## 'makeform' makes are formula object in the environment of the 229s > ## function makeform: 229s > f1 <- makeform() 229s > f1 # print 229s rating ~ temp + contact + (1 | judge) 229s 229s > class(f1) 229s [1] "formula" 229s > ## If we give the data, we can evaluate the model: 229s > fm1 <- clmm(f1, data=wine) 229s > ## We can also evaluate the model because the data are available in 229s > ## the environment associated with the formula: 229s > fm1 <- clmm(f1) 230s > ## For instance, the 'rating' variable is not found in the Global 230s > ## environment; we have to evaluate the 'name' of 'rating' in the 230s > ## appropriate environment: 230s > (try(rating, silent=TRUE)) 230s [1] "Error : object 'rating' not found\n" 230s attr(,"class") 230s [1] "try-error" 230s attr(,"condition") 230s 230s > eval(as.name("rating"), envir=environment(f1)) 230s [1] 2 3 3 4 4 4 5 5 1 2 1 3 2 3 5 4 2 3 3 2 5 5 4 4 3 2 3 2 3 2 5 3 2 3 4 3 3 3 230s [39] 3 3 3 2 3 2 2 4 5 4 1 1 2 2 2 3 2 3 2 2 2 3 3 3 3 4 1 2 3 2 3 2 4 4 230s Levels: 1 < 2 < 3 < 4 < 5 230s > ## If instead we generate the formula in the Global environment where 230s > ## the variables are not found, we cannot evaluate the model: 230s > f2 <- as.formula(rating ~ temp + contact + (1|judge)) 230s > (try(fm2 <- clmm(f2), silent=TRUE)) 230s [1] "Error in eval(predvars, data, env) : object 'rating' not found\n" 230s attr(,"class") 230s [1] "try-error" 230s attr(,"condition") 230s 230s > environment(f2) <- environment(f1) 230s > fm2 <- clmm(f2) 230s > 230s > ################################# 230s > ## Use of formula-objects 230s > f <- formula(rating ~ temp + contact + (1|judge)) 230s > m2 <- clmm(f, data = wine) 230s > summary(m2) 230s Cumulative Link Mixed Model fitted with the Laplace approximation 230s 230s formula: rating ~ temp + contact + (1 | judge) 230s data: wine 230s 230s link threshold nobs logLik AIC niter max.grad cond.H 230s logit flexible 72 -81.57 177.13 332(999) 1.03e-05 2.8e+01 230s 230s Random effects: 230s Groups Name Variance Std.Dev. 230s judge (Intercept) 1.279 1.131 230s Number of groups: judge 9 230s 230s Coefficients: 230s Estimate Std. Error z value Pr(>|z|) 230s tempwarm 3.0630 0.5954 5.145 2.68e-07 *** 230s contactyes 1.8349 0.5125 3.580 0.000344 *** 230s --- 230s Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1 230s 230s Threshold coefficients: 230s Estimate Std. Error z value 230s 1|2 -1.6237 0.6824 -2.379 230s 2|3 1.5134 0.6038 2.507 230s 3|4 4.2285 0.8090 5.227 230s 4|5 6.0888 0.9725 6.261 230s > 230s > ################################# 230s > ## Other ways to construct formulas: 230s > set.seed(12345) 230s > y <- factor(sample(1:4,20,replace=TRUE)) 230s > x <- rnorm(20) 230s > b <- gl(5, 4, labels=letters[1:5]) 230s > data <- data.frame(y=y, x=x, b=b) 230s > rm(x, y, b) 230s > clmm(y ~ x + (1|b), data=data) 230s Cumulative Link Mixed Model fitted with the Laplace approximation 230s 230s formula: y ~ x + (1 | b) 230s data: data 230s 230s link threshold nobs logLik AIC niter max.grad 230s logit flexible 20 -25.37 60.74 338(288) 7.12e-08 230s 230s Random effects: 230s Groups Name Variance Std.Dev. 230s b (Intercept) 9.736e-09 9.867e-05 230s Number of groups: b 5 230s 230s Coefficients: 230s x 230s 0.2527 230s 230s Thresholds: 230s 1|2 2|3 3|4 230s -2.18234 0.06059 0.92746 230s > fit <- clmm(data$y ~ data$x + (1|data$b)) 230s > fit 230s Cumulative Link Mixed Model fitted with the Laplace approximation 230s 230s formula: data$y ~ data$x + (1 | data$b) 230s 230s link threshold nobs logLik AIC niter max.grad 230s logit flexible 20 -25.37 60.74 338(288) 7.12e-08 230s 230s Random effects: 230s Groups Name Variance Std.Dev. 230s data$b (Intercept) 9.736e-09 9.867e-05 230s Number of groups: data$b 5 230s 230s Coefficients: 230s data$x 230s 0.2527 230s 230s Thresholds: 230s 1|2 2|3 3|4 230s -2.18234 0.06059 0.92746 230s > fit <- clmm(data[, 1] ~ data[, 2] + (1|data[, 3])) 230s > fit 230s Cumulative Link Mixed Model fitted with the Laplace approximation 230s 230s formula: data[, 1] ~ data[, 2] + (1 | data[, 3]) 230s 230s link threshold nobs logLik AIC niter max.grad 230s logit flexible 20 -25.37 60.74 338(288) 7.12e-08 230s 230s Random effects: 230s Groups Name Variance Std.Dev. 230s data[, 3] (Intercept) 9.736e-09 9.867e-05 230s Number of groups: data[, 3] 5 230s 230s Coefficients: 230s data[, 2] 230s 0.2527 230s 230s Thresholds: 230s 1|2 2|3 3|4 230s -2.18234 0.06059 0.92746 230s > 230s > ################################# 230s > ## Evaluation within other functions: 230s > ## date: January 18th 2012. 230s > ## 230s > ## The problem was raised by Stefan Herzog (stefan.herzog@unibas.ch) 230s > ## January 12th 2012 in trying to make clmm work with glmulti. 230s > 230s > fun.clmm <- function(formula, data) 230s + ### This only works because clmm via eclmm.model.frame is careful to 230s + ### evaluate the 'formula' in the parent environment such it is not the 230s + ### character "formula" that is attempted evaluated. 230s + clmm(formula, data = data) 230s > 230s > fun2.clmm <- function(formula, data, weights, subset) { 230s + ### This should be the safe way to ensure evaluation of clmm in the 230s + ### right environment. 230s + mc <- match.call() 230s + mc[[1]] <- as.name("clmm") 230s + eval.parent(mc) 230s + } 230s > 230s > fun.clmm(rating ~ temp + contact + (1|judge), data=wine) ## works 230s Cumulative Link Mixed Model fitted with the Laplace approximation 230s 230s formula: rating ~ temp + contact + (1 | judge) 230s data: data 230s 230s link threshold nobs logLik AIC niter max.grad 230s logit flexible 72 -81.57 177.13 332(999) 1.03e-05 230s 230s Random effects: 230s Groups Name Variance Std.Dev. 230s judge (Intercept) 1.279 1.131 230s Number of groups: judge 9 230s 230s Coefficients: 230s tempwarm contactyes 230s 3.063 1.835 230s 230s Thresholds: 230s 1|2 2|3 3|4 4|5 230s -1.624 1.513 4.229 6.089 230s > fun2.clmm(rating ~ temp + contact + (1|judge), data=wine) ## works 230s Cumulative Link Mixed Model fitted with the Laplace approximation 230s 230s formula: rating ~ temp + contact + (1 | judge) 230s data: wine 230s 230s link threshold nobs logLik AIC niter max.grad 230s logit flexible 72 -81.57 177.13 332(999) 1.03e-05 230s 230s Random effects: 230s Groups Name Variance Std.Dev. 230s judge (Intercept) 1.279 1.131 230s Number of groups: judge 9 230s 230s Coefficients: 230s tempwarm contactyes 230s 3.063 1.835 230s 230s Thresholds: 230s 1|2 2|3 3|4 4|5 230s -1.624 1.513 4.229 6.089 230s > 230s > form1 <- "rating ~ temp + contact + (1|judge)" 230s > fun.clmm(form1, data=wine) ## works 230s Cumulative Link Mixed Model fitted with the Laplace approximation 230s 230s formula: rating ~ temp + contact + (1 | judge) 230s data: data 230s 230s link threshold nobs logLik AIC niter max.grad 230s logit flexible 72 -81.57 177.13 332(999) 1.03e-05 230s 230s Random effects: 230s Groups Name Variance Std.Dev. 230s judge (Intercept) 1.279 1.131 230s Number of groups: judge 9 230s 230s Coefficients: 230s tempwarm contactyes 230s 3.063 1.835 230s 230s Thresholds: 230s 1|2 2|3 3|4 4|5 230s -1.624 1.513 4.229 6.089 230s > fun2.clmm(form1, data=wine) ## works 230s Cumulative Link Mixed Model fitted with the Laplace approximation 230s 230s formula: rating ~ temp + contact + (1 | judge) 230s data: wine 230s 230s link threshold nobs logLik AIC niter max.grad 230s logit flexible 72 -81.57 177.13 332(999) 1.03e-05 230s 230s Random effects: 230s Groups Name Variance Std.Dev. 230s judge (Intercept) 1.279 1.131 230s Number of groups: judge 9 230s 230s Coefficients: 230s tempwarm contactyes 230s 3.063 1.835 230s 230s Thresholds: 230s 1|2 2|3 3|4 4|5 230s -1.624 1.513 4.229 6.089 230s > 230s > form2 <- formula(rating ~ temp + contact + (1|judge)) 230s > fun.clmm(form2, data=wine) ## works 230s Cumulative Link Mixed Model fitted with the Laplace approximation 230s 230s formula: rating ~ temp + contact + (1 | judge) 230s data: data 230s 230s link threshold nobs logLik AIC niter max.grad 230s logit flexible 72 -81.57 177.13 332(999) 1.03e-05 230s 230s Random effects: 230s Groups Name Variance Std.Dev. 230s judge (Intercept) 1.279 1.131 230s Number of groups: judge 9 230s 230s Coefficients: 230s tempwarm contactyes 230s 3.063 1.835 230s 230s Thresholds: 230s 1|2 2|3 3|4 4|5 230s -1.624 1.513 4.229 6.089 230s > fun2.clmm(form2, data=wine) ## works 230s Cumulative Link Mixed Model fitted with the Laplace approximation 230s 230s formula: rating ~ temp + contact + (1 | judge) 230s data: wine 230s 230s link threshold nobs logLik AIC niter max.grad 230s logit flexible 72 -81.57 177.13 332(999) 1.03e-05 230s 230s Random effects: 230s Groups Name Variance Std.Dev. 230s judge (Intercept) 1.279 1.131 230s Number of groups: judge 9 230s 230s Coefficients: 230s tempwarm contactyes 230s 3.063 1.835 230s 230s Thresholds: 230s 1|2 2|3 3|4 4|5 230s -1.624 1.513 4.229 6.089 230s > ## Notice that clmm is not able to get the name of the data (wine) 230s > ## correct when using fun.clmm. 230s > 230s > ################################# 230s > 230s > ## ## Example 2: using clmm function 230s > ## # 230s > ## ## Now I want to consider judge as a random effect to account for 230s > ## ## grouping structure of data 230s > ## mod2 <- clmm(rating ~ temp + contact + (1|judge), data=wine) 230s > ## 230s > ## ##Again, I started by using my own code to run all potential models: 230s > ## ## put names of all your variables in this vector: 230s > ## vl2 <- c("temp", "contact") 230s > ## ## generate list of possible combinations of variables: 230s > ## combos2 <- NULL 230s > ## for(i in 1:length(vl2)) { 230s > ## combos2 <- c(combos2, combn(vl2, i, simplify = F)) 230s > ## } 230s > ## ## create formulae and run models one by one, saving them as model1, 230s > ## ## model2 etc... 230s > ## for (i in 1:length(combos2)) { 230s > ## vs2 <- paste(combos2[[i]], collapse=" + ") 230s > ## f2 <- formula(paste("rating ~ ", vs2, "+(1|judge)", sep="")) 230s > ## print(f2) 230s > ## assign(paste("model", i, sep=""), clmm(f2, data=wine)) 230s > ## } 230s > ## summary(model1) # etc 230s > ## summary(model2) # etc 230s > ## summary(model3) # etc 230s > ## 230s > ## models <- vector("list", length(combos2)) 230s > ## for(i in 1:length(combos2)) { 230s > ## vs2 <- paste(combos2[[i]], collapse=" + ") 230s > ## f2 <- formula(paste("rating ~ ", vs2, "+(1|judge)", sep="")) 230s > ## print(f2) 230s > ## models[[i]] <- clmm(f2, data=wine) 230s > ## ## assign(paste("model", i, sep=""), clmm(f2, data=wine)) 230s > ## } 230s > ## 230s > ## ## Coefficients, AIC and BIC: 230s > ## lapply(models, function(m) coef(summary(m))) 230s > ## lapply(models, AIC) 230s > ## lapply(models, BIC) 230s > ## 230s > ## ## library(MuMIn) 230s > ## ## dd2 <- dredge(mod2) ## does not work 230s > ## ## ?dredge 230s > ## ## traceback() 230s > ## ## mod2$formula 230s > ## ## terms(as.formula(formula(mod2))) 230s > ## ## 230s > ## ## library(lme4) 230s > ## ## fmm1 <- lmer(response ~ temp + contact + (1|judge), data=wine) 230s > ## ## fmm1 230s > ## ## terms(as.formula(lme4:::formula(fmm1))) 230s > ## ## terms(as.formula(formula(fmm1))) 230s > 230s BEGIN TEST clmm.methods.R 230s 230s R version 4.4.3 (2025-02-28) -- "Trophy Case" 230s Copyright (C) 2025 The R Foundation for Statistical Computing 230s Platform: arm-unknown-linux-gnueabihf (32-bit) 230s 230s R is free software and comes with ABSOLUTELY NO WARRANTY. 230s You are welcome to redistribute it under certain conditions. 230s Type 'license()' or 'licence()' for distribution details. 230s 230s R is a collaborative project with many contributors. 230s Type 'contributors()' for more information and 230s 'citation()' on how to cite R or R packages in publications. 230s 230s Type 'demo()' for some demos, 'help()' for on-line help, or 230s 'help.start()' for an HTML browser interface to help. 230s Type 'q()' to quit R. 230s 230s > library(ordinal) 231s > data(wine) 231s > 231s > ################################# 231s > ## model.matrix method for clmm-objects: 231s > fmm1 <- clmm(rating ~ contact + temp + (1|judge), data=wine) 231s > mm <- model.matrix(fmm1) 231s > stopifnot(inherits(mm, "matrix"), 231s + dim(mm) == c(72, 3)) 231s > 231s > ################################# 231s > ## anova.clmm works even if formula does not have an environment: 231s > fmm1 <- clmm(rating ~ temp * contact + (1|judge), data = wine) 231s > fmm2 <- clmm(rating ~ temp + contact + (1|judge), data = wine) 232s > environment(fmm1$formula) <- NULL 232s > environment(fmm2$formula) <- NULL 232s > anova(fmm1, fmm2) 232s Likelihood ratio tests of cumulative link models: 232s 232s formula: link: threshold: 232s fmm2 rating ~ temp + contact + (1 | judge) logit flexible 232s fmm1 rating ~ temp * contact + (1 | judge) logit flexible 232s 232s no.par AIC logLik LR.stat df Pr(>Chisq) 232s fmm2 7 177.13 -81.565 232s fmm1 8 179.07 -81.536 0.0589 1 0.8082 232s > 232s > 232s > ################################# 232s > ## Test that ranef, condVar and VarCorr work as they are supposed to whether or 232s > ## not nlme and lme4 are loaded: 232s > 232s > fm <- clmm(rating ~ temp + contact + (1|judge), data = wine) 232s > fm 232s Cumulative Link Mixed Model fitted with the Laplace approximation 232s 232s formula: rating ~ temp + contact + (1 | judge) 232s data: wine 232s 232s link threshold nobs logLik AIC niter max.grad 232s logit flexible 72 -81.57 177.13 332(999) 1.03e-05 232s 232s Random effects: 232s Groups Name Variance Std.Dev. 232s judge (Intercept) 1.279 1.131 232s Number of groups: judge 9 232s 232s Coefficients: 232s tempwarm contactyes 232s 3.063 1.835 232s 232s Thresholds: 232s 1|2 2|3 3|4 4|5 232s -1.624 1.513 4.229 6.089 232s > ranef(fm) 232s $judge 232s (Intercept) 232s 1 1.69617816 232s 2 -0.56578306 232s 3 0.96880827 232s 4 -0.05954988 232s 5 0.23051011 232s 6 0.47703863 232s 7 -1.91097336 232s 8 -0.27294384 232s 9 -0.55467574 232s 232s > VarCorr(fm) 232s $judge 232s (Intercept) 232s (Intercept) 1.279461 232s attr(,"stddev") 232s (Intercept) 232s 1.131133 232s 232s > condVar(fm) 232s $judge 232s (Intercept) 232s 1 0.3067453 232s 2 0.3779358 232s 3 0.3545528 232s 4 0.3651870 232s 5 0.3566066 232s 6 0.3485475 232s 7 0.3435693 232s 8 0.3050453 232s 9 0.3183194 232s 232s > summary(fm) 232s Loading required package: Matrix 232s Cumulative Link Mixed Model fitted with the Laplace approximation 232s 232s formula: rating ~ temp + contact + (1 | judge) 232s data: wine 232s 232s link threshold nobs logLik AIC niter max.grad cond.H 232s logit flexible 72 -81.57 177.13 332(999) 1.03e-05 2.8e+01 232s 232s Random effects: 232s Groups Name Variance Std.Dev. 232s judge (Intercept) 1.279 1.131 232s Number of groups: judge 9 232s 232s Coefficients: 232s Estimate Std. Error z value Pr(>|z|) 232s tempwarm 3.0630 0.5954 5.145 2.68e-07 *** 232s contactyes 1.8349 0.5125 3.580 0.000344 *** 232s --- 232s Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1 232s 232s Threshold coefficients: 232s Estimate Std. Error z value 232s 1|2 -1.6237 0.6824 -2.379 232s 2|3 1.5134 0.6038 2.507 232s 3|4 4.2285 0.8090 5.227 232s 4|5 6.0888 0.9725 6.261 232s > 232s > library(nlme) 232s > ranef(fm) 232s $judge 232s (Intercept) 232s 1 1.69617816 232s 2 -0.56578306 232s 3 0.96880827 232s 4 -0.05954988 232s 5 0.23051011 232s 6 0.47703863 232s 7 -1.91097336 232s 8 -0.27294384 232s 9 -0.55467574 232s 232s > VarCorr(fm) 232s $judge 232s (Intercept) 232s (Intercept) 1.279461 232s attr(,"stddev") 232s (Intercept) 232s 1.131133 232s 232s > condVar(fm) 232s $judge 232s (Intercept) 232s 1 0.3067453 232s 2 0.3779358 232s 3 0.3545528 232s 4 0.3651870 232s 5 0.3566066 232s 6 0.3485475 232s 7 0.3435693 232s 8 0.3050453 232s 9 0.3183194 232s 232s > library(lme4) 232s 232s Attaching package: ‘lme4’ 232s 232s > ranef(fm) 232s $judge 232s (Intercept) 232s 1 1.69617816 232s 2 -0.56578306 232s 3 0.96880827 232s 4 -0.05954988 232s 5 0.23051011 232s 6 0.47703863 232s 7 -1.91097336 232s 8 -0.27294384 232s 9 -0.55467574 232s 232s > VarCorr(fm) 232s The following object is masked from ‘package:nlme’: 232s 232s lmList 232s 232s $judge 232s (Intercept) 232s (Intercept) 1.279461 232s attr(,"stddev") 232s (Intercept) 232s 1.131133 232s 232s > condVar(fm) 232s $judge 232s (Intercept) 232s 1 0.3067453 232s 2 0.3779358 232s 3 0.3545528 232s 4 0.3651870 232s 5 0.3566066 232s 6 0.3485475 232s 7 0.3435693 232s 8 0.3050453 232s 9 0.3183194 232s 232s > fm1 <- lmer(Reaction ~ Days + (Days | Subject), data=sleepstudy) 232s > ranef(fm1) 232s $Subject 232s (Intercept) Days 232s 308 2.2585509 9.1989758 232s 309 -40.3987381 -8.6196806 232s 310 -38.9604090 -5.4488565 232s 330 23.6906196 -4.8143503 232s 331 22.2603126 -3.0699116 232s 332 9.0395679 -0.2721770 232s 333 16.8405086 -0.2236361 232s 334 -7.2326151 1.0745816 232s 335 -0.3336684 -10.7521652 232s 337 34.8904868 8.6282652 232s 349 -25.2102286 1.1734322 232s 350 -13.0700342 6.6142178 232s 351 4.5778642 -3.0152621 232s 352 20.8636782 3.5360011 232s 369 3.2754656 0.8722149 232s 370 -25.6129993 4.8224850 232s 371 0.8070461 -0.9881562 232s 372 12.3145921 1.2840221 232s 232s with conditional variances for “Subject” 232s > VarCorr(fm1) 232s Groups Name Std.Dev. Corr 232s Subject (Intercept) 24.7407 232s Days 5.9221 0.066 232s Residual 25.5918 232s > 232s > ranef(fm) 232s $judge 232s (Intercept) 232s 1 1.69617816 232s 2 -0.56578306 232s 3 0.96880827 232s 4 -0.05954988 232s 5 0.23051011 232s 6 0.47703863 232s 7 -1.91097336 232s 8 -0.27294384 232s 9 -0.55467574 232s 232s > VarCorr(fm) 232s $judge 232s (Intercept) 232s (Intercept) 1.279461 232s attr(,"stddev") 232s (Intercept) 232s 1.131133 232s 232s > condVar(fm) 232s $judge 232s (Intercept) 232s 1 0.3067453 232s 2 0.3779358 232s 3 0.3545528 232s 4 0.3651870 232s 5 0.3566066 232s 6 0.3485475 232s 7 0.3435693 232s 8 0.3050453 232s 9 0.3183194 232s 232s > summary(fm) 232s Cumulative Link Mixed Model fitted with the Laplace approximation 232s 232s formula: rating ~ temp + contact + (1 | judge) 232s data: wine 232s 232s link threshold nobs logLik AIC niter max.grad cond.H 232s logit flexible 72 -81.57 177.13 332(999) 1.03e-05 2.8e+01 232s 232s Random effects: 232s Groups Name Variance Std.Dev. 232s judge (Intercept) 1.279 1.131 232s Number of groups: judge 9 232s 232s Coefficients: 232s Estimate Std. Error z value Pr(>|z|) 232s tempwarm 3.0630 0.5954 5.145 2.68e-07 *** 232s contactyes 1.8349 0.5125 3.580 0.000344 *** 232s --- 232s Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1 232s 232s Threshold coefficients: 232s Estimate Std. Error z value 232s 1|2 -1.6237 0.6824 -2.379 232s 2|3 1.5134 0.6038 2.507 232s 3|4 4.2285 0.8090 5.227 232s 4|5 6.0888 0.9725 6.261 232s > 232s BEGIN TEST confint.R 232s 232s R version 4.4.3 (2025-02-28) -- "Trophy Case" 232s Copyright (C) 2025 The R Foundation for Statistical Computing 232s Platform: arm-unknown-linux-gnueabihf (32-bit) 232s 232s R is free software and comes with ABSOLUTELY NO WARRANTY. 232s You are welcome to redistribute it under certain conditions. 232s Type 'license()' or 'licence()' for distribution details. 232s 232s R is a collaborative project with many contributors. 232s Type 'contributors()' for more information and 232s 'citation()' on how to cite R or R packages in publications. 232s 232s Type 'demo()' for some demos, 'help()' for on-line help, or 232s 'help.start()' for an HTML browser interface to help. 232s Type 'q()' to quit R. 232s 232s > ################################# 232s > ## test profile and confint methods: 232s > library(ordinal) 234s > data(wine) 234s > fm1 <- clm(rating ~ contact + temp, data = wine) 234s > summary(fm1) 234s formula: rating ~ contact + temp 234s data: wine 234s 234s link threshold nobs logLik AIC niter max.grad cond.H 234s logit flexible 72 -86.49 184.98 6(0) 4.01e-12 2.7e+01 234s 234s Coefficients: 234s Estimate Std. Error z value Pr(>|z|) 234s contactyes 1.5278 0.4766 3.205 0.00135 ** 234s tempwarm 2.5031 0.5287 4.735 2.19e-06 *** 234s --- 234s Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1 234s 234s Threshold coefficients: 234s Estimate Std. Error z value 234s 1|2 -1.3444 0.5171 -2.600 234s 2|3 1.2508 0.4379 2.857 234s 3|4 3.4669 0.5978 5.800 234s 4|5 5.0064 0.7309 6.850 234s > 234s > ## profile.clm and confint.clm: 234s > pr1 <- profile(fm1) 234s > confint(pr1) 234s 2.5 % 97.5 % 234s contactyes 0.6158045 2.492424 234s tempwarm 1.5097839 3.595251 234s > pr1 <- profile(fm1, which.beta = 1:2) 234s > confint(pr1) 234s 2.5 % 97.5 % 234s contactyes 0.6158045 2.492424 234s tempwarm 1.5097839 3.595251 234s > pr1 <- profile(fm1, which.beta = 2:1) 234s > confint(pr1) 234s 2.5 % 97.5 % 234s tempwarm 1.5097839 3.595251 234s contactyes 0.6158045 2.492424 234s > pr1 <- profile(fm1, which.beta = 1) 234s > confint(pr1) 234s 2.5 % 97.5 % 234s contactyes 0.6158045 2.492424 234s > pr1 <- profile(fm1, which.beta = 2) 234s > confint(pr1) 234s 2.5 % 97.5 % 234s tempwarm 1.509784 3.595251 234s > pr1 <- try(profile(fm1, which.beta = 0), silent = TRUE) ## error 234s > pr1 <- try(profile(fm1, which.beta = "no.par"), silent = TRUE) ## error 234s > pr1 <- try(profile(fm1, which.beta = -1), silent = TRUE) ## error 234s > pr1 <- profile(fm1, which.beta = "tempwarm") 234s > confint(pr1) 234s 2.5 % 97.5 % 234s tempwarm 1.509784 3.595251 234s > pr1 <- profile(fm1, alpha = 0.1) 234s > confint(pr1) ## should give NA in this case? 234s 2.5 % 97.5 % 234s contactyes NA NA 234s tempwarm NA NA 234s > pr1 <- profile(fm1, max.steps = 9) 234s > pr1 <- profile(fm1, step.warn = 7) 234s > pr1 <- profile(fm1, nsteps = 6) 234s > pr1 <- profile(fm1, trace = 1) 234s 234s Parameter: contactyes down 234s 234s Parameter: contactyes up 234s 234s Parameter: tempwarm down 234s 234s Parameter: tempwarm up 234s > pr1 <- profile(fm1, control = list(gradTol = .1)) 234s > confint(pr1) ## not at all unreliable... 234s 2.5 % 97.5 % 234s contactyes 0.6158045 2.492424 234s tempwarm 1.5097839 3.595251 234s > 234s > ## single regression coef setting: 234s > fm2 <- clm(rating ~ contact, data = wine) 234s > summary(fm2) 234s formula: rating ~ contact 234s data: wine 234s 234s link threshold nobs logLik AIC niter max.grad cond.H 234s logit flexible 72 -99.96 209.91 5(0) 1.67e-07 1.7e+01 234s 234s Coefficients: 234s Estimate Std. Error z value Pr(>|z|) 234s contactyes 1.2070 0.4499 2.683 0.0073 ** 234s --- 234s Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1 234s 234s Threshold coefficients: 234s Estimate Std. Error z value 234s 1|2 -2.13933 0.48981 -4.368 234s 2|3 0.04257 0.32063 0.133 234s 3|4 1.71449 0.38637 4.437 234s 4|5 2.97875 0.50207 5.933 234s > pr2 <- profile(fm2) 234s > confint(pr2) 234s 2.5 % 97.5 % 234s contactyes 0.3403978 2.110952 234s > 234s > ## confint.clm: 234s > confint(fm1) 234s 2.5 % 97.5 % 234s contactyes 0.6157925 2.492404 234s tempwarm 1.5097627 3.595225 234s > confint(fm1, 2) 234s argument 'parm' ignored 234s 2.5 % 97.5 % 234s contactyes 0.6157925 2.492404 234s tempwarm 1.5097627 3.595225 234s > confint(fm1, 1) 234s argument 'parm' ignored 234s 2.5 % 97.5 % 234s contactyes 0.6157925 2.492404 234s tempwarm 1.5097627 3.595225 234s > confint(fm1, "tempwarm") 234s argument 'parm' ignored 234s 2.5 % 97.5 % 234s contactyes 0.6157925 2.492404 234s tempwarm 1.5097627 3.595225 234s > confint(fm1, type = "profile") 234s 2.5 % 97.5 % 234s contactyes 0.6157925 2.492404 234s tempwarm 1.5097627 3.595225 234s > confint(fm1, type = "Wald") 234s 2.5 % 97.5 % 234s 1|2 -2.3578848 -0.330882 234s 2|3 0.3925794 2.109038 234s 3|4 2.2952980 4.638476 234s 4|5 3.5738541 6.438954 234s contactyes 0.5936345 2.461961 234s tempwarm 1.4669081 3.539296 234s > confint(fm1, 2, type = "Wald") 234s 2.5 % 97.5 % 234s 1|2 -2.3578848 -0.330882 234s 2|3 0.3925794 2.109038 234s 3|4 2.2952980 4.638476 234s 4|5 3.5738541 6.438954 234s contactyes 0.5936345 2.461961 234s tempwarm 1.4669081 3.539296 234s > confint(fm1, level = 0.5) 234s argument 'parm' ignored 234s 25 % 75 % 234s contactyes 1.209254 1.852544 234s tempwarm 2.152051 2.865757 234s > confint(fm1, level = 1 - 1e-6) 234s 0 % 100 % 234s contactyes -0.7003630 4.091731 234s tempwarm 0.1351282 5.520007 234s > confint(fm1, level = 1 - 1e-10) ## extreme, but it works 234s 0 % 100 % 234s contactyes -1.4045009 5.059182 234s tempwarm -0.5753928 6.774556 234s > confint(fm1, trace = 1) 234s Wait for profiling to be done... 234s 234s Parameter: contactyes down 234s 234s Parameter: contactyes up 234s 234s Parameter: tempwarm down 234s 234s Parameter: tempwarm up 234s 2.5 % 97.5 % 234s contactyes 0.6157925 2.492404 234s tempwarm 1.5097627 3.595225 234s > 234s > ## plot.profile: 234s > pr1 <- profile(fm1, which.beta=1:2, alpha = 1e-3) 235s > par(mfrow = c(1,2)) 235s > plot(pr1) 235s > plot(pr1, 1) 235s > plot(pr1, "contactyes") 235s > plot(pr1, level = .97) 235s > plot(pr1, Log = TRUE) 235s > plot(pr1, relative = FALSE) 235s > plot(pr1, root = TRUE) 235s > plot(pr1, approx = TRUE) 235s > plot(pr1, n=10) 235s > plot(pr1, ylim = c(0,2)) 235s > plot(pr1, las = 1) 235s > plot(pr2) 235s > 235s > 235s BEGIN TEST nominal.test.R 235s 235s R version 4.4.3 (2025-02-28) -- "Trophy Case" 235s Copyright (C) 2025 The R Foundation for Statistical Computing 235s Platform: arm-unknown-linux-gnueabihf (32-bit) 235s 235s R is free software and comes with ABSOLUTELY NO WARRANTY. 235s You are welcome to redistribute it under certain conditions. 235s Type 'license()' or 'licence()' for distribution details. 235s 235s R is a collaborative project with many contributors. 235s Type 'contributors()' for more information and 235s 'citation()' on how to cite R or R packages in publications. 235s 235s Type 'demo()' for some demos, 'help()' for on-line help, or 235s 'help.start()' for an HTML browser interface to help. 235s Type 'q()' to quit R. 235s 235s > library(ordinal) 236s Loading required package: MASS 236s > 236s > if(require(MASS)) { 236s + fm1 <- clm(Sat ~ Infl + Type + Cont, data=housing, weights=Freq) 236s + scale_test(fm1) 236s + nominal_test(fm1) 236s + 236s + fm2 <- update(fm1, scale=~Cont) 236s + scale_test(fm2) 236s + nominal_test(fm2) 236s + fm3 <- update(fm1, nominal=~ Cont) 236s + fm3$Theta 236s + anova(fm2, fm3) 236s + fm3$alpha.mat 236s + summary(fm3) 236s + } 236s formula: Sat ~ Infl + Type + Cont 236s nominal: ~Cont 236s data: housing 236s 236s link threshold nobs logLik AIC niter max.grad cond.H 236s logit flexible 1681 -1738.35 3494.70 4(0) 1.31e-07 6.3e+01 236s 236s Coefficients: (1 not defined because of singularities) 236s Estimate Std. Error z value Pr(>|z|) 236s InflMedium 0.5695 0.1048 5.436 5.45e-08 *** 236s InflHigh 1.2884 0.1271 10.137 < 2e-16 *** 236s TypeApartment -0.5706 0.1192 -4.788 1.68e-06 *** 236s TypeAtrium -0.3643 0.1552 -2.348 0.0189 * 236s TypeTerrace -1.0980 0.1516 -7.242 4.43e-13 *** 236s ContHigh NA NA NA NA 236s --- 236s Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1 236s 236s Threshold coefficients: 236s Estimate Std. Error z value 236s Low|Medium.(Intercept) -0.4494 0.1279 -3.515 236s Medium|High.(Intercept) 0.6480 0.1279 5.066 236s Low|Medium.ContHigh -0.4440 0.1095 -4.056 236s Medium|High.ContHigh -0.2861 0.1063 -2.691 236s > 236s > ################################# 236s > ### Testing nominal_test and scale_test: 236s > fm1 <- clm(rating ~ temp * contact, data=wine) 236s > ## names(fm1) 236s > fm2 <- clm(rating ~ temp * contact, data=wine, nominal=~contact) 236s > (an <- anova(fm1, fm2)) 236s Likelihood ratio tests of cumulative link models: 236s 236s formula: nominal: link: threshold: 236s fm1 rating ~ temp * contact ~1 logit flexible 236s fm2 rating ~ temp * contact ~contact logit flexible 236s 236s no.par AIC logLik LR.stat df Pr(>Chisq) 236s fm1 7 186.83 -86.416 236s fm2 10 192.17 -86.083 0.6669 3 0.881 236s > (nm <- nominal_test(fm1)) 236s Tests of nominal effects 236s 236s formula: rating ~ temp * contact 236s Df logLik AIC LRT Pr(>Chi) 236s -86.416 186.83 236s temp 3 -84.874 189.75 3.08352 0.3789 236s contact 3 -86.083 192.16 0.66691 0.8810 236s temp:contact 236s > stopifnot(isTRUE(all.equal(an[2, 6], nm["contact", 5]))) 236s > 236s > fm2 <- clm(rating ~ temp * contact, data=wine, scale=~contact) 236s > (an <- anova(fm1, fm2)) 236s Likelihood ratio tests of cumulative link models: 236s 236s formula: scale: link: threshold: 236s fm1 rating ~ temp * contact ~1 logit flexible 236s fm2 rating ~ temp * contact ~contact logit flexible 236s 236s no.par AIC logLik LR.stat df Pr(>Chisq) 236s fm1 7 186.83 -86.416 236s fm2 8 188.60 -86.300 0.2325 1 0.6297 236s > (sc <- scale_test(fm1)) 236s Tests of scale effects 236s 236s formula: rating ~ temp * contact 236s Df logLik AIC LRT Pr(>Chi) 236s -86.416 186.83 236s temp 1 -86.326 188.65 0.18061 0.6709 236s contact 1 -86.300 188.60 0.23252 0.6297 236s temp:contact 3 -86.259 192.52 0.31391 0.9574 236s > stopifnot(isTRUE(all.equal(an[2, 6], sc["contact", "Pr(>Chi)"]))) 236s > 236s > fm1 <- clm(rating ~ temp + contact, 236s + nominal=~temp + contact, data=wine) 236s Warning message: 236s (1) Hessian is numerically singular: parameters are not uniquely determined 236s In addition: Absolute convergence criterion was met, but relative criterion was not met 236s > fm1 236s formula: rating ~ temp + contact 236s nominal: ~temp + contact 236s data: wine 236s 236s 236s no additional terms to add to nominal 236s 236s link threshold nobs logLik AIC niter max.grad cond.H 236s logit flexible 72 -84.61 193.22 20(0) 4.36e-09 5.0e+10 236s 236s Coefficients: (2 not defined because of singularities) 236s tempwarm contactyes 236s NA NA 236s 236s Threshold coefficients: 236s 1|2 2|3 3|4 4|5 236s (Intercept) -1.226 1.033 3.946 24.553 236s tempwarm -21.118 -2.111 -2.940 -22.432 236s contactyes -1.659 -1.343 -1.693 -1.162 236s > try(nominal_test(fm1), silent=TRUE)[1] ## gives error OK 236s Df 236s 236s > scale_test(fm1) 236s Warning messages: 236s 1: (1) Hessian is numerically singular: parameters are not uniquely determined 236s In addition: Absolute convergence criterion was met, but relative criterion was not met 236s 2: (1) Hessian is numerically singular: parameters are not uniquely determined 236s In addition: Absolute convergence criterion was met, but relative criterion was not met 236s Tests of scale effects 236s 236s formula: rating ~ temp + contact 236s nominal: ~temp + contact 236s Df logLik AIC LRT Pr(>Chi) 236s -84.611 193.22 236s temp 1 -84.604 195.21 0.0129568 0.9094 236s contact 1 -84.610 195.22 0.0012219 0.9721 236s > fm1 <- clm(rating ~ temp + contact, 236s + scale=~temp + contact, data=wine) 236s > fm1 236s formula: rating ~ temp + contact 236s scale: ~temp + contact 236s data: wine 236s 236s 236s no relevant terms to add to scale 236s 236s link threshold nobs logLik AIC niter max.grad cond.H 236s logit flexible 72 -86.34 188.68 8(0) 7.40e-09 2.0e+02 236s 236s Coefficients: 236s tempwarm contactyes 236s 2.446 1.482 236s 236s log-scale coefficients: 236s tempwarm contactyes 236s 0.05008 -0.11418 236s 236s Threshold coefficients: 236s 1|2 2|3 3|4 4|5 236s -1.303 1.219 3.377 4.872 236s > try(scale_test(fm1), silent=TRUE)[1] ## gives error OK 236s Df 236s 236s > nominal_test(fm1) 236s Tests of nominal effects 236s 236s formula: rating ~ temp + contact 236s scale: ~temp + contact 236s Df logLik AIC LRT Pr(>Chi) 236s -86.342 188.69 236s temp 3 -84.851 191.70 2.98202 0.3944 236s contact 3 -86.008 194.02 0.66808 0.8807 236s > 236s > 236s > ## Using weights: 236s > set.seed(123454321) 236s > wt <- runif(nrow(wine)) 236s > fm1 <- clm(rating ~ temp * contact, data=wine, weigths=wt) 236s > nominal_test(fm1) 236s Tests of nominal effects 236s 236s formula: rating ~ temp * contact 236s Df logLik AIC LRT Pr(>Chi) 236s -86.416 186.83 236s temp 3 -84.874 189.75 3.08352 0.3789 236s contact 3 -86.083 192.16 0.66691 0.8810 236s temp:contact 236s > scale_test(fm1) 236s Tests of scale effects 236s 236s formula: rating ~ temp * contact 236s Df logLik AIC LRT Pr(>Chi) 236s -86.416 186.83 236s temp 1 -86.326 188.65 0.18061 0.6709 236s contact 1 -86.300 188.60 0.23252 0.6297 236s temp:contact 3 -86.259 192.52 0.31391 0.9574 236s > 236s > ## No nominal test for judge since that model is not identifiable: 236s > fm1 <- clm(rating ~ judge + temp + contact, data=wine) 236s > nominal_test(fm1) 236s Tests of nominal effects 236s 236s formula: rating ~ judge + temp + contact 236s Df logLik AIC LRT Pr(>Chi) 236s -70.921 169.84 236s judge 236s temp 3 -69.900 173.80 2.04253 0.5636 236s contact 3 -70.708 175.42 0.42612 0.9348 236s > scale_test(fm1) 237s Tests of scale effects 237s 237s formula: rating ~ judge + temp + contact 237s Df logLik AIC LRT Pr(>Chi) 237s -70.921 169.84 237s judge 8 -64.731 173.46 12.3790 0.1351 237s temp 1 -70.897 171.79 0.0474 0.8276 237s contact 1 -70.870 171.74 0.1018 0.7497 237s > fm1 <- clm(rating ~ judge + temp, nominal=~contact, data=wine) 237s > nominal_test(fm1) 237s Tests of nominal effects 237s 237s formula: rating ~ judge + temp 237s nominal: ~contact 237s Df logLik AIC LRT Pr(>Chi) 237s -70.708 175.42 237s judge 237s temp 3 -69.707 179.41 2.0015 0.5721 237s > summary(fm1) 237s formula: rating ~ judge + temp 237s nominal: ~contact 237s data: wine 237s 237s link threshold nobs logLik AIC niter max.grad cond.H 237s logit flexible 72 -70.71 175.42 6(0) 8.07e-08 9.9e+01 237s 237s Coefficients: 237s Estimate Std. Error z value Pr(>|z|) 237s judge2 -3.2395 1.0683 -3.032 0.00243 ** 237s judge3 -0.9556 0.9699 -0.985 0.32452 237s judge4 -2.4613 1.0321 -2.385 0.01709 * 237s judge5 -2.0248 1.0093 -2.006 0.04484 * 237s judge6 -1.6379 0.9770 -1.677 0.09364 . 237s judge7 -5.2222 1.1381 -4.589 4.46e-06 *** 237s judge8 -2.7648 0.9776 -2.828 0.00468 ** 237s judge9 -3.1751 1.0028 -3.166 0.00154 ** 237s tempwarm 3.3309 0.6174 5.395 6.87e-08 *** 237s --- 237s Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1 237s 237s Threshold coefficients: 237s Estimate Std. Error z value 237s 1|2.(Intercept) -4.1549 0.9897 -4.198 237s 2|3.(Intercept) -0.7354 0.7920 -0.928 237s 3|4.(Intercept) 2.3388 0.8909 2.625 237s 4|5.(Intercept) 3.8873 1.0352 3.755 237s 1|2.contactyes -2.0216 1.3072 -1.547 237s 2|3.contactyes -1.9865 0.6904 -2.877 237s 3|4.contactyes -2.1825 0.7774 -2.807 237s 4|5.contactyes -1.5077 1.0044 -1.501 237s > 237s > ## A continuous variable: 237s > set.seed(123454321) 237s > x <- rnorm(nrow(wine), sd=1) 237s > fm <- clm(rating ~ temp, nominal=~contact * x, data=wine) 237s Warning message: 237s (1) Hessian is numerically singular: parameters are not uniquely determined 237s In addition: Absolute convergence criterion was met, but relative criterion was not met 237s > nominal_test(fm) 237s Tests of nominal effects 237s 237s formula: rating ~ temp 237s nominal: ~contact * x 237s Df logLik AIC LRT Pr(>Chi) 237s -77.858 189.72 237s temp 3 -76.738 193.48 2.24 0.5241 237s > scale_test(fm) 237s Warning message: 237s (1) Hessian is numerically singular: parameters are not uniquely determined 237s In addition: Absolute convergence criterion was met, but relative criterion was not met 237s Tests of scale effects 237s 237s formula: rating ~ temp 237s nominal: ~contact * x 237s Df logLik AIC LRT Pr(>Chi) 237s -77.858 189.72 237s temp 1 -77.684 191.37 0.34804 0.5552 237s > fm <- clm(rating ~ temp + x, nominal=~contact, data=wine) 237s > nominal_test(fm) 237s Tests of nominal effects 237s 237s formula: rating ~ temp + x 237s nominal: ~contact 237s Df logLik AIC LRT Pr(>Chi) 237s -84.949 189.90 237s temp 3 -83.421 192.84 3.0560 0.3831 237s x 3 -84.333 194.67 1.2322 0.7453 237s > scale_test(fm) 237s Tests of scale effects 237s 237s formula: rating ~ temp + x 237s nominal: ~contact 237s Df logLik AIC LRT Pr(>Chi) 237s -84.949 189.90 237s temp 1 -84.737 191.47 0.42504 0.5144 237s x 1 -84.896 191.79 0.10781 0.7426 237s > ## poly: 237s > fm <- clm(rating ~ temp + poly(x, 2), nominal=~contact, data=wine) 237s > nominal_test(fm) 237s Tests of nominal effects 237s 237s formula: rating ~ temp + poly(x, 2) 237s nominal: ~contact 237s Df logLik AIC LRT Pr(>Chi) 237s -84.079 190.16 237s temp 3 -82.694 193.39 2.7693 0.4286 237s poly(x, 2) 6 -80.941 195.88 6.2762 0.3930 237s > scale_test(fm) 237s Tests of scale effects 237s 237s formula: rating ~ temp + poly(x, 2) 237s nominal: ~contact 237s Df logLik AIC LRT Pr(>Chi) 237s -84.079 190.16 237s temp 1 -84.020 192.04 0.11784 0.7314 237s poly(x, 2) 2 -83.314 192.63 1.53017 0.4653 237s > ## another combination: 237s > fm1 <- clm(SURENESS ~ PRODID + DAY + SOUPTYPE + SOUPFREQ, 237s + scale=~PROD, 237s + nominal=~ DAY*GENDER, data=soup) 237s > fm1 237s formula: SURENESS ~ PRODID + DAY + SOUPTYPE + SOUPFREQ 237s scale: ~PROD 237s nominal: ~DAY * GENDER 237s data: soup 237s 237s link threshold nobs logLik AIC niter max.grad cond.H 237s logit flexible 1847 -2657.84 5375.68 8(2) 3.50e-07 4.0e+03 237s 237s Coefficients: (1 not defined because of singularities) 237s PRODID2 PRODID3 PRODID4 PRODID5 237s 1.0780 1.5090 0.9482 1.4910 237s PRODID6 DAY2 SOUPTYPECanned SOUPTYPEDry-mix 237s 1.8174 NA -0.2337 0.1832 237s SOUPFREQ1-4/month SOUPFREQ<1/month 237s -0.0954 -0.1137 237s 237s log-scale coefficients: 237s PRODTest 237s 0.1427 237s 237s Threshold coefficients: 237s 1|2 2|3 3|4 4|5 5|6 237s (Intercept) -1.65979 -0.75912 -0.36903 0.02374 0.66929 237s DAY2 -0.22291 0.13711 0.16406 0.10279 0.23721 237s GENDERFemale 0.06531 0.06089 -0.01938 -0.13670 -0.01594 237s DAY2:GENDERFemale 0.36194 0.25429 0.25482 0.23375 0.05243 237s > nominal_test(fm1) 238s Tests of nominal effects 238s 238s formula: SURENESS ~ PRODID + DAY + SOUPTYPE + SOUPFREQ 238s scale: ~PROD 238s nominal: ~DAY * GENDER 238s Df logLik AIC LRT Pr(>Chi) 238s -2657.8 5375.7 238s PRODID 20 -2644.7 5389.4 26.2387 0.1580707 238s SOUPTYPE 8 -2654.0 5384.1 7.5969 0.4738067 238s SOUPFREQ 8 -2644.6 5365.1 26.5587 0.0008423 *** 238s PROD 4 -2654.7 5377.5 6.2011 0.1846258 238s --- 238s Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1 238s > scale_test(fm1) 238s Tests of scale effects 238s 238s formula: SURENESS ~ PRODID + DAY + SOUPTYPE + SOUPFREQ 238s scale: ~PROD 238s nominal: ~DAY * GENDER 238s Df logLik AIC LRT Pr(>Chi) 238s -2657.8 5375.7 238s PRODID 4 -2657.3 5382.5 1.1526 0.885842 238s DAY 1 -2655.9 5373.8 3.8544 0.049616 * 238s SOUPTYPE 2 -2657.6 5379.1 0.5416 0.762771 238s SOUPFREQ 2 -2652.7 5369.3 10.3447 0.005671 ** 238s --- 238s Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1 238s > 238s > ################################# 238s > 238s > 238s BEGIN TEST ranef.loading.R 238s 238s R version 4.4.3 (2025-02-28) -- "Trophy Case" 238s Copyright (C) 2025 The R Foundation for Statistical Computing 238s Platform: arm-unknown-linux-gnueabihf (32-bit) 238s 238s R is free software and comes with ABSOLUTELY NO WARRANTY. 238s You are welcome to redistribute it under certain conditions. 238s Type 'license()' or 'licence()' for distribution details. 238s 238s R is a collaborative project with many contributors. 238s Type 'contributors()' for more information and 238s 'citation()' on how to cite R or R packages in publications. 238s 238s Type 'demo()' for some demos, 'help()' for on-line help, or 238s 'help.start()' for an HTML browser interface to help. 238s Type 'q()' to quit R. 238s 238s > # check that ranef and VarCorr work even after loading ordinal: 238s > library(lme4) 238s Loading required package: Matrix 240s > fm1 <- lmer(Reaction ~ Days + (Days | Subject), data=sleepstudy) 240s > ranef(fm1) 240s $Subject 240s (Intercept) Days 240s 308 2.2585509 9.1989758 240s 309 -40.3987381 -8.6196806 240s 310 -38.9604090 -5.4488565 240s 330 23.6906196 -4.8143503 240s 331 22.2603126 -3.0699116 240s 332 9.0395679 -0.2721770 240s 333 16.8405086 -0.2236361 240s 334 -7.2326151 1.0745816 240s 335 -0.3336684 -10.7521652 240s 337 34.8904868 8.6282652 240s 349 -25.2102286 1.1734322 240s 350 -13.0700342 6.6142178 240s 351 4.5778642 -3.0152621 240s 352 20.8636782 3.5360011 240s 369 3.2754656 0.8722149 240s 370 -25.6129993 4.8224850 240s 371 0.8070461 -0.9881562 240s 372 12.3145921 1.2840221 240s 240s with conditional variances for “Subject” 240s > VarCorr(fm1) 240s Groups Name Std.Dev. Corr 240s Subject (Intercept) 24.7407 240s Days 5.9221 0.066 240s Residual 25.5918 240s > library(ordinal) 240s > ranef(fm1) 240s $Subject 240s (Intercept) Days 240s 308 2.2585509 9.1989758 240s 309 -40.3987381 -8.6196806 240s 310 -38.9604090 -5.4488565 240s 330 23.6906196 -4.8143503 240s 331 22.2603126 -3.0699116 240s 332 9.0395679 -0.2721770 240s 333 16.8405086 -0.2236361 240s 334 -7.2326151 1.0745816 240s 335 -0.3336684 -10.7521652 240s 337 34.8904868 8.6282652 240s 349 -25.2102286 1.1734322 240s 350 -13.0700342 6.6142178 240s 351 4.5778642 -3.0152621 240s 352 20.8636782 3.5360011 240s 369 3.2754656 0.8722149 240s 370 -25.6129993 4.8224850 240s 371 0.8070461 -0.9881562 240s 372 12.3145921 1.2840221 240s 240s with conditional variances for “Subject” 240s > VarCorr(fm1) 240s Groups Name Std.Dev. Corr 240s Subject (Intercept) 24.7407 240s Days 5.9221 0.066 240s Residual 25.5918 240s > 240s BEGIN TEST test-all.R 240s 240s R version 4.4.3 (2025-02-28) -- "Trophy Case" 240s Copyright (C) 2025 The R Foundation for Statistical Computing 240s Platform: arm-unknown-linux-gnueabihf (32-bit) 240s 240s R is free software and comes with ABSOLUTELY NO WARRANTY. 240s You are welcome to redistribute it under certain conditions. 240s Type 'license()' or 'licence()' for distribution details. 240s 240s R is a collaborative project with many contributors. 240s Type 'contributors()' for more information and 240s 'citation()' on how to cite R or R packages in publications. 240s 240s Type 'demo()' for some demos, 'help()' for on-line help, or 240s 'help.start()' for an HTML browser interface to help. 240s Type 'q()' to quit R. 240s 240s > 240s > if(require(testthat) && require(ordinal)) { 240s + test_check("ordinal") 240s + } 240s Loading required package: testthat 240s Loading required package: ordinal 249s [ FAIL 0 | WARN 0 | SKIP 0 | PASS 81 ] 249s > 249s BEGIN TEST test.clm.Theta.R 249s 249s R version 4.4.3 (2025-02-28) -- "Trophy Case" 249s Copyright (C) 2025 The R Foundation for Statistical Computing 249s Platform: arm-unknown-linux-gnueabihf (32-bit) 249s 249s R is free software and comes with ABSOLUTELY NO WARRANTY. 249s You are welcome to redistribute it under certain conditions. 249s Type 'license()' or 'licence()' for distribution details. 249s 249s R is a collaborative project with many contributors. 249s Type 'contributors()' for more information and 249s 'citation()' on how to cite R or R packages in publications. 249s 249s Type 'demo()' for some demos, 'help()' for on-line help, or 249s 'help.start()' for an HTML browser interface to help. 249s Type 'q()' to quit R. 249s 249s > library(ordinal) 250s > 250s > ################################# 250s > ## 1 categorical variable in nominal: 250s > fm <- clm(rating ~ temp, nominal=~contact, data=wine) 250s > fm$Theta 250s contact 1|2 2|3 3|4 4|5 250s 1 no -1.323043 1.2464435 3.550044 4.660247 250s 2 yes -2.938103 -0.2651238 1.875288 3.609624 250s > fm$alpha.mat 250s 1|2 2|3 3|4 4|5 250s (Intercept) -1.323043 1.246444 3.550044 4.660247 250s contactyes -1.615059 -1.511567 -1.674756 -1.050623 250s > ## Threshold effects: 250s > fm <- clm(rating ~ temp, nominal=~contact, data=wine, 250s + threshold="symmetric") 250s > fm$Theta 250s contact 1|2 2|3 3|4 4|5 250s 1 no -1.054279 1.083892 3.383980 5.522152 250s 2 yes -2.360683 -0.356889 1.753317 3.757111 250s > fm$alpha.mat 250s central.1 central.2 spacing.1 250s (Intercept) 1.083892 3.383980 2.1381713 250s contactyes -1.440781 -1.630663 -0.1343777 250s > fm <- clm(rating ~ temp, nominal=~contact, data=wine, 250s + threshold="equidistant") 250s > fm$Theta 250s contact 1|2 2|3 3|4 4|5 250s 1 no -1.089140 1.1176064 3.324353 5.531099 250s 2 yes -2.386361 -0.3365063 1.713348 3.763202 250s > fm$alpha.mat 250s threshold.1 spacing 250s (Intercept) -1.08914 2.2067465 250s contactyes -1.29722 -0.1568922 250s > ## Singular fit is still ok (with a warning, though) 250s > fm <- clm(rating ~ contact, nominal=~temp, data=wine) 250s > fm$alpha.mat 250s 1|2 2|3 3|4 4|5 250s (Intercept) -1.265638 1.104045 3.765661 24.89643 250s tempwarm -21.095417 -2.153024 -2.873317 -22.55000 250s > fm$Theta 250s temp 1|2 2|3 3|4 4|5 250s 1 cold -1.265638 1.104045 3.7656606 24.896432 250s 2 warm -22.361055 -1.048979 0.8923431 2.346436 250s > 250s > ################################# 250s > ## 1 continuous variable: 250s > set.seed(123) 250s > x <- rnorm(nrow(wine), sd=1) 250s Warning message: 250s (1) Hessian is numerically singular: parameters are not uniquely determined 250s In addition: Absolute convergence criterion was met, but relative criterion was not met 250s > fm <- clm(rating ~ temp, nominal=~ x, data=wine) 250s > fm$alpha.mat 250s 1|2 2|3 3|4 4|5 250s (Intercept) -1.93392115 0.4251062 2.4798775 3.9190335 250s x 0.09463825 0.3805713 0.4261607 0.3809099 250s > fm$Theta 250s 1|2 2|3 3|4 4|5 250s 1 -1.933921 0.4251062 2.479878 3.919034 250s > fm <- clm(rating ~ temp, nominal=~ poly(x, 2), data=wine) 250s > fm$alpha.mat 250s 1|2 2|3 3|4 4|5 250s (Intercept) -1.9310988 0.4469436 2.517523 4.094448 250s poly(x, 2)1 0.8763914 3.2908002 3.471603 4.422045 250s poly(x, 2)2 -0.3826811 0.2518184 -2.064209 5.810095 250s > fm$Theta 250s 1|2 2|3 3|4 4|5 250s 1 -1.931099 0.4469436 2.517523 4.094448 250s > 250s > ################################# 250s > ## 1 categorical + 1 continuous variable: 250s > set.seed(123) 250s > x <- rnorm(nrow(wine), sd=1) 250s > fm <- clm(rating ~ temp, nominal=~contact + x, data=wine) 250s > fm$alpha.mat 250s 1|2 2|3 3|4 4|5 250s (Intercept) -1.279484 1.2782515 3.612766 4.7496630 250s contactyes -1.770377 -1.6715296 -1.647335 -0.9575417 250s x 0.300792 0.5330593 0.351517 0.3320371 250s > fm$Theta 250s contact 1|2 2|3 3|4 4|5 250s 1 no -1.279484 1.2782515 3.612766 4.749663 250s 2 yes -3.049860 -0.3932781 1.965431 3.792121 250s > fm <- clm(rating ~ temp, nominal=~contact + x, data=wine, 250s + threshold="symmetric") 250s > fm$alpha.mat 250s central.1 central.2 spacing.1 250s (Intercept) 1.1195535 3.4384752 2.134429723 250s contactyes -1.5864032 -1.5904314 -0.007568099 250s x 0.5069573 0.3485632 0.137951085 250s > fm$Theta 250s contact 1|2 2|3 3|4 4|5 250s 1 no -1.014876 1.1195535 3.438475 5.572905 250s 2 yes -2.593711 -0.4668497 1.848044 3.974905 250s > ################################# 250s > ### NOTE: To get the by-threshold nominal effects of continuous terms 250s > ## use: 250s > with(fm, t(apply(alpha.mat, 1, function(th) tJac %*% th))) 250s [,1] [,2] [,3] [,4] 250s (Intercept) -1.0148763 1.1195535 3.4384752 5.5729049 250s contactyes -1.5788351 -1.5864032 -1.5904314 -1.5979995 250s x 0.3690062 0.5069573 0.3485632 0.4865143 250s > ################################# 250s > ## Interactions: 250s > fm <- clm(rating ~ temp, nominal=~contact:x, data=wine) 250s > fm$alpha.mat 250s 1|2 2|3 3|4 4|5 250s (Intercept) -1.9577944 0.5997213 2.6863244 4.1510613 250s contactno:x 0.1127629 0.7818026 0.4423216 0.9364319 250s contactyes:x 0.2129232 -0.2720801 0.3848893 0.1730418 250s > fm$Theta 250s 1|2 2|3 3|4 4|5 250s 1 -1.957794 0.5997213 2.686324 4.151061 250s > fm <- clm(rating ~ temp, nominal=~contact+x+contact:x, data=wine) 250s > fm$alpha.mat 250s 1|2 2|3 3|4 4|5 250s (Intercept) -1.3000385 1.4056290 3.8340494 5.195521 250s contactyes -2.2801110 -1.5685386 -1.7308097 -1.318630 250s x 0.1790630 0.8754972 0.5140440 1.061857 250s contactyes:x 0.7541913 -0.8829449 -0.2203363 -1.055090 250s > fm$Theta 250s contact 1|2 2|3 3|4 4|5 250s 1 no -1.300039 1.4056290 3.834049 5.195521 250s 2 yes -3.580150 -0.1629096 2.103240 3.876891 250s > fm <- clm(rating ~ temp, nominal=~contact*x, data=wine) 250s > fm$alpha.mat 250s 1|2 2|3 3|4 4|5 250s (Intercept) -1.3000385 1.4056290 3.8340494 5.195521 250s contactyes -2.2801110 -1.5685386 -1.7308097 -1.318630 250s x 0.1790630 0.8754972 0.5140440 1.061857 250s contactyes:x 0.7541913 -0.8829449 -0.2203363 -1.055090 250s > fm$Theta 250s contact 1|2 2|3 3|4 4|5 250s 1 no -1.300039 1.4056290 3.834049 5.195521 250s 2 yes -3.580150 -0.1629096 2.103240 3.876891 250s > ## polynomial terms: 250s > fm <- clm(rating ~ temp, nominal=~contact + poly(x, 2), data=wine) 250s > fm$alpha.mat 250s 1|2 2|3 3|4 4|5 250s (Intercept) -1.2704762 1.3058436 3.635351 4.984803 250s contactyes -1.7725959 -1.6863567 -1.668402 -1.045016 250s poly(x, 2)1 2.4660191 4.4257770 3.395876 4.572499 250s poly(x, 2)2 -0.5079931 -0.4326472 -2.815490 5.853814 250s > fm$Theta 250s contact 1|2 2|3 3|4 4|5 250s 1 no -1.270476 1.3058436 3.635351 4.984803 250s 2 yes -3.043072 -0.3805131 1.966949 3.939787 250s > ## logical variables: (treated like numeric variables) 250s > wine$Con <- as.character(wine$contact) == "yes" 250s > fm <- clm(rating ~ temp, nominal=~Con, data=wine) 250s > fm$Theta 250s 1|2 2|3 3|4 4|5 250s 1 -1.323043 1.246444 3.550044 4.660247 250s > fm$alpha.mat 250s 1|2 2|3 3|4 4|5 250s (Intercept) -1.323043 1.246444 3.550044 4.660247 250s ConTRUE -1.615059 -1.511567 -1.674756 -1.050623 250s > wine$Con.num <- 1 * wine$Con 250s > fm <- clm(rating ~ temp, nominal=~Con.num, data=wine) 250s > fm$Theta 250s 1|2 2|3 3|4 4|5 250s 1 -1.323043 1.246444 3.550044 4.660247 250s > fm$alpha.mat 250s 1|2 2|3 3|4 4|5 250s (Intercept) -1.323043 1.246444 3.550044 4.660247 250s Con.num -1.615059 -1.511567 -1.674756 -1.050623 250s > ################################# 250s > ## Two continuous variables: 250s > set.seed(321) 250s > y <- rnorm(nrow(wine), sd=1) 250s > fm1 <- clm(rating ~ temp, nominal=~y + x, data=wine) 250s > fm1$alpha.mat 250s 1|2 2|3 3|4 4|5 250s (Intercept) -2.0361734 0.4221202 2.4970718 3.92796873 250s y 0.4687950 0.1396038 0.3125431 0.08012751 250s x 0.1283933 0.3903469 0.4322374 0.37584062 250s > fm1$Theta 250s 1|2 2|3 3|4 4|5 250s 1 -2.036173 0.4221202 2.497072 3.927969 250s > ## summary(fm1) 250s > 250s > ################################# 250s > ## 1 categorical + 2 continuous variables: 250s > fm1 <- clm(rating ~ temp, nominal=~y + contact + x, data=wine) 250s > fm1$alpha.mat 250s 1|2 2|3 3|4 4|5 250s (Intercept) -1.3789903 1.2645381 3.5778844 4.76356985 250s y 0.4385042 0.1049073 0.2439721 -0.01655843 250s contactyes -1.7688345 -1.6608152 -1.5801690 -0.98076349 250s x 0.3414184 0.5436276 0.3683201 0.33263316 250s > fm1$Theta 250s contact 1|2 2|3 3|4 4|5 250s 1 no -1.378990 1.2645381 3.577884 4.763570 250s 2 yes -3.147825 -0.3962771 1.997715 3.782806 250s > 250s > fm1 <- clm(rating ~ temp, nominal=~contact + x + contact:x + y, 250s + data=wine) 250s > summary(fm1) 250s formula: rating ~ temp 250s nominal: ~contact + x + contact:x + y 250s data: wine 250s 250s link threshold nobs logLik AIC niter max.grad cond.H 250s logit flexible 72 -81.86 205.72 7(0) 6.30e-12 9.3e+01 250s 250s Coefficients: 250s Estimate Std. Error z value Pr(>|z|) 250s tempwarm 2.8541 0.6159 4.634 3.58e-06 *** 250s --- 250s Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1 250s 250s Threshold coefficients: 250s Estimate Std. Error z value 250s 1|2.(Intercept) -1.40166 0.63306 -2.214 250s 2|3.(Intercept) 1.38723 0.49672 2.793 250s 3|4.(Intercept) 3.78725 0.71352 5.308 250s 4|5.(Intercept) 5.19478 1.07162 4.848 250s 1|2.contactyes -2.25974 1.68593 -1.340 250s 2|3.contactyes -1.54343 0.62658 -2.463 250s 3|4.contactyes -1.65472 0.68161 -2.428 250s 4|5.contactyes -1.34417 1.10192 -1.220 250s 1|2.x 0.21217 0.60781 0.349 250s 2|3.x 0.88433 0.41592 2.126 250s 3|4.x 0.47072 0.57857 0.814 250s 4|5.x 0.98582 0.94345 1.045 250s 1|2.y 0.41959 0.59889 0.701 250s 2|3.y 0.08377 0.27912 0.300 250s 3|4.y 0.27724 0.33118 0.837 250s 4|5.y -0.03370 0.59652 -0.056 250s 1|2.contactyes:x 0.71850 1.19479 0.601 250s 2|3.contactyes:x -0.89167 0.68974 -1.293 250s 3|4.contactyes:x -0.10843 0.74237 -0.146 250s 4|5.contactyes:x -0.98243 1.06343 -0.924 250s > fm1$Theta 250s contact 1|2 2|3 3|4 4|5 250s 1 no -1.401661 1.3872281 3.787248 5.194782 250s 2 yes -3.661402 -0.1562067 2.132530 3.850615 250s > fm1$alpha.mat 250s 1|2 2|3 3|4 4|5 250s (Intercept) -1.4016606 1.38722808 3.7872478 5.19478152 250s contactyes -2.2597419 -1.54343480 -1.6547177 -1.34416691 250s x 0.2121750 0.88432858 0.4707237 0.98581604 250s y 0.4195947 0.08377343 0.2772447 -0.03369796 250s contactyes:x 0.7184952 -0.89166532 -0.1084271 -0.98242663 250s > fm1 <- clm(rating ~ temp, nominal=~contact*x + y, data=wine) 250s > fm1$Theta 250s contact 1|2 2|3 3|4 4|5 250s 1 no -1.401661 1.3872281 3.787248 5.194782 250s 2 yes -3.661402 -0.1562067 2.132530 3.850615 250s > fm1$alpha.mat 250s 1|2 2|3 3|4 4|5 250s (Intercept) -1.4016606 1.38722808 3.7872478 5.19478152 250s contactyes -2.2597419 -1.54343480 -1.6547177 -1.34416691 250s x 0.2121750 0.88432858 0.4707237 0.98581604 250s y 0.4195947 0.08377343 0.2772447 -0.03369796 250s contactyes:x 0.7184952 -0.89166532 -0.1084271 -0.98242663 250s > t(fm1$alpha.mat) 250s (Intercept) contactyes x y contactyes:x 250s 1|2 -1.401661 -2.259742 0.2121750 0.41959467 0.7184952 250s 2|3 1.387228 -1.543435 0.8843286 0.08377343 -0.8916653 250s 3|4 3.787248 -1.654718 0.4707237 0.27724473 -0.1084271 250s 4|5 5.194782 -1.344167 0.9858160 -0.03369796 -0.9824266 250s > fm1 250s formula: rating ~ temp 250s nominal: ~contact * x + y 250s data: wine 250s 250s link threshold nobs logLik AIC niter max.grad cond.H 250s logit flexible 72 -81.86 205.72 7(0) 6.30e-12 9.3e+01 250s 250s Coefficients: 250s tempwarm 250s 2.854 250s 250s Threshold coefficients: 250s 1|2 2|3 3|4 4|5 250s (Intercept) -1.40166 1.38723 3.78725 5.19478 250s contactyes -2.25974 -1.54343 -1.65472 -1.34417 250s x 0.21217 0.88433 0.47072 0.98582 250s y 0.41959 0.08377 0.27724 -0.03370 250s contactyes:x 0.71850 -0.89167 -0.10843 -0.98243 250s > 250s > ################################# 250s > ## ordered factors (behaves like numerical variables): 250s > data(soup, package="ordinal") 250s > fm2 <- clm(SURENESS ~ 1, nominal=~PRODID + DAY, data=soup) 250s > fm2$Theta 250s PRODID DAY 1|2 2|3 3|4 4|5 5|6 250s 1 1 1 -1.541481 -0.5738506 -0.21399538 0.04222703 0.75684062 250s 2 2 1 -2.260759 -1.5442697 -1.21890789 -0.91689299 -0.24659733 250s 3 3 1 -2.662588 -1.8500284 -1.67612929 -1.15745279 -0.65265582 250s 4 4 1 -2.230317 -1.3875834 -1.10527201 -0.70760465 -0.16454916 250s 5 5 1 -2.291960 -1.8870049 -1.51852627 -1.32708454 -0.64222204 250s 6 6 1 -2.765844 -2.1222058 -1.93080891 -1.76177831 -0.87239437 250s 7 1 2 -1.497366 -0.2765643 0.08617449 0.27652240 0.97863135 250s 8 2 2 -2.216645 -1.2469835 -0.91873802 -0.68259762 -0.02480661 250s 9 3 2 -2.618473 -1.5527421 -1.37595942 -0.92315742 -0.43086509 250s 10 4 2 -2.186203 -1.0902972 -0.80510215 -0.47330927 0.05724157 250s 11 5 2 -2.247845 -1.5897187 -1.21835640 -1.09278917 -0.42043131 250s 12 6 2 -2.721729 -1.8249196 -1.63063905 -1.52748294 -0.65060365 250s > fm2$alpha.mat 250s 1|2 2|3 3|4 4|5 5|6 250s (Intercept) -1.54148084 -0.5738506 -0.2139954 0.04222703 0.7568406 250s PRODID2 -0.71927809 -0.9704192 -1.0049125 -0.95912001 -1.0034380 250s PRODID3 -1.12110698 -1.2761778 -1.4621339 -1.19967981 -1.4094964 250s PRODID4 -0.68883656 -0.8137329 -0.8912766 -0.74983167 -0.9213898 250s PRODID5 -0.75047874 -1.3131544 -1.3045309 -1.36931157 -1.3990627 250s PRODID6 -1.22436292 -1.5483553 -1.7168135 -1.80400534 -1.6292350 250s DAY2 0.04411439 0.2972862 0.3001699 0.23429537 0.2217907 250s > prodid <- factor(soup$PRODID, ordered=TRUE) 250s > fm2 <- clm(SURENESS ~ 1, nominal=~prodid + DAY, data=soup) 250s > fm2$alpha.mat 250s 1|2 2|3 3|4 4|5 5|6 250s (Intercept) -2.29215806 -1.5608238 -1.2772733 -0.9714310 -0.3035963 250s prodid.L -0.69121817 -0.9929406 -1.0651956 -1.1714141 -1.0571728 250s prodid.Q 0.28234300 0.3165731 0.3424949 0.1207237 0.3905959 250s prodid.C -0.56889235 -0.5360906 -0.6536897 -0.5924148 -0.5462885 250s prodid^4 -0.08220340 0.2121409 0.0953785 0.2423256 0.1732012 250s prodid^5 0.20500444 0.3017272 0.3458281 0.2989342 0.3294562 250s DAY2 0.04411439 0.2972862 0.3001699 0.2342954 0.2217907 250s > fm2$Theta 250s DAY 1|2 2|3 3|4 4|5 5|6 250s 1 1 -2.292158 -1.560824 -1.2772733 -0.9714310 -0.30359635 250s 2 2 -2.248044 -1.263538 -0.9771034 -0.7371357 -0.08180562 250s > fm2 <- clm(SURENESS ~ 1, nominal=~prodid, data=soup) 250s > fm2$alpha.mat 250s 1|2 2|3 3|4 4|5 5|6 250s (Intercept) -2.2615449 -1.4231189 -1.13844940 -0.8610163 -0.20025662 250s prodid.L -0.6802192 -1.0171675 -1.08713192 -1.1713363 -1.05578526 250s prodid.Q 0.2551357 0.3521163 0.37511177 0.1651463 0.43182970 250s prodid.C -0.6064464 -0.5635065 -0.68182671 -0.6050149 -0.55490977 250s prodid^4 -0.1115795 0.1036958 -0.01443457 0.1577696 0.09355651 250s prodid^5 0.2349647 0.4222560 0.46856405 0.3867234 0.41280490 250s > fm2$Theta 250s 1|2 2|3 3|4 4|5 5|6 250s 1 -2.261545 -1.423119 -1.138449 -0.8610163 -0.2002566 250s > ################################# 250s > ## Aliased Coefficients: 250s > ## 250s > ## Example where the interaction in the nominal effects is aliased (by 250s > ## design). Here the two Theta matrices coincide. The alpha.mat 250s > ## matrices are similar except one has an extra row with NAs: 250s > soup2 <- soup 250s > levels(soup2$DAY) 250s [1] "1" "2" 250s > levels(soup2$GENDER) 250s [1] "Male" "Female" 250s > xx <- with(soup2, DAY == "2" & GENDER == "Female") 250s > ## Model with additive nominal effects: 250s > fm8 <- clm(SURENESS ~ PRODID, nominal= ~ DAY + GENDER, data=soup2, subset=!xx) 250s > fm8$alpha.mat 250s 1|2 2|3 3|4 4|5 5|6 250s (Intercept) -1.5296912 -0.68765358 -0.3255117394 0.03773041 0.629325973 250s DAY2 -0.2553049 0.08584421 0.1101987830 0.05149732 0.168514829 250s GENDERFemale 0.0790841 0.07464904 -0.0001589362 -0.11045608 -0.005418789 250s > fm8$Theta 250s DAY GENDER 1|2 2|3 3|4 4|5 5|6 250s 1 1 Male -1.529691 -0.6876536 -0.3255117 0.03773041 0.6293260 250s 2 2 Male -1.784996 -0.6018094 -0.2153130 0.08922773 0.7978408 250s 3 1 Female -1.450607 -0.6130045 -0.3256707 -0.07272568 0.6239072 250s 4 2 Female -1.705912 -0.5271603 -0.2154719 -0.02122835 0.7924220 250s > ## Model with non-additive, but aliased nominal effects: 250s > fm9 <- clm(SURENESS ~ PRODID, nominal= ~ DAY * GENDER, data=soup2, subset=!xx) 250s > fm9$alpha.mat 250s 1|2 2|3 3|4 4|5 5|6 250s (Intercept) -1.5296912 -0.68765358 -0.3255117394 0.03773041 0.629325973 250s DAY2 -0.2553049 0.08584421 0.1101987830 0.05149732 0.168514829 250s GENDERFemale 0.0790841 0.07464904 -0.0001589362 -0.11045608 -0.005418789 250s DAY2:GENDERFemale NA NA NA NA NA 250s > fm9$Theta 250s DAY GENDER 1|2 2|3 3|4 4|5 5|6 250s 1 1 Male -1.529691 -0.6876536 -0.3255117 0.03773041 0.6293260 250s 2 2 Male -1.784996 -0.6018094 -0.2153130 0.08922773 0.7978408 250s 3 1 Female -1.450607 -0.6130045 -0.3256707 -0.07272568 0.6239072 250s 4 2 Female -1.705912 -0.5271603 -0.2154719 -0.02122835 0.7924220 250s > 250s > stopEqual <- function(x, y, ca=FALSE) 250s + stopifnot(isTRUE(all.equal(x, y, check.attributes=ca))) 250s > 250s > stopEqual(fm8$alpha.mat, fm9$alpha.mat[1:3, ]) 250s > stopEqual(fm8$Theta, fm9$Theta) 251s > stopEqual(logLik(fm8), logLik(fm9)) 251s > 251s > ################################# 251s > ## Weights: 251s > set.seed(12345) 251s > wts <- runif(nrow(soup)) 251s > fm2 <- clm(SURENESS ~ 1, nominal=~SOUPTYPE + DAY, data=soup, weights=wts) 251s > fm2$Theta 251s SOUPTYPE DAY 1|2 2|3 3|4 4|5 5|6 251s 1 Self-made 1 -1.957136 -1.2051740 -0.8829317 -0.6651699 -0.03270025 251s 2 Canned 1 -1.665918 -0.9408556 -0.6818962 -0.4277315 0.14356406 251s 3 Dry-mix 1 -2.180024 -1.2221288 -1.1502087 -0.8113657 -0.24840514 251s 4 Self-made 2 -1.988269 -0.9456030 -0.5614139 -0.3852570 0.23978932 251s 5 Canned 2 -1.697051 -0.6812846 -0.3603783 -0.1478186 0.41605363 251s 6 Dry-mix 2 -2.211157 -0.9625577 -0.8286909 -0.5314528 0.02408443 251s > 251s > ## Offset (correctly gives and error) 251s > fm2 <- try(clm(SURENESS ~ 1, nominal=~SOUPTYPE + DAY + offset(wts), 251s + data=soup), silent=TRUE) 251s > stopifnot(inherits(fm2, "try-error")) 251s > 251s > ################################# 251s > ### Other (misc) examples: 251s > fm2 <- clm(SURENESS ~ 1, nominal=~SOUPTYPE + DAY, data=soup) 251s > fm2$Theta 251s SOUPTYPE DAY 1|2 2|3 3|4 4|5 5|6 251s 1 Self-made 1 -2.040111 -1.2615146 -0.9302684 -0.6740629 -0.05003069 251s 2 Canned 1 -1.816274 -1.0347697 -0.7305192 -0.4563265 0.15972072 251s 3 Dry-mix 1 -2.313198 -1.3029029 -1.1328903 -0.8076982 -0.23529457 251s 4 Self-made 2 -1.956698 -0.9371883 -0.5968669 -0.4131354 0.21403949 251s 5 Canned 2 -1.732861 -0.7104435 -0.3971177 -0.1953990 0.42379090 251s 6 Dry-mix 2 -2.229785 -0.9785767 -0.7994888 -0.5467707 0.02877561 251s > fm2 251s formula: SURENESS ~ 1 251s nominal: ~SOUPTYPE + DAY 251s data: soup 251s 251s link threshold nobs logLik AIC niter max.grad cond.H 251s logit flexible 1847 -2758.02 5556.03 6(2) 1.77e-11 8.7e+02 251s 251s Threshold coefficients: 251s 1|2 2|3 3|4 4|5 5|6 251s (Intercept) -2.04011 -1.26151 -0.93027 -0.67406 -0.05003 251s SOUPTYPECanned 0.22384 0.22674 0.19975 0.21774 0.20975 251s SOUPTYPEDry-mix -0.27309 -0.04139 -0.20262 -0.13364 -0.18526 251s DAY2 0.08341 0.32433 0.33340 0.26093 0.26407 251s > fm2 <- clm(SURENESS ~ 1, nominal=~SOUPTYPE * DAY, data=soup) 251s > fm2$Theta 251s SOUPTYPE DAY 1|2 2|3 3|4 4|5 5|6 251s 1 Self-made 1 -2.062794 -1.3083328 -0.9935434 -0.7187896 -0.05107493 251s 2 Canned 1 -1.757074 -0.9398212 -0.6286087 -0.3721287 0.15415068 251s 3 Dry-mix 1 -2.369525 -1.3618033 -1.1700713 -0.8661663 -0.23795864 251s 4 Self-made 2 -1.945910 -0.9005649 -0.5459555 -0.3731219 0.21392690 251s 5 Canned 2 -1.775759 -0.7985077 -0.4924765 -0.2776317 0.43428555 251s 6 Dry-mix 2 -2.182299 -0.9257695 -0.7649729 -0.4964369 0.02702867 251s > fm2 251s formula: SURENESS ~ 1 251s nominal: ~SOUPTYPE * DAY 251s data: soup 251s 251s link threshold nobs logLik AIC niter max.grad cond.H 251s logit flexible 1847 -2755.60 5571.21 6(2) 1.76e-11 4.9e+03 251s 251s Threshold coefficients: 251s 1|2 2|3 3|4 4|5 5|6 251s (Intercept) -2.063e+00 -1.308e+00 -9.935e-01 -7.188e-01 -5.107e-02 251s SOUPTYPECanned 3.057e-01 3.685e-01 3.649e-01 3.467e-01 2.052e-01 251s SOUPTYPEDry-mix -3.067e-01 -5.347e-02 -1.765e-01 -1.474e-01 -1.869e-01 251s DAY2 1.169e-01 4.078e-01 4.476e-01 3.457e-01 2.650e-01 251s SOUPTYPECanned:DAY2 -1.356e-01 -2.665e-01 -3.115e-01 -2.512e-01 1.513e-02 251s SOUPTYPEDry-mix:DAY2 7.034e-02 2.827e-02 -4.249e-02 2.406e-02 -1.452e-05 251s > fm2$alpha.mat 251s 1|2 2|3 3|4 4|5 251s (Intercept) -2.06279431 -1.30833282 -0.99354336 -0.71878961 251s SOUPTYPECanned 0.30572040 0.36851159 0.36493470 0.34666092 251s SOUPTYPEDry-mix -0.30673027 -0.05347052 -0.17652789 -0.14737673 251s DAY2 0.11688416 0.40776793 0.44758789 0.34566775 251s SOUPTYPECanned:DAY2 -0.13556938 -0.26645440 -0.31145572 -0.25117080 251s SOUPTYPEDry-mix:DAY2 0.07034149 0.02826594 -0.04248955 0.02406171 251s 5|6 251s (Intercept) -5.107493e-02 251s SOUPTYPECanned 2.052256e-01 251s SOUPTYPEDry-mix -1.868837e-01 251s DAY2 2.650018e-01 251s SOUPTYPECanned:DAY2 1.513304e-02 251s SOUPTYPEDry-mix:DAY2 -1.451666e-05 251s > fm2 <- clm(SURENESS ~ 1, nominal=~SOUPTYPE * DAY, data=soup, 251s + threshold="symmetric") 251s > fm2$Theta 251s SOUPTYPE DAY 1|2 2|3 3|4 4|5 5|6 251s 1 Self-made 1 -2.023473 -1.3261580 -1.0328445 -0.7395310 -0.04221610 251s 2 Canned 1 -1.650803 -1.0121961 -0.7301243 -0.4480525 0.19055466 251s 3 Dry-mix 1 -2.214507 -1.4643357 -1.2132431 -0.9621504 -0.21197912 251s 4 Self-made 2 -1.757994 -1.0009894 -0.7422397 -0.4834900 0.27351461 251s 5 Canned 2 -1.673970 -0.8581393 -0.5997040 -0.3412687 0.47456211 251s 6 Dry-mix 2 -1.899340 -1.1167968 -0.9013722 -0.6859476 0.09659551 251s > fm2$alpha.mat 251s central spacing.1 spacing.2 251s (Intercept) -1.03284450 0.293313471 0.99062841 251s SOUPTYPECanned 0.30272022 -0.011241697 -0.06994946 251s SOUPTYPEDry-mix -0.18039855 -0.042220836 0.01063552 251s DAY2 0.29060480 -0.034563797 0.02512591 251s SOUPTYPECanned:DAY2 -0.16018453 0.010927306 0.12846128 251s SOUPTYPEDry-mix:DAY2 0.02126607 -0.001104241 -0.02842214 251s > 251s > ################################# 251s > ### Check correctness of Theta matrix when intercept is removed in 251s > ### nominal formula: 251s > ### December 25th 2014, RHBC 251s > fm1 <- clm(rating ~ temp, nominal=~contact-1, data=wine) 251s > fm2 <- clm(rating ~ temp, nominal=~contact, data=wine) 251s Warning message: 251s an intercept is needed and assumed in 'nominal' 251s > stopifnot(isTRUE(all.equal(fm1$Theta, fm2$Theta))) 251s > stopifnot(isTRUE(all.equal(fm1$logLik, fm2$logLik))) 251s > wine2 <- wine 251s > wine2$contact <- relevel(wine2$contact, "yes") 251s > fm3 <- clm(rating ~ temp, nominal=~contact, data=wine2) 251s > stopifnot(isTRUE(all.equal(coef(fm1, na.rm=TRUE), coef(fm3)))) 251s > ################################# 251s > 251s > 251s BEGIN TEST test.clm.convergence.R 251s 251s R version 4.4.3 (2025-02-28) -- "Trophy Case" 251s Copyright (C) 2025 The R Foundation for Statistical Computing 251s Platform: arm-unknown-linux-gnueabihf (32-bit) 251s 251s R is free software and comes with ABSOLUTELY NO WARRANTY. 251s You are welcome to redistribute it under certain conditions. 251s Type 'license()' or 'licence()' for distribution details. 251s 251s R is a collaborative project with many contributors. 251s Type 'contributors()' for more information and 251s 'citation()' on how to cite R or R packages in publications. 251s 251s Type 'demo()' for some demos, 'help()' for on-line help, or 251s 'help.start()' for an HTML browser interface to help. 251s Type 'q()' to quit R. 251s 251s > library(ordinal) 252s > 252s > 252s > ## Testing that errors in chol() are caught soon enough: 252s > cy <- with(wine, which(temp == "cold" & contact == "yes")) 252s > wine2 <- subset(wine, subset=(!1:nrow(wine) %in% cy)) 252s > wine2[c(9, 15, 46), "rating"] <- NA 252s > fm1 <- clm(rating ~ temp, scale=~contact, nominal=~contact, 252s + data=wine2) 252s > fm1 <- try(clm(rating ~ temp, scale=~contact, nominal=~contact, 252s + data=wine2, control=list(gradTol=1e-12)), silent=TRUE) 252s Warning message: 252s (1) Hessian is numerically singular: parameters are not uniquely determined 252s In addition: Absolute convergence criterion was met, but relative criterion was not met 252s Warning message: 252s (1) Hessian is numerically singular: parameters are not uniquely determined 252s In addition: Absolute convergence criterion was met, but relative criterion was not met 252s > fm2 <- try(clm(rating ~ temp, scale=~contact, nominal=~contact, 252s + data=wine2, control=list(gradTol=1e-15)), silent=TRUE) 252s > ## These gave errors in version 2014.11-12. 252s > stopifnot(!inherits(fm1, "try-error")) 252s > stopifnot(!inherits(fm2, "try-error")) 252s > summary(fm1) 252s formula: rating ~ temp 252s scale: ~contact 252s nominal: ~contact 252s data: wine2 252s 252s Warning message: 252s (-1) Model failed to converge with max|grad| = 4.32588e-08 (tol = 1e-15) 252s In addition: iteration limit reached 252s link threshold nobs logLik AIC niter max.grad cond.H 252s logit flexible 51 -60.44 140.87 64(40) 5.26e-14 3.5e+16 252s 252s Coefficients: 252s Estimate Std. Error z value Pr(>|z|) 252s tempwarm 2.306 NA NA NA 252s 252s log-scale coefficients: 252s Estimate Std. Error z value Pr(>|z|) 252s contactyes -0.0715 NA NA NA 252s 252s Threshold coefficients: 252s Estimate Std. Error z value 252s 1|2.(Intercept) -1.354 NA NA 252s 2|3.(Intercept) 1.092 NA NA 252s 3|4.(Intercept) 3.469 NA NA 252s 4|5.(Intercept) 5.066 NA NA 252s 1|2.contactyes -30.757 NA NA 252s 2|3.contactyes -1.424 NA NA 252s 3|4.contactyes -1.808 NA NA 252s 4|5.contactyes -1.870 NA NA 252s (3 observations deleted due to missingness) 252s > summary(fm2) 252s formula: rating ~ temp 252s scale: ~contact 252s nominal: ~contact 252s data: wine2 252s 252s link threshold nobs logLik AIC niter max.grad cond.H 252s logit flexible 51 -60.44 140.87 111(88) 4.33e-08 1.6e+16 252s 252s Coefficients: 252s Estimate Std. Error z value Pr(>|z|) 252s tempwarm 2.3060 0.7713 2.99 0.00279 ** 252s --- 252s Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1 252s 252s log-scale coefficients: 252s Estimate Std. Error z value Pr(>|z|) 252s contactyes -0.07113 4807.97981 0 1 252s 252s Threshold coefficients: 252s Estimate Std. Error z value 252s 1|2.(Intercept) -1.354e+00 5.707e-01 -2.373 252s 2|3.(Intercept) 1.092e+00 5.251e-01 2.080 252s 3|4.(Intercept) 3.469e+00 7.982e-01 4.346 252s 4|5.(Intercept) 5.066e+00 1.193e+00 4.246 252s 1|2.contactyes -3.824e+01 1.288e+09 0.000 252s 2|3.contactyes -1.425e+00 1.269e+04 0.000 252s 3|4.contactyes -1.808e+00 3.104e+03 -0.001 252s 4|5.contactyes -1.870e+00 4.279e+03 0.000 252s (3 observations deleted due to missingness) 252s > 252s > ## Error in convergence.clm() due to bad evaluation of model 252s > ## environment with update(object, doFit=FALSE): 252s > wine3 <- wine 252s > set.seed(1234) 252s > wts <- runif(nrow(wine3), 0, 2) 252s > fm3 <- clm(rating ~ temp + contact, data=wine3, 252s + weights=wts) 252s > c0 <- convergence(fm3) 252s > set.seed(1234) 252s > fm3 <- clm(rating ~ temp + contact, data=wine3, 252s + weights=runif(nrow(wine3), 0, 2)) 252s > c1 <- convergence(fm3) 252s > c0$info$logLik.Error 252s [1] "<1e-10" 252s > c1$info$logLik.Error 252s [1] "<1e-10" 252s > all.equal(c0$info$logLik.Error, c1$info$logLik.Error) 252s [1] TRUE 252s > ## In version 2014.11-14: 252s > ## > wine3 <- wine 252s > ## > set.seed(1234) 252s > ## > wts <- runif(nrow(wine3), 0, 2) 252s > ## > fm3 <- clm(rating ~ temp + contact, data=wine3, 252s > ## + weights=wts) 252s > ## > c0 <- convergence(fm3) 252s > ## > set.seed(1234) 252s > ## > fm3 <- clm(rating ~ temp + contact, data=wine3, 252s > ## + weights=runif(nrow(wine3), 0, 2)) 252s > ## > c1 <- convergence(fm3) 252s > ## > c0$info$logLik.Error 252s > ## [1] "<1e-10" 252s > ## > c1$info$logLik.Error 252s > ## [1] "4.80e+00" 252s > ## > all.equal(c0$info$logLik.Error, c1$info$logLik.Error) 252s > ## [1] "1 string mismatch" 252s > stopifnot(c0$info$logLik.Error == 252s + c1$info$logLik.Error) 252s > 252s BEGIN TEST test.clm.flex.link.R 252s 252s R version 4.4.3 (2025-02-28) -- "Trophy Case" 252s Copyright (C) 2025 The R Foundation for Statistical Computing 252s Platform: arm-unknown-linux-gnueabihf (32-bit) 252s 252s R is free software and comes with ABSOLUTELY NO WARRANTY. 252s You are welcome to redistribute it under certain conditions. 252s Type 'license()' or 'licence()' for distribution details. 252s 252s R is a collaborative project with many contributors. 252s Type 'contributors()' for more information and 252s 'citation()' on how to cite R or R packages in publications. 252s 252s Type 'demo()' for some demos, 'help()' for on-line help, or 252s 'help.start()' for an HTML browser interface to help. 252s Type 'q()' to quit R. 252s 252s > # test.clm.flex.link.R 252s > 252s > library(ordinal) 253s > 253s > fm <- clm(rating ~ contact + temp, data=wine, link="log-gamma") 253s Changing to 'nlminb' optimizer for flexible link function 254s Warning message: 254s (-1) Model failed to converge with max|grad| = 9.90148e-05 (tol = 1e-06) 254s > fm 254s formula: rating ~ contact + temp 254s data: wine 254s 254s link threshold nobs logLik AIC niter max.grad cond.H 254s log-gamma flexible 72 -85.72 185.44 27(179) 9.90e-05 5.9e+01 254s 254s Coefficients: 254s contactyes tempwarm 254s 0.8614 1.5072 254s 254s Link coefficient: 254s lambda 254s 0.1615 254s 254s Threshold coefficients: 254s 1|2 2|3 3|4 4|5 254s -0.8798 0.6678 1.9807 2.8593 254s > summary(fm) 254s formula: rating ~ contact + temp 254s data: wine 254s 254s link threshold nobs logLik AIC niter max.grad cond.H 254s log-gamma flexible 72 -85.72 185.44 27(179) 9.90e-05 5.9e+01 254s Profile intervals not available for models with flexible link function: 254s reporting Wald intervals instead 254s Changing to 'nlminb' optimizer for flexible link function 254s 254s Coefficients: 254s Estimate Std. Error z value Pr(>|z|) 254s contactyes 0.8614 0.2675 3.220 0.00128 ** 254s tempwarm 1.5072 0.2947 5.114 3.16e-07 *** 254s --- 254s Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1 254s 254s Link coefficients: 254s Estimate Std. Error z value Pr(>|z|) 254s lambda 0.1615 0.5752 0.281 0.779 254s 254s Threshold coefficients: 254s Estimate Std. Error z value 254s 1|2 -0.8798 0.5003 -1.759 254s 2|3 0.6678 0.3450 1.936 254s 3|4 1.9807 0.3826 5.177 254s 4|5 2.8593 0.4656 6.141 254s > vcov(fm) 254s 1|2 2|3 3|4 4|5 contactyes 254s 1|2 0.25029668 0.12858124 0.11888120 0.14341730 0.03339111 254s 2|3 0.12858124 0.11899385 0.10688715 0.12363923 0.04117758 254s 3|4 0.11888120 0.10688715 0.14635448 0.15493865 0.05320442 254s 4|5 0.14341730 0.12363923 0.15493865 0.21676904 0.06051103 254s contactyes 0.03339111 0.04117758 0.05320442 0.06051103 0.07156735 254s tempwarm 0.00707258 0.03006561 0.05390802 0.06549176 0.01159715 254s lambda -0.23173316 -0.13979171 -0.12509774 -0.15581155 -0.01157951 254s tempwarm lambda 254s 1|2 0.00707258 -0.23173316 254s 2|3 0.03006561 -0.13979171 254s 3|4 0.05390802 -0.12509774 254s 4|5 0.06549176 -0.15581155 254s contactyes 0.01159715 -0.01157951 254s tempwarm 0.08687098 0.01970691 254s lambda 0.01970691 0.33082449 254s > logLik(fm) 254s 'log Lik.' -85.72141 (df=7) 254s > extractAIC(fm) 254s [1] 7.0000 185.4428 254s > fm2 <- update(fm, link="probit") 254s > anova(fm, fm2) 254s Likelihood ratio tests of cumulative link models: 254s 254s formula: link: threshold: 254s fm2 rating ~ contact + temp probit flexible 254s fm rating ~ contact + temp log-gamma flexible 254s 254s no.par AIC logLik LR.stat df Pr(>Chisq) 254s fm2 6 183.52 -85.761 254s fm 7 185.44 -85.721 0.0795 1 0.778 254s > head(model.matrix(fm)$X) 254s (Intercept) contactyes tempwarm 254s 1 1 0 0 254s 2 1 0 0 254s 3 1 1 0 254s 4 1 1 0 254s 5 1 0 1 254s 6 1 0 1 254s > head(model.frame(fm)) 254s rating contact temp 254s 1 2 no cold 254s 2 3 no cold 254s 3 3 yes cold 254s 4 4 yes cold 254s 5 4 no warm 254s 6 4 no warm 254s > coef(fm) 254s 1|2 2|3 3|4 4|5 contactyes tempwarm lambda 254s -0.8797774 0.6678307 1.9806826 2.8593125 0.8614400 1.5071959 0.1614741 254s > coef(summary(fm)) 254s Estimate Std. Error z value Pr(>|z|) 254s 1|2 -0.8797774 0.5002966 -1.7585116 7.866049e-02 254s 2|3 0.6678307 0.3449548 1.9359945 5.286838e-02 254s 3|4 1.9806826 0.3825630 5.1774020 2.249971e-07 254s 4|5 2.8593125 0.4655846 6.1413379 8.182932e-10 254s contactyes 0.8614400 0.2675208 3.2200867 1.281518e-03 254s tempwarm 1.5071959 0.2947388 5.1136658 3.159661e-07 254s lambda 0.1614741 0.5751734 0.2807398 7.789100e-01 254s > nobs(fm) 254s [1] 72 254s > terms(fm) 254s rating ~ contact + temp 254s attr(,"variables") 254s list(rating, contact, temp) 254s attr(,"factors") 254s contact temp 254s rating 0 0 254s contact 1 0 254s temp 0 1 254s attr(,"term.labels") 254s [1] "contact" "temp" 254s attr(,"order") 254s [1] 1 1 254s attr(,"intercept") 254s [1] 1 254s attr(,"response") 254s [1] 1 254s attr(,".Environment") 254s 254s attr(,"predvars") 254s list(rating, contact, temp) 254s attr(,"dataClasses") 254s rating contact temp 254s "ordered" "factor" "factor" 254s > # profile(fm) # not implemented 254s > confint(fm) 254s 2.5 % 97.5 % 254s 1|2 -1.860340665 0.1007859 254s 2|3 -0.008268395 1.3439298 254s 3|4 1.230872839 2.7304924 254s 4|5 1.946783395 3.7718416 254s contactyes 0.337108993 1.3857711 254s tempwarm 0.929518433 2.0848735 254s lambda -0.965845161 1.2887933 254s > 254s > predict(fm, se=TRUE, interval = TRUE) 254s $fit 254s [1] 0.55792545 0.21565445 0.44140778 0.09846706 0.22428321 0.22428321 254s [7] 0.29090566 0.29090566 0.21042288 0.55792545 0.05388914 0.44140778 254s [13] 0.20737472 0.48129483 0.29090566 0.33832254 0.55792545 0.21565445 254s [19] 0.44140778 0.39099052 0.07269587 0.07269587 0.33832254 0.33832254 254s [25] 0.21565445 0.55792545 0.44140778 0.39099052 0.48129483 0.20737472 254s [31] 0.29090566 0.31272339 0.55792545 0.21565445 0.09846706 0.44140778 254s [37] 0.48129483 0.48129483 0.31272339 0.31272339 0.21565445 0.55792545 254s [43] 0.44140778 0.39099052 0.20737472 0.22428321 0.29090566 0.33832254 254s [49] 0.21042288 0.21042288 0.39099052 0.39099052 0.20737472 0.48129483 254s [55] 0.05636253 0.31272339 0.55792545 0.55792545 0.39099052 0.44140778 254s [61] 0.48129483 0.48129483 0.31272339 0.33832254 0.21042288 0.55792545 254s [67] 0.44140778 0.39099052 0.48129483 0.20737472 0.33832254 0.33832254 254s 254s $se.fit 254s [1] 0.09164058 0.09494135 0.08777656 0.05464347 0.08112461 0.08112461 254s [7] 0.13494789 0.13494789 0.13693811 0.09164058 0.04809909 0.08777656 254s [13] 0.09512593 0.07373113 0.13494789 0.08236628 0.09164058 0.09494135 254s [19] 0.08777656 0.09756681 0.06362571 0.06362571 0.08236628 0.08236628 254s [25] 0.09494135 0.09164058 0.08777656 0.09756681 0.07373113 0.09512593 254s [31] 0.13494789 0.09451059 0.09164058 0.09494135 0.05464347 0.08777656 254s [37] 0.07373113 0.07373113 0.09451059 0.09451059 0.09494135 0.09164058 254s [43] 0.08777656 0.09756681 0.09512593 0.08112461 0.13494789 0.08236628 254s [49] 0.13693811 0.13693811 0.09756681 0.09756681 0.09512593 0.07373113 254s [55] 0.03866211 0.09451059 0.09164058 0.09164058 0.09756681 0.08777656 254s [61] 0.07373113 0.07373113 0.09451059 0.08236628 0.13693811 0.09164058 254s [67] 0.08777656 0.09756681 0.07373113 0.09512593 0.08236628 0.08236628 254s 254s $lwr 254s [1] 0.378604422 0.083839588 0.282278453 0.031650564 0.103885178 0.103885178 254s [7] 0.102183448 0.102183448 0.050316475 0.378604422 0.008885132 0.282278453 254s [13] 0.077621510 0.342154616 0.102183448 0.199101468 0.378604422 0.083839588 254s [19] 0.282278453 0.223352984 0.012177666 0.012177666 0.199101468 0.199101468 254s [25] 0.083839588 0.378604422 0.282278453 0.223352984 0.342154616 0.077621510 254s [31] 0.102183448 0.161206608 0.378604422 0.083839588 0.031650564 0.282278453 254s [37] 0.342154616 0.342154616 0.161206608 0.161206608 0.083839588 0.378604422 254s [43] 0.282278453 0.223352984 0.077621510 0.103885178 0.102183448 0.199101468 254s [49] 0.050316475 0.050316475 0.223352984 0.223352984 0.077621510 0.342154616 254s [55] 0.014165415 0.161206608 0.378604422 0.378604422 0.223352984 0.282278453 254s [61] 0.342154616 0.342154616 0.161206608 0.199101468 0.050316475 0.378604422 254s [67] 0.282278453 0.223352984 0.342154616 0.077621510 0.199101468 0.199101468 254s 254s $upr 254s [1] 0.7233159 0.4523801 0.6135565 0.2673887 0.4189772 0.4189772 0.5965756 254s [8] 0.5965756 0.5727401 0.7233159 0.2657272 0.6135565 0.4485489 0.6233979 254s [15] 0.5965756 0.5125880 0.7233159 0.4523801 0.6135565 0.5890239 0.3326787 254s [22] 0.3326787 0.5125880 0.5125880 0.4523801 0.7233159 0.6135565 0.5890239 254s [29] 0.6233979 0.4485489 0.5965756 0.5186019 0.7233159 0.4523801 0.2673887 254s [36] 0.6135565 0.6233979 0.6233979 0.5186019 0.5186019 0.4523801 0.7233159 254s [43] 0.6135565 0.5890239 0.4485489 0.4189772 0.5965756 0.5125880 0.5727401 254s [50] 0.5727401 0.5890239 0.5890239 0.4485489 0.6233979 0.1988990 0.5186019 254s [57] 0.7233159 0.7233159 0.5890239 0.6135565 0.6233979 0.6233979 0.5186019 254s [64] 0.5125880 0.5727401 0.7233159 0.6135565 0.5890239 0.6233979 0.4485489 254s [71] 0.5125880 0.5125880 254s 254s > predict(fm, type="class") 254s $fit 254s [1] 2 2 3 3 3 3 4 4 2 2 3 3 3 3 4 4 2 2 3 3 3 3 4 4 2 2 3 3 3 3 4 4 2 2 3 3 3 3 254s [39] 4 4 2 2 3 3 3 3 4 4 2 2 3 3 3 3 4 4 2 2 3 3 3 3 4 4 2 2 3 3 3 3 4 4 254s Levels: 1 2 3 4 5 254s 254s > newData <- expand.grid(temp = c("cold", "warm"), 254s + contact = c("no", "yes")) 254s > 254s > ## Predicted probabilities in all five response categories for each of 254s > ## the four cases in newData: 254s > predict(fm, newdata=newData, type="prob") 254s $fit 254s 1 2 3 4 5 254s 1 0.210422882 0.55792545 0.2156544 0.01517801 0.0008192111 254s 2 0.014351371 0.20737472 0.4812948 0.22428321 0.0726958743 254s 3 0.053889141 0.39099052 0.4414078 0.09846706 0.0152454932 254s 4 0.001685878 0.05636253 0.3127234 0.33832254 0.2909056643 254s 254s > predict(fm, newdata=newData, type="class") 254s $fit 254s [1] 2 3 3 4 254s Levels: 1 2 3 4 5 254s 254s > 254s > predict(fm, newdata=newData, type="prob", se.fit = TRUE, interval = TRUE) 254s $fit 254s 1 2 3 4 5 254s 1 0.210422882 0.55792545 0.2156544 0.01517801 0.0008192111 254s 2 0.014351371 0.20737472 0.4812948 0.22428321 0.0726958743 254s 3 0.053889141 0.39099052 0.4414078 0.09846706 0.0152454932 254s 4 0.001685878 0.05636253 0.3127234 0.33832254 0.2909056643 254s 254s $se.fit 254s 1 2 3 4 5 254s 1 0.136938111 0.09164058 0.09494135 0.01696529 0.002047363 254s 2 0.016247015 0.09512593 0.07373113 0.08112461 0.063625711 254s 3 0.048099092 0.09756681 0.08777656 0.05464347 0.019268561 254s 4 0.002046575 0.03866211 0.09451059 0.08236628 0.134947885 254s 254s $lwr 254s 1 2 3 4 5 254s 1 0.050316475 0.37860442 0.08383959 0.001663553 6.091051e-06 254s 2 0.001530524 0.07762151 0.34215462 0.103885178 1.217767e-02 254s 3 0.008885132 0.22335298 0.28227845 0.031650564 1.249665e-03 254s 4 0.000155750 0.01416541 0.16120661 0.199101468 1.021834e-01 254s 254s $upr 254s 1 2 3 4 5 254s 1 0.57274013 0.7233159 0.4523801 0.1247616 0.09939056 254s 2 0.12150065 0.4485489 0.6233979 0.4189772 0.33267866 254s 3 0.26572719 0.5890239 0.6135565 0.2673887 0.16075952 254s 4 0.01797808 0.1988990 0.5186019 0.5125880 0.59657563 254s 254s > 254s > 254s > ## Aranda-Ordaz link: 254s > fm <- clm(rating ~ contact + temp, data=wine, link="Aranda-Ordaz") 254s > fm 254s formula: rating ~ contact + temp 254s data: wine 254s 254s link threshold nobs logLik AIC niter max.grad cond.H 254s Aranda-Ordaz flexible 72 -86.34 186.68 31(219) 1.63e-05 3.9e+02 254s 254s Coefficients: 254s contactyes tempwarm 254s 1.193 2.076 254s 254s Link coefficient: 254s lambda 254s 0.4994 254s 254s Threshold coefficients: 254s 1|2 2|3 3|4 4|5 254s -1.5284 0.7669 2.6021 3.7962 254s > summary(fm) 254s formula: rating ~ contact + temp 254s data: wine 254s 254s Warning message: 254s (-1) Model failed to converge with max|grad| = 1.6288e-05 (tol = 1e-06) 254s link threshold nobs logLik AIC niter max.grad cond.H 254s Aranda-Ordaz flexible 72 -86.34 186.68 31(219) 1.63e-05 3.9e+02 254s 254s Coefficients: 254s Estimate Std. Error z value Pr(>|z|) 254s contactyes 1.1927 0.6526 1.828 0.0676 . 254s tempwarm 2.0758 0.8196 2.533 0.0113 * 254s --- 254s Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1 254s 254s Link coefficients: 254s Profile intervals not available for models with flexible link function: 254s reporting Wald intervals instead 254s Estimate Std. Error z value Pr(>|z|) 254s lambda 0.4994 0.7840 0.637 0.524 254s 254s Threshold coefficients: 254s Estimate Std. Error z value 254s 1|2 -1.5284 0.5775 -2.647 254s 2|3 0.7669 0.8234 0.931 254s 3|4 2.6021 1.4335 1.815 254s 4|5 3.7962 1.9674 1.930 254s > vcov(fm) 254s 1|2 2|3 3|4 4|5 contactyes tempwarm 254s 1|2 0.3335060 0.2983830 0.4851477 0.6557866 0.2132243 0.2586679 254s 2|3 0.2983830 0.6780278 1.1261329 1.5330564 0.4699069 0.5953101 254s 3|4 0.4851477 1.1261329 2.0550132 2.7755715 0.8214403 1.0831428 254s 4|5 0.6557866 1.5330564 2.7755715 3.8705158 1.1194941 1.4831342 254s contactyes 0.2132243 0.4699069 0.8214403 1.1194941 0.4259333 0.3965112 254s tempwarm 0.2586679 0.5953101 1.0831428 1.4831342 0.3965112 0.6717720 254s lambda 0.2424389 0.5895693 1.0675177 1.4810301 0.4153797 0.5471765 254s lambda 254s 1|2 0.2424389 254s 2|3 0.5895693 254s 3|4 1.0675177 254s 4|5 1.4810301 254s contactyes 0.4153797 254s tempwarm 0.5471765 254s lambda 0.6146953 254s > logLik(fm) 254s 'log Lik.' -86.34171 (df=7) 254s > extractAIC(fm) 254s [1] 7.0000 186.6834 254s > fm2 <- update(fm, link="logit") 254s > anova(fm, fm2) 254s Likelihood ratio tests of cumulative link models: 254s 254s formula: link: threshold: 254s fm2 rating ~ contact + temp logit flexible 254s fm rating ~ contact + temp Aranda-Ordaz flexible 254s 254s no.par AIC logLik LR.stat df Pr(>Chisq) 254s fm2 6 184.98 -86.492 254s fm 7 186.68 -86.342 0.3004 1 0.5836 254s > head(model.matrix(fm)$X) 254s (Intercept) contactyes tempwarm 254s 1 1 0 0 254s 2 1 0 0 254s 3 1 1 0 254s 4 1 1 0 254s 5 1 0 1 254s 6 1 0 1 254s > head(model.frame(fm)) 254s rating contact temp 254s 1 2 no cold 254s 2 3 no cold 254s 3 3 yes cold 254s 4 4 yes cold 254s 5 4 no warm 254s 6 4 no warm 254s > coef(fm) 254s 1|2 2|3 3|4 4|5 contactyes tempwarm lambda 254s -1.5283885 0.7668892 2.6021281 3.7962200 1.1927244 2.0757936 0.4994415 254s > coef(summary(fm)) 254s Estimate Std. Error z value Pr(>|z|) 254s 1|2 -1.5283885 0.5774998 -2.6465611 0.008131482 254s 2|3 0.7668892 0.8234244 0.9313413 0.351677025 254s 3|4 2.6021281 1.4335317 1.8151869 0.069495186 254s 4|5 3.7962200 1.9673627 1.9295985 0.053656609 254s contactyes 1.1927244 0.6526357 1.8275501 0.067617099 254s tempwarm 2.0757936 0.8196170 2.5326386 0.011320761 254s lambda 0.4994415 0.7840251 0.6370223 0.524110286 254s > nobs(fm) 254s [1] 72 254s > terms(fm) 254s rating ~ contact + temp 254s attr(,"variables") 254s list(rating, contact, temp) 254s attr(,"factors") 254s contact temp 254s rating 0 0 254s contact 1 0 254s temp 0 1 254s attr(,"term.labels") 254s [1] "contact" "temp" 254s attr(,"order") 254s [1] 1 1 254s attr(,"intercept") 254s [1] 1 254s attr(,"response") 254s [1] 1 254s attr(,".Environment") 254s 254s attr(,"predvars") 254s list(rating, contact, temp) 254s attr(,"dataClasses") 254s rating contact temp 254s "ordered" "factor" "factor" 254s > # profile(fm) # not implemented 254s > confint(fm) 254s 2.5 % 97.5 % 254s 1|2 -2.66026726 -0.3965097 254s 2|3 -0.84699301 2.3807714 254s 3|4 -0.20754248 5.4117986 254s 4|5 -0.05973998 7.6521799 254s contactyes -0.08641802 2.4718668 254s tempwarm 0.46937383 3.6822133 254s lambda -1.03721940 2.0361024 254s > 254s > predict(fm, se=TRUE, interval = TRUE) 254s $fit 254s [1] 0.58209325 0.21518056 0.46054754 0.09103825 0.22383779 0.22383779 254s [7] 0.29286866 0.29286866 0.18610435 0.58209325 0.06269201 0.46054754 254s [13] 0.19716614 0.48293297 0.29286866 0.34021081 0.58209325 0.21518056 254s [19] 0.46054754 0.36913993 0.06939859 0.06939859 0.34021081 0.34021081 254s [25] 0.21518056 0.58209325 0.46054754 0.36913993 0.48293297 0.19716614 254s [31] 0.29286866 0.28974275 0.58209325 0.21518056 0.09103825 0.46054754 254s [37] 0.48293297 0.48293297 0.28974275 0.28974275 0.21518056 0.58209325 254s [43] 0.46054754 0.36913993 0.19716614 0.22383779 0.29286866 0.34021081 254s [49] 0.18610435 0.18610435 0.36913993 0.36913993 0.19716614 0.48293297 254s [55] 0.06897335 0.28974275 0.58209325 0.58209325 0.36913993 0.46054754 254s [61] 0.48293297 0.48293297 0.28974275 0.34021081 0.18610435 0.58209325 254s [67] 0.46054754 0.36913993 0.48293297 0.19716614 0.34021081 0.34021081 254s 254s $se.fit 254s [1] 0.14151187 0.09458704 0.10284384 0.06173010 0.06089158 0.06089158 254s [7] 0.17401323 0.17401323 0.08458282 0.14151187 0.03342713 0.10284384 254s [13] 0.06151480 0.16022480 0.17401323 0.14317221 0.14151187 0.09458704 254s [19] 0.10284384 0.09671235 0.16165494 0.16165494 0.14317221 0.14317221 254s [25] 0.09458704 0.14151187 0.10284384 0.09671235 0.16022480 0.06151480 254s [31] 0.17401323 0.08680263 0.14151187 0.09458704 0.06173010 0.10284384 254s [37] 0.16022480 0.16022480 0.08680263 0.08680263 0.09458704 0.14151187 254s [43] 0.10284384 0.09671235 0.06151480 0.06089158 0.17401323 0.14317221 254s [49] 0.08458282 0.08458282 0.09671235 0.09671235 0.06151480 0.16022480 254s [55] 0.03861752 0.08680263 0.14151187 0.14151187 0.09671235 0.10284384 254s [61] 0.16022480 0.16022480 0.08680263 0.14317221 0.08458282 0.14151187 254s [67] 0.10284384 0.09671235 0.16022480 0.06151480 0.14317221 0.14317221 254s 254s $lwr 254s [1] 0.3081470907 0.0838051152 0.2749859872 0.0226847131 0.1267084217 254s [6] 0.1267084217 0.0738941554 0.0738941554 0.0710944695 0.3081470907 254s [11] 0.0214631498 0.2749859872 0.1028661817 0.2098384787 0.0738941554 254s [16] 0.1287024772 0.3081470907 0.0838051152 0.2749859872 0.2058910207 254s [21] 0.0005517244 0.0005517244 0.1287024772 0.1287024772 0.0838051152 254s [26] 0.3081470907 0.2749859872 0.2058910207 0.2098384787 0.1028661817 254s [31] 0.0738941554 0.1514410900 0.3081470907 0.0838051152 0.0226847131 254s [36] 0.2749859872 0.2098384787 0.2098384787 0.1514410900 0.1514410900 254s [41] 0.0838051152 0.3081470907 0.2749859872 0.2058910207 0.1028661817 254s [46] 0.1267084217 0.0738941554 0.1287024772 0.0710944695 0.0710944695 254s [51] 0.2058910207 0.2058910207 0.1028661817 0.2098384787 0.0222866430 254s [56] 0.1514410900 0.3081470907 0.3081470907 0.2058910207 0.2749859872 254s [61] 0.2098384787 0.2098384787 0.1514410900 0.1287024772 0.0710944695 254s [66] 0.3081470907 0.2749859872 0.2058910207 0.2098384787 0.1028661817 254s [71] 0.1287024772 0.1287024772 254s 254s $upr 254s [1] 0.8132915 0.4511024 0.6577298 0.3017605 0.3643579 0.3643579 0.6825186 254s [8] 0.6825186 0.4058732 0.8132915 0.1694071 0.6577298 0.3446983 0.7666176 254s [15] 0.6825186 0.6428534 0.8132915 0.4511024 0.6577298 0.5690698 0.9097003 254s [22] 0.9097003 0.6428534 0.6428534 0.4511024 0.8132915 0.6577298 0.5690698 254s [29] 0.7666176 0.3446983 0.6825186 0.4825259 0.8132915 0.4511024 0.3017605 254s [36] 0.6577298 0.7666176 0.7666176 0.4825259 0.4825259 0.4511024 0.8132915 254s [43] 0.6577298 0.5690698 0.3446983 0.3643579 0.6825186 0.6428534 0.4058732 254s [50] 0.4058732 0.5690698 0.5690698 0.3446983 0.7666176 0.1940499 0.4825259 254s [57] 0.8132915 0.8132915 0.5690698 0.6577298 0.7666176 0.7666176 0.4825259 254s [64] 0.6428534 0.4058732 0.8132915 0.6577298 0.5690698 0.7666176 0.3446983 254s [71] 0.6428534 0.6428534 254s 254s > predict(fm, type="class") 254s $fit 254s [1] 2 2 3 3 3 3 4 4 2 2 3 3 3 3 4 4 2 2 3 3 3 3 4 4 2 2 3 3 3 3 4 4 2 2 3 3 3 3 254s [39] 4 4 2 2 3 3 3 3 4 4 2 2 3 3 3 3 4 4 2 2 3 3 3 3 4 4 2 2 3 3 3 3 4 4 254s Levels: 1 2 3 4 5 254s 254s > newData <- expand.grid(temp = c("cold", "warm"), 254s + contact = c("no", "yes")) 254s > 254s > ## Predicted probabilities in all five response categories for each of 254s > ## the four cases in newData: 254s > predict(fm, newdata=newData, type="prob") 254s $fit 254s 1 2 3 4 5 254s 1 0.186104347 0.58209325 0.2151806 0.01478353 0.001838315 254s 2 0.026664518 0.19716614 0.4829330 0.22383779 0.069398588 254s 3 0.062692012 0.36913993 0.4605475 0.09103825 0.016582262 254s 4 0.008204432 0.06897335 0.2897428 0.34021081 0.292868655 254s 254s > predict(fm, newdata=newData, type="class") 254s $fit 254s [1] 2 3 3 4 254s Levels: 1 2 3 4 5 254s 254s > 254s > predict(fm, newdata=newData, type="prob", se.fit = TRUE, interval = TRUE) 254s $fit 254s 1 2 3 4 5 254s 1 0.186104347 0.58209325 0.2151806 0.01478353 0.001838315 254s 2 0.026664518 0.19716614 0.4829330 0.22383779 0.069398588 254s 3 0.062692012 0.36913993 0.4605475 0.09103825 0.016582262 254s 4 0.008204432 0.06897335 0.2897428 0.34021081 0.292868655 254s 254s $se.fit 254s 1 2 3 4 5 254s 1 0.084582817 0.14151187 0.09458704 0.05105462 0.04225890 254s 2 0.018013146 0.06151480 0.16022480 0.06089158 0.16165494 254s 3 0.033427133 0.09671235 0.10284384 0.06173010 0.09203687 254s 4 0.009189041 0.03861752 0.08680263 0.14317221 0.17401323 254s 254s $lwr 254s 1 2 3 4 5 254s 1 0.0710944695 0.30814709 0.08380512 1.557841e-05 4.590852e-23 254s 2 0.0069799028 0.10286618 0.20983848 1.267084e-01 5.517244e-04 254s 3 0.0214631498 0.20589102 0.27498599 2.268471e-02 2.647288e-07 254s 4 0.0009036362 0.02228664 0.15144109 1.287025e-01 7.389416e-02 254s 254s $upr 254s 1 2 3 4 5 254s 1 0.40587324 0.8132915 0.4511024 0.9352884 1.0000000 254s 2 0.09647027 0.3446983 0.7666176 0.3643579 0.9097003 254s 3 0.16940714 0.5690698 0.6577298 0.3017605 0.9990698 254s 4 0.07033824 0.1940499 0.4825259 0.6428534 0.6825186 254s 254s > 254s > ######################################################################## 254s > ### Models with scale + flex link (or cauchit link) 254s > ######################################################################## 254s > 254s > fm <- clm(SURENESS ~ PRODID, scale=~PROD, data = soup, link="Aranda-Ordaz") 254s Changing to 'nlminb' optimizer for flexible link function 254s Warning message: 254s (-1) Model failed to converge with max|grad| = 0.000376367 (tol = 1e-06) 254s > summary(fm) 254s formula: SURENESS ~ PRODID 254s scale: ~PROD 254s data: soup 254s 254s link threshold nobs logLik AIC niter max.grad cond.H 254s Aranda-Ordaz flexible 1847 -2674.65 5373.30 57(720) 3.76e-04 9.0e+03 254s 254s Coefficients: 254s Estimate Std. Error z value Pr(>|z|) 254s PRODID2 1.3604 0.4137 3.289 0.001007 ** 254s PRODID3 2.2066 0.6659 3.314 0.000921 *** 254s PRODID4 1.2553 0.4086 3.072 0.002124 ** 254s PRODID5 1.9820 0.5886 3.367 0.000759 *** 254s PRODID6 2.4715 0.7713 3.204 0.001355 ** 254s --- 254s Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1 254s 254s log-scale coefficients: 254s Estimate Std. Error z value Pr(>|z|) 254s PRODTest 0.2807 0.1553 1.808 0.0706 . 254s --- 254s Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1 254s 254s Link coefficients: 254s Estimate Std. Error z value Pr(>|z|) 254s lambda 2.063 1.136 1.816 0.0693 . 254s --- 254s Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1 254s 254s Threshold coefficients: 254s Estimate Std. Error z value 254s 1|2 -1.3927 0.1491 -9.344 254s 2|3 -0.1449 0.3533 -0.410 254s 3|4 0.3051 0.4699 0.649 254s 4|5 0.6733 0.5802 1.160 254s 5|6 1.7210 0.9594 1.794 254s > 254s > fm <- clm(SURENESS ~ PRODID, scale=~PROD, data = soup, link="log-gamma") 254s Changing to 'nlminb' optimizer for flexible link function 257s Warning message: 257s (-1) Model failed to converge with max|grad| = 0.00281342 (tol = 1e-06) 257s > summary(fm) 257s formula: SURENESS ~ PRODID 257s scale: ~PROD 257s data: soup 257s 257s link threshold nobs logLik AIC niter max.grad cond.H 257s log-gamma flexible 1847 -2676.84 5377.68 79(1001) 2.81e-03 8.9e+03 257s 257s Coefficients: 257s Estimate Std. Error z value Pr(>|z|) 257s PRODID2 0.62876 0.09223 6.817 9.27e-12 *** 257s PRODID3 1.02757 0.13449 7.640 2.16e-14 *** 257s PRODID4 0.59158 0.11435 5.173 2.30e-07 *** 257s PRODID5 0.91937 0.12977 7.085 1.39e-12 *** 257s PRODID6 1.13202 0.13927 8.128 4.35e-16 *** 257s --- 257s Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1 257s 257s log-scale coefficients: 257s Estimate Std. Error z value Pr(>|z|) 257s PRODTest 0.09066 0.18405 0.493 0.622 257s 257s Link coefficients: 257s Estimate Std. Error z value Pr(>|z|) 257s lambda 0.4749 0.7031 0.675 0.499 257s 257s Threshold coefficients: 257s Estimate Std. Error z value 257s 1|2 -1.15648 0.45771 -2.527 257s 2|3 -0.47328 0.29574 -1.600 257s 3|4 -0.24744 0.26543 -0.932 257s 4|5 -0.07223 0.24987 -0.289 257s 5|6 0.37914 0.24135 1.571 257s Changing to 'nlminb' optimizer for flexible link function 257s > 257s > fm <- clm(SURENESS ~ PRODID, scale=~PROD, data = soup, link="cauchit") 257s > summary(fm) 257s formula: SURENESS ~ PRODID 257s scale: ~PROD 257s data: soup 257s 257s link threshold nobs logLik AIC niter max.grad cond.H 257s cauchit flexible 1847 -2679.34 5380.67 11(1) 3.10e-07 3.0e+02 257s 257s Coefficients: 257s Estimate Std. Error z value Pr(>|z|) 257s PRODID2 0.70550 0.09611 7.341 2.12e-13 *** 257s PRODID3 1.06186 0.13882 7.649 2.02e-14 *** 257s PRODID4 0.66876 0.11911 5.614 1.97e-08 *** 257s PRODID5 1.01135 0.13277 7.617 2.59e-14 *** 257s PRODID6 1.12784 0.14159 7.966 1.64e-15 *** 257s --- 257s Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1 257s 257s log-scale coefficients: 257s Estimate Std. Error z value Pr(>|z|) 257s PRODTest -0.20801 0.09524 -2.184 0.029 * 257s --- 257s Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1 257s 257s Threshold coefficients: 257s Estimate Std. Error z value 257s 1|2 -1.70920 0.14977 -11.412 257s 2|3 -0.36737 0.06302 -5.830 257s 3|4 -0.06736 0.05734 -1.175 257s 4|5 0.14657 0.05708 2.568 257s 5|6 0.67063 0.07072 9.483 257s > 257s > ######################################################################## 257s > ### clm.fit 257s > ######################################################################## 257s > 257s > ## Example with log-gamma: 257s > fm1 <- clm(rating ~ contact + temp, data=wine, link="log-gamma") 257s > summary(fm1) 257s formula: rating ~ contact + temp 257s data: wine 257s 257s Warning message: 257s (-1) Model failed to converge with max|grad| = 9.90148e-05 (tol = 1e-06) 257s link threshold nobs logLik AIC niter max.grad cond.H 257s log-gamma flexible 72 -85.72 185.44 27(179) 9.90e-05 5.9e+01 257s 257s Coefficients: 257s Estimate Std. Error z value Pr(>|z|) 257s contactyes 0.8614 0.2675 3.220 0.00128 ** 257s tempwarm 1.5072 0.2947 5.114 3.16e-07 *** 257s --- 257s Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1 257s 257s Link coefficients: 257s Estimate Std. Error z value Pr(>|z|) 257s lambda 0.1615 0.5752 0.281 0.779 257s 257s Threshold coefficients: 257s Estimate Std. Error z value 257s 1|2 -0.8798 0.5003 -1.759 257s 2|3 0.6678 0.3450 1.936 257s 3|4 1.9807 0.3826 5.177 257s 4|5 2.8593 0.4656 6.141 257s > ## get the model frame containing y and X: 257s > mf1 <- update(fm1, method="design") 257s > names(mf1) 257s [1] "y" "y.levels" "X" "offset" "terms" "contrasts" 257s [7] "xlevels" "weights" "doFit" "control" "link" "threshold" 257s [13] "start" "formulas" 257s > res <- clm.fit(mf1$y, mf1$X, link="log-gamma") ## invoking the factor method 257s Changing to 'nlminb' optimizer for flexible link function 257s > coef(res) 257s 1|2 2|3 3|4 4|5 contactyes tempwarm lambda 257s -0.8797774 0.6678307 1.9806826 2.8593125 0.8614400 1.5071959 0.1614741 257s > stopifnot(all.equal(coef(res), coef(fm1))) 257s Warning message: 257s (-1) Model failed to converge with max|grad| = 9.90148e-05 (tol = 1e-06) 257s > 257s > ## Example with Aranda-Ordaz: 257s > fm1 <- clm(rating ~ contact + temp, data=wine, link="Aranda-Ordaz") 257s Changing to 'nlminb' optimizer for flexible link function 257s > mf1 <- update(fm1, method="design") 257s Warning message: 257s (-1) Model failed to converge with max|grad| = 1.6288e-05 (tol = 1e-06) 257s > res <- clm.fit(mf1$y, mf1$X, link="Aranda") ## invoking the factor method 257s Changing to 'nlminb' optimizer for flexible link function 257s Warning message: 257s (-1) Model failed to converge with max|grad| = 1.6288e-05 (tol = 1e-06) 257s > stopifnot(all.equal(coef(res), coef(fm1))) 257s > 257s > 257s BEGIN TEST test.clm.model.matrix.R 257s 257s R version 4.4.3 (2025-02-28) -- "Trophy Case" 257s Copyright (C) 2025 The R Foundation for Statistical Computing 257s Platform: arm-unknown-linux-gnueabihf (32-bit) 257s 257s R is free software and comes with ABSOLUTELY NO WARRANTY. 257s You are welcome to redistribute it under certain conditions. 257s Type 'license()' or 'licence()' for distribution details. 257s 257s R is a collaborative project with many contributors. 257s Type 'contributors()' for more information and 257s 'citation()' on how to cite R or R packages in publications. 257s 257s Type 'demo()' for some demos, 'help()' for on-line help, or 257s 'help.start()' for an HTML browser interface to help. 257s Type 'q()' to quit R. 257s 257s > library(ordinal) 258s > ## source("test.clm.model.matrix.R") 258s > 258s > ## library(devtools) 258s > ## r2path <- "/Users/rhbc/Documents/Rpackages/ordinal/pkg/ordinal" 258s > ## clean_dll(pkg = r2path) 258s > ## load_all(r2path) 258s > 258s > ## Check that get_clmDesign works in standard setting: 258s > fm1 <- clm(rating ~ temp, scale=~contact, nominal=~contact, data=wine) 258s > contr <- c(fm1$contrasts, fm1$S.contrasts, fm1$nom.contrasts) 258s > XX <- ordinal:::get_clmDesign(fm1$model, terms(fm1, "all"), contrasts=contr) 258s > XX2 <- update(fm1, method="design") 258s > (keep <- intersect(names(XX), names(XX2))) 258s [1] "y" "y.levels" "X" "offset" 258s [5] "terms" "contrasts" "xlevels" "weights" 258s [9] "S" "S.terms" "S.off" "S.contrasts" 258s [13] "S.xlevels" "NOM" "nom.terms" "nom.contrasts" 258s [17] "nom.xlevels" 258s > (test <- mapply(function(x, y) isTRUE(all.equal(x, y)), 258s + XX[keep], XX2[keep])) 258s y y.levels X offset terms 258s TRUE TRUE TRUE TRUE TRUE 258s contrasts xlevels weights S S.terms 258s TRUE TRUE TRUE TRUE TRUE 258s S.off S.contrasts S.xlevels NOM nom.terms 258s TRUE TRUE TRUE TRUE TRUE 258s nom.contrasts nom.xlevels 258s TRUE TRUE 258s > stopifnot(all(test)) 258s > 258s > ## Check that get_clmDesign works with singular fit and NAs: 258s > cy <- with(wine, which(temp == "cold" & contact == "yes")) 258s > wine2 <- subset(wine, subset=(!1:nrow(wine) %in% cy)) 258s > wine2[c(9, 15, 46), "rating"] <- NA 258s > fm1 <- clm(rating ~ temp, scale=~contact, nominal=~contact, 258s + data=wine2) 258s Warning message: 258s (1) Hessian is numerically singular: parameters are not uniquely determined 258s In addition: Absolute convergence criterion was met, but relative criterion was not met 258s > contr <- c(fm1$contrasts, fm1$S.contrasts, fm1$nom.contrasts) 258s > XX <- ordinal:::get_clmDesign(fm1$model, terms(fm1, "all"), contrasts=contr) 258s > XX2 <- update(fm1, method="design") 258s > (keep <- intersect(names(XX), names(XX2))) 258s [1] "y" "y.levels" "X" "offset" 258s [5] "terms" "contrasts" "xlevels" "na.action" 258s [9] "weights" "S" "S.terms" "S.off" 258s [13] "S.contrasts" "S.xlevels" "NOM" "nom.terms" 258s [17] "nom.contrasts" "nom.xlevels" 258s > (test <- mapply(function(x, y) isTRUE(all.equal(x, y)), 258s + XX[keep], XX2[keep])) 258s y y.levels X offset terms 258s TRUE TRUE TRUE TRUE TRUE 258s contrasts xlevels na.action weights S 258s TRUE TRUE TRUE TRUE TRUE 258s S.terms S.off S.contrasts S.xlevels NOM 258s TRUE TRUE TRUE TRUE TRUE 258s nom.terms nom.contrasts nom.xlevels 258s TRUE TRUE TRUE 258s > stopifnot(all(test)) 258s > 258s > ## In this situation update and get_clmRho give the same results: 258s > wine2 <- wine 258s > fm1 <- clm(rating ~ temp + contact, data=wine2) ## OK 258s > rho1 <- ordinal:::get_clmRho.clm(fm1) 258s > l1 <- as.list(rho1) 258s > l2 <- as.list(update(fm1, doFit=FALSE)) 258s > (test <- mapply(function(x, y) isTRUE(all.equal(x, y)), 258s + l1, l2[names(l1)])) 258s nlambda link gfun dfun pfun par clm.hess clm.grad 258s TRUE TRUE TRUE TRUE TRUE TRUE TRUE TRUE 258s clm.nll wts fitted has.scale sigma k Soff S 258s TRUE TRUE TRUE TRUE TRUE TRUE TRUE TRUE 258s n.psi o2 o1 B2 B1 258s TRUE TRUE TRUE TRUE TRUE 258s > stopifnot(all(test)) 258s > ## If we modify the data (or other subset, weights, formulae, etc.) 258s > ## used in the model call, the results from update no longer correspond 258s > ## to the elements of the fitted model object. get_clmRho gets it 258s > ## right on the other hand: 258s > wine2[10:13, "rating"] <- NA 258s > l3 <- as.list(ordinal:::get_clmRho.clm(fm1)) 258s > l4 <- as.list(update(fm1, doFit=FALSE)) 258s > (test <- mapply(function(x, y) isTRUE(all.equal(x, y)), 258s + l1, l3)) 258s nlambda link gfun dfun pfun par clm.hess clm.grad 258s TRUE TRUE TRUE TRUE TRUE TRUE TRUE TRUE 258s clm.nll wts fitted has.scale sigma k Soff S 258s TRUE TRUE TRUE TRUE TRUE TRUE TRUE TRUE 258s n.psi o2 o1 B2 B1 258s TRUE TRUE TRUE TRUE TRUE 258s > stopifnot(all(test)) ## same 258s > (test <- mapply(function(x, y) isTRUE(all.equal(x, y)), 258s + l3, l4[names(l3)])) 258s nlambda link gfun dfun pfun par clm.hess clm.grad 258s TRUE TRUE TRUE TRUE TRUE TRUE TRUE TRUE 258s clm.nll wts fitted has.scale sigma k Soff S 258s TRUE FALSE FALSE TRUE FALSE TRUE FALSE TRUE 258s n.psi o2 o1 B2 B1 258s TRUE FALSE FALSE FALSE FALSE 258s > stopifnot(sum(!test) == 8) ## not all the same anymore! 258s > ## In conclusion l1, l2, and l3 are identical. l4 is different. 258s > 258s > ################################# 258s > ## Test that checkContrasts give appropriate warnings: 258s > contr <- c(temp="contr.sum", contact="contr.sum") 258s > fm1 <- clm(rating ~ temp + contact, scale=~contact, data=wine) ## OK 258s > fm1 <- clm(rating ~ temp + contact, scale=~contact, data=wine, 258s + contrasts=contr) ## OK 258s > fm1 <- clm(rating ~ temp, scale=~contact, data=wine, 258s + contrasts=contr) ## OK 258s Warning messages: 258s 1: In model.matrix.default(terms, data = fullmf, contrasts.arg = getContrasts(terms, : 258s non-list contrasts argument ignored 258s 2: In model.matrix.default(terms, data = fullmf, contrasts.arg = getContrasts(terms, : 258s non-list contrasts argument ignored 258s > ## These should give warnings: 258s > fm1 <- clm(rating ~ temp, contrasts=c(contact="contr.sum"), data=wine) 258s Warning messages: 258s 1: In model.matrix.default(terms, data = fullmf, contrasts.arg = getContrasts(terms, : 258s non-list contrasts argument ignored 258s 2: In model.matrix.default(terms, data = fullmf, contrasts.arg = getContrasts(terms, : 258s non-list contrasts argument ignored 258s Warning messages: 258s 1: variable 'contact' is absent: its contrasts will be ignored 258s 2: In model.matrix.default(terms, data = fullmf, contrasts.arg = getContrasts(terms, : 258s non-list contrasts argument ignored 258s > fm1 <- clm(rating ~ temp, contrasts=contr, data=wine) 258s > fm1 <- clm(rating ~ 1, scale=~contact, contrasts=c(temp="contr.sum"), 258s + data=wine) 258s Warning messages: 258s 1: variable 'contact' is absent: its contrasts will be ignored 258s 2: In model.matrix.default(terms, data = fullmf, contrasts.arg = getContrasts(terms, : 258s non-list contrasts argument ignored 258s Warning messages: 258s 1: variable 'temp' is absent: its contrasts will be ignored 258s 2: In model.matrix.default(terms, data = fullmf, contrasts.arg = getContrasts(terms, : 258s non-list contrasts argument ignored 258s 3: In model.matrix.default(terms, data = fullmf, contrasts.arg = getContrasts(terms, : 258s non-list contrasts argument ignored 258s > fm1 <- clm(rating ~ 1, scale=~contact, contrasts=list(temp="contr.sum"), 258s + data=wine) 258s > 258s > fm0 <- clm(rating ~ temp + contact, scale=~contact, data=wine) 258s Warning message: 258s variable 'temp' is absent: its contrasts will be ignored 258s > ordinal:::checkContrasts(fm0$S.terms, fm0$contrasts) 258s > ordinal:::checkContrasts(fm0$S.terms, fm0$S.contrasts) 258s > ordinal:::checkContrasts(fm0$terms, fm0$contrasts) 258s > ordinal:::checkContrasts(fm0$terms, fm0$S.contrasts) 258s > 258s > ################################# 258s > ## Check that clm and model.matrix respects contrast settings: 258s > options("contrasts" = c("contr.treatment", "contr.poly")) 258s > fm0 <- clm(rating ~ temp + contact, data=wine) 258s Warning message: 258s variable 'temp' is absent: its contrasts will be ignored 258s > options("contrasts" = c("contr.sum", "contr.poly")) 258s > fm1 <- clm(rating ~ temp + contact, data=wine) 258s > stopifnot(all(model.matrix(fm0)$X[, 2] %in% c(0, 1))) 258s > stopifnot(all(model.matrix(fm1)$X[, 2] %in% c(1, -1))) 258s > 258s > ################################# 258s > ## Check that model.matrix results do not depend on global contrast 258s > ## setting: 258s > options("contrasts" = c("contr.sum", "contr.poly")) 258s > fm0 <- clm(rating ~ temp + contact, scale=~contact, data=wine) 258s > MM <- model.matrix(fm0) 258s > options("contrasts" = c("contr.treatment", "contr.poly")) 258s > MM2 <- model.matrix(fm0) 258s > for(x in MM) print(head(x)) 258s (Intercept) temp1 contact1 258s 1 1 1 1 258s 2 1 1 1 258s 3 1 1 -1 258s 4 1 1 -1 258s 5 1 -1 1 258s 6 1 -1 1 258s (Intercept) contact1 258s 1 1 1 258s 2 1 1 258s 3 1 -1 258s 4 1 -1 258s 5 1 1 258s 6 1 1 258s > for(x in MM2) print(head(x)) 258s (Intercept) temp1 contact1 258s 1 1 1 1 258s 2 1 1 1 258s 3 1 1 -1 258s 4 1 1 -1 258s 5 1 -1 1 258s 6 1 -1 1 258s (Intercept) contact1 258s 1 1 1 258s 2 1 1 258s 3 1 -1 258s 4 1 -1 258s 5 1 1 258s 6 1 1 258s > stopifnot(all(mapply(all.equal, MM, MM2))) 258s > 258s > ################################# 258s > ## This gave a warning before getContrasts was implemented: 258s > fm0 <- clm(rating ~ temp + contact, scale=~contact, data=wine) 258s > MM <- model.matrix(fm0) 258s > ## > fm0 <- clm(rating ~ temp + contact, scale=~contact, data=wine) 258s > ## > MM <- model.matrix(fm0) 258s > ## Warning message: 258s > ## In model.matrix.default(res$S.terms, data = fullmf, contrasts.arg = getContrasts(res$S.terms, : 258s > ## variable 'temp' is absent, its contrast will be ignored 258s > for(x in MM) print(head(x)) 258s (Intercept) tempwarm contactyes 258s 1 1 0 0 258s 2 1 0 0 258s 3 1 0 1 258s 4 1 0 1 258s 5 1 1 0 258s 6 1 1 0 258s (Intercept) contactyes 258s 1 1 0 258s 2 1 0 258s 3 1 1 258s 4 1 1 258s 5 1 0 258s 6 1 0 258s > 258s > 258s BEGIN TEST test.clm.predict.R 258s 258s R version 4.4.3 (2025-02-28) -- "Trophy Case" 258s Copyright (C) 2025 The R Foundation for Statistical Computing 258s Platform: arm-unknown-linux-gnueabihf (32-bit) 258s 258s R is free software and comes with ABSOLUTELY NO WARRANTY. 258s You are welcome to redistribute it under certain conditions. 258s Type 'license()' or 'licence()' for distribution details. 258s 258s R is a collaborative project with many contributors. 258s Type 'contributors()' for more information and 258s 'citation()' on how to cite R or R packages in publications. 258s 258s Type 'demo()' for some demos, 'help()' for on-line help, or 258s 'help.start()' for an HTML browser interface to help. 258s Type 'q()' to quit R. 258s 258s > library(ordinal) 260s > ## source("test.clm.predict.R") 260s > 260s > ## library(devtools) 260s > ## r2path <- "/Users/rhbc/Documents/Rpackages/ordinal/pkg/ordinal" 260s > ## clean_dll(pkg = r2path) 260s > ## load_all(r2path) 260s > 260s > cy <- with(wine, which(temp == "cold" & contact == "yes")) 260s > options("contrasts" = c("contr.treatment", "contr.poly")) 260s > getOption("contrasts") 260s [1] "contr.treatment" "contr.poly" 260s > 260s > ## Example model 260s > 260s > wine1.clm <- clm(rating ~ temp*contact, subset = -cy, data = wine) 260s > summary(wine1.clm) 260s formula: rating ~ temp * contact 260s data: wine 260s subset: -cy 260s 260s link threshold nobs logLik AIC niter max.grad cond.H 260s logit flexible 54 -65.47 142.93 6(0) 2.80e-12 2.9e+01 260s 260s Coefficients: (1 not defined because of singularities) 260s Estimate Std. Error z value Pr(>|z|) 260s tempwarm 2.2892 0.7192 3.183 0.00146 ** 260s contactyes 1.6505 0.6698 2.464 0.01374 * 260s tempwarm:contactyes NA NA NA NA 260s --- 260s Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1 260s 260s Threshold coefficients: 260s Estimate Std. Error z value 260s 1|2 -1.3971 0.5728 -2.439 260s 2|3 1.1349 0.5262 2.157 260s 3|4 3.3351 0.6987 4.774 260s 4|5 4.7924 0.7996 5.994 260s > names(wine1.clm) 260s [1] "aliased" "alpha" "beta" "call" 260s [5] "coefficients" "cond.H" "contrasts" "control" 260s [9] "convergence" "df.residual" "edf" "fitted.values" 260s [13] "formula" "formulas" "gradient" "Hessian" 260s [17] "info" "link" "logLik" "maxGradient" 260s [21] "message" "model" "n" "niter" 260s [25] "nobs" "start" "terms" "Theta" 260s [29] "threshold" "tJac" "vcov" "xlevels" 260s [33] "y" "y.levels" 260s > 260s > wine.clm <- clm(rating~temp*contact, data=wine) 260s > summary(wine.clm) 260s formula: rating ~ temp * contact 260s data: wine 260s 260s link threshold nobs logLik AIC niter max.grad cond.H 260s logit flexible 72 -86.42 186.83 6(0) 5.22e-12 5.1e+01 260s 260s Coefficients: 260s Estimate Std. Error z value Pr(>|z|) 260s tempwarm 2.3212 0.7009 3.311 0.000928 *** 260s contactyes 1.3475 0.6604 2.041 0.041300 * 260s tempwarm:contactyes 0.3595 0.9238 0.389 0.697129 260s --- 260s Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1 260s 260s Threshold coefficients: 260s Estimate Std. Error z value 260s 1|2 -1.4113 0.5454 -2.588 260s 2|3 1.1436 0.5097 2.244 260s 3|4 3.3771 0.6382 5.292 260s 4|5 4.9420 0.7509 6.581 260s > names(wine.clm) 260s [1] "aliased" "alpha" "beta" "call" 260s [5] "coefficients" "cond.H" "contrasts" "control" 260s [9] "convergence" "df.residual" "edf" "fitted.values" 260s [13] "formula" "formulas" "gradient" "Hessian" 260s [17] "info" "link" "logLik" "maxGradient" 260s [21] "message" "model" "n" "niter" 260s [25] "nobs" "start" "terms" "Theta" 260s [29] "threshold" "tJac" "vcov" "xlevels" 260s [33] "y" "y.levels" 260s > ## Make sure the same elements are present with a rank deficient model 260s > ## fit: 260s > stopifnot(all(names(wine1.clm) == names(wine.clm))) 260s > 260s > ## With treatment contrasts: 260s > options("contrasts" = c("contr.treatment", "contr.poly")) 260s > wine.clm <- clm(rating~temp*contact, data=wine) 260s > coef(summary(wine.clm)) 260s Estimate Std. Error z value Pr(>|z|) 260s 1|2 -1.4112620 0.5453532 -2.5877943 9.659266e-03 260s 2|3 1.1435537 0.5096555 2.2437776 2.484671e-02 260s 3|4 3.3770825 0.6381617 5.2918913 1.210578e-07 260s 4|5 4.9419823 0.7509113 6.5813133 4.663108e-11 260s tempwarm 2.3211843 0.7009479 3.3114931 9.279953e-04 260s contactyes 1.3474604 0.6603557 2.0405072 4.129984e-02 260s tempwarm:contactyes 0.3595489 0.9238188 0.3891985 6.971293e-01 260s > head(model.matrix(wine.clm)$X) 260s (Intercept) tempwarm contactyes tempwarm:contactyes 260s 1 1 0 0 0 260s 2 1 0 0 0 260s 3 1 0 1 0 260s 4 1 0 1 0 260s 5 1 1 0 0 260s 6 1 1 0 0 260s > wine.clm$contrasts 260s $temp 260s [1] "contr.treatment" 260s 260s $contact 260s [1] "contr.treatment" 260s 260s > head(pred1 <- predict(wine.clm)$fit) 260s [1] 0.56229641 0.20864908 0.43467309 0.08938852 0.19028226 0.19028226 260s > 260s > ## With sum contrasts: 260s > options("contrasts" = c("contr.sum", "contr.poly")) 260s > wine.clm <- clm(rating~temp*contact, data=wine) 260s > coef(summary(wine.clm)) 260s Estimate Std. Error z value Pr(>|z|) 260s 1|2 -3.33547153 0.5253364 -6.3492103 2.164231e-10 260s 2|3 -0.78065590 0.2945538 -2.6503003 8.042025e-03 260s 3|4 1.45287292 0.3367529 4.3143590 1.600667e-05 260s 4|5 3.01777269 0.4813097 6.2699186 3.612370e-10 260s temp1 -1.25047935 0.2641023 -4.7348292 2.192396e-06 260s contact1 -0.76361743 0.2380971 -3.2071683 1.340485e-03 260s temp1:contact1 0.08988722 0.2309547 0.3891985 6.971293e-01 260s > head(model.matrix(wine.clm)$X) 260s (Intercept) temp1 contact1 temp1:contact1 260s 1 1 1 1 1 260s 2 1 1 1 1 260s 3 1 1 -1 -1 260s 4 1 1 -1 -1 260s 5 1 -1 1 -1 260s 6 1 -1 1 -1 260s > wine.clm$contrasts 260s $temp 260s [1] "contr.sum" 260s 260s $contact 260s [1] "contr.sum" 260s 260s > head(pred2 <- predict(wine.clm)$fit) 260s [1] 0.56229641 0.20864908 0.43467309 0.08938852 0.19028226 0.19028226 260s > 260s > ## Mixture of sum and treatment contrasts: 260s > options("contrasts" = c("contr.treatment", "contr.poly")) 260s > wine.clm <- clm(rating~temp*contact, data=wine, 260s + contrasts=list(temp="contr.sum")) 260s > coef(summary(wine.clm)) 260s Estimate Std. Error z value Pr(>|z|) 260s 1|2 -2.57185410 0.5227165 -4.92016984 8.646915e-07 260s 2|3 -0.01703847 0.3611634 -0.04717662 9.623725e-01 260s 3|4 2.21649036 0.4529312 4.89365773 9.897892e-07 260s 4|5 3.78139013 0.5957919 6.34683010 2.197966e-10 260s temp1 -1.16059213 0.3504740 -3.31149309 9.279953e-04 260s contactyes 1.52723487 0.4761942 3.20716830 1.340485e-03 260s temp1:contactyes -0.17977444 0.4619094 -0.38919847 6.971293e-01 260s > head(model.matrix(wine.clm)$X) 260s (Intercept) temp1 contactyes temp1:contactyes 260s 1 1 1 0 0 260s 2 1 1 0 0 260s 3 1 1 1 1 260s 4 1 1 1 1 260s 5 1 -1 0 0 260s 6 1 -1 0 0 260s > wine.clm$contrasts 260s $temp 260s [1] "contr.sum" 260s 260s $contact 260s [1] "contr.treatment" 260s 260s > head(pred3 <- predict(wine.clm)$fit) 260s [1] 0.56229641 0.20864908 0.43467309 0.08938852 0.19028226 0.19028226 260s > 260s > stopifnot(isTRUE(all.equal(pred1, pred2))) 260s > stopifnot(isTRUE(all.equal(pred1, pred3))) 260s > 260s > ################################# 260s > ### Now for a rank deficient fit: 260s > ################################# 260s > 260s > cy <- with(wine, which(temp == "cold" & contact == "yes")) 260s > options("contrasts" = c("contr.treatment", "contr.poly")) 260s > wine1.clm <- clm(rating ~ temp*contact, subset = -cy, data = wine) 260s > coef(summary(wine1.clm)) 260s Estimate Std. Error z value Pr(>|z|) 260s 1|2 -1.397134 0.5727918 -2.439164 1.472127e-02 260s 2|3 1.134907 0.5261653 2.156940 3.101038e-02 260s 3|4 3.335090 0.6986647 4.773521 1.810331e-06 260s 4|5 4.792428 0.7995580 5.993846 2.049352e-09 260s tempwarm 2.289221 0.7191705 3.183140 1.456870e-03 260s contactyes 1.650538 0.6698484 2.464047 1.373782e-02 260s tempwarm:contactyes NA NA NA NA 260s > attributes(model.matrix(wine1.clm)$X)$contrasts 260s $temp 260s [1] "contr.treatment" 260s 260s $contact 260s [1] "contr.treatment" 260s 260s > wine1.clm$contrasts 260s $temp 260s [1] "contr.treatment" 260s 260s $contact 260s [1] "contr.treatment" 260s 260s > head(pred4 <- predict(wine1.clm)$fit) 260s [1] 0.5584719 0.2088699 0.1843854 0.1843854 0.2988733 0.2988733 260s > 260s > options("contrasts" = c("contr.sum", "contr.poly")) 260s > wine1.clm <- clm(rating ~ temp*contact, subset = -cy, data = wine) 260s > attributes(model.matrix(wine1.clm)$X)$contrasts 260s $temp 260s [1] "contr.sum" 260s 260s $contact 260s [1] "contr.sum" 260s 260s > options("contrasts" = c("contr.treatment", "contr.poly")) 260s > attributes(model.matrix(wine1.clm)$X)$contrasts 260s $temp 260s [1] "contr.sum" 260s 260s $contact 260s [1] "contr.sum" 260s 260s > ## Notice that the contrasts change in the attributes of the fit!!! 260s > coef(summary(wine1.clm)) 260s Estimate Std. Error z value Pr(>|z|) 260s 1|2 -3.3670128 0.6149672 -5.475110 4.372411e-08 260s 2|3 -0.8349725 0.4231096 -1.973419 4.844787e-02 260s 3|4 1.3652108 0.4310181 3.167409 1.538037e-03 260s 4|5 2.8225483 0.5190089 5.438343 5.377826e-08 260s temp1 -1.1446104 0.3595853 -3.183140 1.456870e-03 260s contact1 -0.8252689 0.3349242 -2.464047 1.373782e-02 260s temp1:contact1 NA NA NA NA 260s > wine1.clm$contrasts 260s $temp 260s [1] "contr.sum" 260s 260s $contact 260s [1] "contr.sum" 260s 260s > head(pred5 <- predict(wine1.clm)$fit) 260s [1] 0.5584719 0.2088699 0.1843854 0.1843854 0.2988733 0.2988733 260s > 260s > head(cbind(pred4, pred5)) 260s pred4 pred5 260s [1,] 0.5584719 0.5584719 260s [2,] 0.2088699 0.2088699 260s [3,] 0.1843854 0.1843854 260s [4,] 0.1843854 0.1843854 260s [5,] 0.2988733 0.2988733 260s [6,] 0.2988733 0.2988733 260s > stopifnot(isTRUE(all.equal(pred4, pred5))) 260s > 260s > options("contrasts" = c("contr.treatment", "contr.poly")) 260s > wine1.clm <- clm(rating ~ temp*contact, subset = -cy, data = wine, 260s + contrasts=list(temp="contr.sum")) 260s > coef(summary(wine1.clm)) 260s Estimate Std. Error z value Pr(>|z|) 260s 1|2 -2.54174387 0.5792622 -4.38789851 1.144512e-05 260s 2|3 -0.00970353 0.3737929 -0.02595964 9.792895e-01 260s 3|4 2.19047975 0.4965589 4.41131906 1.027428e-05 260s 4|5 3.64781729 0.6257007 5.82997171 5.543677e-09 260s temp1 -1.14461036 0.3595853 -3.18314035 1.456870e-03 260s contactyes 1.65053789 0.6698484 2.46404685 1.373782e-02 260s temp1:contactyes NA NA NA NA 260s > head(model.matrix(wine1.clm)$X) 260s (Intercept) temp1 contactyes temp1:contactyes 260s 1 1 1 0 0 260s 2 1 1 0 0 260s 5 1 -1 0 0 260s 6 1 -1 0 0 260s 7 1 -1 1 -1 260s 8 1 -1 1 -1 260s > attributes(model.matrix(wine1.clm)$X)$contrasts 260s $temp 260s [1] "contr.sum" 260s 260s $contact 260s [1] "contr.treatment" 260s 260s > wine1.clm$contrasts 260s $temp 260s [1] "contr.sum" 260s 260s $contact 260s [1] "contr.treatment" 260s 260s > head(pred6 <- predict(wine1.clm)$fit) 260s [1] 0.5584719 0.2088699 0.1843854 0.1843854 0.2988733 0.2988733 260s > 260s > head(cbind(pred4, pred5, pred6)) 260s pred4 pred5 pred6 260s [1,] 0.5584719 0.5584719 0.5584719 260s [2,] 0.2088699 0.2088699 0.2088699 260s [3,] 0.1843854 0.1843854 0.1843854 260s [4,] 0.1843854 0.1843854 0.1843854 260s [5,] 0.2988733 0.2988733 0.2988733 260s [6,] 0.2988733 0.2988733 0.2988733 260s > stopifnot(isTRUE(all.equal(pred4, pred6))) 260s > ################################################################## 260s > 260s > ## Compare equality of fitted values for models with different contrasts: 260s > options("contrasts" = c("contr.treatment", "contr.poly")) 260s > fm1 <- clm(rating ~ temp + contact, data=wine) 260s > fitted(fm1) 260s [1] 0.57064970 0.19229094 0.44305990 0.09582084 0.20049402 0.20049402 260s [7] 0.27378469 0.27378469 0.20679013 0.57064970 0.05354601 0.44305990 260s [13] 0.20141572 0.50157554 0.27378469 0.36359581 0.57064970 0.19229094 260s [19] 0.44305990 0.37764614 0.07562701 0.07562701 0.36359581 0.36359581 260s [25] 0.19229094 0.57064970 0.44305990 0.37764614 0.50157554 0.20141572 260s [31] 0.27378469 0.30420994 0.57064970 0.19229094 0.09582084 0.44305990 260s [37] 0.50157554 0.50157554 0.30420994 0.30420994 0.19229094 0.57064970 260s [43] 0.44305990 0.37764614 0.20141572 0.20049402 0.27378469 0.36359581 260s [49] 0.20679013 0.20679013 0.37764614 0.37764614 0.20141572 0.50157554 260s [55] 0.05380128 0.30420994 0.57064970 0.57064970 0.37764614 0.44305990 260s [61] 0.50157554 0.50157554 0.30420994 0.36359581 0.20679013 0.57064970 260s [67] 0.44305990 0.37764614 0.50157554 0.20141572 0.36359581 0.36359581 260s > options("contrasts" = c("contr.sum", "contr.poly")) 260s > fm2 <- clm(rating ~ temp + contact, data=wine) 260s > fitted(fm2) 260s [1] 0.57064970 0.19229094 0.44305990 0.09582084 0.20049402 0.20049402 260s [7] 0.27378469 0.27378469 0.20679013 0.57064970 0.05354601 0.44305990 260s [13] 0.20141572 0.50157554 0.27378469 0.36359581 0.57064970 0.19229094 260s [19] 0.44305990 0.37764614 0.07562701 0.07562701 0.36359581 0.36359581 260s [25] 0.19229094 0.57064970 0.44305990 0.37764614 0.50157554 0.20141572 260s [31] 0.27378469 0.30420994 0.57064970 0.19229094 0.09582084 0.44305990 260s [37] 0.50157554 0.50157554 0.30420994 0.30420994 0.19229094 0.57064970 260s [43] 0.44305990 0.37764614 0.20141572 0.20049402 0.27378469 0.36359581 260s [49] 0.20679013 0.20679013 0.37764614 0.37764614 0.20141572 0.50157554 260s [55] 0.05380128 0.30420994 0.57064970 0.57064970 0.37764614 0.44305990 260s [61] 0.50157554 0.50157554 0.30420994 0.36359581 0.20679013 0.57064970 260s [67] 0.44305990 0.37764614 0.50157554 0.20141572 0.36359581 0.36359581 260s > options("contrasts" = c("contr.treatment", "contr.poly")) 260s > fm3 <- clm(rating ~ temp + contact, data=wine, 260s + contrasts=list(contact="contr.sum")) 260s > fitted(fm3) 260s [1] 0.57064970 0.19229094 0.44305990 0.09582084 0.20049402 0.20049402 260s [7] 0.27378469 0.27378469 0.20679013 0.57064970 0.05354601 0.44305990 260s [13] 0.20141572 0.50157554 0.27378469 0.36359581 0.57064970 0.19229094 260s [19] 0.44305990 0.37764614 0.07562701 0.07562701 0.36359581 0.36359581 260s [25] 0.19229094 0.57064970 0.44305990 0.37764614 0.50157554 0.20141572 260s [31] 0.27378469 0.30420994 0.57064970 0.19229094 0.09582084 0.44305990 260s [37] 0.50157554 0.50157554 0.30420994 0.30420994 0.19229094 0.57064970 260s [43] 0.44305990 0.37764614 0.20141572 0.20049402 0.27378469 0.36359581 260s [49] 0.20679013 0.20679013 0.37764614 0.37764614 0.20141572 0.50157554 260s [55] 0.05380128 0.30420994 0.57064970 0.57064970 0.37764614 0.44305990 260s [61] 0.50157554 0.50157554 0.30420994 0.36359581 0.20679013 0.57064970 260s [67] 0.44305990 0.37764614 0.50157554 0.20141572 0.36359581 0.36359581 260s > stopifnot(isTRUE(all.equal(fitted(fm1), fitted(fm2)))) 260s > stopifnot(isTRUE(all.equal(fitted(fm1), fitted(fm3)))) 260s > 260s > ################################################################## 260s > ## Compare equality of fitted values for models with different 260s > ## contrasts in face of aliased coefficients: 260s > options("contrasts" = c("contr.treatment", "contr.poly")) 260s > cy <- with(wine, which(temp == "cold" & contact == "yes")) 260s > Wine <- subset(wine, subset=!(temp == "cold" & contact == "yes")) 260s > fm1 <- clm(rating ~ temp + contact, data=Wine) 260s > options("contrasts" = c("contr.sum", "contr.poly")) 260s > fm2 <- clm(rating ~ temp + contact, data=Wine) 260s > options("contrasts" = c("contr.treatment", "contr.poly")) 260s > fm3 <- clm(rating ~ temp + contact, data=Wine, 260s + contrasts=list(contact="contr.sum")) 260s > 260s > stopifnot(isTRUE(all.equal(fitted(fm1), fitted(fm2)))) 260s > stopifnot(isTRUE(all.equal(fitted(fm1), fitted(fm3)))) 260s > stopifnot(isTRUE(all.equal(predict(fm1)$fit, predict(fm2)$fit))) 260s > stopifnot(isTRUE(all.equal(predict(fm1)$fit, predict(fm3)$fit))) 260s > 260s > ################################# 260s > ## Does this also happen if the wine data has changed? 260s > options("contrasts" = c("contr.treatment", "contr.poly")) 260s > Wine <- subset(wine, subset=!(temp == "cold" & contact == "yes")) 260s > fm1 <- clm(rating ~ temp + contact, data=Wine) 260s > fit1 <- fitted(fm1) 260s > pred1 <- predict(fm1)$fit 260s > Wine <- wine 260s > pred2 <- predict(fm1)$fit 260s > stopifnot(isTRUE(all.equal(fit1, pred1))) 260s > stopifnot(isTRUE(all.equal(fit1, pred2))) 260s > 260s > ## What if weights, say, is an expression? 260s > ## Notice that updating the model object changes it: 260s > set.seed(123) 260s > fm1 <- clm(rating ~ temp + contact, data=wine, 260s + weights=runif(nrow(wine), .5, 1.5)) 260s > fm2 <- update(fm1) 260s > stopifnot(isTRUE(all.equal(fitted(fm1), predict(fm1)$fit))) 260s > stopifnot(!isTRUE(all.equal(fitted(fm1), fitted(fm2)))) 260s > 260s > ################################# 260s > ## Test equality of fits and predictions of models with: 260s > ## 'x + I(x^2)' and 'poly(x, 2)': 260s > ## December 25th 2014, RHBC. 260s > data(wine) 260s > set.seed(1) 260s > x <- rnorm(nrow(wine), sd=2) + as.numeric(wine$rating) 260s > range(x) 260s [1] -1.429400 7.803236 260s > 260s > ## Comparison of 'x + I(x^2)' and 'poly(x, 2)': 260s > fm3 <- clm(rating ~ temp + x + I(x^2), data=wine) 260s > fm4 <- clm(rating ~ temp + poly(x, 2), data=wine) 260s > ## Same model fits, but different parameterizations: 260s > stopifnot( 260s + !isTRUE(all.equal(coef(fm3), coef(fm4), check.names=FALSE)) 260s + ) 260s > stopifnot(isTRUE(all.equal(logLik(fm3), logLik(fm4)))) 260s > newData <- expand.grid(temp = levels(wine$temp), 260s + x=seq(-1, 7, 3)) 260s > predict(fm3, newdata=newData)$fit 260s 1 2 3 4 5 260s 1 0.206057293 0.56152859 0.2029812 0.0245885 0.004844463 260s 2 0.036289668 0.28766182 0.5031703 0.1404155 0.032462707 260s 3 0.147105364 0.53988789 0.2693657 0.0363691 0.007271946 260s 4 0.024413857 0.21711772 0.5192073 0.1912002 0.048060899 260s 5 0.035397238 0.28292433 0.5050762 0.1433185 0.033283705 260s 6 0.005296054 0.05815716 0.3400568 0.4047024 0.191787585 260s > predict(fm4, newdata=newData)$fit 260s 1 2 3 4 5 260s 1 0.206057293 0.56152859 0.2029812 0.0245885 0.004844463 260s 2 0.036289668 0.28766182 0.5031703 0.1404155 0.032462707 260s 3 0.147105364 0.53988789 0.2693657 0.0363691 0.007271946 260s 4 0.024413857 0.21711772 0.5192073 0.1912002 0.048060899 260s 5 0.035397238 0.28292433 0.5050762 0.1433185 0.033283705 260s 6 0.005296054 0.05815716 0.3400568 0.4047024 0.191787585 260s > stopifnot(isTRUE(all.equal(fitted(fm3), fitted(fm4)))) 260s > stopifnot(isTRUE( 260s + all.equal(predict(fm3, newdata=newData)$fit, 260s + predict(fm4, newdata=newData)$fit))) 260s > ################################# 260s > 260s BEGIN TEST test.clm.profile.R 260s 260s R version 4.4.3 (2025-02-28) -- "Trophy Case" 260s Copyright (C) 2025 The R Foundation for Statistical Computing 260s Platform: arm-unknown-linux-gnueabihf (32-bit) 260s 260s R is free software and comes with ABSOLUTELY NO WARRANTY. 260s You are welcome to redistribute it under certain conditions. 260s Type 'license()' or 'licence()' for distribution details. 260s 260s R is a collaborative project with many contributors. 260s Type 'contributors()' for more information and 260s 'citation()' on how to cite R or R packages in publications. 260s 260s Type 'demo()' for some demos, 'help()' for on-line help, or 260s 'help.start()' for an HTML browser interface to help. 260s Type 'q()' to quit R. 260s 260s > library(ordinal) 261s > 261s > ## Testing that the profile remains the same - that the model object 261s > ## is not 'distorted' by update(object/fitted, doFit=FALSE) 261s > set.seed(1234) 261s > wts <- runif(nrow(wine), 0, 2) 261s > fm3 <- clm(rating ~ temp + contact, data=wine, 261s + weights=wts) 261s > pr <- profile(fm3) 261s > 261s > set.seed(1234) 261s > fm3 <- clm(rating ~ temp + contact, data=wine, 261s + weights=runif(nrow(wine), 0, 2)) 261s > pr3 <- profile(fm3) 261s > ## > set.seed(1234) 261s > ## > fm3 <- clm(rating ~ temp + contact, data=wine, 261s > ## + weights=runif(nrow(wine), 0, 2)) 261s > ## > pr3 <- profile(fm3) 261s > ## Warning messages: 261s > ## 1: In profile.clm.beta(fitted, which.beta, alpha, max.steps, nsteps, : 261s > ## profile may be unreliable for tempwarm because only 1 261s > ## steps were taken down 261s > ## 2: In profile.clm.beta(fitted, which.beta, alpha, max.steps, nsteps, : 261s > ## profile may be unreliable for tempwarm because only 1 261s > ## steps were taken up 261s > ## 3: In profile.clm.beta(fitted, which.beta, alpha, max.steps, nsteps, : 261s > ## profile may be unreliable for contactyes because only 1 261s > ## steps were taken down 261s > ## 4: In profile.clm.beta(fitted, which.beta, alpha, max.steps, nsteps, : 261s > ## profile may be unreliable for contactyes because only 1 261s > ## steps were taken up 261s > ## 261s > stopifnot(isTRUE(all.equal(pr, pr3, check.attributes=FALSE))) 261s > stopifnot( 261s + isTRUE(all.equal(pr$tempwarm[, "lroot"], pr3$tempwarm[, "lroot"])), 261s + isTRUE(all.equal(pr$contactyes[, "lroot"], pr3$contactyes[, "lroot"]))) 261s > 261s BEGIN TEST test.clm.single.anova.R 261s 261s R version 4.4.3 (2025-02-28) -- "Trophy Case" 261s Copyright (C) 2025 The R Foundation for Statistical Computing 261s Platform: arm-unknown-linux-gnueabihf (32-bit) 261s 261s R is free software and comes with ABSOLUTELY NO WARRANTY. 261s You are welcome to redistribute it under certain conditions. 261s Type 'license()' or 'licence()' for distribution details. 261s 261s R is a collaborative project with many contributors. 261s Type 'contributors()' for more information and 261s 'citation()' on how to cite R or R packages in publications. 261s 261s Type 'demo()' for some demos, 'help()' for on-line help, or 261s 'help.start()' for an HTML browser interface to help. 261s Type 'q()' to quit R. 261s 261s > # test.clm.single.anova.R 261s > 261s > library(ordinal) 262s > 262s > # WRE says "using if(requireNamespace("pkgname")) is preferred, if possible." 262s > # even in tests: 262s > assertError <- function(expr, ...) 262s + if(requireNamespace("tools")) tools::assertError(expr, ...) else invisible() 262s > assertWarning <- function(expr, ...) 262s + if(requireNamespace("tools")) tools::assertWarning(expr, ...) else invisible() 262s > 262s > fm <- clm(rating ~ temp * contact, scale=~contact, data=wine) 262s > 262s > anova(fm, type="I") 262s Type I Analysis of Deviance Table with Wald chi-square tests 262s 262s Df Chisq Pr(>Chisq) 262s temp 1 17.1046 3.538e-05 *** 262s contact 1 9.1574 0.002477 ** 262s temp:contact 1 0.1097 0.740512 262s --- 262s Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1 262s > anova(fm, type="II") 262s Type II Analysis of Deviance Table with Wald chi-square tests 262s 262s Df Chisq Pr(>Chisq) 262s temp 1 17.1046 3.538e-05 *** 262s contact 1 9.1574 0.002477 ** 262s temp:contact 1 0.1097 0.740512 262s --- 262s Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1 262s > anova(fm, type="III") 262s Type III Analysis of Deviance Table with Wald chi-square tests 262s 262s Df Chisq Pr(>Chisq) 262s temp 1 9.5681 0.00198 ** 262s contact 1 4.1830 0.04083 * 262s temp:contact 1 0.1097 0.74051 262s --- 262s Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1 262s > anova(fm, type=1) 262s Type I Analysis of Deviance Table with Wald chi-square tests 262s 262s Df Chisq Pr(>Chisq) 262s temp 1 17.1046 3.538e-05 *** 262s contact 1 9.1574 0.002477 ** 262s temp:contact 1 0.1097 0.740512 262s --- 262s Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1 262s > anova(fm, type=2) 262s Type II Analysis of Deviance Table with Wald chi-square tests 262s 262s Df Chisq Pr(>Chisq) 262s temp 1 17.1046 3.538e-05 *** 262s contact 1 9.1574 0.002477 ** 262s temp:contact 1 0.1097 0.740512 262s --- 262s Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1 262s > anova(fm, type=3) 262s Type III Analysis of Deviance Table with Wald chi-square tests 262s 262s Df Chisq Pr(>Chisq) 262s temp 1 9.5681 0.00198 ** 262s contact 1 4.1830 0.04083 * 262s temp:contact 1 0.1097 0.74051 262s --- 262s Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1 262s > anova(fm, type="1") 262s Type I Analysis of Deviance Table with Wald chi-square tests 262s 262s Df Chisq Pr(>Chisq) 262s temp 1 17.1046 3.538e-05 *** 262s contact 1 9.1574 0.002477 ** 262s temp:contact 1 0.1097 0.740512 262s --- 262s Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1 262s > anova(fm, type="2") 262s Type II Analysis of Deviance Table with Wald chi-square tests 262s 262s Df Chisq Pr(>Chisq) 262s temp 1 17.1046 3.538e-05 *** 262s contact 1 9.1574 0.002477 ** 262s temp:contact 1 0.1097 0.740512 262s --- 262s Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1 262s > anova(fm, type="3") 262s Type III Analysis of Deviance Table with Wald chi-square tests 262s 262s Df Chisq Pr(>Chisq) 262s temp 1 9.5681 0.00198 ** 262s contact 1 4.1830 0.04083 * 262s temp:contact 1 0.1097 0.74051 262s --- 262s Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1 262s > anova(fm, type="marginal") 262s Marginal Analysis of Deviance Table with Wald chi-square tests 262s 262s Df Chisq Pr(>Chisq) 262s temp 1 9.5681 0.00198 ** 262s contact 1 4.1830 0.04083 * 262s temp:contact 1 0.1097 0.74051 262s --- 262s Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1 262s > 262s > # Nominal effects: 262s > fm <- clm(rating ~ temp, nominal=~contact, data=wine) 262s > anova(fm) 263s Type I Analysis of Deviance Table with Wald chi-square tests 263s 263s Df Chisq Pr(>Chisq) 263s temp 1 22.166 2.501e-06 *** 263s --- 263s Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1 263s > 263s > # Flexible links: 263s > fm1 <- clm(rating ~ temp + contact, link="log-gamma", data=wine) 263s Changing to 'nlminb' optimizer for flexible link function 263s Warning message: 263s (-1) Model failed to converge with max|grad| = 9.89593e-05 (tol = 1e-06) 263s > anova(fm1, type=1) 263s Type I Analysis of Deviance Table with Wald chi-square tests 263s 263s Df Chisq Pr(>Chisq) 263s temp 1 26.150 3.16e-07 *** 263s contact 1 10.369 0.001282 ** 263s --- 263s Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1 263s > anova(fm1, type=2) 263s Type II Analysis of Deviance Table with Wald chi-square tests 263s 263s Df Chisq Pr(>Chisq) 263s temp 1 26.150 3.16e-07 *** 263s contact 1 10.369 0.001282 ** 263s --- 263s Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1 263s > anova(fm1, type=3) 263s Type III Analysis of Deviance Table with Wald chi-square tests 263s 263s Df Chisq Pr(>Chisq) 263s temp 1 26.150 3.16e-07 *** 263s contact 1 10.369 0.001282 ** 263s --- 263s Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1 263s > 263s > # Equivalence of tests irrespective of contrasts: 263s > fm1 <- clm(SURENESS ~ PRODID * SOUPFREQ, data=soup) 263s > # summary(fm1) 263s > (an1 <- anova(fm1, type=3)) 263s Type III Analysis of Deviance Table with Wald chi-square tests 263s 263s Df Chisq Pr(>Chisq) 263s PRODID 5 72.5901 2.959e-14 *** 263s SOUPFREQ 2 1.8132 0.4039 263s PRODID:SOUPFREQ 10 8.5837 0.5720 263s --- 263s Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1 263s > fm2 <- clm(SURENESS ~ PRODID * SOUPFREQ, data=soup, 263s + contrasts = list(SOUPFREQ = "contr.sum", PRODID = "contr.SAS")) 263s > # summary(fm2) 263s > anova(fm1, fm2) 263s Likelihood ratio tests of cumulative link models: 263s 263s formula: link: threshold: 263s fm1 SURENESS ~ PRODID * SOUPFREQ logit flexible 263s fm2 SURENESS ~ PRODID * SOUPFREQ logit flexible 263s 263s no.par AIC logLik LR.stat df Pr(>Chisq) 263s fm1 22 5388 -2672 263s fm2 22 5388 -2672 0 0 263s > (an2 <- anova(fm2, type=3)) 263s Type III Analysis of Deviance Table with Wald chi-square tests 263s 263s Df Chisq Pr(>Chisq) 263s PRODID 5 72.5901 2.959e-14 *** 263s SOUPFREQ 2 1.8132 0.4039 263s PRODID:SOUPFREQ 10 8.5837 0.5720 263s --- 263s Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1 263s > stopifnot( 263s + isTRUE(all.equal(an1, an2, check.attributes=FALSE)) 263s + ) 263s > 263s > 263s > # Aliased coefficients: 263s > fm1 <- clm(SURENESS ~ PRODID * DAY, data=soup) 263s > anova(fm1, type=1) 263s Type I Analysis of Deviance Table with Wald chi-square tests 263s 263s Df Chisq Pr(>Chisq) 263s PRODID 5 185.2017 < 2e-16 *** 263s DAY 1 4.1131 0.04255 * 263s PRODID:DAY 4 5.1186 0.27534 263s --- 263s Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1 263s > anova(fm1, type=2) 263s Type II Analysis of Deviance Table with Wald chi-square tests 263s 263s Df Chisq Pr(>Chisq) 263s PRODID 5 181.5967 < 2e-16 *** 263s DAY 1 4.1131 0.04255 * 263s PRODID:DAY 4 5.1186 0.27534 263s --- 263s Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1 263s > anova(fm1, type=3) 263s Missing cells for: PRODID3:DAY2. 263s Interpret type III hypotheses with care. 263s Type III Analysis of Deviance Table with Wald chi-square tests 263s 263s Df Chisq Pr(>Chisq) 263s PRODID 5 76.3722 4.81e-15 *** 263s DAY 1 10.1485 0.001444 ** 263s PRODID:DAY 4 5.1186 0.275344 263s --- 263s Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1 263s > 263s > # Aliased term (due to nominal effects): 263s > fm <- clm(rating ~ temp * contact, nominal=~contact, data=wine) 263s > anova(fm, type=1) 263s Type I Analysis of Deviance Table with Wald chi-square tests 263s 263s Df Chisq Pr(>Chisq) 263s temp 1 22.066 2.634e-06 *** 263s contact 263s temp:contact 1 0.250 0.6171 263s --- 263s Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1 263s > anova(fm, type=2) 263s Type II Analysis of Deviance Table with Wald chi-square tests 263s 263s Df Chisq Pr(>Chisq) 263s temp 1 22.066 2.634e-06 *** 263s contact 263s temp:contact 1 0.250 0.6171 263s --- 263s Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1 263s > anova(fm, type=3) 263s Type III Analysis of Deviance Table with Wald chi-square tests 263s 263s Df Chisq Pr(>Chisq) 263s temp 1 9.6335 0.001911 ** 263s contact 263s temp:contact 1 0.2500 0.617071 263s --- 263s Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1 263s > 263s > # model with all NA in vcov(object): 263s > fm <- clm(rating ~ temp * contact, nominal=~contact, scale=~contact, data=wine) 263s > assertError(anova(fm, type=1)) # error 263s Warning message: 263s (1) Hessian is numerically singular: parameters are not uniquely determined 263s In addition: Absolute convergence criterion was met, but relative criterion was not met 263s Loading required namespace: tools 263s > assertError(anova(fm, type=2)) # error 263s > assertError(anova(fm, type=3)) # error 263s > all(is.na(vcov(fm))) 263s [1] TRUE 263s > 263s BEGIN TEST test.general.R 263s 263s R version 4.4.3 (2025-02-28) -- "Trophy Case" 263s Copyright (C) 2025 The R Foundation for Statistical Computing 263s Platform: arm-unknown-linux-gnueabihf (32-bit) 263s 263s R is free software and comes with ABSOLUTELY NO WARRANTY. 263s You are welcome to redistribute it under certain conditions. 263s Type 'license()' or 'licence()' for distribution details. 263s 263s R is a collaborative project with many contributors. 263s Type 'contributors()' for more information and 263s 'citation()' on how to cite R or R packages in publications. 263s 263s Type 'demo()' for some demos, 'help()' for on-line help, or 263s 'help.start()' for an HTML browser interface to help. 263s Type 'q()' to quit R. 263s 263s > 263s > txt <- citation("ordinal") 263s > stopifnot(as.logical(grep("year", txt))) 263s > 263s BEGIN TEST test.makeThresholds.R 263s 263s R version 4.4.3 (2025-02-28) -- "Trophy Case" 263s Copyright (C) 2025 The R Foundation for Statistical Computing 263s Platform: arm-unknown-linux-gnueabihf (32-bit) 263s 263s R is free software and comes with ABSOLUTELY NO WARRANTY. 263s You are welcome to redistribute it under certain conditions. 263s Type 'license()' or 'licence()' for distribution details. 263s 263s R is a collaborative project with many contributors. 263s Type 'contributors()' for more information and 263s 'citation()' on how to cite R or R packages in publications. 263s 263s Type 'demo()' for some demos, 'help()' for on-line help, or 263s 'help.start()' for an HTML browser interface to help. 263s Type 'q()' to quit R. 263s 263s > # test.makeThresholds.R 263s > 263s > library(ordinal) 265s > 265s > # Prvious bug which is now fixed: 265s > res <- ordinal:::makeThresholds(letters[1:3], "symmetric") 265s > stopifnot(length(res$alpha.names) == res$nalpha) 265s > # length(res$alpha.names) used to be 4 265s > 265s > # Real data example: 265s > wine <- within(wine, { 265s + rating_comb3b <- rating 265s + levels(rating_comb3b) <- c("1-2", "1-2", "3", "4-5", "4-5") 265s + }) 265s > wine$rating_comb3b[1] <- "4-5" # Need to remove the zero here to avoid inf MLE 265s > ftable(rating_comb3b ~ temp + contact, data=wine) 265s rating_comb3b 1-2 3 4-5 265s temp contact 265s cold no 12 5 1 265s yes 8 8 2 265s warm no 5 8 5 265s yes 1 5 12 265s > 265s > fm.comb3_c <- clm(rating_comb3b ~ contact, #scale=~contact, 265s + threshold = "symmetric", data=wine) # no error 265s > 265s BEGIN TEST test.sign.R 265s 265s R version 4.4.3 (2025-02-28) -- "Trophy Case" 265s Copyright (C) 2025 The R Foundation for Statistical Computing 265s Platform: arm-unknown-linux-gnueabihf (32-bit) 265s 265s R is free software and comes with ABSOLUTELY NO WARRANTY. 265s You are welcome to redistribute it under certain conditions. 265s Type 'license()' or 'licence()' for distribution details. 265s 265s R is a collaborative project with many contributors. 265s Type 'contributors()' for more information and 265s 'citation()' on how to cite R or R packages in publications. 265s 265s Type 'demo()' for some demos, 'help()' for on-line help, or 265s 'help.start()' for an HTML browser interface to help. 265s Type 'q()' to quit R. 265s 265s > # test.sign.R 265s > 265s > # Test the use of sign.location and sign.nominal in clm.control(): 265s > 265s > library(ordinal) 266s > 266s > fm1 <- clm(rating ~ temp + contact, data=wine) 266s > fm2 <- clm(rating ~ temp + contact, data=wine, 266s + sign.location="positive") 266s > # dput(names(fm1)) 266s > keep <- c("aliased", "alpha", "cond.H", 266s + "contrasts", "convergence", "df.residual", "edf", 266s + "fitted.values", "formula", "formulas", "gradient", 266s + "info", "link", "logLik", "maxGradient", "message", "model", 266s + "n", "niter", "nobs", "start", "terms", "Theta", "threshold", 266s + "tJac", "xlevels", "y", "y.levels") 266s > check <- mapply(function(x, y) isTRUE(all.equal(x, y)), fm1[keep], fm2[keep]) 266s > stopifnot(all(check)) 266s > stopifnot(isTRUE(all.equal( 266s + fm1$beta, - fm2$beta 266s + ))) 266s > 266s > fm1 <- clm(rating ~ temp, nominal=~ contact, data=wine) 266s > fm2 <- clm(rating ~ temp, nominal=~ contact, data=wine, 266s + sign.nominal="negative") 266s > keep <- c("aliased", "beta", "cond.H", 266s + "contrasts", "convergence", "df.residual", "edf", 266s + "fitted.values", "formula", "formulas", "gradient", 266s + "info", "link", "logLik", "maxGradient", "message", "model", 266s + "n", "niter", "nobs", "start", "terms", "Theta", "threshold", 266s + "tJac", "xlevels", "y", "y.levels") 266s > # check <- mapply(function(x, y) isTRUE(all.equal(x, y)), fm1, fm2) 266s > check <- mapply(function(x, y) isTRUE(all.equal(x, y)), fm1[keep], fm2[keep]) 266s > stopifnot(all(check)) 266s > stopifnot(isTRUE(all.equal( 266s + fm1$alpha[5:8], -fm2$alpha[5:8] 266s + ))) 266s > 266s > 266s > fm1 <- clm(rating ~ temp, nominal=~ contact, data=wine) 266s > fm2 <- clm(rating ~ temp, nominal=~ contact, data=wine, 266s + sign.nominal="negative", sign.location="positive") 266s > keep <- c("aliased", "cond.H", 266s + "contrasts", "convergence", "df.residual", "edf", 266s + "fitted.values", "formula", "formulas", "gradient", 266s + "info", "link", "logLik", "maxGradient", "message", "model", 266s + "n", "niter", "nobs", "start", "terms", "Theta", "threshold", 266s + "tJac", "xlevels", "y", "y.levels") 266s > # check <- mapply(function(x, y) isTRUE(all.equal(x, y)), fm1, fm2) 266s > check <- mapply(function(x, y) isTRUE(all.equal(x, y)), fm1[keep], fm2[keep]) 266s > stopifnot(all(check)) 266s > stopifnot( 266s + isTRUE(all.equal(fm1$alpha[5:8], -fm2$alpha[5:8])), 266s + isTRUE(all.equal(fm1$beta, -fm2$beta)) 266s + ) 266s > 266s > # Check predict method: 266s > newData <- with(wine, expand.grid(temp=levels(temp), contact=levels(contact))) 266s > (p1 <- predict(fm1, newdata=newData)) 266s $fit 266s 1 2 3 4 5 266s 1 0.210312404 0.56637121 0.1953950 0.0185460 0.009375394 266s 2 0.020998377 0.19781391 0.5182972 0.1577343 0.105156202 266s 3 0.050301839 0.38380275 0.4329644 0.1065821 0.026348960 266s 4 0.004247588 0.05393811 0.2862121 0.4040930 0.251509196 266s 266s > (p2 <- predict(fm2, newdata=newData)) 266s $fit 266s 1 2 3 4 5 266s 1 0.210312404 0.56637121 0.1953950 0.0185460 0.009375394 266s 2 0.020998377 0.19781391 0.5182972 0.1577343 0.105156202 266s 3 0.050301839 0.38380275 0.4329644 0.1065821 0.026348960 266s 4 0.004247588 0.05393811 0.2862121 0.4040930 0.251509196 266s 266s > stopifnot(isTRUE(all.equal(p1, p2))) 266s > 266s > stopifnot(isTRUE( 266s + all.equal(predict(fm1, newdata=wine, se=TRUE, interval=TRUE), 266s + predict(fm2, newdata=wine, se=TRUE, interval=TRUE)) 266s + )) 266s > 266s > # Check profile and confint methods: 266s > confint.default(fm1) 266s 2.5 % 97.5 % 266s 1|2.(Intercept) -2.4250844 -0.2210024 266s 2|3.(Intercept) 0.3158056 2.1770814 266s 3|4.(Intercept) 2.2642614 4.8358258 266s 4|5.(Intercept) 2.9738888 6.3466053 266s 1|2.contactyes -3.8921464 0.6620280 266s 2|3.contactyes -2.6692032 -0.3539315 266s 3|4.contactyes -2.9464535 -0.4030579 266s 4|5.contactyes -2.8077520 0.7065061 266s tempwarm 1.4703720 3.5677176 266s > confint.default(fm2) 266s 2.5 % 97.5 % 266s 1|2.(Intercept) -2.4250844 -0.2210024 266s 2|3.(Intercept) 0.3158056 2.1770814 266s 3|4.(Intercept) 2.2642614 4.8358258 266s 4|5.(Intercept) 2.9738888 6.3466053 266s 1|2.contactyes -0.6620280 3.8921464 266s 2|3.contactyes 0.3539315 2.6692032 266s 3|4.contactyes 0.4030579 2.9464535 266s 4|5.contactyes -0.7065061 2.8077520 266s tempwarm -3.5677176 -1.4703720 266s > 266s > stopifnot( 266s + isTRUE(all.equal(confint(fm1), -confint(fm2)[, 2:1, drop=FALSE], 266s + check.attributes=FALSE)) 266s + ) 266s > 266s > fm1 <- clm(rating ~ temp + contact, data=wine) 266s > fm2 <- clm(rating ~ temp + contact, data=wine, 266s + sign.location="positive") 266s > pr1 <- profile(fm1) 266s > pr2 <- profile(fm2) 266s > stopifnot( 266s + isTRUE(all.equal(confint(fm1), - confint(fm2)[, 2:1], check.attributes=FALSE)) 266s + ) 266s > 266s > 266s BEGIN TEST test0weights.R 266s 266s R version 4.4.3 (2025-02-28) -- "Trophy Case" 266s Copyright (C) 2025 The R Foundation for Statistical Computing 266s Platform: arm-unknown-linux-gnueabihf (32-bit) 266s 266s R is free software and comes with ABSOLUTELY NO WARRANTY. 266s You are welcome to redistribute it under certain conditions. 266s Type 'license()' or 'licence()' for distribution details. 266s 266s R is a collaborative project with many contributors. 266s Type 'contributors()' for more information and 266s 'citation()' on how to cite R or R packages in publications. 266s 266s Type 'demo()' for some demos, 'help()' for on-line help, or 266s 'help.start()' for an HTML browser interface to help. 266s Type 'q()' to quit R. 266s 266s > library(ordinal) 268s > options(contrasts = c("contr.treatment", "contr.poly")) 268s > ## library(devtools) 268s > ## r2path <- "/Users/rhbc/Documents/Rpackages/ordinal/pkg/ordinal" 268s > ## clean_dll(pkg = r2path) 268s > ## load_all(r2path) 268s > 268s > ## one zero weight: 268s > data(wine, package="ordinal") 268s > wts <- rep(1, nrow(wine)) 268s > wine$rating 268s [1] 2 3 3 4 4 4 5 5 1 2 1 3 2 3 5 4 2 3 3 2 5 5 4 4 3 2 3 2 3 2 5 3 2 3 4 3 3 3 268s [39] 3 3 3 2 3 2 2 4 5 4 1 1 2 2 2 3 2 3 2 2 2 3 3 3 3 4 1 2 3 2 3 2 4 4 268s Levels: 1 < 2 < 3 < 4 < 5 268s > wts[1] <- 0 268s > fm1 <- clm(rating ~ contact + temp, data=wine, weights=wts) 268s > fm1 268s formula: rating ~ contact + temp 268s data: wine 268s 268s link threshold nobs logLik AIC niter max.grad cond.H 268s logit flexible 71 -85.92 183.84 6(0) 3.43e-12 2.7e+01 268s 268s Coefficients: 268s contactyes tempwarm 268s 1.511 2.482 268s 268s Threshold coefficients: 268s 1|2 2|3 3|4 4|5 268s -1.295 1.220 3.437 4.975 268s > fm1$n ## 72 268s [1] 72 268s > fm1$nobs ## 71 268s [1] 71 268s > confint(fm1) 268s 2.5 % 97.5 % 268s contactyes 0.5951066 2.478924 268s tempwarm 1.4856829 3.577621 268s > plot(profile(fm1)) 268s > plot(slice(fm1), 5) 268s > convergence(fm1) 268s nobs logLik niter max.grad cond.H logLik.Error 268s 71 -85.92 6(0) 3.43e-12 2.7e+01 <1e-10 268s 268s Estimate Std.Err Gradient Error Cor.Dec Sig.Dig 268s 1|2 -1.295 0.5220 7.57e-13 7.84e-14 12 13 268s 2|3 1.220 0.4436 2.65e-12 -1.27e-13 12 13 268s 3|4 3.437 0.6014 -3.43e-12 -7.17e-13 11 12 268s 4|5 4.975 0.7341 -6.06e-14 -7.01e-13 11 12 268s contactyes 1.511 0.4785 1.53e-13 -1.95e-13 12 13 268s tempwarm 2.482 0.5303 -4.07e-13 -4.95e-13 12 13 268s 268s Eigen values of Hessian: 268s 21.7419 18.5476 10.4115 5.2426 4.0755 0.8013 268s 268s Convergence message from clm: 268s (0) successful convergence 268s In addition: Absolute and relative convergence criteria were met 268s 268s > drop1(fm1, test="Chi") 268s Single term deletions 268s 268s Model: 268s rating ~ contact + temp 268s Df AIC LRT Pr(>Chi) 268s 183.84 268s contact 1 192.54 10.698 0.001072 ** 268s temp 1 208.07 26.234 3.024e-07 *** 268s --- 268s Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1 268s > add1(fm1, scope=~.^2, test="Chi") 268s Single term additions 268s 268s Model: 268s rating ~ contact + temp 268s Df AIC LRT Pr(>Chi) 268s 183.84 268s contact:temp 1 185.66 0.18256 0.6692 268s > ## clm_anova(fm1) 268s > pred <- predict(fm1, newdata=wine) ## OK 268s > step.fm1 <- step(fm1, trace=0) 268s > fitted(fm1) 268s [1] 0.19683278 0.44514183 0.09677403 0.20147980 0.20147980 0.27261558 268s [7] 0.27261558 0.21497073 0.55705124 0.05699435 0.44514183 0.19814731 268s [13] 0.50160837 0.27261558 0.36288756 0.55705124 0.19683278 0.44514183 268s [19] 0.37073110 0.07640020 0.07640020 0.36288756 0.36288756 0.19683278 268s [25] 0.55705124 0.44514183 0.37073110 0.50160837 0.19814731 0.27261558 268s [31] 0.30572865 0.55705124 0.19683278 0.09677403 0.44514183 0.50160837 268s [37] 0.50160837 0.30572865 0.30572865 0.19683278 0.55705124 0.44514183 268s [43] 0.37073110 0.19814731 0.20147980 0.27261558 0.36288756 0.21497073 268s [49] 0.21497073 0.37073110 0.37073110 0.19814731 0.50160837 0.05374460 268s [55] 0.30572865 0.55705124 0.55705124 0.37073110 0.44514183 0.50160837 268s [61] 0.50160837 0.30572865 0.36288756 0.21497073 0.55705124 0.44514183 268s [67] 0.37073110 0.50160837 0.19814731 0.36288756 0.36288756 268s > dim(model.matrix(fm1)$X) 268s [1] 72 3 268s > dim(model.matrix(fm1, "B")$B1) 268s [1] 71 6 268s > mf <- update(fm1, method="model.frame") 268s > str(mf) 268s 'data.frame': 72 obs. of 4 variables: 268s $ rating : Ord.factor w/ 5 levels "1"<"2"<"3"<"4"<..: 2 3 3 4 4 4 5 5 1 2 ... 268s $ contact : Factor w/ 2 levels "no","yes": 1 1 2 2 1 1 2 2 1 1 ... 268s $ temp : Factor w/ 2 levels "cold","warm": 1 1 1 1 2 2 2 2 1 1 ... 268s $ (weights): num 0 1 1 1 1 1 1 1 1 1 ... 268s - attr(*, "terms")=Classes 'terms', 'formula' language rating ~ contact + temp 268s .. ..- attr(*, "variables")= language list(rating, contact, temp) 268s .. ..- attr(*, "factors")= int [1:3, 1:2] 0 1 0 0 0 1 268s .. .. ..- attr(*, "dimnames")=List of 2 268s .. .. .. ..$ : chr [1:3] "rating" "contact" "temp" 268s .. .. .. ..$ : chr [1:2] "contact" "temp" 268s .. ..- attr(*, "term.labels")= chr [1:2] "contact" "temp" 268s .. ..- attr(*, "order")= int [1:2] 1 1 268s .. ..- attr(*, "intercept")= int 1 268s .. ..- attr(*, "response")= int 1 268s .. ..- attr(*, ".Environment")= 268s .. ..- attr(*, "predvars")= language list(rating, contact, temp) 268s .. ..- attr(*, "dataClasses")= Named chr [1:4] "ordered" "factor" "factor" "numeric" 268s .. .. ..- attr(*, "names")= chr [1:4] "rating" "contact" "temp" "(weights)" 268s > wts <- mf$wts 268s > dim(model.matrix(fm1)$X[wts > 0, , drop=FALSE]) 268s [1] 0 3 268s > 268s > fm1b <- clm(rating ~ temp, scale=~contact, data=wine, weights=wts) 268s > summary(fm1b) 268s formula: rating ~ temp 268s scale: ~contact 268s data: wine 268s 268s link threshold nobs logLik AIC niter max.grad cond.H 268s logit flexible 72 -91.92 195.83 8(0) 1.57e-09 5.6e+01 268s 268s Coefficients: 268s Estimate Std. Error z value Pr(>|z|) 268s tempwarm 2.1690 0.5527 3.924 8.69e-05 *** 268s --- 268s Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1 268s 268s log-scale coefficients: 268s Estimate Std. Error z value Pr(>|z|) 268s contactyes -0.1222 0.2775 -0.44 0.66 268s 268s Threshold coefficients: 268s Estimate Std. Error z value 268s 1|2 -1.8957 0.4756 -3.986 268s 2|3 0.3668 0.3442 1.066 268s 3|4 2.2483 0.5932 3.790 268s 4|5 3.5393 0.8336 4.246 268s > pr <- profile(fm1b) 268s > confint(pr) 268s 2.5 % 97.5 % 268s tempwarm 1.2122036 3.4033767 268s sca.contactyes -0.6721766 0.4156449 268s > plot(pr, 1) 268s > fm1c <- clm(rating ~ temp, nominal=~contact, data=wine, weights=wts) 268s > summary(fm1c) 268s formula: rating ~ temp 268s nominal: ~contact 268s data: wine 268s 268s link threshold nobs logLik AIC niter max.grad cond.H 268s logit flexible 72 -86.21 190.42 6(0) 1.64e-10 4.8e+01 268s 268s Coefficients: 268s Estimate Std. Error z value Pr(>|z|) 268s tempwarm 2.519 0.535 4.708 2.5e-06 *** 268s --- 268s Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1 268s 268s Threshold coefficients: 268s Estimate Std. Error z value 268s 1|2.(Intercept) -1.3230 0.5623 -2.353 268s 2|3.(Intercept) 1.2464 0.4748 2.625 268s 3|4.(Intercept) 3.5500 0.6560 5.411 268s 4|5.(Intercept) 4.6602 0.8604 5.416 268s 1|2.contactyes -1.6151 1.1618 -1.390 268s 2|3.contactyes -1.5116 0.5906 -2.559 268s 3|4.contactyes -1.6748 0.6488 -2.581 268s 4|5.contactyes -1.0506 0.8965 -1.172 268s > pr <- profile(fm1c) 268s > confint(pr) 268s 2.5 % 97.5 % 268s tempwarm 1.516862 3.629098 268s > plot(pr, 1) 268s > 268s > ## nominal.test(fm1) 268s > ## scale.test(fm1) 268s > 268s > ## zero out an entire response category: 268s > wts2 <- 1 * with(wine, rating != "2") 268s > fm2 <- clm(rating ~ contact + temp, data=wine, weights=wts2) 268s > fm2 268s formula: rating ~ contact + temp 268s data: wine 268s 268s link threshold nobs logLik AIC niter max.grad cond.H 268s logit flexible 50 -46.76 103.52 7(0) 3.56e-13 4.2e+01 268s 268s Coefficients: 268s contactyes tempwarm 268s 1.593 3.062 268s 268s Threshold coefficients: 268s 1|3 3|4 4|5 268s -0.5173 3.6238 5.3657 268s > fm2$n ## 72 268s [1] 72 268s > fm2$nobs ## 50 268s [1] 50 268s > ## Dimension of X and B1, B2 differ: 268s > dim(model.matrix(fm2)$X) 268s [1] 72 3 268s > dim(model.matrix(fm2, "B")$B1) 268s [1] 50 5 268s > ## Cannot directly evaluate predictions on the original data: 268s > try(predict(fm2, newdata=wine), silent=TRUE)[1] 268s [1] "Error in predict.clm(fm2, newdata = wine) : \n response factor 'rating' has new levels\n" 268s > confint(fm2) 268s 2.5 % 97.5 % 268s contactyes 0.4216272 2.876550 268s tempwarm 1.5970977 5.026527 268s > profile(fm2) 268s $contactyes 268s lroot par.vals.1|3 par.vals.3|4 par.vals.4|5 par.vals.contactyes 268s 1 3.4747852 -1.448538968 2.255543944 3.804439509 -0.447374822 268s 2 3.0276372 -1.308493024 2.407453551 3.967827135 -0.192380808 268s 3 2.5822211 -1.174976592 2.565043880 4.140537415 0.062613207 268s 4 2.1395315 -1.048101582 2.728199207 4.322490592 0.317607222 268s 5 1.7005507 -0.927983229 2.896810974 4.513576014 0.572601236 268s 6 1.2662317 -0.814738724 3.070776301 4.713647671 0.827595251 268s 7 0.8374817 -0.708483160 3.249996208 4.922519451 1.082589265 268s 8 0.4151468 -0.609322477 3.434373593 5.139960291 1.337583280 268s 9 0.0000000 -0.517343412 3.623810880 5.365689290 1.592577294 268s 10 -0.4072702 -0.432600941 3.818207180 5.599370818 1.847571309 268s 11 -0.8060673 -0.355104205 4.017454848 5.840609731 2.102565323 268s 12 -1.1958918 -0.284802472 4.221435388 6.088946911 2.357559338 268s 13 -1.5763436 -0.221573075 4.430015019 6.343855637 2.612553352 268s 14 -1.9471215 -0.165213368 4.643040370 6.604739566 2.867547367 268s 15 -2.3080198 -0.115438462 4.860335061 6.870933284 3.122541381 268s 16 -2.6589228 -0.071885700 5.081697900 7.141706504 3.377535396 268s 17 -2.9997972 -0.034125762 5.306903276 7.416272839 3.632529410 268s 18 -3.3306833 -0.001679093 5.535703885 7.693803770 3.887523425 268s par.vals.tempwarm 268s 1 2.840981986 268s 2 2.848907417 268s 3 2.863086150 268s 4 2.883227511 268s 5 2.909025226 268s 6 2.940155181 268s 7 2.976272850 268s 8 3.017010511 268s 9 3.061974244 268s 10 3.110740675 268s 11 3.162853507 268s 12 3.217819929 268s 13 3.275107380 268s 14 3.334141312 268s 15 3.394304942 268s 16 3.454942107 268s 17 3.515364293 268s 18 3.574862708 268s 268s $tempwarm 268s lroot par.vals.1|3 par.vals.3|4 par.vals.4|5 par.vals.contactyes 268s 1 3.4300164 -1.3083735 1.7272573 3.1899360 1.3296606 268s 2 2.8813858 -1.1550431 1.9737448 3.4740817 1.3627908 268s 3 2.3491188 -1.0148529 2.2280703 3.7683888 1.3992293 268s 4 1.8354355 -0.8881411 2.4904988 4.0722937 1.4379639 268s 5 1.3422735 -0.7751174 2.7612331 4.3850175 1.4778669 268s 6 0.8712358 -0.6758159 3.0403898 4.7055883 1.5177348 268s 7 0.4235444 -0.5900448 3.3279674 5.0328829 1.5563515 268s 8 0.0000000 -0.5173434 3.6238109 5.3656893 1.5925773 268s 9 -0.3990485 -0.4569595 3.9275814 5.7027863 1.6254526 268s 10 -0.7737184 -0.4078590 4.2387443 6.0430310 1.6542958 268s 11 -1.1245809 -0.3687765 4.5565843 6.3854348 1.6787668 268s 12 -1.4526173 -0.3383014 4.8802522 6.7292117 1.6988730 268s 13 -1.7591420 -0.3149843 5.2088333 7.0737893 1.7149136 268s 14 -2.0457031 -0.2974396 5.5414220 7.4187857 1.7273842 268s 15 -2.3139760 -0.2844232 5.8771833 7.7639689 1.7368704 268s 16 -2.5656664 -0.2748765 6.2153929 8.1092106 1.7439599 268s 17 -2.8024328 -0.2679376 6.5554528 8.4544482 1.7491850 268s 18 -3.0258332 -0.2629290 6.8968876 8.7996559 1.7529951 268s 19 -3.2372944 -0.2593326 7.2393314 9.1448275 1.7557514 268s 20 -3.4380992 -0.2567600 7.5825083 9.4899654 1.7577335 268s par.vals.tempwarm 268s 1 0.6468007 268s 2 0.9918255 268s 3 1.3368503 268s 4 1.6818751 268s 5 2.0268999 268s 6 2.3719247 268s 7 2.7169495 268s 8 3.0619742 268s 9 3.4069990 268s 10 3.7520238 268s 11 4.0970486 268s 12 4.4420734 268s 13 4.7870982 268s 14 5.1321230 268s 15 5.4771478 268s 16 5.8221726 268s 17 6.1671974 268s 18 6.5122222 268s 19 6.8572470 268s 20 7.2022718 268s 268s attr(,"original.fit") 268s formula: rating ~ contact + temp 268s data: wine 268s 268s link threshold nobs logLik AIC niter max.grad cond.H 268s logit flexible 50 -46.76 103.52 7(0) 3.56e-13 4.2e+01 268s 268s Coefficients: 268s contactyes tempwarm 268s 1.593 3.062 268s 268s Threshold coefficients: 268s 1|3 3|4 4|5 268s -0.5173 3.6238 5.3657 268s attr(,"class") 268s [1] "profile.clm" 268s > plot(slice(fm2), 5) 268s > step.fm2 <- step(fm2, trace=0) 268s > fitted(fm2) 268s [1] 0.60053892 0.77590129 0.09349820 0.27230685 0.27230685 0.32934749 268s [7] 0.32934749 0.37347364 0.10813631 0.77590129 0.60973967 0.32934749 268s [13] 0.40771198 0.60053892 0.77590129 0.09081575 0.09081575 0.40771198 268s [19] 0.40771198 0.60053892 0.77590129 0.60973967 0.32934749 0.25729874 268s [25] 0.60053892 0.09349820 0.77590129 0.60973967 0.60973967 0.25729874 268s [31] 0.25729874 0.60053892 0.77590129 0.27230685 0.32934749 0.40771198 268s [37] 0.37347364 0.37347364 0.60973967 0.25729874 0.77590129 0.60973967 268s [43] 0.60973967 0.25729874 0.40771198 0.37347364 0.77590129 0.60973967 268s [49] 0.40771198 0.40771198 268s > ## Scale and nominal effects: 268s > fm2b <- clm(rating ~ temp, scale=~contact, data=wine, weights=wts2) 268s > summary(fm2b) 268s formula: rating ~ temp 268s scale: ~contact 268s data: wine 268s 268s link threshold nobs logLik AIC niter max.grad cond.H 268s logit flexible 50 -50.35 110.71 9(0) 2.51e-08 1.2e+02 268s 268s Coefficients: 268s Estimate Std. Error z value Pr(>|z|) 268s tempwarm 2.667 1.059 2.519 0.0118 * 268s --- 268s Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1 268s 268s log-scale coefficients: 268s Estimate Std. Error z value Pr(>|z|) 268s contactyes -0.09812 0.38836 -0.253 0.801 268s 268s Threshold coefficients: 268s Estimate Std. Error z value 268s 1|3 -1.2009 0.5033 -2.386 268s 3|4 2.3219 1.0427 2.227 268s 4|5 3.7986 1.3876 2.738 268s > pr <- profile(fm2b) 268s > confint(pr) 268s 2.5 % 97.5 % 268s tempwarm 1.1319929 6.0851931 268s sca.contactyes -0.8403892 0.7190847 268s > plot(pr, 1) 268s > fm2c <- clm(rating ~ temp, nominal=~contact, data=wine, weights=wts2) 268s > summary(fm2c) 268s formula: rating ~ temp 268s nominal: ~contact 268s data: wine 268s 268s link threshold nobs logLik AIC niter max.grad cond.H 268s logit flexible 50 -46.36 106.72 7(0) 1.22e-12 4.8e+01 268s 268s Coefficients: 268s Estimate Std. Error z value Pr(>|z|) 268s tempwarm 3.1100 0.8529 3.646 0.000266 *** 268s --- 268s Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1 268s 268s Threshold coefficients: 268s Estimate Std. Error z value 268s 1|3.(Intercept) -0.4250 0.6381 -0.666 268s 3|4.(Intercept) 3.6911 0.9505 3.883 268s 4|5.(Intercept) 4.8968 1.1001 4.451 268s 1|3.contactyes -1.8993 1.2128 -1.566 268s 3|4.contactyes -1.7003 0.7432 -2.288 268s 4|5.contactyes -0.9153 0.9243 -0.990 268s > pr <- profile(fm2c) 268s > confint(pr) 268s 2.5 % 97.5 % 268s tempwarm 1.623761 5.102185 268s > plot(pr, 1) 268s > pred <- predict(fm2c, newdata=wine[!names(wine) %in% "rating"]) 268s > pred <- predict(fm2b, newdata=wine[!names(wine) %in% "rating"]) 268s > 268s > ## nominal.test(fm2) 268s > ## scale.test(fm2) 268s > 268s > ## Different data sets (error): 268s > try(anova(fm1, fm2), silent=TRUE)[1] ## OK 268s [1] "Error in anova.clm(fm1, fm2) : \n models were not all fitted to the same dataset\n" 268s > 268s > ## Test clm.fit: 268s > wts2 <- 1 * with(wine, rating != "2") 268s > mf2 <- update(fm2, method="design") 268s > fm3 <- with(mf2, clm.fit(y, X, weights=wts)) 268s > 268s > ################################# 268s > 268s BEGIN TEST testAnova.clm2.R 268s 268s R version 4.4.3 (2025-02-28) -- "Trophy Case" 268s Copyright (C) 2025 The R Foundation for Statistical Computing 268s Platform: arm-unknown-linux-gnueabihf (32-bit) 268s 268s R is free software and comes with ABSOLUTELY NO WARRANTY. 268s You are welcome to redistribute it under certain conditions. 268s Type 'license()' or 'licence()' for distribution details. 268s 268s R is a collaborative project with many contributors. 268s Type 'contributors()' for more information and 268s 'citation()' on how to cite R or R packages in publications. 268s 268s Type 'demo()' for some demos, 'help()' for on-line help, or 268s 'help.start()' for an HTML browser interface to help. 268s Type 'q()' to quit R. 268s 269s > library(ordinal) 270s > options(contrasts = c("contr.treatment", "contr.poly")) 270s > 270s > ## More manageable data set: 270s > (tab26 <- with(soup, table("Product" = PROD, "Response" = SURENESS))) 270s Response 270s Product 1 2 3 4 5 6 270s Ref 132 161 65 41 121 219 270s Test 96 99 50 57 156 650 270s > dimnames(tab26)[[2]] <- c("Sure", "Not Sure", "Guess", "Guess", "Not Sure", "Sure") 270s > dat26 <- expand.grid(sureness = as.factor(1:6), prod = c("Ref", "Test")) 270s > dat26$wghts <- c(t(tab26)) 270s > m1 <- clm(sureness ~ prod, scale = ~prod, data = dat26, 270s + weights = wghts, link = "logit") 270s > 270s > ## anova 270s > m2 <- update(m1, scale = ~1) 270s > anova(m1, m2) 270s Likelihood ratio tests of cumulative link models: 270s 270s formula: scale: link: threshold: 270s m2 sureness ~ prod ~1 logit flexible 270s m1 sureness ~ prod ~prod logit flexible 270s 270s no.par AIC logLik LR.stat df Pr(>Chisq) 270s m2 6 5392.7 -2690.3 270s m1 7 5389.5 -2687.7 5.1749 1 0.02292 * 270s --- 270s Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1 270s > mN1 <- clm(sureness ~ 1, nominal = ~prod, data = dat26, 270s + link = "logit") 270s > anova(m1, mN1) 270s Likelihood ratio tests of cumulative link models: 270s 270s formula: nominal: scale: link: threshold: 270s m1 sureness ~ prod ~1 ~prod logit flexible 270s mN1 sureness ~ 1 ~prod ~1 logit flexible 270s 270s no.par AIC logLik LR.stat df Pr(>Chisq) 270s m1 7 5389.489 -2687.745 270s mN1 10 63.002 -21.501 5332.5 3 < 2.2e-16 *** 270s --- 270s Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1 270s > anova(m1, m2, mN1) 270s Likelihood ratio tests of cumulative link models: 270s 270s formula: nominal: scale: link: threshold: 270s m2 sureness ~ prod ~1 ~1 logit flexible 270s m1 sureness ~ prod ~1 ~prod logit flexible 270s mN1 sureness ~ 1 ~prod ~1 logit flexible 270s 270s no.par AIC logLik LR.stat df Pr(>Chisq) 270s m2 6 5392.664 -2690.332 270s m1 7 5389.489 -2687.745 5.1749 1 0.02292 * 270s mN1 10 63.002 -21.501 5332.4869 3 < 2e-16 *** 270s --- 270s Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1 270s > 270s > ## dropterm 270s > if(require(MASS)) { 270s + dropterm(m1, test = "Chi") 270s + mB1 <- clm(SURENESS ~ PROD + GENDER + SOUPTYPE, 270s + scale = ~ COLD, data = soup, link = "probit") 270s + dropterm(mB1, test = "Chi") # or 270s + 270s + ## addterm 270s + addterm(mB1, scope = ~.^2, test = "Chi") 270s + ## addterm(mB1, scope = ~ . + AGEGROUP + SOUPFREQ, 270s + ## test = "Chi", which = "location") 270s + ## addterm(mB1, scope = ~ . + GENDER + SOUPTYPE, 270s + ## test = "Chi", which = "scale") 270s + 270s + ## Fit model from polr example: 270s + ## data(housing, package = "MASS") 270s + 270s + fm1 <- clm(Sat ~ Infl + Type + Cont, weights = Freq, data = housing) 270s + ## addterm(fm1, ~ Infl + Type + Cont, test= "Chisq", which = "scale") 270s + dropterm(fm1, test = "Chisq") 270s + fm2 <- update(fm1, scale =~ Cont) 270s + fm3 <- update(fm1, formula =~.-Cont, nominal =~ Cont) 270s + anova(fm1, fm2, fm3) 270s + } 270s Loading required package: MASS 270s Likelihood ratio tests of cumulative link models: 270s 270s formula: nominal: scale: link: threshold: 270s fm1 Sat ~ Infl + Type + Cont ~1 ~1 logit flexible 270s fm2 Sat ~ Infl + Type + Cont ~1 ~Cont logit flexible 270s fm3 Sat ~ Infl + Type ~Cont ~1 logit flexible 270s 270s no.par AIC logLik LR.stat df Pr(>Chisq) 270s fm1 8 3495.1 -1739.6 270s fm2 9 3491.5 -1736.7 5.6559 1 0.0174 * 270s fm3 9 3494.7 -1738.4 -3.2113 0 270s --- 270s Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1 270s > 270s > 270s BEGIN TEST testCLM.R 270s 270s R version 4.4.3 (2025-02-28) -- "Trophy Case" 270s Copyright (C) 2025 The R Foundation for Statistical Computing 270s Platform: arm-unknown-linux-gnueabihf (32-bit) 270s 270s R is free software and comes with ABSOLUTELY NO WARRANTY. 270s You are welcome to redistribute it under certain conditions. 270s Type 'license()' or 'licence()' for distribution details. 270s 270s R is a collaborative project with many contributors. 270s Type 'contributors()' for more information and 270s 'citation()' on how to cite R or R packages in publications. 270s 270s Type 'demo()' for some demos, 'help()' for on-line help, or 270s 'help.start()' for an HTML browser interface to help. 270s Type 'q()' to quit R. 270s 270s > library(ordinal) 271s > options(contrasts = c("contr.treatment", "contr.poly")) 271s > ## library(devtools) 271s > ## r2path <- "/Users/rhbc/Documents/Rpackages/ordinal/pkg/ordinal" 271s > ## clean_dll(pkg = r2path) 271s > ## load_all(r2path) 271s > 271s > ## More manageable data set: 271s > data(soup, package="ordinal") 271s > (tab26 <- with(soup, table("Product" = PROD, "Response" = SURENESS))) 271s Response 271s Product 1 2 3 4 5 6 271s Ref 132 161 65 41 121 219 271s Test 96 99 50 57 156 650 271s > dimnames(tab26)[[2]] <- c("Sure", "Not Sure", "Guess", "Guess", "Not Sure", "Sure") 271s > dat26 <- expand.grid(sureness = as.factor(1:6), prod = c("Ref", "Test")) 271s > dat26$wghts <- c(t(tab26)) 271s > m1 <- clm(sureness ~ prod, scale = ~prod, data = dat26, 271s + weights = wghts, link = "logit") 271s > ## print, summary, vcov, logLik, AIC: 271s > m1 271s formula: sureness ~ prod 271s scale: ~prod 271s data: dat26 271s 271s link threshold nobs logLik AIC niter max.grad cond.H 271s logit flexible 1847 -2687.74 5389.49 8(1) 5.09e-07 1.0e+02 271s 271s Coefficients: 271s prodTest 271s 1.296 271s 271s log-scale coefficients: 271s prodTest 271s 0.148 271s 271s Threshold coefficients: 271s 1|2 2|3 3|4 4|5 5|6 271s -1.4913 -0.4522 -0.1072 0.1634 0.8829 271s > summary(m1) 271s formula: sureness ~ prod 271s scale: ~prod 271s data: dat26 271s 271s link threshold nobs logLik AIC niter max.grad cond.H 271s logit flexible 1847 -2687.74 5389.49 8(1) 5.09e-07 1.0e+02 271s 271s Coefficients: 271s Estimate Std. Error z value Pr(>|z|) 271s prodTest 1.296 0.119 10.89 <2e-16 *** 271s --- 271s Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1 271s 271s log-scale coefficients: 271s Estimate Std. Error z value Pr(>|z|) 271s prodTest 0.1480 0.0651 2.273 0.023 * 271s --- 271s Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1 271s 271s Threshold coefficients: 271s Estimate Std. Error z value 271s 1|2 -1.49126 0.09215 -16.183 271s 2|3 -0.45218 0.07182 -6.296 271s 3|4 -0.10721 0.06995 -1.533 271s 4|5 0.16337 0.07025 2.325 271s 5|6 0.88291 0.07957 11.096 271s > vcov(m1) 271s 1|2 2|3 3|4 4|5 5|6 271s 1|2 0.0084917417 0.0046258673 0.0038492096 0.003316006 0.002036170 271s 2|3 0.0046258673 0.0051586967 0.0044974099 0.004099300 0.003352323 271s 3|4 0.0038492096 0.0044974099 0.0048935739 0.004528181 0.003948048 271s 4|5 0.0033160059 0.0040993002 0.0045281811 0.004935721 0.004489054 271s 5|6 0.0020361699 0.0033523229 0.0039480481 0.004489054 0.006331523 271s prodTest 0.0009111749 0.0031074167 0.0039832831 0.004738959 0.007064828 271s prodTest -0.0024312129 -0.0007825923 -0.0001820514 0.000338977 0.001989991 271s prodTest prodTest 271s 1|2 0.0009111749 -0.0024312129 271s 2|3 0.0031074167 -0.0007825923 271s 3|4 0.0039832831 -0.0001820514 271s 4|5 0.0047389591 0.0003389770 271s 5|6 0.0070648284 0.0019899912 271s prodTest 0.0141687135 0.0045752922 271s prodTest 0.0045752922 0.0042385585 271s > 271s > logLik(m1) 271s 'log Lik.' -2687.745 (df=7) 271s > ll.m1 <- structure(-2687.74456343981, df = 7L, nobs = 1847, 271s + class = "logLik") 271s > stopifnot(all.equal(logLik(m1), ll.m1)) 271s > 271s > AIC(m1) 271s [1] 5389.489 271s > 271s > coef(m1) 271s 1|2 2|3 3|4 4|5 5|6 prodTest prodTest 271s -1.4912570 -0.4521846 -0.1072083 0.1633653 0.8829135 1.2958776 0.1479862 271s > cm1 <- c(-1.49125702755587, -0.45218462707814, -0.107208315524318, 0.163365282774162, 271s + 0.88291347877514, 1.29587762626394, 0.147986162902775) 271s > stopifnot(all.equal(as.vector(coef(m1)), cm1)) 271s > 271s > coef(summary(m1)) 271s Estimate Std. Error z value Pr(>|z|) 271s 1|2 -1.4912570 0.09215065 -16.182817 6.667319e-59 271s 2|3 -0.4521846 0.07182407 -6.295726 3.059652e-10 271s 3|4 -0.1072083 0.06995408 -1.532553 1.253861e-01 271s 4|5 0.1633653 0.07025469 2.325329 2.005437e-02 271s 5|6 0.8829135 0.07957087 11.095938 1.312749e-28 271s prodTest 1.2958776 0.11903241 10.886763 1.332938e-27 271s prodTest 0.1479862 0.06510421 2.273066 2.302222e-02 271s > csm1 <- structure(c(-1.49125702755587, -0.45218462707814, -0.107208315524318, 271s + 0.163365282774162, 0.88291347877514, 1.29587762626394, 0.147986162902775, 271s + 0.0921506468161812, 0.0718240681909781, 0.069954084652323, 0.0702546879687391, 271s + 0.0795708692869622, 0.119032405993894, 0.065104213008022, -16.1828167145758, 271s + -6.2957256316336, -1.53255261729392, 2.32532927691394, 11.0959385851501, 271s + 10.8867632762999, 2.27306584421104, 6.66732036748908e-59, 3.05965144996025e-10, 271s + 0.125386123756898, 0.0200543599621069, 1.31274723412040e-28, 271s + 1.33293711602276e-27, 0.0230222123418036), .Dim = c(7L, 4L), .Dimnames = list( 271s + c("1|2", "2|3", "3|4", "4|5", "5|6", "prodTest", "prodTest" 271s + ), c("Estimate", "Std. Error", "z value", "Pr(>|z|)"))) 271s > stopifnot(all.equal(coef(summary(m1)), csm1)) 271s > 271s > ## link functions: 271s > m2 <- update(m1, link = "probit") 271s > m3 <- update(m1, link = "cloglog") 271s > 271s > m4 <- update(m1, link = "loglog") 271s > m5 <- update(m1, link = "cauchit", start = coef(m1)) 271s > ## m6 <- update(m1, link = "Aranda-Ordaz", lambda = 1) 271s > ## m7 <- update(m1, link = "Aranda-Ordaz") 271s > ## m8 <- update(m1, link = "log-gamma", lambda = 1) 271s > ## m9 <- update(m1, link = "log-gamma") 271s > ## nominal effects: 271s > mN1 <- clm(sureness ~ 1, nominal = ~ prod, data = dat26, 271s + weights = wghts) 271s > anova(m1, mN1) 271s Likelihood ratio tests of cumulative link models: 271s 271s formula: nominal: scale: link: threshold: 271s m1 sureness ~ prod ~1 ~prod logit flexible 271s mN1 sureness ~ 1 ~prod ~1 logit flexible 271s 271s no.par AIC logLik LR.stat df Pr(>Chisq) 271s m1 7 5389.5 -2687.7 271s mN1 10 5390.1 -2685.1 5.3755 3 0.1463 271s > ## optimizer / method: 271s > update(m1, scale = ~ 1, method = "Newton") 271s formula: sureness ~ prod 271s scale: ~1 271s data: dat26 271s 271s link threshold nobs logLik AIC niter max.grad cond.H 271s logit flexible 1847 -2690.33 5392.66 6(1) 3.35e-12 1.1e+02 271s 271s Coefficients: 271s prodTest 271s 1.144 271s 271s Threshold coefficients: 271s 1|2 2|3 3|4 4|5 5|6 271s -1.4050 -0.4247 -0.1013 0.1508 0.8126 271s > update(m1, scale = ~ 1, method = "ucminf") 271s formula: sureness ~ prod 271s scale: ~1 271s data: dat26 271s 271s link threshold nobs logLik AIC niter max.grad cond.H 271s logit flexible 1847 -2690.33 5392.66 19(0) 1.26e-08 1.1e+02 271s 271s Coefficients: 271s prodTest 271s 1.144 271s 271s Threshold coefficients: 271s 1|2 2|3 3|4 4|5 5|6 271s -1.4050 -0.4247 -0.1013 0.1508 0.8126 271s > update(m1, scale = ~ 1, method = "nlminb") 271s formula: sureness ~ prod 271s scale: ~1 271s data: dat26 271s 271s Warning message: 271s (-1) Model failed to converge with max|grad| = 0.00413248 (tol = 1e-06) 271s link threshold nobs logLik AIC niter max.grad cond.H 271s logit flexible 1847 -2690.33 5392.66 56(43) 4.13e-03 1.1e+02 271s 271s Coefficients: 271s prodTest 271s 1.144 271s 271s Threshold coefficients: 271s 1|2 2|3 3|4 4|5 5|6 271s -1.4050 -0.4247 -0.1013 0.1508 0.8126 271s > update(m1, scale = ~ 1, method = "optim") 271s formula: sureness ~ prod 271s scale: ~1 271s data: dat26 271s 271s Warning message: 271s (-1) Model failed to converge with max|grad| = 0.00472568 (tol = 1e-06) 271s link threshold nobs logLik AIC niter max.grad cond.H 271s logit flexible 1847 -2690.33 5392.66 44(12) 4.73e-03 1.1e+02 271s 271s Coefficients: 271s prodTest 271s 1.144 271s 271s Threshold coefficients: 271s 1|2 2|3 3|4 4|5 5|6 271s -1.4050 -0.4247 -0.1013 0.1508 0.8126 271s > update(m1, scale = ~ 1, method = "model.frame") 272s sureness prod (weights) 272s 1 1 Ref 132 272s 2 2 Ref 161 272s 3 3 Ref 65 272s 4 4 Ref 41 272s 5 5 Ref 121 272s 6 6 Ref 219 272s 7 1 Test 96 272s 8 2 Test 99 272s 9 3 Test 50 272s 10 4 Test 57 272s 11 5 Test 156 272s 12 6 Test 650 272s > update(m1, ~.-prod, scale = ~ 1, 272s + nominal = ~ prod, method = "model.frame") 272s sureness prod (weights) 272s 1 1 Ref 132 272s 2 2 Ref 161 272s 3 3 Ref 65 272s 4 4 Ref 41 272s 5 5 Ref 121 272s 6 6 Ref 219 272s 7 1 Test 96 272s 8 2 Test 99 272s 9 3 Test 50 272s 10 4 Test 57 272s 11 5 Test 156 272s 12 6 Test 650 272s > ## threshold functions 272s > mT1 <- update(m1, threshold = "symmetric") 272s > mT2 <- update(m1, threshold = "equidistant") 272s > anova(m1, mT1, mT2) 272s Loading required package: MASS 272s Likelihood ratio tests of cumulative link models: 272s 272s formula: scale: link: threshold: 272s mT2 sureness ~ prod ~prod logit equidistant 272s mT1 sureness ~ prod ~prod logit symmetric 272s m1 sureness ~ prod ~prod logit flexible 272s 272s no.par AIC logLik LR.stat df Pr(>Chisq) 272s mT2 4 5585.6 -2788.8 272s mT1 5 5407.8 -2698.9 179.806 1 < 2.2e-16 *** 272s m1 7 5389.5 -2687.7 22.271 2 1.459e-05 *** 272s --- 272s Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1 272s > 272s > ## Extend example from polr in package MASS: 272s > ## Fit model from polr example: 272s > if(require(MASS)) { 272s + fm1 <- clm(Sat ~ Infl + Type + Cont, weights = Freq, data = housing) 272s + fm1 272s + summary(fm1) 272s + ## With probit link: 272s + summary(update(fm1, link = "probit")) 272s + ## Allow scale to depend on Cont-variable 272s + summary(fm2 <- update(fm1, scale =~ Cont)) 272s + summary(fm3 <- update(fm1, location =~.-Cont, nominal =~ Cont)) 272s + summary(fm4 <- update(fm2, location =~.-Cont, nominal =~ Cont)) 272s + anova(fm1, fm2, fm3, fm4) 272s + ## which seems to improve the fit 272s + } 272s Likelihood ratio tests of cumulative link models: 272s 272s formula: nominal: scale: link: threshold: 272s fm1 Sat ~ Infl + Type + Cont ~1 ~1 logit flexible 272s fm2 Sat ~ Infl + Type + Cont ~1 ~Cont logit flexible 272s fm3 Sat ~ Infl + Type + Cont ~Cont ~1 logit flexible 272s fm4 Sat ~ Infl + Type + Cont ~Cont ~Cont logit flexible 272s 272s no.par AIC logLik LR.stat df Pr(>Chisq) 272s fm1 8 3495.1 -1739.6 272s fm2 9 3491.5 -1736.7 5.6559 1 0.01740 * 272s fm3 9 3494.7 -1738.4 -3.2113 0 272s fm4 10 3492.5 -1736.2 4.2190 1 0.03997 * 272s --- 272s Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1 272s > 272s > ################################# 272s > ## Better handling of ill-defined variance-covariance matrix of the 272s > ## parameters in summary methods for clm and clmm objects: 272s > dat26.2 <- data.frame(sureness = as.factor(1:12), 272s + prod = rep(c("One", "Two", "Three"),each=4)) 272s > fm1 <- clm(sureness ~ prod, ~prod, data = dat26.2) 272s > fm1 272s formula: sureness ~ prod 272s scale: ~prod 272s data: dat26.2 272s 272s link threshold nobs logLik AIC niter max.grad cond.H 272s logit flexible 12 -16.64 63.27 33(14) 6.18e-07 2.0e+12 272s 272s Coefficients: 272s prodThree prodTwo 272s 90.72 46.65 272s 272s log-scale coefficients: 272s prodThree prodTwo 272s -0.11719 -0.09167 272s 272s Threshold coefficients: 272s 1|2 2|3 3|4 4|5 5|6 6|7 7|8 272s -1.099e+00 2.045e-16 1.099e+00 2.441e+01 4.564e+01 4.665e+01 4.765e+01 272s 8|9 9|10 10|11 11|12 272s 6.888e+01 8.975e+01 9.072e+01 9.170e+01 272s > summary(fm1) 272s Warning message: 272s (1) Hessian is numerically singular: parameters are not uniquely determined 272s In addition: Absolute convergence criterion was met, but relative criterion was not met 272s formula: sureness ~ prod 272s scale: ~prod 272s data: dat26.2 272s 272s link threshold nobs logLik AIC niter max.grad cond.H 272s logit flexible 12 -16.64 63.27 33(14) 6.18e-07 2.0e+12 272s 272s Coefficients: 272s Estimate Std. Error z value Pr(>|z|) 272s prodThree 90.72 NA NA NA 272s prodTwo 46.65 NA NA NA 272s 272s log-scale coefficients: 272s Estimate Std. Error z value Pr(>|z|) 272s prodThree -0.11719 NA NA NA 272s prodTwo -0.09167 NA NA NA 272s 272s Threshold coefficients: 272s Estimate Std. Error z value 272s 1|2 -1.099e+00 NA NA 272s 2|3 2.045e-16 NA NA 272s 3|4 1.099e+00 NA NA 272s 4|5 2.441e+01 NA NA 272s 5|6 4.564e+01 NA NA 272s 6|7 4.665e+01 NA NA 272s 7|8 4.765e+01 NA NA 272s 8|9 6.888e+01 NA NA 272s 9|10 8.975e+01 NA NA 272s 10|11 9.072e+01 NA NA 272s 11|12 9.170e+01 NA NA 272s > summary(fm1, corr = 1) 272s formula: sureness ~ prod 272s scale: ~prod 272s data: dat26.2 272s 272s link threshold nobs logLik AIC niter max.grad cond.H 272s logit flexible 12 -16.64 63.27 33(14) 6.18e-07 2.0e+12 272s 272s Coefficients: 272s Estimate Std. Error z value Pr(>|z|) 272s prodThree 90.72 NA NA NA 272s prodTwo 46.65 NA NA NA 272s 272s log-scale coefficients: 272s Estimate Std. Error z value Pr(>|z|) 272s prodThree -0.11719 NA NA NA 272s prodTwo -0.09167 NA NA NA 272s 272s Threshold coefficients: 272s Estimate Std. Error z value 272s 1|2 -1.099e+00 NA NA 272s 2|3 2.045e-16 NA NA 272s 3|4 1.099e+00 NA NA 272s 4|5 2.441e+01 NA NA 272s 5|6 4.564e+01 NA NA 272s 6|7 4.665e+01 NA NA 272s 7|8 4.765e+01 NA NA 272s 8|9 6.888e+01 NA NA 272s 9|10 8.975e+01 NA NA 272s 10|11 9.072e+01 NA NA 272s 11|12 9.170e+01 NA NA 272s > ## fm1$Hessian 272s > ## sl1 <- slice(fm1, 13) 272s > ## fitted(fm1) 272s > ## convergence(fm1) 272s > ## eigen(fm1$Hessian)$values 272s > ## sqrt(diag(solve(fm1$Hessian))) 272s > ## sqrt(diag(ginv(fm1$Hessian))) 272s > 272s > ################################# 272s > ## Missing values: 272s > ## Bug-report from Jonathan Williams 272s > ## , 18 March 2010 12:42 272s > data(soup, package = "ordinal") 272s > soup$SURENESS[10] <- NA 272s Warning message: 272s In summary.clm(fm1, corr = 1) : Correlation matrix is unavailable 272s > c1a <- clm(ordered(SURENESS)~PROD, data=soup); summary(c1a) 272s formula: ordered(SURENESS) ~ PROD 272s data: soup 272s 272s link threshold nobs logLik AIC niter max.grad cond.H 272s logit flexible 1846 -2688.71 5389.43 6(1) 2.49e-12 1.1e+02 272s 272s Coefficients: 272s Estimate Std. Error z value Pr(>|z|) 272s PRODTest 1.14251 0.08931 12.79 <2e-16 *** 272s --- 272s Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1 272s 272s Threshold coefficients: 272s Estimate Std. Error z value 272s 1|2 -1.40460 0.08174 -17.184 272s 2|3 -0.42733 0.06965 -6.135 272s 3|4 -0.10357 0.06884 -1.505 272s 4|5 0.14862 0.06898 2.155 272s 5|6 0.81063 0.07185 11.282 272s (1 observation deleted due to missingness) 272s > c2a <- clm(ordered(SURENESS)~PROD, scale = ~PROD, data=soup) 272s > summary(c2a) 272s formula: ordered(SURENESS) ~ PROD 272s scale: ~PROD 272s data: soup 272s 272s link threshold nobs logLik AIC niter max.grad cond.H 272s logit flexible 1846 -2686.16 5386.32 8(1) 4.81e-07 1.0e+02 272s 272s Coefficients: 272s Estimate Std. Error z value Pr(>|z|) 272s PRODTest 1.293 0.119 10.87 <2e-16 *** 272s --- 272s Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1 272s 272s log-scale coefficients: 272s Estimate Std. Error z value Pr(>|z|) 272s PRODTest 0.14711 0.06514 2.258 0.0239 * 272s --- 272s Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1 272s 272s Threshold coefficients: 272s Estimate Std. Error z value 272s 1|2 -1.49041 0.09219 -16.166 272s 2|3 -0.45478 0.07189 -6.326 272s 3|4 -0.10961 0.07000 -1.566 272s 4|5 0.16104 0.07029 2.291 272s 5|6 0.88052 0.07959 11.064 272s (1 observation deleted due to missingness) 272s > c3a <- clm(ordered(SURENESS)~1, scale = ~PROD, data=soup) 272s > summary(c3a) 272s formula: ordered(SURENESS) ~ 1 272s scale: ~PROD 272s data: soup 272s 272s link threshold nobs logLik AIC niter max.grad cond.H 272s logit flexible 1846 -2769.95 5551.91 10(1) 3.37e-13 6.9e+01 272s 272s log-scale coefficients: 272s Estimate Std. Error z value Pr(>|z|) 272s PRODTest -0.15478 0.06683 -2.316 0.0206 * 272s --- 272s Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1 272s 272s Threshold coefficients: 272s Estimate Std. Error z value 272s 1|2 -1.85565 0.08111 -22.878 272s 2|3 -0.98626 0.05260 -18.752 272s 3|4 -0.70743 0.04676 -15.129 272s 4|5 -0.49243 0.04393 -11.208 272s 5|6 0.06504 0.04653 1.398 272s (1 observation deleted due to missingness) 272s > data(soup, package = "ordinal") 272s > soup$PROD[1] <- NA 272s > c1a <- clm(ordered(SURENESS)~PROD, data=soup) 272s > summary(c1a) 272s formula: ordered(SURENESS) ~ PROD 272s data: soup 272s 272s link threshold nobs logLik AIC niter max.grad cond.H 272s logit flexible 1846 -2689.15 5390.30 6(1) 3.37e-12 1.1e+02 272s 272s Coefficients: 272s Estimate Std. Error z value Pr(>|z|) 272s PRODTest 1.14774 0.08932 12.85 <2e-16 *** 272s --- 272s Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1 272s 272s Threshold coefficients: 272s Estimate Std. Error z value 272s 1|2 -1.40278 0.08171 -17.167 272s 2|3 -0.42216 0.06962 -6.064 272s 3|4 -0.09849 0.06882 -1.431 272s 4|5 0.15373 0.06898 2.229 272s 5|6 0.81613 0.07188 11.353 272s (1 observation deleted due to missingness) 272s > c2a <- clm(ordered(SURENESS)~PROD, scale = ~PROD, data=soup) 272s > summary(c2a) 272s formula: ordered(SURENESS) ~ PROD 272s scale: ~PROD 272s data: soup 272s 272s link threshold nobs logLik AIC niter max.grad cond.H 272s logit flexible 1846 -2686.51 5387.03 8(1) 5.41e-07 1.0e+02 272s 272s Coefficients: 272s Estimate Std. Error z value Pr(>|z|) 272s PRODTest 1.3009 0.1192 10.91 <2e-16 *** 272s --- 272s Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1 272s 272s log-scale coefficients: 272s Estimate Std. Error z value Pr(>|z|) 272s PRODTest 0.1494 0.0651 2.295 0.0217 * 272s --- 272s Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1 272s 272s Threshold coefficients: 272s Estimate Std. Error z value 272s 1|2 -1.48982 0.09217 -16.163 272s 2|3 -0.44981 0.07186 -6.260 272s 3|4 -0.10441 0.07000 -1.492 272s 4|5 0.16655 0.07031 2.369 272s 5|6 0.88740 0.07969 11.136 272s (1 observation deleted due to missingness) 272s > c3a <- clm(ordered(SURENESS)~1, scale = ~PROD, data=soup) 272s > summary(c3a) 272s formula: ordered(SURENESS) ~ 1 272s scale: ~PROD 272s data: soup 272s 272s link threshold nobs logLik AIC niter max.grad cond.H 272s logit flexible 1846 -2771.22 5554.43 10(1) 7.51e-13 6.9e+01 272s 272s log-scale coefficients: 272s Estimate Std. Error z value Pr(>|z|) 272s PRODTest -0.15330 0.06689 -2.292 0.0219 * 272s --- 272s Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1 272s 272s Threshold coefficients: 272s Estimate Std. Error z value 272s 1|2 -1.85700 0.08108 -22.903 272s 2|3 -0.98437 0.05252 -18.742 272s 3|4 -0.70562 0.04673 -15.100 272s 4|5 -0.49061 0.04395 -11.163 272s 5|6 0.06723 0.04667 1.441 272s (1 observation deleted due to missingness) 272s > soup$SURENESS[10] <- NA 272s > c1a <- clm(ordered(SURENESS)~PROD, data=soup) 272s > summary(c1a) 272s formula: ordered(SURENESS) ~ PROD 272s data: soup 272s 272s link threshold nobs logLik AIC niter max.grad cond.H 272s logit flexible 1845 -2687.53 5387.07 6(1) 2.94e-12 1.1e+02 272s 272s Coefficients: 272s Estimate Std. Error z value Pr(>|z|) 272s PRODTest 1.14581 0.08934 12.82 <2e-16 *** 272s --- 272s Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1 272s 272s Threshold coefficients: 272s Estimate Std. Error z value 272s 1|2 -1.40237 0.08175 -17.155 272s 2|3 -0.42475 0.06968 -6.096 272s 3|4 -0.10080 0.06887 -1.464 272s 4|5 0.15158 0.06902 2.196 272s 5|6 0.81421 0.07191 11.322 272s (2 observations deleted due to missingness) 272s > c2a <- clm(ordered(SURENESS)~PROD, scale = ~PROD, data=soup) 272s > summary(c2a) 272s formula: ordered(SURENESS) ~ PROD 272s scale: ~PROD 272s data: soup 272s 272s link threshold nobs logLik AIC niter max.grad cond.H 272s logit flexible 1845 -2684.93 5383.86 8(1) 5.12e-07 1.0e+02 272s 272s Coefficients: 272s Estimate Std. Error z value Pr(>|z|) 272s PRODTest 1.2979 0.1192 10.89 <2e-16 *** 272s --- 272s Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1 272s 272s log-scale coefficients: 272s Estimate Std. Error z value Pr(>|z|) 272s PRODTest 0.14853 0.06514 2.28 0.0226 * 272s --- 272s Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1 272s 272s Threshold coefficients: 272s Estimate Std. Error z value 272s 1|2 -1.48896 0.09222 -16.147 272s 2|3 -0.45241 0.07192 -6.290 272s 3|4 -0.10681 0.07004 -1.525 272s 4|5 0.16422 0.07034 2.335 272s 5|6 0.88500 0.07970 11.104 272s (2 observations deleted due to missingness) 272s > c3a <- clm(ordered(SURENESS)~1, scale = ~PROD, data=soup) 272s > summary(c3a) 272s formula: ordered(SURENESS) ~ 1 272s scale: ~PROD 272s data: soup 272s 272s link threshold nobs logLik AIC niter max.grad cond.H 272s logit flexible 1845 -2769.23 5550.46 10(1) 9.65e-13 6.9e+01 272s 272s log-scale coefficients: 272s Estimate Std. Error z value Pr(>|z|) 272s PRODTest -0.15410 0.06688 -2.304 0.0212 * 272s --- 272s Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1 272s 272s Threshold coefficients: 272s Estimate Std. Error z value 272s 1|2 -1.85563 0.08111 -22.877 272s 2|3 -0.98586 0.05259 -18.745 272s 3|4 -0.70689 0.04676 -15.116 272s 4|5 -0.49176 0.04395 -11.188 272s 5|6 0.06616 0.04661 1.419 272s (2 observations deleted due to missingness) 272s > 272s > ## na.actions: 272s > c4a <- clm(ordered(SURENESS)~PROD, scale = ~PROD, data=soup, 272s + na.action=na.omit) 272s > summary(c4a) 272s formula: ordered(SURENESS) ~ PROD 272s scale: ~PROD 272s data: soup 272s 272s link threshold nobs logLik AIC niter max.grad cond.H 272s logit flexible 1845 -2684.93 5383.86 8(1) 5.12e-07 1.0e+02 272s 272s Coefficients: 272s Estimate Std. Error z value Pr(>|z|) 272s PRODTest 1.2979 0.1192 10.89 <2e-16 *** 272s --- 272s Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1 272s 272s log-scale coefficients: 272s Estimate Std. Error z value Pr(>|z|) 272s PRODTest 0.14853 0.06514 2.28 0.0226 * 272s --- 272s Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1 272s 272s Threshold coefficients: 272s Estimate Std. Error z value 272s 1|2 -1.48896 0.09222 -16.147 272s 2|3 -0.45241 0.07192 -6.290 272s 3|4 -0.10681 0.07004 -1.525 272s 4|5 0.16422 0.07034 2.335 272s 5|6 0.88500 0.07970 11.104 272s (2 observations deleted due to missingness) 272s > 272s > tC1 <- try(clm(ordered(SURENESS)~PROD, scale = ~PROD, data=soup, 272s + na.action=na.fail), silent = TRUE) 272s > stopifnot(inherits(tC1, "try-error")) 272s > 272s > c4a <- clm(ordered(SURENESS)~PROD, scale = ~PROD, data=soup, 272s + na.action=na.exclude) 272s > summary(c4a) 272s formula: ordered(SURENESS) ~ PROD 272s scale: ~PROD 272s data: soup 272s 272s link threshold nobs logLik AIC niter max.grad cond.H 272s logit flexible 1845 -2684.93 5383.86 8(1) 5.12e-07 1.0e+02 272s 272s Coefficients: 272s Estimate Std. Error z value Pr(>|z|) 272s PRODTest 1.2979 0.1192 10.89 <2e-16 *** 272s --- 272s Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1 272s 272s log-scale coefficients: 272s Estimate Std. Error z value Pr(>|z|) 272s PRODTest 0.14853 0.06514 2.28 0.0226 * 272s --- 272s Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1 272s 272s Threshold coefficients: 272s Estimate Std. Error z value 272s 1|2 -1.48896 0.09222 -16.147 272s 2|3 -0.45241 0.07192 -6.290 272s 3|4 -0.10681 0.07004 -1.525 272s 4|5 0.16422 0.07034 2.335 272s 5|6 0.88500 0.07970 11.104 272s (2 observations deleted due to missingness) 272s > 272s > tC2 <- try(clm(ordered(SURENESS)~PROD, scale = ~PROD, data=soup, 272s + na.action=na.pass), silent = TRUE) 272s > stopifnot(inherits(tC2, "try-error")) 272s > 272s > ## Subset: 272s > data(soup, package="ordinal") 272s > c4a <- clm(ordered(SURENESS)~PROD, scale = ~PROD, data=soup, 272s + subset = 1:100) 272s > c4a <- clm(ordered(SURENESS)~1, scale = ~PROD, data=soup, 272s + subset = 1:100) 272s > c4a <- clm(ordered(SURENESS)~PROD, data=soup, 272s + subset = 1:100) 272s > c4a <- clm(ordered(SURENESS)~1, data=soup, 272s + subset = 1:100) 272s > 272s > ## Offset: 272s > data(soup, package = "ordinal") 272s > set.seed(290980) 272s > offs <- runif(nrow(soup)) 272s > c4a <- clm(ordered(SURENESS)~PROD + offset(offs), 272s + scale = ~PROD, data=soup, subset = 1:100) 272s > summary(c4a) 272s formula: ordered(SURENESS) ~ PROD + offset(offs) 272s scale: ~PROD 272s data: soup 272s subset: 1:100 272s 272s link threshold nobs logLik AIC niter max.grad cond.H 272s logit flexible 100 -139.58 293.17 9(2) 1.41e-07 2.0e+02 272s 272s Coefficients: 272s Estimate Std. Error z value Pr(>|z|) 272s PRODTest 2.4410 0.7091 3.443 0.000576 *** 272s --- 272s Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1 272s 272s log-scale coefficients: 272s Estimate Std. Error z value Pr(>|z|) 272s PRODTest 0.5105 0.2671 1.911 0.056 . 272s --- 272s Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1 272s 272s Threshold coefficients: 272s Estimate Std. Error z value 272s 1|2 -1.0470 0.4019 -2.605 272s 2|3 0.4213 0.3106 1.356 272s 3|4 0.5488 0.3106 1.767 272s 4|5 0.9217 0.3162 2.915 272s 5|6 2.0775 0.4062 5.114 272s > 272s > c4a <- clm(ordered(SURENESS)~PROD + offset(offs), 272s + scale = ~PROD + offset(offs), data=soup, subset = 1:100) 272s > summary(c4a) 272s formula: ordered(SURENESS) ~ PROD + offset(offs) 272s scale: ~PROD + offset(offs) 272s data: soup 272s subset: 1:100 272s 272s link threshold nobs logLik AIC niter max.grad cond.H 272s logit flexible 100 -143.12 300.24 9(2) 5.32e-09 1.9e+02 272s 272s Coefficients: 272s Estimate Std. Error z value Pr(>|z|) 272s PRODTest 3.344 1.020 3.277 0.00105 ** 272s --- 272s Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1 272s 272s log-scale coefficients: 272s Estimate Std. Error z value Pr(>|z|) 272s PRODTest 0.4412 0.2753 1.603 0.109 272s 272s Threshold coefficients: 272s Estimate Std. Error z value 272s 1|2 -2.09797 0.62565 -3.353 272s 2|3 0.06671 0.46874 0.142 272s 3|4 0.25559 0.46525 0.549 272s 4|5 0.80178 0.46743 1.715 272s 5|6 2.46041 0.59193 4.157 272s > 272s > off2 <- offs 272s > c4a <- clm(ordered(SURENESS)~PROD + offset(offs), 272s + scale = ~PROD + offset(off2), data=soup, subset = 1:100) 272s > summary(c4a) 272s formula: ordered(SURENESS) ~ PROD + offset(offs) 272s scale: ~PROD + offset(off2) 272s data: soup 272s subset: 1:100 272s 272s link threshold nobs logLik AIC niter max.grad cond.H 272s logit flexible 100 -143.12 300.24 9(2) 5.32e-09 1.9e+02 272s 272s Coefficients: 272s Estimate Std. Error z value Pr(>|z|) 272s PRODTest 3.344 1.020 3.277 0.00105 ** 272s --- 272s Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1 272s 272s log-scale coefficients: 272s Estimate Std. Error z value Pr(>|z|) 272s PRODTest 0.4412 0.2753 1.603 0.109 272s 272s Threshold coefficients: 272s Estimate Std. Error z value 272s 1|2 -2.09797 0.62565 -3.353 272s 2|3 0.06671 0.46874 0.142 272s 3|4 0.25559 0.46525 0.549 272s 4|5 0.80178 0.46743 1.715 272s 5|6 2.46041 0.59193 4.157 272s > 272s > c4a <- clm(ordered(SURENESS)~PROD, 272s + scale = ~PROD + offset(offs), data=soup, subset = 1:100) 272s > summary(c4a) 272s formula: ordered(SURENESS) ~ PROD 272s scale: ~PROD + offset(offs) 272s data: soup 272s subset: 1:100 272s 272s link threshold nobs logLik AIC niter max.grad cond.H 272s logit flexible 100 -142.15 298.31 10(2) 7.69e-10 1.8e+02 272s 272s Coefficients: 272s Estimate Std. Error z value Pr(>|z|) 272s PRODTest 3.283 1.016 3.231 0.00123 ** 272s --- 272s Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1 272s 272s log-scale coefficients: 272s Estimate Std. Error z value Pr(>|z|) 272s PRODTest 0.4263 0.2801 1.522 0.128 272s 272s Threshold coefficients: 272s Estimate Std. Error z value 272s 1|2 -2.4698 0.6308 -3.915 272s 2|3 -0.2916 0.4668 -0.625 272s 3|4 -0.1005 0.4628 -0.217 272s 4|5 0.4484 0.4638 0.967 272s 5|6 2.1036 0.5864 3.587 272s > 272s > ## data as matrix: 272s > dat26M <- as.matrix(dat26) 272s > m1 <- clm(sureness ~ prod, scale = ~prod, data = dat26, 272s + weights = wghts, link = "logit") 272s > summary(m1) 272s formula: sureness ~ prod 272s scale: ~prod 272s data: dat26 272s 272s link threshold nobs logLik AIC niter max.grad cond.H 272s logit flexible 1847 -2687.74 5389.49 8(1) 5.09e-07 1.0e+02 272s 272s Coefficients: 272s Estimate Std. Error z value Pr(>|z|) 272s prodTest 1.296 0.119 10.89 <2e-16 *** 272s --- 272s Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1 272s 272s log-scale coefficients: 272s Estimate Std. Error z value Pr(>|z|) 272s prodTest 0.1480 0.0651 2.273 0.023 * 272s --- 272s Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1 272s 272s Threshold coefficients: 272s Estimate Std. Error z value 272s 1|2 -1.49126 0.09215 -16.183 272s 2|3 -0.45218 0.07182 -6.296 272s 3|4 -0.10721 0.06995 -1.533 272s 4|5 0.16337 0.07025 2.325 272s 5|6 0.88291 0.07957 11.096 272s > 272s > ## data in enclosing environment: 272s > attach(soup) 272s > m1 <- clm(SURENESS ~ PROD, scale = ~PROD) 272s > summary(m1) 272s formula: SURENESS ~ PROD 272s scale: ~PROD 272s 272s link threshold nobs logLik AIC niter max.grad cond.H 272s logit flexible 1847 -2687.74 5389.49 8(1) 5.09e-07 1.0e+02 272s 272s Coefficients: 272s Estimate Std. Error z value Pr(>|z|) 272s PRODTest 1.296 0.119 10.89 <2e-16 *** 272s --- 272s Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1 272s 272s log-scale coefficients: 272s Estimate Std. Error z value Pr(>|z|) 272s PRODTest 0.1480 0.0651 2.273 0.023 * 272s --- 272s Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1 272s 272s Threshold coefficients: 272s Estimate Std. Error z value 272s 1|2 -1.49126 0.09215 -16.183 272s 2|3 -0.45218 0.07182 -6.296 272s 3|4 -0.10721 0.06995 -1.533 272s 4|5 0.16337 0.07025 2.325 272s 5|6 0.88291 0.07957 11.096 272s > detach(soup) 272s > 272s > ################################################################## 272s > ### Parameter estimates were not correct with large scale effects due 272s > ### to end cut-points being \pm 100. This is not enough for 272s > ### location-scale model, but seems to be for location only models. 272s > ### Bug report from Ioannis Kosmidis : 272s > 272s > ### A 2x3 contigency table that will give a large estimated value of 272s > ### zeta 272s > x <- rep(0:1, each = 3) 272s > response <- factor(rep(c(1, 2, 3), times = 2)) 272s > freq <- c(1, 11, 1, 13, 1, 14) 272s > totals <- rep(tapply(freq, x, sum), each = 3) 272s > Dat <- data.frame(response, x, freq) 272s > 272s > ### Fitting a cumulative link model with dispersion effects 272s > modClm <- clm(response ~ x, scale = ~ x, weights = freq, data = Dat, 272s + control = clm.control(grtol = 1e-10, convTol = 1e-10)) 272s > summary(modClm) 272s formula: response ~ x 272s scale: ~x 272s data: Dat 272s 272s link threshold nobs logLik AIC niter max.grad cond.H 272s logit flexible 41 -29.98 67.96 10(3) 9.23e-10 2.4e+02 272s 272s Coefficients: 272s Estimate Std. Error z value Pr(>|z|) 272s x 2.485 13.168 0.189 0.85 272s 272s log-scale coefficients: 272s Estimate Std. Error z value Pr(>|z|) 272s x 3.548 1.023 3.468 0.000524 *** 272s --- 272s Signif. codes: 0 ‘***’ 0.001 ‘**’ 0.01 ‘*’ 0.05 ‘.’ 0.1 ‘ ’ 1 272s 272s Threshold coefficients: 272s Estimate Std. Error z value 272s 1|2 -2.485 1.041 -2.387 272s 2|3 2.485 1.041 2.387 272s > ### The maximized log-likelihood for this saturated model should be 272s > sum(freq*log(freq/totals)) 272s [1] -29.97808 272s > # > sum(freq*log(freq/totals)) 272s > # [1] -29.97808 272s > ### but apparently clm fails to maximixe the log-likelihood 272s > modClm$logLik 272s [1] -29.97808 272s > # > modClm$logLik 272s > # [1] -30.44452 272s > stopifnot(isTRUE(all.equal(sum(freq*log(freq/totals)), modClm$logLik))) 272s > 272s > ### The estimates reported by clm are 272s > coef(modClm) 272s 1|2 2|3 x x 272s -2.484907 2.484907 2.484907 3.547588 272s > coef.res <- structure(c(-2.48490664104217, 2.48490665578163, 272s + 2.48490659188594, 272s + 3.54758796387530), .Names = c("1|2", "2|3", 272s + "x", "x")) 272s > stopifnot(isTRUE(all.equal(coef.res, coef(modClm)))) 272s > # > modClm$coefficients 272s > # 1|2 2|3 x x 272s > # -2.297718 2.297038 1.239023 2.834285 272s > ### while they should be (from my own software) 272s > # 1|2 2|3 x disp.x 272s > #-2.484907 2.484907 2.484907 3.547588 272s > convergence(modClm) 272s nobs logLik niter max.grad cond.H logLik.Error 272s 41 -29.98 10(3) 9.23e-10 2.4e+02 <1e-10 272s 272s Estimate Std.Err Gradient Error Cor.Dec Sig.Dig 272s 1|2 -2.485 1.041 3.50e-10 5.32e-10 8 9 272s 2|3 2.485 1.041 -1.60e-10 -5.32e-10 8 9 272s x 2.485 13.168 -1.90e-10 -3.54e-08 7 8 272s x 3.548 1.023 -9.23e-10 -1.55e-09 8 9 272s 272s Eigen values of Hessian: 272s 1.374792 0.855786 0.785151 0.005766 272s 272s Convergence message from clm: 272s (0) successful convergence 272s In addition: Absolute and relative convergence criteria were met 272s 272s > 272s > ################################################################## 272s > 272s autopkgtest [15:23:48]: test run-unit-test: -----------------------] 277s autopkgtest [15:23:53]: test run-unit-test: - - - - - - - - - - results - - - - - - - - - - 277s run-unit-test PASS 280s autopkgtest [15:23:56]: test pkg-r-autopkgtest: preparing testbed 304s autopkgtest [15:24:20]: testbed dpkg architecture: armhf 306s autopkgtest [15:24:22]: testbed apt version: 2.9.33 310s autopkgtest [15:24:26]: @@@@@@@@@@@@@@@@@@@@ test bed setup 312s autopkgtest [15:24:28]: testbed release detected to be: plucky 320s autopkgtest [15:24:36]: updating testbed package index (apt update) 322s Get:1 http://ftpmaster.internal/ubuntu plucky-proposed InRelease [126 kB] 322s Get:2 http://ftpmaster.internal/ubuntu plucky InRelease [257 kB] 323s Get:3 http://ftpmaster.internal/ubuntu plucky-updates InRelease [126 kB] 323s Get:4 http://ftpmaster.internal/ubuntu plucky-security InRelease [126 kB] 323s Get:5 http://ftpmaster.internal/ubuntu plucky-proposed/main Sources [101 kB] 323s Get:6 http://ftpmaster.internal/ubuntu plucky-proposed/universe Sources [404 kB] 323s Get:7 http://ftpmaster.internal/ubuntu plucky-proposed/multiverse Sources [15.8 kB] 323s Get:8 http://ftpmaster.internal/ubuntu plucky-proposed/main armhf Packages [81.0 kB] 323s Get:9 http://ftpmaster.internal/ubuntu plucky-proposed/main armhf c-n-f Metadata [1944 B] 323s Get:10 http://ftpmaster.internal/ubuntu plucky-proposed/restricted armhf c-n-f Metadata [116 B] 323s Get:11 http://ftpmaster.internal/ubuntu plucky-proposed/universe armhf Packages [326 kB] 323s Get:12 http://ftpmaster.internal/ubuntu plucky-proposed/universe armhf c-n-f Metadata [12.1 kB] 323s Get:13 http://ftpmaster.internal/ubuntu plucky-proposed/multiverse armhf Packages [3472 B] 323s Get:14 http://ftpmaster.internal/ubuntu plucky-proposed/multiverse armhf c-n-f Metadata [332 B] 323s Get:15 http://ftpmaster.internal/ubuntu plucky/universe Sources [21.0 MB] 327s Get:16 http://ftpmaster.internal/ubuntu plucky/multiverse Sources [299 kB] 327s Get:17 http://ftpmaster.internal/ubuntu plucky/main Sources [1400 kB] 327s Get:18 http://ftpmaster.internal/ubuntu plucky/main armhf Packages [1378 kB] 327s Get:19 http://ftpmaster.internal/ubuntu plucky/main armhf c-n-f Metadata [29.4 kB] 327s Get:20 http://ftpmaster.internal/ubuntu plucky/restricted armhf c-n-f Metadata [108 B] 327s Get:21 http://ftpmaster.internal/ubuntu plucky/universe armhf Packages [15.1 MB] 330s Get:22 http://ftpmaster.internal/ubuntu plucky/multiverse armhf Packages [172 kB] 331s Fetched 41.0 MB in 9s (4520 kB/s) 332s Reading package lists... 339s autopkgtest [15:24:55]: upgrading testbed (apt dist-upgrade and autopurge) 341s Reading package lists... 341s Building dependency tree... 341s Reading state information... 342s Calculating upgrade...Starting pkgProblemResolver with broken count: 0 342s Starting 2 pkgProblemResolver with broken count: 0 342s Done 343s Entering ResolveByKeep 343s 343s Calculating upgrade... 343s The following packages will be upgraded: 343s libc-bin libc6 locales python3-jinja2 sos strace 344s 6 upgraded, 0 newly installed, 0 to remove and 0 not upgraded. 344s Need to get 8642 kB of archives. 344s After this operation, 23.6 kB of additional disk space will be used. 344s Get:1 http://ftpmaster.internal/ubuntu plucky-proposed/main armhf libc6 armhf 2.41-1ubuntu2 [2932 kB] 345s Get:2 http://ftpmaster.internal/ubuntu plucky-proposed/main armhf libc-bin armhf 2.41-1ubuntu2 [545 kB] 345s Get:3 http://ftpmaster.internal/ubuntu plucky-proposed/main armhf locales all 2.41-1ubuntu2 [4246 kB] 345s Get:4 http://ftpmaster.internal/ubuntu plucky/main armhf strace armhf 6.13+ds-1ubuntu1 [445 kB] 345s Get:5 http://ftpmaster.internal/ubuntu plucky/main armhf python3-jinja2 all 3.1.5-2ubuntu1 [109 kB] 345s Get:6 http://ftpmaster.internal/ubuntu plucky/main armhf sos all 4.9.0-5 [365 kB] 346s Preconfiguring packages ... 346s Fetched 8642 kB in 2s (4142 kB/s) 346s (Reading database ... (Reading database ... 5% (Reading database ... 10% (Reading database ... 15% (Reading database ... 20% (Reading database ... 25% (Reading database ... 30% (Reading database ... 35% (Reading database ... 40% (Reading database ... 45% (Reading database ... 50% (Reading database ... 55% (Reading database ... 60% (Reading database ... 65% (Reading database ... 70% (Reading database ... 75% (Reading database ... 80% (Reading database ... 85% (Reading database ... 90% (Reading database ... 95% (Reading database ... 100% (Reading database ... 64655 files and directories currently installed.) 346s Preparing to unpack .../libc6_2.41-1ubuntu2_armhf.deb ... 346s Unpacking libc6:armhf (2.41-1ubuntu2) over (2.41-1ubuntu1) ... 347s Setting up libc6:armhf (2.41-1ubuntu2) ... 347s (Reading database ... (Reading database ... 5% (Reading database ... 10% (Reading database ... 15% (Reading database ... 20% (Reading database ... 25% (Reading database ... 30% (Reading database ... 35% (Reading database ... 40% (Reading database ... 45% (Reading database ... 50% (Reading database ... 55% (Reading database ... 60% (Reading database ... 65% (Reading database ... 70% (Reading database ... 75% (Reading database ... 80% (Reading database ... 85% (Reading database ... 90% (Reading database ... 95% (Reading database ... 100% (Reading database ... 64655 files and directories currently installed.) 347s Preparing to unpack .../libc-bin_2.41-1ubuntu2_armhf.deb ... 347s Unpacking libc-bin (2.41-1ubuntu2) over (2.41-1ubuntu1) ... 347s Setting up libc-bin (2.41-1ubuntu2) ... 347s (Reading database ... (Reading database ... 5% (Reading database ... 10% (Reading database ... 15% (Reading database ... 20% (Reading database ... 25% (Reading database ... 30% (Reading database ... 35% (Reading database ... 40% (Reading database ... 45% (Reading database ... 50% (Reading database ... 55% (Reading database ... 60% (Reading database ... 65% (Reading database ... 70% (Reading database ... 75% (Reading database ... 80% (Reading database ... 85% (Reading database ... 90% (Reading database ... 95% (Reading database ... 100% (Reading database ... 64655 files and directories currently installed.) 347s Preparing to unpack .../locales_2.41-1ubuntu2_all.deb ... 347s Unpacking locales (2.41-1ubuntu2) over (2.41-1ubuntu1) ... 347s Preparing to unpack .../strace_6.13+ds-1ubuntu1_armhf.deb ... 347s Unpacking strace (6.13+ds-1ubuntu1) over (6.11-0ubuntu1) ... 347s Preparing to unpack .../python3-jinja2_3.1.5-2ubuntu1_all.deb ... 348s Unpacking python3-jinja2 (3.1.5-2ubuntu1) over (3.1.5-2) ... 348s Preparing to unpack .../archives/sos_4.9.0-5_all.deb ... 348s Unpacking sos (4.9.0-5) over (4.9.0-4) ... 348s Setting up sos (4.9.0-5) ... 349s Setting up locales (2.41-1ubuntu2) ... 349s Generating locales (this might take a while)... 351s en_US.UTF-8... done 351s Generation complete. 351s Setting up python3-jinja2 (3.1.5-2ubuntu1) ... 352s Setting up strace (6.13+ds-1ubuntu1) ... 352s Processing triggers for man-db (2.13.0-1) ... 353s Processing triggers for systemd (257.3-1ubuntu3) ... 355s Reading package lists... 356s Building dependency tree... 356s Reading state information... 356s Starting pkgProblemResolver with broken count: 0 356s Starting 2 pkgProblemResolver with broken count: 0 356s Done 356s Solving dependencies... 357s 0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded. 359s autopkgtest [15:25:15]: rebooting testbed after setup commands that affected boot 425s Reading package lists... 425s Building dependency tree... 425s Reading state information... 426s Starting pkgProblemResolver with broken count: 0 426s Starting 2 pkgProblemResolver with broken count: 0 426s Done 427s The following NEW packages will be installed: 427s build-essential cpp cpp-14 cpp-14-arm-linux-gnueabihf 427s cpp-arm-linux-gnueabihf dctrl-tools fontconfig fontconfig-config 427s fonts-dejavu-core fonts-dejavu-mono g++ g++-14 g++-14-arm-linux-gnueabihf 427s g++-arm-linux-gnueabihf gcc gcc-14 gcc-14-arm-linux-gnueabihf 427s gcc-arm-linux-gnueabihf gfortran gfortran-14 gfortran-14-arm-linux-gnueabihf 427s gfortran-arm-linux-gnueabihf icu-devtools libasan8 libblas-dev libblas3 427s libbz2-dev libc-dev-bin libc6-dev libcairo2 libcc1-0 libcrypt-dev libdatrie1 427s libdeflate-dev libdeflate0 libfontconfig1 libfreetype6 libgcc-14-dev 427s libgfortran-14-dev libgfortran5 libgomp1 libgraphite2-3 libharfbuzz0b 427s libice6 libicu-dev libisl23 libjbig0 libjpeg-dev libjpeg-turbo8 427s libjpeg-turbo8-dev libjpeg8 libjpeg8-dev liblapack-dev liblapack3 liblerc4 427s liblzma-dev libmpc3 libncurses-dev libnlopt0 libpango-1.0-0 427s libpangocairo-1.0-0 libpangoft2-1.0-0 libpaper-utils libpaper2 libpcre2-16-0 427s libpcre2-32-0 libpcre2-dev libpcre2-posix3 libpixman-1-0 libpkgconf3 427s libpng-dev libreadline-dev libsharpyuv0 libsm6 libstdc++-14-dev libtcl8.6 427s libthai-data libthai0 libtiff6 libtirpc-dev libtk8.6 libubsan1 libwebp7 427s libxcb-render0 libxcb-shm0 libxft2 libxrender1 libxss1 libxt6t64 427s linux-libc-dev littler pkg-r-autopkgtest pkgconf pkgconf-bin r-base-core 427s r-base-dev r-cran-boot r-cran-brio r-cran-callr r-cran-cli r-cran-crayon 427s r-cran-desc r-cran-diffobj r-cran-digest r-cran-evaluate r-cran-fs 427s r-cran-glue r-cran-jsonlite r-cran-lattice r-cran-lifecycle r-cran-littler 427s r-cran-lme4 r-cran-magrittr r-cran-mass r-cran-matrix r-cran-minqa 427s r-cran-nlme r-cran-nloptr r-cran-nnet r-cran-numderiv r-cran-ordinal 427s r-cran-pkgbuild r-cran-pkgkitten r-cran-pkgload r-cran-praise 427s r-cran-processx r-cran-ps r-cran-r6 r-cran-rbibutils r-cran-rcpp 427s r-cran-rcppeigen r-cran-rdpack r-cran-reformulas r-cran-rlang 427s r-cran-rprojroot r-cran-statmod r-cran-testthat r-cran-ucminf r-cran-waldo 427s r-cran-withr r-cran-xtable rpcsvc-proto unzip x11-common xdg-utils zip 427s zlib1g-dev 427s 0 upgraded, 147 newly installed, 0 to remove and 0 not upgraded. 427s Need to get 148 MB of archives. 427s After this operation, 377 MB of additional disk space will be used. 427s Get:1 http://ftpmaster.internal/ubuntu plucky-proposed/main armhf libc-dev-bin armhf 2.41-1ubuntu2 [23.0 kB] 427s Get:2 http://ftpmaster.internal/ubuntu plucky/main armhf linux-libc-dev armhf 6.14.0-10.10 [1683 kB] 428s Get:3 http://ftpmaster.internal/ubuntu plucky/main armhf libcrypt-dev armhf 1:4.4.38-1 [120 kB] 428s Get:4 http://ftpmaster.internal/ubuntu plucky/main armhf rpcsvc-proto armhf 1.4.2-0ubuntu7 [62.2 kB] 428s Get:5 http://ftpmaster.internal/ubuntu plucky-proposed/main armhf libc6-dev armhf 2.41-1ubuntu2 [1396 kB] 429s Get:6 http://ftpmaster.internal/ubuntu plucky/main armhf libisl23 armhf 0.27-1 [546 kB] 429s Get:7 http://ftpmaster.internal/ubuntu plucky/main armhf libmpc3 armhf 1.3.1-1build2 [47.1 kB] 429s Get:8 http://ftpmaster.internal/ubuntu plucky/main armhf cpp-14-arm-linux-gnueabihf armhf 14.2.0-17ubuntu3 [9220 kB] 433s Get:9 http://ftpmaster.internal/ubuntu plucky/main armhf cpp-14 armhf 14.2.0-17ubuntu3 [1030 B] 433s Get:10 http://ftpmaster.internal/ubuntu plucky/main armhf cpp-arm-linux-gnueabihf armhf 4:14.2.0-1ubuntu1 [5578 B] 433s Get:11 http://ftpmaster.internal/ubuntu plucky/main armhf cpp armhf 4:14.2.0-1ubuntu1 [22.4 kB] 433s Get:12 http://ftpmaster.internal/ubuntu plucky/main armhf libcc1-0 armhf 15-20250222-0ubuntu1 [38.9 kB] 433s Get:13 http://ftpmaster.internal/ubuntu plucky/main armhf libgomp1 armhf 15-20250222-0ubuntu1 [128 kB] 433s Get:14 http://ftpmaster.internal/ubuntu plucky/main armhf libasan8 armhf 15-20250222-0ubuntu1 [2955 kB] 434s Get:15 http://ftpmaster.internal/ubuntu plucky/main armhf libubsan1 armhf 15-20250222-0ubuntu1 [1191 kB] 434s Get:16 http://ftpmaster.internal/ubuntu plucky/main armhf libgcc-14-dev armhf 14.2.0-17ubuntu3 [897 kB] 435s Get:17 http://ftpmaster.internal/ubuntu plucky/main armhf gcc-14-arm-linux-gnueabihf armhf 14.2.0-17ubuntu3 [18.0 MB] 441s Get:18 http://ftpmaster.internal/ubuntu plucky/main armhf gcc-14 armhf 14.2.0-17ubuntu3 [506 kB] 441s Get:19 http://ftpmaster.internal/ubuntu plucky/main armhf gcc-arm-linux-gnueabihf armhf 4:14.2.0-1ubuntu1 [1218 B] 441s Get:20 http://ftpmaster.internal/ubuntu plucky/main armhf gcc armhf 4:14.2.0-1ubuntu1 [5004 B] 441s Get:21 http://ftpmaster.internal/ubuntu plucky/main armhf libstdc++-14-dev armhf 14.2.0-17ubuntu3 [2573 kB] 442s Get:22 http://ftpmaster.internal/ubuntu plucky/main armhf g++-14-arm-linux-gnueabihf armhf 14.2.0-17ubuntu3 [10.5 MB] 445s Get:23 http://ftpmaster.internal/ubuntu plucky/main armhf g++-14 armhf 14.2.0-17ubuntu3 [21.8 kB] 445s Get:24 http://ftpmaster.internal/ubuntu plucky/main armhf g++-arm-linux-gnueabihf armhf 4:14.2.0-1ubuntu1 [966 B] 445s Get:25 http://ftpmaster.internal/ubuntu plucky/main armhf g++ armhf 4:14.2.0-1ubuntu1 [1084 B] 445s Get:26 http://ftpmaster.internal/ubuntu plucky/main armhf build-essential armhf 12.10ubuntu1 [4928 B] 445s Get:27 http://ftpmaster.internal/ubuntu plucky/main armhf dctrl-tools armhf 2.24-3build3 [94.7 kB] 445s Get:28 http://ftpmaster.internal/ubuntu plucky/main armhf libfreetype6 armhf 2.13.3+dfsg-1 [330 kB] 445s Get:29 http://ftpmaster.internal/ubuntu plucky/main armhf fonts-dejavu-mono all 2.37-8 [502 kB] 445s Get:30 http://ftpmaster.internal/ubuntu plucky/main armhf fonts-dejavu-core all 2.37-8 [835 kB] 445s Get:31 http://ftpmaster.internal/ubuntu plucky/main armhf fontconfig-config armhf 2.15.0-2ubuntu1 [37.5 kB] 445s Get:32 http://ftpmaster.internal/ubuntu plucky/main armhf libfontconfig1 armhf 2.15.0-2ubuntu1 [114 kB] 445s Get:33 http://ftpmaster.internal/ubuntu plucky/main armhf fontconfig armhf 2.15.0-2ubuntu1 [190 kB] 445s Get:34 http://ftpmaster.internal/ubuntu plucky/main armhf libgfortran5 armhf 15-20250222-0ubuntu1 [330 kB] 445s Get:35 http://ftpmaster.internal/ubuntu plucky/main armhf libgfortran-14-dev armhf 14.2.0-17ubuntu3 [370 kB] 446s Get:36 http://ftpmaster.internal/ubuntu plucky/main armhf gfortran-14-arm-linux-gnueabihf armhf 14.2.0-17ubuntu3 [9763 kB] 449s Get:37 http://ftpmaster.internal/ubuntu plucky/main armhf gfortran-14 armhf 14.2.0-17ubuntu3 [13.6 kB] 449s Get:38 http://ftpmaster.internal/ubuntu plucky/main armhf gfortran-arm-linux-gnueabihf armhf 4:14.2.0-1ubuntu1 [1026 B] 449s Get:39 http://ftpmaster.internal/ubuntu plucky/main armhf gfortran armhf 4:14.2.0-1ubuntu1 [1166 B] 449s Get:40 http://ftpmaster.internal/ubuntu plucky/main armhf icu-devtools armhf 76.1-1ubuntu2 [206 kB] 449s Get:41 http://ftpmaster.internal/ubuntu plucky/main armhf libblas3 armhf 3.12.1-2 [132 kB] 449s Get:42 http://ftpmaster.internal/ubuntu plucky/main armhf libblas-dev armhf 3.12.1-2 [141 kB] 449s Get:43 http://ftpmaster.internal/ubuntu plucky/main armhf libbz2-dev armhf 1.0.8-6 [30.9 kB] 449s Get:44 http://ftpmaster.internal/ubuntu plucky/main armhf libpixman-1-0 armhf 0.44.0-3 [183 kB] 449s Get:45 http://ftpmaster.internal/ubuntu plucky/main armhf libxcb-render0 armhf 1.17.0-2 [15.3 kB] 449s Get:46 http://ftpmaster.internal/ubuntu plucky/main armhf libxcb-shm0 armhf 1.17.0-2 [5774 B] 449s Get:47 http://ftpmaster.internal/ubuntu plucky/main armhf libxrender1 armhf 1:0.9.10-1.1build1 [16.0 kB] 449s Get:48 http://ftpmaster.internal/ubuntu plucky/main armhf libcairo2 armhf 1.18.2-2 [484 kB] 449s Get:49 http://ftpmaster.internal/ubuntu plucky/main armhf libdatrie1 armhf 0.2.13-3build1 [15.7 kB] 449s Get:50 http://ftpmaster.internal/ubuntu plucky/main armhf libdeflate0 armhf 1.23-1 [38.5 kB] 449s Get:51 http://ftpmaster.internal/ubuntu plucky/main armhf libdeflate-dev armhf 1.23-1 [45.0 kB] 449s Get:52 http://ftpmaster.internal/ubuntu plucky/main armhf libgraphite2-3 armhf 1.3.14-2ubuntu1 [64.8 kB] 449s Get:53 http://ftpmaster.internal/ubuntu plucky/main armhf libharfbuzz0b armhf 10.2.0-1 [464 kB] 449s Get:54 http://ftpmaster.internal/ubuntu plucky/main armhf x11-common all 1:7.7+23ubuntu3 [21.7 kB] 449s Get:55 http://ftpmaster.internal/ubuntu plucky/main armhf libice6 armhf 2:1.1.1-1 [36.5 kB] 449s Get:56 http://ftpmaster.internal/ubuntu plucky/main armhf libicu-dev armhf 76.1-1ubuntu2 [12.0 MB] 452s Get:57 http://ftpmaster.internal/ubuntu plucky/main armhf libjpeg-turbo8 armhf 2.1.5-3ubuntu2 [127 kB] 452s Get:58 http://ftpmaster.internal/ubuntu plucky/main armhf libjpeg-turbo8-dev armhf 2.1.5-3ubuntu2 [265 kB] 452s Get:59 http://ftpmaster.internal/ubuntu plucky/main armhf libjpeg8 armhf 8c-2ubuntu11 [2148 B] 452s Get:60 http://ftpmaster.internal/ubuntu plucky/main armhf libjpeg8-dev armhf 8c-2ubuntu11 [1484 B] 452s Get:61 http://ftpmaster.internal/ubuntu plucky/main armhf libjpeg-dev armhf 8c-2ubuntu11 [1482 B] 452s Get:62 http://ftpmaster.internal/ubuntu plucky/main armhf liblapack3 armhf 3.12.1-2 [2091 kB] 453s Get:63 http://ftpmaster.internal/ubuntu plucky/main armhf liblapack-dev armhf 3.12.1-2 [2207 kB] 454s Get:64 http://ftpmaster.internal/ubuntu plucky/main armhf liblerc4 armhf 4.0.0+ds-5ubuntu1 [160 kB] 454s Get:65 http://ftpmaster.internal/ubuntu plucky/main armhf libncurses-dev armhf 6.5+20250216-2 [345 kB] 454s Get:66 http://ftpmaster.internal/ubuntu plucky/main armhf libthai-data all 0.1.29-2build1 [158 kB] 454s Get:67 http://ftpmaster.internal/ubuntu plucky/main armhf libthai0 armhf 0.1.29-2build1 [15.2 kB] 454s Get:68 http://ftpmaster.internal/ubuntu plucky/main armhf libpango-1.0-0 armhf 1.56.2-1 [216 kB] 454s Get:69 http://ftpmaster.internal/ubuntu plucky/main armhf libpangoft2-1.0-0 armhf 1.56.2-1 [43.6 kB] 454s Get:70 http://ftpmaster.internal/ubuntu plucky/main armhf libpangocairo-1.0-0 armhf 1.56.2-1 [25.1 kB] 454s Get:71 http://ftpmaster.internal/ubuntu plucky/main armhf libpaper2 armhf 2.2.5-0.3 [16.3 kB] 454s Get:72 http://ftpmaster.internal/ubuntu plucky/main armhf libpaper-utils armhf 2.2.5-0.3 [14.2 kB] 454s Get:73 http://ftpmaster.internal/ubuntu plucky/main armhf libpcre2-16-0 armhf 10.45-1 [207 kB] 454s Get:74 http://ftpmaster.internal/ubuntu plucky/main armhf libpcre2-32-0 armhf 10.45-1 [197 kB] 454s Get:75 http://ftpmaster.internal/ubuntu plucky/main armhf libpcre2-posix3 armhf 10.45-1 [6300 B] 454s Get:76 http://ftpmaster.internal/ubuntu plucky/main armhf libpcre2-dev armhf 10.45-1 [752 kB] 454s Get:77 http://ftpmaster.internal/ubuntu plucky/main armhf libpkgconf3 armhf 1.8.1-4 [26.6 kB] 454s Get:78 http://ftpmaster.internal/ubuntu plucky/main armhf zlib1g-dev armhf 1:1.3.dfsg+really1.3.1-1ubuntu1 [880 kB] 455s Get:79 http://ftpmaster.internal/ubuntu plucky/main armhf libpng-dev armhf 1.6.47-1 [251 kB] 455s Get:80 http://ftpmaster.internal/ubuntu plucky/main armhf libreadline-dev armhf 8.2-6 [153 kB] 455s Get:81 http://ftpmaster.internal/ubuntu plucky/main armhf libsharpyuv0 armhf 1.5.0-0.1 [16.4 kB] 455s Get:82 http://ftpmaster.internal/ubuntu plucky/main armhf libsm6 armhf 2:1.2.4-1 [15.1 kB] 455s Get:83 http://ftpmaster.internal/ubuntu plucky/main armhf libtcl8.6 armhf 8.6.16+dfsg-1 [909 kB] 455s Get:84 http://ftpmaster.internal/ubuntu plucky/main armhf libjbig0 armhf 2.1-6.1ubuntu2 [24.9 kB] 455s Get:85 http://ftpmaster.internal/ubuntu plucky/main armhf libwebp7 armhf 1.5.0-0.1 [188 kB] 455s Get:86 http://ftpmaster.internal/ubuntu plucky/main armhf libtiff6 armhf 4.5.1+git230720-4ubuntu4 [179 kB] 456s Get:87 http://ftpmaster.internal/ubuntu plucky/main armhf libxft2 armhf 2.3.6-1build1 [37.4 kB] 456s Get:88 http://ftpmaster.internal/ubuntu plucky/main armhf libxss1 armhf 1:1.2.3-1build3 [6500 B] 456s Get:89 http://ftpmaster.internal/ubuntu plucky/main armhf libtk8.6 armhf 8.6.16-1 [686 kB] 456s Get:90 http://ftpmaster.internal/ubuntu plucky/main armhf libxt6t64 armhf 1:1.2.1-1.2build1 [145 kB] 456s Get:91 http://ftpmaster.internal/ubuntu plucky/main armhf zip armhf 3.0-14ubuntu2 [164 kB] 456s Get:92 http://ftpmaster.internal/ubuntu plucky/main armhf unzip armhf 6.0-28ubuntu6 [167 kB] 456s Get:93 http://ftpmaster.internal/ubuntu plucky/main armhf xdg-utils all 1.2.1-2ubuntu1 [66.0 kB] 456s Get:94 http://ftpmaster.internal/ubuntu plucky/universe armhf r-base-core armhf 4.4.3-1 [28.2 MB] 466s Get:95 http://ftpmaster.internal/ubuntu plucky/universe armhf r-cran-littler armhf 0.3.20-2 [90.9 kB] 466s Get:96 http://ftpmaster.internal/ubuntu plucky/universe armhf littler all 0.3.20-2 [2554 B] 466s Get:97 http://ftpmaster.internal/ubuntu plucky/main armhf liblzma-dev armhf 5.6.4-1 [166 kB] 466s Get:98 http://ftpmaster.internal/ubuntu plucky/main armhf pkgconf-bin armhf 1.8.1-4 [21.2 kB] 466s Get:99 http://ftpmaster.internal/ubuntu plucky/main armhf pkgconf armhf 1.8.1-4 [16.8 kB] 466s Get:100 http://ftpmaster.internal/ubuntu plucky/main armhf libtirpc-dev armhf 1.3.4+ds-1.3 [184 kB] 466s Get:101 http://ftpmaster.internal/ubuntu plucky/universe armhf r-base-dev all 4.4.3-1 [4176 B] 467s Get:102 http://ftpmaster.internal/ubuntu plucky/universe armhf pkg-r-autopkgtest all 20231212ubuntu1 [6448 B] 467s Get:103 http://ftpmaster.internal/ubuntu plucky/universe armhf r-cran-boot all 1.3-31-1 [635 kB] 468s Get:104 http://ftpmaster.internal/ubuntu plucky/universe armhf r-cran-brio armhf 1.1.5-1 [37.9 kB] 468s Get:105 http://ftpmaster.internal/ubuntu plucky/universe armhf r-cran-ps armhf 1.9.0-1 [403 kB] 468s Get:106 http://ftpmaster.internal/ubuntu plucky/universe armhf r-cran-r6 all 2.6.1-1 [101 kB] 468s Get:107 http://ftpmaster.internal/ubuntu plucky/universe armhf r-cran-processx armhf 3.8.6-1 [359 kB] 468s Get:108 http://ftpmaster.internal/ubuntu plucky/universe armhf r-cran-callr all 3.7.6-1 [458 kB] 468s Get:109 http://ftpmaster.internal/ubuntu plucky/universe armhf r-cran-cli armhf 3.6.4-1 [1377 kB] 469s Get:110 http://ftpmaster.internal/ubuntu plucky/universe armhf r-cran-crayon all 1.5.3-1 [165 kB] 469s Get:111 http://ftpmaster.internal/ubuntu plucky/universe armhf r-cran-desc all 1.4.3-1 [359 kB] 469s Get:112 http://ftpmaster.internal/ubuntu plucky/universe armhf r-cran-diffobj armhf 0.3.5-1 [1115 kB] 469s Get:113 http://ftpmaster.internal/ubuntu plucky/universe armhf r-cran-digest armhf 0.6.37-1 [207 kB] 469s Get:114 http://ftpmaster.internal/ubuntu plucky/universe armhf r-cran-evaluate all 1.0.3-1 [114 kB] 469s Get:115 http://ftpmaster.internal/ubuntu plucky/universe armhf r-cran-fs armhf 1.6.5+dfsg-1 [242 kB] 469s Get:116 http://ftpmaster.internal/ubuntu plucky/universe armhf r-cran-glue armhf 1.8.0-1 [162 kB] 469s Get:117 http://ftpmaster.internal/ubuntu plucky/universe armhf r-cran-jsonlite armhf 1.9.1+dfsg-1 [440 kB] 470s Get:118 http://ftpmaster.internal/ubuntu plucky/universe armhf r-cran-lattice armhf 0.22-6-1 [1363 kB] 470s Get:119 http://ftpmaster.internal/ubuntu plucky/universe armhf r-cran-rlang armhf 1.1.5-1 [1701 kB] 471s Get:120 http://ftpmaster.internal/ubuntu plucky/universe armhf r-cran-lifecycle all 1.0.4+dfsg-1 [110 kB] 471s Get:121 http://ftpmaster.internal/ubuntu plucky/universe armhf r-cran-matrix armhf 1.7-3-1 [4039 kB] 472s Get:122 http://ftpmaster.internal/ubuntu plucky/universe armhf r-cran-mass armhf 7.3-64-1 [1105 kB] 472s Get:123 http://ftpmaster.internal/ubuntu plucky/universe armhf r-cran-nlme armhf 3.1.167-1 [2306 kB] 473s Get:124 http://ftpmaster.internal/ubuntu plucky/universe armhf r-cran-pkgkitten all 0.2.4-1 [27.2 kB] 473s Get:125 http://ftpmaster.internal/ubuntu plucky/universe armhf r-cran-rcpp armhf 1.0.14-1 [1976 kB] 474s Get:126 http://ftpmaster.internal/ubuntu plucky/universe armhf r-cran-minqa armhf 1.2.8-1 [108 kB] 474s Get:127 http://ftpmaster.internal/ubuntu plucky/universe armhf libnlopt0 armhf 2.7.1-6ubuntu3 [154 kB] 474s Get:128 http://ftpmaster.internal/ubuntu plucky/universe armhf r-cran-nloptr armhf 2.1.1-1 [250 kB] 474s Get:129 http://ftpmaster.internal/ubuntu plucky/universe armhf r-cran-rbibutils armhf 2.3-1 [943 kB] 474s Get:130 http://ftpmaster.internal/ubuntu plucky/universe armhf r-cran-rdpack all 2.6.2-1syncable1 [756 kB] 474s Get:131 http://ftpmaster.internal/ubuntu plucky/universe armhf r-cran-reformulas all 0.4.0-1 [91.5 kB] 474s Get:132 http://ftpmaster.internal/ubuntu plucky/universe armhf r-cran-rcppeigen armhf 0.3.4.0.2-1 [1402 kB] 475s Get:133 http://ftpmaster.internal/ubuntu plucky/universe armhf r-cran-statmod armhf 1.5.0-1 [294 kB] 475s Get:134 http://ftpmaster.internal/ubuntu plucky/universe armhf r-cran-lme4 armhf 1.1-36-1 [4108 kB] 476s Get:135 http://ftpmaster.internal/ubuntu plucky/universe armhf r-cran-magrittr armhf 2.0.3-1 [154 kB] 476s Get:136 http://ftpmaster.internal/ubuntu plucky/universe armhf r-cran-nnet armhf 7.3-20-1 [111 kB] 476s Get:137 http://ftpmaster.internal/ubuntu plucky/universe armhf r-cran-numderiv all 2016.8-1.1-3 [115 kB] 476s Get:138 http://ftpmaster.internal/ubuntu plucky/universe armhf r-cran-ucminf armhf 1.2.2-1 [34.5 kB] 476s Get:139 http://ftpmaster.internal/ubuntu plucky/universe armhf r-cran-ordinal armhf 2023.12-4.1-1 [1265 kB] 477s Get:140 http://ftpmaster.internal/ubuntu plucky/universe armhf r-cran-pkgbuild all 1.4.6-1 [213 kB] 477s Get:141 http://ftpmaster.internal/ubuntu plucky/universe armhf r-cran-rprojroot all 2.0.4-2 [125 kB] 477s Get:142 http://ftpmaster.internal/ubuntu plucky/universe armhf r-cran-withr all 3.0.2+dfsg-1 [214 kB] 477s Get:143 http://ftpmaster.internal/ubuntu plucky/universe armhf r-cran-pkgload all 1.4.0-1 [247 kB] 477s Get:144 http://ftpmaster.internal/ubuntu plucky/universe armhf r-cran-praise all 1.0.0-4build1 [20.3 kB] 477s Get:145 http://ftpmaster.internal/ubuntu plucky/universe armhf r-cran-waldo all 0.6.1-2 [150 kB] 477s Get:146 http://ftpmaster.internal/ubuntu plucky/universe armhf r-cran-testthat armhf 3.2.3-1 [1633 kB] 478s Get:147 http://ftpmaster.internal/ubuntu plucky/universe armhf r-cran-xtable all 1:1.8-4-2 [689 kB] 479s Preconfiguring packages ... 479s Fetched 148 MB in 51s (2879 kB/s) 479s Selecting previously unselected package libc-dev-bin. 479s (Reading database ... (Reading database ... 5% (Reading database ... 10% (Reading database ... 15% (Reading database ... 20% (Reading database ... 25% (Reading database ... 30% (Reading database ... 35% (Reading database ... 40% (Reading database ... 45% (Reading database ... 50% (Reading database ... 55% (Reading database ... 60% (Reading database ... 65% (Reading database ... 70% (Reading database ... 75% (Reading database ... 80% (Reading database ... 85% (Reading database ... 90% (Reading database ... 95% (Reading database ... 100% (Reading database ... 64655 files and directories currently installed.) 479s Preparing to unpack .../000-libc-dev-bin_2.41-1ubuntu2_armhf.deb ... 479s Unpacking libc-dev-bin (2.41-1ubuntu2) ... 479s Selecting previously unselected package linux-libc-dev:armhf. 479s Preparing to unpack .../001-linux-libc-dev_6.14.0-10.10_armhf.deb ... 479s Unpacking linux-libc-dev:armhf (6.14.0-10.10) ... 479s Selecting previously unselected package libcrypt-dev:armhf. 479s Preparing to unpack .../002-libcrypt-dev_1%3a4.4.38-1_armhf.deb ... 479s Unpacking libcrypt-dev:armhf (1:4.4.38-1) ... 479s Selecting previously unselected package rpcsvc-proto. 479s Preparing to unpack .../003-rpcsvc-proto_1.4.2-0ubuntu7_armhf.deb ... 479s Unpacking rpcsvc-proto (1.4.2-0ubuntu7) ... 479s Selecting previously unselected package libc6-dev:armhf. 479s Preparing to unpack .../004-libc6-dev_2.41-1ubuntu2_armhf.deb ... 479s Unpacking libc6-dev:armhf (2.41-1ubuntu2) ... 479s Selecting previously unselected package libisl23:armhf. 479s Preparing to unpack .../005-libisl23_0.27-1_armhf.deb ... 479s Unpacking libisl23:armhf (0.27-1) ... 479s Selecting previously unselected package libmpc3:armhf. 479s Preparing to unpack .../006-libmpc3_1.3.1-1build2_armhf.deb ... 479s Unpacking libmpc3:armhf (1.3.1-1build2) ... 480s Selecting previously unselected package cpp-14-arm-linux-gnueabihf. 480s Preparing to unpack .../007-cpp-14-arm-linux-gnueabihf_14.2.0-17ubuntu3_armhf.deb ... 480s Unpacking cpp-14-arm-linux-gnueabihf (14.2.0-17ubuntu3) ... 480s Selecting previously unselected package cpp-14. 480s Preparing to unpack .../008-cpp-14_14.2.0-17ubuntu3_armhf.deb ... 480s Unpacking cpp-14 (14.2.0-17ubuntu3) ... 480s Selecting previously unselected package cpp-arm-linux-gnueabihf. 480s Preparing to unpack .../009-cpp-arm-linux-gnueabihf_4%3a14.2.0-1ubuntu1_armhf.deb ... 480s Unpacking cpp-arm-linux-gnueabihf (4:14.2.0-1ubuntu1) ... 480s Selecting previously unselected package cpp. 480s Preparing to unpack .../010-cpp_4%3a14.2.0-1ubuntu1_armhf.deb ... 480s Unpacking cpp (4:14.2.0-1ubuntu1) ... 480s Selecting previously unselected package libcc1-0:armhf. 480s Preparing to unpack .../011-libcc1-0_15-20250222-0ubuntu1_armhf.deb ... 480s Unpacking libcc1-0:armhf (15-20250222-0ubuntu1) ... 480s Selecting previously unselected package libgomp1:armhf. 480s Preparing to unpack .../012-libgomp1_15-20250222-0ubuntu1_armhf.deb ... 480s Unpacking libgomp1:armhf (15-20250222-0ubuntu1) ... 480s Selecting previously unselected package libasan8:armhf. 480s Preparing to unpack .../013-libasan8_15-20250222-0ubuntu1_armhf.deb ... 480s Unpacking libasan8:armhf (15-20250222-0ubuntu1) ... 480s Selecting previously unselected package libubsan1:armhf. 480s Preparing to unpack .../014-libubsan1_15-20250222-0ubuntu1_armhf.deb ... 480s Unpacking libubsan1:armhf (15-20250222-0ubuntu1) ... 480s Selecting previously unselected package libgcc-14-dev:armhf. 480s Preparing to unpack .../015-libgcc-14-dev_14.2.0-17ubuntu3_armhf.deb ... 480s Unpacking libgcc-14-dev:armhf (14.2.0-17ubuntu3) ... 480s Selecting previously unselected package gcc-14-arm-linux-gnueabihf. 480s Preparing to unpack .../016-gcc-14-arm-linux-gnueabihf_14.2.0-17ubuntu3_armhf.deb ... 480s Unpacking gcc-14-arm-linux-gnueabihf (14.2.0-17ubuntu3) ... 481s Selecting previously unselected package gcc-14. 481s Preparing to unpack .../017-gcc-14_14.2.0-17ubuntu3_armhf.deb ... 481s Unpacking gcc-14 (14.2.0-17ubuntu3) ... 481s Selecting previously unselected package gcc-arm-linux-gnueabihf. 481s Preparing to unpack .../018-gcc-arm-linux-gnueabihf_4%3a14.2.0-1ubuntu1_armhf.deb ... 481s Unpacking gcc-arm-linux-gnueabihf (4:14.2.0-1ubuntu1) ... 481s Selecting previously unselected package gcc. 481s Preparing to unpack .../019-gcc_4%3a14.2.0-1ubuntu1_armhf.deb ... 481s Unpacking gcc (4:14.2.0-1ubuntu1) ... 481s Selecting previously unselected package libstdc++-14-dev:armhf. 481s Preparing to unpack .../020-libstdc++-14-dev_14.2.0-17ubuntu3_armhf.deb ... 481s Unpacking libstdc++-14-dev:armhf (14.2.0-17ubuntu3) ... 481s Selecting previously unselected package g++-14-arm-linux-gnueabihf. 481s Preparing to unpack .../021-g++-14-arm-linux-gnueabihf_14.2.0-17ubuntu3_armhf.deb ... 481s Unpacking g++-14-arm-linux-gnueabihf (14.2.0-17ubuntu3) ... 482s Selecting previously unselected package g++-14. 482s Preparing to unpack .../022-g++-14_14.2.0-17ubuntu3_armhf.deb ... 482s Unpacking g++-14 (14.2.0-17ubuntu3) ... 482s Selecting previously unselected package g++-arm-linux-gnueabihf. 482s Preparing to unpack .../023-g++-arm-linux-gnueabihf_4%3a14.2.0-1ubuntu1_armhf.deb ... 482s Unpacking g++-arm-linux-gnueabihf (4:14.2.0-1ubuntu1) ... 482s Selecting previously unselected package g++. 482s Preparing to unpack .../024-g++_4%3a14.2.0-1ubuntu1_armhf.deb ... 482s Unpacking g++ (4:14.2.0-1ubuntu1) ... 482s Selecting previously unselected package build-essential. 482s Preparing to unpack .../025-build-essential_12.10ubuntu1_armhf.deb ... 482s Unpacking build-essential (12.10ubuntu1) ... 482s Selecting previously unselected package dctrl-tools. 482s Preparing to unpack .../026-dctrl-tools_2.24-3build3_armhf.deb ... 482s Unpacking dctrl-tools (2.24-3build3) ... 482s Selecting previously unselected package libfreetype6:armhf. 482s Preparing to unpack .../027-libfreetype6_2.13.3+dfsg-1_armhf.deb ... 482s Unpacking libfreetype6:armhf (2.13.3+dfsg-1) ... 482s Selecting previously unselected package fonts-dejavu-mono. 482s Preparing to unpack .../028-fonts-dejavu-mono_2.37-8_all.deb ... 482s Unpacking fonts-dejavu-mono (2.37-8) ... 482s Selecting previously unselected package fonts-dejavu-core. 482s Preparing to unpack .../029-fonts-dejavu-core_2.37-8_all.deb ... 482s Unpacking fonts-dejavu-core (2.37-8) ... 482s Selecting previously unselected package fontconfig-config. 482s Preparing to unpack .../030-fontconfig-config_2.15.0-2ubuntu1_armhf.deb ... 483s Unpacking fontconfig-config (2.15.0-2ubuntu1) ... 483s Selecting previously unselected package libfontconfig1:armhf. 483s Preparing to unpack .../031-libfontconfig1_2.15.0-2ubuntu1_armhf.deb ... 483s Unpacking libfontconfig1:armhf (2.15.0-2ubuntu1) ... 483s Selecting previously unselected package fontconfig. 483s Preparing to unpack .../032-fontconfig_2.15.0-2ubuntu1_armhf.deb ... 483s Unpacking fontconfig (2.15.0-2ubuntu1) ... 483s Selecting previously unselected package libgfortran5:armhf. 483s Preparing to unpack .../033-libgfortran5_15-20250222-0ubuntu1_armhf.deb ... 483s Unpacking libgfortran5:armhf (15-20250222-0ubuntu1) ... 483s Selecting previously unselected package libgfortran-14-dev:armhf. 483s Preparing to unpack .../034-libgfortran-14-dev_14.2.0-17ubuntu3_armhf.deb ... 483s Unpacking libgfortran-14-dev:armhf (14.2.0-17ubuntu3) ... 483s Selecting previously unselected package gfortran-14-arm-linux-gnueabihf. 483s Preparing to unpack .../035-gfortran-14-arm-linux-gnueabihf_14.2.0-17ubuntu3_armhf.deb ... 483s Unpacking gfortran-14-arm-linux-gnueabihf (14.2.0-17ubuntu3) ... 483s Selecting previously unselected package gfortran-14. 483s Preparing to unpack .../036-gfortran-14_14.2.0-17ubuntu3_armhf.deb ... 483s Unpacking gfortran-14 (14.2.0-17ubuntu3) ... 483s Selecting previously unselected package gfortran-arm-linux-gnueabihf. 484s Preparing to unpack .../037-gfortran-arm-linux-gnueabihf_4%3a14.2.0-1ubuntu1_armhf.deb ... 484s Unpacking gfortran-arm-linux-gnueabihf (4:14.2.0-1ubuntu1) ... 484s Selecting previously unselected package gfortran. 484s Preparing to unpack .../038-gfortran_4%3a14.2.0-1ubuntu1_armhf.deb ... 484s Unpacking gfortran (4:14.2.0-1ubuntu1) ... 484s Selecting previously unselected package icu-devtools. 484s Preparing to unpack .../039-icu-devtools_76.1-1ubuntu2_armhf.deb ... 484s Unpacking icu-devtools (76.1-1ubuntu2) ... 484s Selecting previously unselected package libblas3:armhf. 484s Preparing to unpack .../040-libblas3_3.12.1-2_armhf.deb ... 484s Unpacking libblas3:armhf (3.12.1-2) ... 484s Selecting previously unselected package libblas-dev:armhf. 484s Preparing to unpack .../041-libblas-dev_3.12.1-2_armhf.deb ... 484s Unpacking libblas-dev:armhf (3.12.1-2) ... 484s Selecting previously unselected package libbz2-dev:armhf. 484s Preparing to unpack .../042-libbz2-dev_1.0.8-6_armhf.deb ... 484s Unpacking libbz2-dev:armhf (1.0.8-6) ... 484s Selecting previously unselected package libpixman-1-0:armhf. 484s Preparing to unpack .../043-libpixman-1-0_0.44.0-3_armhf.deb ... 484s Unpacking libpixman-1-0:armhf (0.44.0-3) ... 484s Selecting previously unselected package libxcb-render0:armhf. 484s Preparing to unpack .../044-libxcb-render0_1.17.0-2_armhf.deb ... 484s Unpacking libxcb-render0:armhf (1.17.0-2) ... 484s Selecting previously unselected package libxcb-shm0:armhf. 484s Preparing to unpack .../045-libxcb-shm0_1.17.0-2_armhf.deb ... 484s Unpacking libxcb-shm0:armhf (1.17.0-2) ... 484s Selecting previously unselected package libxrender1:armhf. 484s Preparing to unpack .../046-libxrender1_1%3a0.9.10-1.1build1_armhf.deb ... 484s Unpacking libxrender1:armhf (1:0.9.10-1.1build1) ... 484s Selecting previously unselected package libcairo2:armhf. 484s Preparing to unpack .../047-libcairo2_1.18.2-2_armhf.deb ... 484s Unpacking libcairo2:armhf (1.18.2-2) ... 484s Selecting previously unselected package libdatrie1:armhf. 484s Preparing to unpack .../048-libdatrie1_0.2.13-3build1_armhf.deb ... 484s Unpacking libdatrie1:armhf (0.2.13-3build1) ... 484s Selecting previously unselected package libdeflate0:armhf. 484s Preparing to unpack .../049-libdeflate0_1.23-1_armhf.deb ... 484s Unpacking libdeflate0:armhf (1.23-1) ... 484s Selecting previously unselected package libdeflate-dev:armhf. 484s Preparing to unpack .../050-libdeflate-dev_1.23-1_armhf.deb ... 484s Unpacking libdeflate-dev:armhf (1.23-1) ... 484s Selecting previously unselected package libgraphite2-3:armhf. 484s Preparing to unpack .../051-libgraphite2-3_1.3.14-2ubuntu1_armhf.deb ... 484s Unpacking libgraphite2-3:armhf (1.3.14-2ubuntu1) ... 484s Selecting previously unselected package libharfbuzz0b:armhf. 484s Preparing to unpack .../052-libharfbuzz0b_10.2.0-1_armhf.deb ... 484s Unpacking libharfbuzz0b:armhf (10.2.0-1) ... 484s Selecting previously unselected package x11-common. 484s Preparing to unpack .../053-x11-common_1%3a7.7+23ubuntu3_all.deb ... 484s Unpacking x11-common (1:7.7+23ubuntu3) ... 484s Selecting previously unselected package libice6:armhf. 484s Preparing to unpack .../054-libice6_2%3a1.1.1-1_armhf.deb ... 484s Unpacking libice6:armhf (2:1.1.1-1) ... 484s Selecting previously unselected package libicu-dev:armhf. 484s Preparing to unpack .../055-libicu-dev_76.1-1ubuntu2_armhf.deb ... 484s Unpacking libicu-dev:armhf (76.1-1ubuntu2) ... 485s Selecting previously unselected package libjpeg-turbo8:armhf. 485s Preparing to unpack .../056-libjpeg-turbo8_2.1.5-3ubuntu2_armhf.deb ... 485s Unpacking libjpeg-turbo8:armhf (2.1.5-3ubuntu2) ... 485s Selecting previously unselected package libjpeg-turbo8-dev:armhf. 485s Preparing to unpack .../057-libjpeg-turbo8-dev_2.1.5-3ubuntu2_armhf.deb ... 485s Unpacking libjpeg-turbo8-dev:armhf (2.1.5-3ubuntu2) ... 485s Selecting previously unselected package libjpeg8:armhf. 485s Preparing to unpack .../058-libjpeg8_8c-2ubuntu11_armhf.deb ... 485s Unpacking libjpeg8:armhf (8c-2ubuntu11) ... 485s Selecting previously unselected package libjpeg8-dev:armhf. 485s Preparing to unpack .../059-libjpeg8-dev_8c-2ubuntu11_armhf.deb ... 485s Unpacking libjpeg8-dev:armhf (8c-2ubuntu11) ... 485s Selecting previously unselected package libjpeg-dev:armhf. 485s Preparing to unpack .../060-libjpeg-dev_8c-2ubuntu11_armhf.deb ... 485s Unpacking libjpeg-dev:armhf (8c-2ubuntu11) ... 485s Selecting previously unselected package liblapack3:armhf. 485s Preparing to unpack .../061-liblapack3_3.12.1-2_armhf.deb ... 485s Unpacking liblapack3:armhf (3.12.1-2) ... 485s Selecting previously unselected package liblapack-dev:armhf. 485s Preparing to unpack .../062-liblapack-dev_3.12.1-2_armhf.deb ... 485s Unpacking liblapack-dev:armhf (3.12.1-2) ... 485s Selecting previously unselected package liblerc4:armhf. 486s Preparing to unpack .../063-liblerc4_4.0.0+ds-5ubuntu1_armhf.deb ... 486s Unpacking liblerc4:armhf (4.0.0+ds-5ubuntu1) ... 486s Selecting previously unselected package libncurses-dev:armhf. 486s Preparing to unpack .../064-libncurses-dev_6.5+20250216-2_armhf.deb ... 486s Unpacking libncurses-dev:armhf (6.5+20250216-2) ... 486s Selecting previously unselected package libthai-data. 486s Preparing to unpack .../065-libthai-data_0.1.29-2build1_all.deb ... 486s Unpacking libthai-data (0.1.29-2build1) ... 486s Selecting previously unselected package libthai0:armhf. 486s Preparing to unpack .../066-libthai0_0.1.29-2build1_armhf.deb ... 486s Unpacking libthai0:armhf (0.1.29-2build1) ... 486s Selecting previously unselected package libpango-1.0-0:armhf. 486s Preparing to unpack .../067-libpango-1.0-0_1.56.2-1_armhf.deb ... 486s Unpacking libpango-1.0-0:armhf (1.56.2-1) ... 486s Selecting previously unselected package libpangoft2-1.0-0:armhf. 486s Preparing to unpack .../068-libpangoft2-1.0-0_1.56.2-1_armhf.deb ... 486s Unpacking libpangoft2-1.0-0:armhf (1.56.2-1) ... 486s Selecting previously unselected package libpangocairo-1.0-0:armhf. 486s Preparing to unpack .../069-libpangocairo-1.0-0_1.56.2-1_armhf.deb ... 486s Unpacking libpangocairo-1.0-0:armhf (1.56.2-1) ... 486s Selecting previously unselected package libpaper2:armhf. 486s Preparing to unpack .../070-libpaper2_2.2.5-0.3_armhf.deb ... 486s Unpacking libpaper2:armhf (2.2.5-0.3) ... 486s Selecting previously unselected package libpaper-utils. 486s Preparing to unpack .../071-libpaper-utils_2.2.5-0.3_armhf.deb ... 486s Unpacking libpaper-utils (2.2.5-0.3) ... 486s Selecting previously unselected package libpcre2-16-0:armhf. 486s Preparing to unpack .../072-libpcre2-16-0_10.45-1_armhf.deb ... 486s Unpacking libpcre2-16-0:armhf (10.45-1) ... 486s Selecting previously unselected package libpcre2-32-0:armhf. 486s Preparing to unpack .../073-libpcre2-32-0_10.45-1_armhf.deb ... 486s Unpacking libpcre2-32-0:armhf (10.45-1) ... 486s Selecting previously unselected package libpcre2-posix3:armhf. 486s Preparing to unpack .../074-libpcre2-posix3_10.45-1_armhf.deb ... 486s Unpacking libpcre2-posix3:armhf (10.45-1) ... 486s Selecting previously unselected package libpcre2-dev:armhf. 486s Preparing to unpack .../075-libpcre2-dev_10.45-1_armhf.deb ... 486s Unpacking libpcre2-dev:armhf (10.45-1) ... 486s Selecting previously unselected package libpkgconf3:armhf. 486s Preparing to unpack .../076-libpkgconf3_1.8.1-4_armhf.deb ... 486s Unpacking libpkgconf3:armhf (1.8.1-4) ... 486s Selecting previously unselected package zlib1g-dev:armhf. 486s Preparing to unpack .../077-zlib1g-dev_1%3a1.3.dfsg+really1.3.1-1ubuntu1_armhf.deb ... 486s Unpacking zlib1g-dev:armhf (1:1.3.dfsg+really1.3.1-1ubuntu1) ... 486s Selecting previously unselected package libpng-dev:armhf. 486s Preparing to unpack .../078-libpng-dev_1.6.47-1_armhf.deb ... 486s Unpacking libpng-dev:armhf (1.6.47-1) ... 486s Selecting previously unselected package libreadline-dev:armhf. 486s Preparing to unpack .../079-libreadline-dev_8.2-6_armhf.deb ... 486s Unpacking libreadline-dev:armhf (8.2-6) ... 486s Selecting previously unselected package libsharpyuv0:armhf. 486s Preparing to unpack .../080-libsharpyuv0_1.5.0-0.1_armhf.deb ... 486s Unpacking libsharpyuv0:armhf (1.5.0-0.1) ... 486s Selecting previously unselected package libsm6:armhf. 486s Preparing to unpack .../081-libsm6_2%3a1.2.4-1_armhf.deb ... 486s Unpacking libsm6:armhf (2:1.2.4-1) ... 486s Selecting previously unselected package libtcl8.6:armhf. 486s Preparing to unpack .../082-libtcl8.6_8.6.16+dfsg-1_armhf.deb ... 486s Unpacking libtcl8.6:armhf (8.6.16+dfsg-1) ... 487s Selecting previously unselected package libjbig0:armhf. 487s Preparing to unpack .../083-libjbig0_2.1-6.1ubuntu2_armhf.deb ... 487s Unpacking libjbig0:armhf (2.1-6.1ubuntu2) ... 487s Selecting previously unselected package libwebp7:armhf. 487s Preparing to unpack .../084-libwebp7_1.5.0-0.1_armhf.deb ... 487s Unpacking libwebp7:armhf (1.5.0-0.1) ... 487s Selecting previously unselected package libtiff6:armhf. 487s Preparing to unpack .../085-libtiff6_4.5.1+git230720-4ubuntu4_armhf.deb ... 487s Unpacking libtiff6:armhf (4.5.1+git230720-4ubuntu4) ... 487s Selecting previously unselected package libxft2:armhf. 487s Preparing to unpack .../086-libxft2_2.3.6-1build1_armhf.deb ... 487s Unpacking libxft2:armhf (2.3.6-1build1) ... 487s Selecting previously unselected package libxss1:armhf. 487s Preparing to unpack .../087-libxss1_1%3a1.2.3-1build3_armhf.deb ... 487s Unpacking libxss1:armhf (1:1.2.3-1build3) ... 487s Selecting previously unselected package libtk8.6:armhf. 487s Preparing to unpack .../088-libtk8.6_8.6.16-1_armhf.deb ... 487s Unpacking libtk8.6:armhf (8.6.16-1) ... 487s Selecting previously unselected package libxt6t64:armhf. 487s Preparing to unpack .../089-libxt6t64_1%3a1.2.1-1.2build1_armhf.deb ... 487s Unpacking libxt6t64:armhf (1:1.2.1-1.2build1) ... 487s Selecting previously unselected package zip. 487s Preparing to unpack .../090-zip_3.0-14ubuntu2_armhf.deb ... 487s Unpacking zip (3.0-14ubuntu2) ... 487s Selecting previously unselected package unzip. 487s Preparing to unpack .../091-unzip_6.0-28ubuntu6_armhf.deb ... 487s Unpacking unzip (6.0-28ubuntu6) ... 487s Selecting previously unselected package xdg-utils. 487s Preparing to unpack .../092-xdg-utils_1.2.1-2ubuntu1_all.deb ... 487s Unpacking xdg-utils (1.2.1-2ubuntu1) ... 487s Selecting previously unselected package r-base-core. 487s Preparing to unpack .../093-r-base-core_4.4.3-1_armhf.deb ... 487s Unpacking r-base-core (4.4.3-1) ... 488s Selecting previously unselected package r-cran-littler. 488s Preparing to unpack .../094-r-cran-littler_0.3.20-2_armhf.deb ... 488s Unpacking r-cran-littler (0.3.20-2) ... 488s Selecting previously unselected package littler. 488s Preparing to unpack .../095-littler_0.3.20-2_all.deb ... 488s Unpacking littler (0.3.20-2) ... 488s Selecting previously unselected package liblzma-dev:armhf. 488s Preparing to unpack .../096-liblzma-dev_5.6.4-1_armhf.deb ... 488s Unpacking liblzma-dev:armhf (5.6.4-1) ... 488s Selecting previously unselected package pkgconf-bin. 488s Preparing to unpack .../097-pkgconf-bin_1.8.1-4_armhf.deb ... 488s Unpacking pkgconf-bin (1.8.1-4) ... 488s Selecting previously unselected package pkgconf:armhf. 488s Preparing to unpack .../098-pkgconf_1.8.1-4_armhf.deb ... 488s Unpacking pkgconf:armhf (1.8.1-4) ... 488s Selecting previously unselected package libtirpc-dev:armhf. 488s Preparing to unpack .../099-libtirpc-dev_1.3.4+ds-1.3_armhf.deb ... 488s Unpacking libtirpc-dev:armhf (1.3.4+ds-1.3) ... 488s Selecting previously unselected package r-base-dev. 488s Preparing to unpack .../100-r-base-dev_4.4.3-1_all.deb ... 488s Unpacking r-base-dev (4.4.3-1) ... 488s Selecting previously unselected package pkg-r-autopkgtest. 488s Preparing to unpack .../101-pkg-r-autopkgtest_20231212ubuntu1_all.deb ... 488s Unpacking pkg-r-autopkgtest (20231212ubuntu1) ... 488s Selecting previously unselected package r-cran-boot. 488s Preparing to unpack .../102-r-cran-boot_1.3-31-1_all.deb ... 488s Unpacking r-cran-boot (1.3-31-1) ... 488s Selecting previously unselected package r-cran-brio. 488s Preparing to unpack .../103-r-cran-brio_1.1.5-1_armhf.deb ... 488s Unpacking r-cran-brio (1.1.5-1) ... 488s Selecting previously unselected package r-cran-ps. 488s Preparing to unpack .../104-r-cran-ps_1.9.0-1_armhf.deb ... 488s Unpacking r-cran-ps (1.9.0-1) ... 488s Selecting previously unselected package r-cran-r6. 488s Preparing to unpack .../105-r-cran-r6_2.6.1-1_all.deb ... 488s Unpacking r-cran-r6 (2.6.1-1) ... 488s Selecting previously unselected package r-cran-processx. 488s Preparing to unpack .../106-r-cran-processx_3.8.6-1_armhf.deb ... 488s Unpacking r-cran-processx (3.8.6-1) ... 488s Selecting previously unselected package r-cran-callr. 488s Preparing to unpack .../107-r-cran-callr_3.7.6-1_all.deb ... 488s Unpacking r-cran-callr (3.7.6-1) ... 488s Selecting previously unselected package r-cran-cli. 488s Preparing to unpack .../108-r-cran-cli_3.6.4-1_armhf.deb ... 488s Unpacking r-cran-cli (3.6.4-1) ... 488s Selecting previously unselected package r-cran-crayon. 488s Preparing to unpack .../109-r-cran-crayon_1.5.3-1_all.deb ... 488s Unpacking r-cran-crayon (1.5.3-1) ... 488s Selecting previously unselected package r-cran-desc. 488s Preparing to unpack .../110-r-cran-desc_1.4.3-1_all.deb ... 488s Unpacking r-cran-desc (1.4.3-1) ... 488s Selecting previously unselected package r-cran-diffobj. 488s Preparing to unpack .../111-r-cran-diffobj_0.3.5-1_armhf.deb ... 488s Unpacking r-cran-diffobj (0.3.5-1) ... 489s Selecting previously unselected package r-cran-digest. 489s Preparing to unpack .../112-r-cran-digest_0.6.37-1_armhf.deb ... 489s Unpacking r-cran-digest (0.6.37-1) ... 489s Selecting previously unselected package r-cran-evaluate. 489s Preparing to unpack .../113-r-cran-evaluate_1.0.3-1_all.deb ... 489s Unpacking r-cran-evaluate (1.0.3-1) ... 489s Selecting previously unselected package r-cran-fs. 489s Preparing to unpack .../114-r-cran-fs_1.6.5+dfsg-1_armhf.deb ... 489s Unpacking r-cran-fs (1.6.5+dfsg-1) ... 489s Selecting previously unselected package r-cran-glue. 489s Preparing to unpack .../115-r-cran-glue_1.8.0-1_armhf.deb ... 489s Unpacking r-cran-glue (1.8.0-1) ... 489s Selecting previously unselected package r-cran-jsonlite. 489s Preparing to unpack .../116-r-cran-jsonlite_1.9.1+dfsg-1_armhf.deb ... 489s Unpacking r-cran-jsonlite (1.9.1+dfsg-1) ... 489s Selecting previously unselected package r-cran-lattice. 489s Preparing to unpack .../117-r-cran-lattice_0.22-6-1_armhf.deb ... 489s Unpacking r-cran-lattice (0.22-6-1) ... 489s Selecting previously unselected package r-cran-rlang. 489s Preparing to unpack .../118-r-cran-rlang_1.1.5-1_armhf.deb ... 489s Unpacking r-cran-rlang (1.1.5-1) ... 489s Selecting previously unselected package r-cran-lifecycle. 489s Preparing to unpack .../119-r-cran-lifecycle_1.0.4+dfsg-1_all.deb ... 489s Unpacking r-cran-lifecycle (1.0.4+dfsg-1) ... 489s Selecting previously unselected package r-cran-matrix. 489s Preparing to unpack .../120-r-cran-matrix_1.7-3-1_armhf.deb ... 489s Unpacking r-cran-matrix (1.7-3-1) ... 489s Selecting previously unselected package r-cran-mass. 489s Preparing to unpack .../121-r-cran-mass_7.3-64-1_armhf.deb ... 489s Unpacking r-cran-mass (7.3-64-1) ... 489s Selecting previously unselected package r-cran-nlme. 489s Preparing to unpack .../122-r-cran-nlme_3.1.167-1_armhf.deb ... 489s Unpacking r-cran-nlme (3.1.167-1) ... 489s Selecting previously unselected package r-cran-pkgkitten. 489s Preparing to unpack .../123-r-cran-pkgkitten_0.2.4-1_all.deb ... 489s Unpacking r-cran-pkgkitten (0.2.4-1) ... 489s Selecting previously unselected package r-cran-rcpp. 489s Preparing to unpack .../124-r-cran-rcpp_1.0.14-1_armhf.deb ... 489s Unpacking r-cran-rcpp (1.0.14-1) ... 489s Selecting previously unselected package r-cran-minqa. 489s Preparing to unpack .../125-r-cran-minqa_1.2.8-1_armhf.deb ... 489s Unpacking r-cran-minqa (1.2.8-1) ... 490s Selecting previously unselected package libnlopt0:armhf. 490s Preparing to unpack .../126-libnlopt0_2.7.1-6ubuntu3_armhf.deb ... 490s Unpacking libnlopt0:armhf (2.7.1-6ubuntu3) ... 490s Selecting previously unselected package r-cran-nloptr. 490s Preparing to unpack .../127-r-cran-nloptr_2.1.1-1_armhf.deb ... 490s Unpacking r-cran-nloptr (2.1.1-1) ... 490s Selecting previously unselected package r-cran-rbibutils. 490s Preparing to unpack .../128-r-cran-rbibutils_2.3-1_armhf.deb ... 490s Unpacking r-cran-rbibutils (2.3-1) ... 490s Selecting previously unselected package r-cran-rdpack. 490s Preparing to unpack .../129-r-cran-rdpack_2.6.2-1syncable1_all.deb ... 490s Unpacking r-cran-rdpack (2.6.2-1syncable1) ... 490s Selecting previously unselected package r-cran-reformulas. 490s Preparing to unpack .../130-r-cran-reformulas_0.4.0-1_all.deb ... 490s Unpacking r-cran-reformulas (0.4.0-1) ... 490s Selecting previously unselected package r-cran-rcppeigen. 490s Preparing to unpack .../131-r-cran-rcppeigen_0.3.4.0.2-1_armhf.deb ... 490s Unpacking r-cran-rcppeigen (0.3.4.0.2-1) ... 490s Selecting previously unselected package r-cran-statmod. 490s Preparing to unpack .../132-r-cran-statmod_1.5.0-1_armhf.deb ... 490s Unpacking r-cran-statmod (1.5.0-1) ... 490s Selecting previously unselected package r-cran-lme4. 490s Preparing to unpack .../133-r-cran-lme4_1.1-36-1_armhf.deb ... 490s Unpacking r-cran-lme4 (1.1-36-1) ... 490s Selecting previously unselected package r-cran-magrittr. 490s Preparing to unpack .../134-r-cran-magrittr_2.0.3-1_armhf.deb ... 490s Unpacking r-cran-magrittr (2.0.3-1) ... 490s Selecting previously unselected package r-cran-nnet. 490s Preparing to unpack .../135-r-cran-nnet_7.3-20-1_armhf.deb ... 490s Unpacking r-cran-nnet (7.3-20-1) ... 490s Selecting previously unselected package r-cran-numderiv. 490s Preparing to unpack .../136-r-cran-numderiv_2016.8-1.1-3_all.deb ... 490s Unpacking r-cran-numderiv (2016.8-1.1-3) ... 491s Selecting previously unselected package r-cran-ucminf. 491s Preparing to unpack .../137-r-cran-ucminf_1.2.2-1_armhf.deb ... 491s Unpacking r-cran-ucminf (1.2.2-1) ... 491s Selecting previously unselected package r-cran-ordinal. 491s Preparing to unpack .../138-r-cran-ordinal_2023.12-4.1-1_armhf.deb ... 491s Unpacking r-cran-ordinal (2023.12-4.1-1) ... 491s Selecting previously unselected package r-cran-pkgbuild. 491s Preparing to unpack .../139-r-cran-pkgbuild_1.4.6-1_all.deb ... 491s Unpacking r-cran-pkgbuild (1.4.6-1) ... 491s Selecting previously unselected package r-cran-rprojroot. 491s Preparing to unpack .../140-r-cran-rprojroot_2.0.4-2_all.deb ... 491s Unpacking r-cran-rprojroot (2.0.4-2) ... 491s Selecting previously unselected package r-cran-withr. 491s Preparing to unpack .../141-r-cran-withr_3.0.2+dfsg-1_all.deb ... 491s Unpacking r-cran-withr (3.0.2+dfsg-1) ... 491s Selecting previously unselected package r-cran-pkgload. 491s Preparing to unpack .../142-r-cran-pkgload_1.4.0-1_all.deb ... 491s Unpacking r-cran-pkgload (1.4.0-1) ... 491s Selecting previously unselected package r-cran-praise. 491s Preparing to unpack .../143-r-cran-praise_1.0.0-4build1_all.deb ... 491s Unpacking r-cran-praise (1.0.0-4build1) ... 491s Selecting previously unselected package r-cran-waldo. 491s Preparing to unpack .../144-r-cran-waldo_0.6.1-2_all.deb ... 491s Unpacking r-cran-waldo (0.6.1-2) ... 491s Selecting previously unselected package r-cran-testthat. 491s Preparing to unpack .../145-r-cran-testthat_3.2.3-1_armhf.deb ... 491s Unpacking r-cran-testthat (3.2.3-1) ... 491s Selecting previously unselected package r-cran-xtable. 491s Preparing to unpack .../146-r-cran-xtable_1%3a1.8-4-2_all.deb ... 491s Unpacking r-cran-xtable (1:1.8-4-2) ... 491s Setting up libgraphite2-3:armhf (1.3.14-2ubuntu1) ... 491s Setting up libpixman-1-0:armhf (0.44.0-3) ... 491s Setting up libsharpyuv0:armhf (1.5.0-0.1) ... 491s Setting up liblerc4:armhf (4.0.0+ds-5ubuntu1) ... 491s Setting up libxrender1:armhf (1:0.9.10-1.1build1) ... 491s Setting up libdatrie1:armhf (0.2.13-3build1) ... 491s Setting up libxcb-render0:armhf (1.17.0-2) ... 491s Setting up unzip (6.0-28ubuntu6) ... 491s Setting up x11-common (1:7.7+23ubuntu3) ... 492s Setting up libdeflate0:armhf (1.23-1) ... 492s Setting up linux-libc-dev:armhf (6.14.0-10.10) ... 492s Setting up libnlopt0:armhf (2.7.1-6ubuntu3) ... 492s Setting up libxcb-shm0:armhf (1.17.0-2) ... 492s Setting up libgomp1:armhf (15-20250222-0ubuntu1) ... 492s Setting up libjbig0:armhf (2.1-6.1ubuntu2) ... 492s Setting up libpcre2-16-0:armhf (10.45-1) ... 492s Setting up zip (3.0-14ubuntu2) ... 492s Setting up libpcre2-32-0:armhf (10.45-1) ... 492s Setting up libblas3:armhf (3.12.1-2) ... 492s update-alternatives: using /usr/lib/arm-linux-gnueabihf/blas/libblas.so.3 to provide /usr/lib/arm-linux-gnueabihf/libblas.so.3 (libblas.so.3-arm-linux-gnueabihf) in auto mode 492s Setting up libtirpc-dev:armhf (1.3.4+ds-1.3) ... 492s Setting up libpkgconf3:armhf (1.8.1-4) ... 492s Setting up rpcsvc-proto (1.4.2-0ubuntu7) ... 492s Setting up libfreetype6:armhf (2.13.3+dfsg-1) ... 492s Setting up fonts-dejavu-mono (2.37-8) ... 492s Setting up libmpc3:armhf (1.3.1-1build2) ... 492s Setting up libtcl8.6:armhf (8.6.16+dfsg-1) ... 492s Setting up icu-devtools (76.1-1ubuntu2) ... 492s Setting up fonts-dejavu-core (2.37-8) ... 492s Setting up pkgconf-bin (1.8.1-4) ... 492s Setting up libjpeg-turbo8:armhf (2.1.5-3ubuntu2) ... 492s Setting up libgfortran5:armhf (15-20250222-0ubuntu1) ... 492s Setting up libwebp7:armhf (1.5.0-0.1) ... 492s Setting up liblzma-dev:armhf (5.6.4-1) ... 492s Setting up libubsan1:armhf (15-20250222-0ubuntu1) ... 492s Setting up libpcre2-posix3:armhf (10.45-1) ... 492s Setting up libcrypt-dev:armhf (1:4.4.38-1) ... 492s Setting up libasan8:armhf (15-20250222-0ubuntu1) ... 492s Setting up libharfbuzz0b:armhf (10.2.0-1) ... 492s Setting up libthai-data (0.1.29-2build1) ... 492s Setting up libxss1:armhf (1:1.2.3-1build3) ... 492s Setting up libpaper2:armhf (2.2.5-0.3) ... 492s Setting up libgcc-14-dev:armhf (14.2.0-17ubuntu3) ... 492s Setting up libisl23:armhf (0.27-1) ... 492s Setting up libc-dev-bin (2.41-1ubuntu2) ... 492s Setting up libdeflate-dev:armhf (1.23-1) ... 492s Setting up xdg-utils (1.2.1-2ubuntu1) ... 492s update-alternatives: using /usr/bin/xdg-open to provide /usr/bin/open (open) in auto mode 492s Setting up libcc1-0:armhf (15-20250222-0ubuntu1) ... 492s Setting up libblas-dev:armhf (3.12.1-2) ... 492s update-alternatives: using /usr/lib/arm-linux-gnueabihf/blas/libblas.so to provide /usr/lib/arm-linux-gnueabihf/libblas.so (libblas.so-arm-linux-gnueabihf) in auto mode 492s Setting up dctrl-tools (2.24-3build3) ... 492s Setting up cpp-14-arm-linux-gnueabihf (14.2.0-17ubuntu3) ... 492s Setting up libjpeg8:armhf (8c-2ubuntu11) ... 492s Setting up libgfortran-14-dev:armhf (14.2.0-17ubuntu3) ... 492s Setting up libice6:armhf (2:1.1.1-1) ... 492s Setting up liblapack3:armhf (3.12.1-2) ... 492s update-alternatives: using /usr/lib/arm-linux-gnueabihf/lapack/liblapack.so.3 to provide /usr/lib/arm-linux-gnueabihf/liblapack.so.3 (liblapack.so.3-arm-linux-gnueabihf) in auto mode 492s Setting up fontconfig-config (2.15.0-2ubuntu1) ... 492s Setting up gcc-14-arm-linux-gnueabihf (14.2.0-17ubuntu3) ... 492s Setting up libpaper-utils (2.2.5-0.3) ... 492s Setting up pkgconf:armhf (1.8.1-4) ... 492s Setting up libthai0:armhf (0.1.29-2build1) ... 492s Setting up liblapack-dev:armhf (3.12.1-2) ... 492s update-alternatives: using /usr/lib/arm-linux-gnueabihf/lapack/liblapack.so to provide /usr/lib/arm-linux-gnueabihf/liblapack.so (liblapack.so-arm-linux-gnueabihf) in auto mode 492s Setting up cpp-14 (14.2.0-17ubuntu3) ... 492s Setting up libtiff6:armhf (4.5.1+git230720-4ubuntu4) ... 492s Setting up libc6-dev:armhf (2.41-1ubuntu2) ... 492s Setting up libfontconfig1:armhf (2.15.0-2ubuntu1) ... 492s Setting up libstdc++-14-dev:armhf (14.2.0-17ubuntu3) ... 492s Setting up libsm6:armhf (2:1.2.4-1) ... 492s Setting up libicu-dev:armhf (76.1-1ubuntu2) ... 492s Setting up cpp-arm-linux-gnueabihf (4:14.2.0-1ubuntu1) ... 492s Setting up gfortran-14-arm-linux-gnueabihf (14.2.0-17ubuntu3) ... 492s Setting up libbz2-dev:armhf (1.0.8-6) ... 492s Setting up gcc-arm-linux-gnueabihf (4:14.2.0-1ubuntu1) ... 492s Setting up g++-14-arm-linux-gnueabihf (14.2.0-17ubuntu3) ... 492s Setting up fontconfig (2.15.0-2ubuntu1) ... 494s Regenerating fonts cache... done. 494s Setting up libjpeg-turbo8-dev:armhf (2.1.5-3ubuntu2) ... 494s Setting up libxft2:armhf (2.3.6-1build1) ... 494s Setting up libncurses-dev:armhf (6.5+20250216-2) ... 494s Setting up libpcre2-dev:armhf (10.45-1) ... 494s Setting up libtk8.6:armhf (8.6.16-1) ... 494s Setting up libpango-1.0-0:armhf (1.56.2-1) ... 494s Setting up libreadline-dev:armhf (8.2-6) ... 494s Setting up libcairo2:armhf (1.18.2-2) ... 494s Setting up gcc-14 (14.2.0-17ubuntu3) ... 494s Setting up gfortran-arm-linux-gnueabihf (4:14.2.0-1ubuntu1) ... 494s Setting up libxt6t64:armhf (1:1.2.1-1.2build1) ... 494s Setting up zlib1g-dev:armhf (1:1.3.dfsg+really1.3.1-1ubuntu1) ... 494s Setting up cpp (4:14.2.0-1ubuntu1) ... 494s Setting up g++-14 (14.2.0-17ubuntu3) ... 494s Setting up libpangoft2-1.0-0:armhf (1.56.2-1) ... 494s Setting up libjpeg8-dev:armhf (8c-2ubuntu11) ... 494s Setting up gfortran-14 (14.2.0-17ubuntu3) ... 494s Setting up libpangocairo-1.0-0:armhf (1.56.2-1) ... 494s Setting up g++-arm-linux-gnueabihf (4:14.2.0-1ubuntu1) ... 494s Setting up libpng-dev:armhf (1.6.47-1) ... 494s Setting up libjpeg-dev:armhf (8c-2ubuntu11) ... 494s Setting up gcc (4:14.2.0-1ubuntu1) ... 494s Setting up r-base-core (4.4.3-1) ... 494s Creating config file /etc/R/Renviron with new version 494s Setting up r-cran-crayon (1.5.3-1) ... 494s Setting up r-cran-lattice (0.22-6-1) ... 494s Setting up r-cran-ps (1.9.0-1) ... 494s Setting up r-cran-nlme (3.1.167-1) ... 494s Setting up g++ (4:14.2.0-1ubuntu1) ... 494s update-alternatives: using /usr/bin/g++ to provide /usr/bin/c++ (c++) in auto mode 494s Setting up r-cran-statmod (1.5.0-1) ... 494s Setting up build-essential (12.10ubuntu1) ... 494s Setting up r-cran-nnet (7.3-20-1) ... 494s Setting up r-cran-r6 (2.6.1-1) ... 494s Setting up r-cran-pkgkitten (0.2.4-1) ... 494s Setting up r-cran-numderiv (2016.8-1.1-3) ... 494s Setting up r-cran-magrittr (2.0.3-1) ... 494s Setting up r-cran-littler (0.3.20-2) ... 494s Setting up r-cran-fs (1.6.5+dfsg-1) ... 494s Setting up r-cran-rcpp (1.0.14-1) ... 494s Setting up r-cran-brio (1.1.5-1) ... 494s Setting up r-cran-nloptr (2.1.1-1) ... 494s Setting up r-cran-boot (1.3-31-1) ... 494s Setting up r-cran-diffobj (0.3.5-1) ... 494s Setting up r-cran-rlang (1.1.5-1) ... 494s Setting up littler (0.3.20-2) ... 494s Setting up r-cran-withr (3.0.2+dfsg-1) ... 494s Setting up r-cran-processx (3.8.6-1) ... 494s Setting up r-cran-praise (1.0.0-4build1) ... 495s Setting up r-cran-digest (0.6.37-1) ... 495s Setting up r-cran-evaluate (1.0.3-1) ... 495s Setting up r-cran-mass (7.3-64-1) ... 495s Setting up r-cran-glue (1.8.0-1) ... 495s Setting up r-cran-xtable (1:1.8-4-2) ... 495s Setting up r-cran-cli (3.6.4-1) ... 495s Setting up gfortran (4:14.2.0-1ubuntu1) ... 495s update-alternatives: using /usr/bin/gfortran to provide /usr/bin/f95 (f95) in auto mode 495s update-alternatives: warning: skip creation of /usr/share/man/man1/f95.1.gz because associated file /usr/share/man/man1/gfortran.1.gz (of link group f95) doesn't exist 495s update-alternatives: using /usr/bin/gfortran to provide /usr/bin/f77 (f77) in auto mode 495s update-alternatives: warning: skip creation of /usr/share/man/man1/f77.1.gz because associated file /usr/share/man/man1/gfortran.1.gz (of link group f77) doesn't exist 495s Setting up r-cran-rbibutils (2.3-1) ... 495s Setting up r-cran-lifecycle (1.0.4+dfsg-1) ... 495s Setting up r-cran-rprojroot (2.0.4-2) ... 495s Setting up r-cran-jsonlite (1.9.1+dfsg-1) ... 495s Setting up r-cran-ucminf (1.2.2-1) ... 495s Setting up r-cran-waldo (0.6.1-2) ... 495s Setting up r-cran-matrix (1.7-3-1) ... 495s Setting up r-cran-rcppeigen (0.3.4.0.2-1) ... 495s Setting up r-cran-minqa (1.2.8-1) ... 495s Setting up r-base-dev (4.4.3-1) ... 495s Setting up r-cran-callr (3.7.6-1) ... 495s Setting up r-cran-ordinal (2023.12-4.1-1) ... 495s Setting up r-cran-desc (1.4.3-1) ... 495s Setting up r-cran-rdpack (2.6.2-1syncable1) ... 495s Setting up pkg-r-autopkgtest (20231212ubuntu1) ... 495s Setting up r-cran-pkgbuild (1.4.6-1) ... 495s Setting up r-cran-reformulas (0.4.0-1) ... 495s Setting up r-cran-pkgload (1.4.0-1) ... 495s Setting up r-cran-lme4 (1.1-36-1) ... 495s Setting up r-cran-testthat (3.2.3-1) ... 495s Processing triggers for libc-bin (2.41-1ubuntu2) ... 495s Processing triggers for man-db (2.13.0-1) ... 496s Processing triggers for install-info (7.1.1-1) ... 512s autopkgtest [15:27:48]: test pkg-r-autopkgtest: /usr/share/dh-r/pkg-r-autopkgtest 512s autopkgtest [15:27:48]: test pkg-r-autopkgtest: [----------------------- 514s Test: Try to load the R library ordinal 514s 514s R version 4.4.3 (2025-02-28) -- "Trophy Case" 514s Copyright (C) 2025 The R Foundation for Statistical Computing 514s Platform: arm-unknown-linux-gnueabihf (32-bit) 514s 514s R is free software and comes with ABSOLUTELY NO WARRANTY. 514s You are welcome to redistribute it under certain conditions. 514s Type 'license()' or 'licence()' for distribution details. 514s 514s R is a collaborative project with many contributors. 514s Type 'contributors()' for more information and 514s 'citation()' on how to cite R or R packages in publications. 514s 514s Type 'demo()' for some demos, 'help()' for on-line help, or 514s 'help.start()' for an HTML browser interface to help. 514s Type 'q()' to quit R. 514s 514s > library('ordinal') 515s > 515s > 515s Other tests are currently unsupported! 515s They will be progressively added. 516s autopkgtest [15:27:52]: test pkg-r-autopkgtest: -----------------------] 520s pkg-r-autopkgtest PASS 520s autopkgtest [15:27:55]: test pkg-r-autopkgtest: - - - - - - - - - - results - - - - - - - - - - 523s autopkgtest [15:27:59]: @@@@@@@@@@@@@@@@@@@@ summary 523s run-unit-test PASS 523s pkg-r-autopkgtest PASS