0s autopkgtest [10:44:24]: starting date and time: 2024-03-23 10:44:24+0000 0s autopkgtest [10:44:24]: git checkout: 4a1cd702 l/adt_testbed: don't blame the testbed for unsolvable build deps 0s autopkgtest [10:44:24]: host juju-7f2275-prod-proposed-migration-environment-2; command line: /home/ubuntu/autopkgtest/runner/autopkgtest --output-dir /tmp/autopkgtest-work._ugodeot/out --timeout-copy=6000 -a i386 --setup-commands /home/ubuntu/autopkgtest-cloud/worker-config-production/setup-canonical.sh --setup-commands /home/ubuntu/autopkgtest/setup-commands/setup-testbed --apt-pocket=proposed=src:r-base --apt-upgrade r-cran-pbapply --timeout-short=300 --timeout-copy=20000 --timeout-build=20000 --env=ADT_TEST_TRIGGERS=r-base/4.3.3-2build1 -- ssh -s /home/ubuntu/autopkgtest/ssh-setup/nova -- --flavor autopkgtest --security-groups autopkgtest-juju-7f2275-prod-proposed-migration-environment-2@lcy02-54.secgroup --name adt-noble-i386-r-cran-pbapply-20240323-103841-juju-7f2275-prod-proposed-migration-environment-2 --image adt/ubuntu-noble-amd64-server --keyname testbed-juju-7f2275-prod-proposed-migration-environment-2 --net-id=net_prod-proposed-migration -e TERM=linux -e ''"'"'http_proxy=http://squid.internal:3128'"'"'' -e ''"'"'https_proxy=http://squid.internal:3128'"'"'' -e ''"'"'no_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,launchpadlibrarian.net,launchpadcontent.net,launchpad.net,10.24.0.0/24,keystone.ps5.canonical.com,objectstorage.prodstack5.canonical.com'"'"'' --mirror=http://ftpmaster.internal/ubuntu/ 98s autopkgtest [10:46:02]: testbed dpkg architecture: amd64 98s autopkgtest [10:46:02]: testbed apt version: 2.7.12 98s autopkgtest [10:46:02]: test architecture: i386 98s autopkgtest [10:46:02]: @@@@@@@@@@@@@@@@@@@@ test bed setup 98s Get:1 http://ftpmaster.internal/ubuntu noble-proposed InRelease [117 kB] 98s Get:2 http://ftpmaster.internal/ubuntu noble-proposed/universe Sources [3969 kB] 98s Get:3 http://ftpmaster.internal/ubuntu noble-proposed/main Sources [494 kB] 98s Get:4 http://ftpmaster.internal/ubuntu noble-proposed/restricted Sources [6540 B] 98s Get:5 http://ftpmaster.internal/ubuntu noble-proposed/multiverse Sources [56.9 kB] 98s Get:6 http://ftpmaster.internal/ubuntu noble-proposed/main i386 Packages [450 kB] 98s Get:7 http://ftpmaster.internal/ubuntu noble-proposed/main amd64 Packages [685 kB] 98s Get:8 http://ftpmaster.internal/ubuntu noble-proposed/main amd64 c-n-f Metadata [3508 B] 98s Get:9 http://ftpmaster.internal/ubuntu noble-proposed/restricted i386 Packages [6700 B] 98s Get:10 http://ftpmaster.internal/ubuntu noble-proposed/restricted amd64 Packages [30.5 kB] 98s Get:11 http://ftpmaster.internal/ubuntu noble-proposed/restricted amd64 c-n-f Metadata [116 B] 98s Get:12 http://ftpmaster.internal/ubuntu noble-proposed/universe amd64 Packages [4432 kB] 98s Get:13 http://ftpmaster.internal/ubuntu noble-proposed/universe i386 Packages [1298 kB] 98s Get:14 http://ftpmaster.internal/ubuntu noble-proposed/universe amd64 c-n-f Metadata [9396 B] 98s Get:15 http://ftpmaster.internal/ubuntu noble-proposed/multiverse i386 Packages [27.1 kB] 98s Get:16 http://ftpmaster.internal/ubuntu noble-proposed/multiverse amd64 Packages [96.1 kB] 98s Get:17 http://ftpmaster.internal/ubuntu noble-proposed/multiverse amd64 c-n-f Metadata [196 B] 102s Fetched 11.7 MB in 2s (7174 kB/s) 102s Reading package lists... 104s Reading package lists... 104s Building dependency tree... 104s Reading state information... 105s Calculating upgrade... 105s The following packages will be upgraded: 105s libc-bin libc6 locales 105s 3 upgraded, 0 newly installed, 0 to remove and 0 not upgraded. 105s Need to get 8176 kB of archives. 105s After this operation, 2048 B of additional disk space will be used. 105s Get:1 http://ftpmaster.internal/ubuntu noble/main amd64 libc6 amd64 2.39-0ubuntu6 [3262 kB] 105s Get:2 http://ftpmaster.internal/ubuntu noble/main amd64 libc-bin amd64 2.39-0ubuntu6 [682 kB] 105s Get:3 http://ftpmaster.internal/ubuntu noble/main amd64 locales all 2.39-0ubuntu6 [4232 kB] 105s Preconfiguring packages ... 106s Fetched 8176 kB in 0s (84.7 MB/s) 106s (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 ... 71864 files and directories currently installed.) 106s Preparing to unpack .../libc6_2.39-0ubuntu6_amd64.deb ... 106s Unpacking libc6:amd64 (2.39-0ubuntu6) over (2.39-0ubuntu2) ... 106s Setting up libc6:amd64 (2.39-0ubuntu6) ... 107s (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 ... 71864 files and directories currently installed.) 107s Preparing to unpack .../libc-bin_2.39-0ubuntu6_amd64.deb ... 107s Unpacking libc-bin (2.39-0ubuntu6) over (2.39-0ubuntu2) ... 107s Setting up libc-bin (2.39-0ubuntu6) ... 107s (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 ... 71864 files and directories currently installed.) 107s Preparing to unpack .../locales_2.39-0ubuntu6_all.deb ... 107s Unpacking locales (2.39-0ubuntu6) over (2.39-0ubuntu2) ... 107s Setting up locales (2.39-0ubuntu6) ... 108s Generating locales (this might take a while)... 109s en_US.UTF-8... done 109s Generation complete. 109s Processing triggers for man-db (2.12.0-3) ... 111s Reading package lists... 111s Building dependency tree... 111s Reading state information... 112s 0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded. 112s sh: Attempting to set up Debian/Ubuntu apt sources automatically 112s sh: Distribution appears to be Ubuntu 113s Reading package lists... 113s Building dependency tree... 113s Reading state information... 114s eatmydata is already the newest version (131-1). 114s 0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded. 114s Reading package lists... 114s Building dependency tree... 114s Reading state information... 115s dbus is already the newest version (1.14.10-4ubuntu1). 115s 0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded. 115s Reading package lists... 115s Building dependency tree... 115s Reading state information... 115s rng-tools-debian is already the newest version (2.4). 115s 0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded. 115s Reading package lists... 115s Building dependency tree... 115s Reading state information... 116s The following packages will be REMOVED: 116s cloud-init* python3-configobj* python3-debconf* 116s 0 upgraded, 0 newly installed, 3 to remove and 0 not upgraded. 116s After this operation, 3256 kB disk space will be freed. 116s (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 ... 71864 files and directories currently installed.) 116s Removing cloud-init (24.1.2-0ubuntu1) ... 117s Removing python3-configobj (5.0.8-3) ... 117s Removing python3-debconf (1.5.86) ... 117s Processing triggers for man-db (2.12.0-3) ... 117s (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 ... 71475 files and directories currently installed.) 117s Purging configuration files for cloud-init (24.1.2-0ubuntu1) ... 118s dpkg: warning: while removing cloud-init, directory '/etc/cloud/cloud.cfg.d' not empty so not removed 118s Processing triggers for rsyslog (8.2312.0-3ubuntu3) ... 118s invoke-rc.d: policy-rc.d denied execution of try-restart. 118s Reading package lists... 118s Building dependency tree... 118s Reading state information... 119s linux-generic is already the newest version (6.8.0-11.11+1). 119s 0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded. 119s Hit:1 http://ftpmaster.internal/ubuntu noble InRelease 119s Hit:2 http://ftpmaster.internal/ubuntu noble-updates InRelease 119s Hit:3 http://ftpmaster.internal/ubuntu noble-security InRelease 121s Reading package lists... 121s Reading package lists... 121s Building dependency tree... 121s Reading state information... 122s Calculating upgrade... 122s 0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded. 122s Reading package lists... 122s Building dependency tree... 122s Reading state information... 123s 0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded. 123s autopkgtest [10:46:27]: rebooting testbed after setup commands that affected boot 145s autopkgtest [10:46:49]: testbed running kernel: Linux 6.8.0-11-generic #11-Ubuntu SMP PREEMPT_DYNAMIC Wed Feb 14 00:29:05 UTC 2024 146s autopkgtest [10:46:50]: @@@@@@@@@@@@@@@@@@@@ apt-source r-cran-pbapply 147s Get:1 http://ftpmaster.internal/ubuntu noble/universe r-cran-pbapply 1.7-2-1 (dsc) [2127 B] 147s Get:2 http://ftpmaster.internal/ubuntu noble/universe r-cran-pbapply 1.7-2-1 (tar) [24.0 kB] 147s Get:3 http://ftpmaster.internal/ubuntu noble/universe r-cran-pbapply 1.7-2-1 (diff) [2808 B] 147s gpgv: Signature made Fri Jun 30 14:06:59 2023 UTC 147s gpgv: using RSA key F1F007320A035541F0A663CA578A0494D1C646D1 147s gpgv: issuer "tille@debian.org" 147s gpgv: Can't check signature: No public key 147s dpkg-source: warning: cannot verify inline signature for ./r-cran-pbapply_1.7-2-1.dsc: no acceptable signature found 147s autopkgtest [10:46:51]: testing package r-cran-pbapply version 1.7-2-1 147s autopkgtest [10:46:51]: build not needed 149s autopkgtest [10:46:53]: test run-unit-test: preparing testbed 152s Note, using file '/tmp/autopkgtest.6yOvjE/1-autopkgtest-satdep.dsc' to get the build dependencies 152s Reading package lists... 152s Building dependency tree... 152s Reading state information... 153s Starting pkgProblemResolver with broken count: 0 153s Starting 2 pkgProblemResolver with broken count: 0 153s Done 153s The following NEW packages will be installed: 153s build-essential cpp cpp-13 cpp-13-x86-64-linux-gnu cpp-x86-64-linux-gnu 153s fontconfig fontconfig-config fonts-dejavu-core fonts-dejavu-mono 153s fonts-font-awesome fonts-glyphicons-halflings g++ g++-13 153s g++-13-x86-64-linux-gnu g++-x86-64-linux-gnu gcc gcc-13 153s gcc-13-x86-64-linux-gnu gcc-x86-64-linux-gnu javascript-common libasan8 153s libatomic1 libblas3 libc-dev-bin libc6-dev libcairo2 libcc1-0 libcrypt-dev 153s libdatrie1 libdeflate0 libfontconfig1 libgcc-13-dev libgfortran5 libgomp1 153s libgraphite2-3 libharfbuzz0b libhwasan0 libice6 libisl23 libitm1 libjbig0 153s libjpeg-turbo8 libjpeg8 libjs-bootstrap libjs-bootstrap4 libjs-d3 153s libjs-es5-shim libjs-highlight.js libjs-jquery libjs-jquery-datatables 153s libjs-jquery-selectize.js libjs-jquery-ui libjs-json libjs-microplugin.js 153s libjs-popper.js libjs-sifter.js libjs-twitter-bootstrap-datepicker 153s liblapack3 liblerc4 liblsan0 libmpc3 libpango-1.0-0 libpangocairo-1.0-0 153s libpangoft2-1.0-0 libpaper-utils libpaper1 libpixman-1-0 libquadmath0 153s libsharpyuv0 libsm6 libstdc++-13-dev libtcl8.6 libthai-data libthai0 153s libtiff6 libtk8.6 libtsan2 libubsan1 libwebp7 libxcb-render0 libxcb-shm0 153s libxft2 libxrender1 libxss1 libxt6 linux-libc-dev littler 153s node-bootstrap-sass node-html5shiv node-normalize.css r-base-core 153s r-cran-base64enc r-cran-bslib r-cran-cachem r-cran-cli r-cran-codetools 153s r-cran-commonmark r-cran-crayon r-cran-digest r-cran-ellipsis r-cran-fastmap 153s r-cran-fontawesome r-cran-fs r-cran-future r-cran-future.apply 153s r-cran-globals r-cran-glue r-cran-htmltools r-cran-httpuv r-cran-jquerylib 153s r-cran-jsonlite r-cran-later r-cran-lifecycle r-cran-listenv r-cran-littler 153s r-cran-magrittr r-cran-memoise r-cran-mime r-cran-parallelly r-cran-pbapply 153s r-cran-pkgkitten r-cran-promises r-cran-r6 r-cran-rappdirs r-cran-rcpp 153s r-cran-rlang r-cran-sass r-cran-shiny r-cran-sourcetools r-cran-withr 153s r-cran-xtable rpcsvc-proto unzip x11-common xdg-utils zip 153s 0 upgraded, 136 newly installed, 0 to remove and 0 not upgraded. 153s Need to get 128 MB of archives. 153s After this operation, 385 MB of additional disk space will be used. 153s Get:1 http://ftpmaster.internal/ubuntu noble/main amd64 libc-dev-bin amd64 2.39-0ubuntu6 [20.4 kB] 153s Get:2 http://ftpmaster.internal/ubuntu noble/main amd64 linux-libc-dev amd64 6.8.0-11.11 [1595 kB] 153s Get:3 http://ftpmaster.internal/ubuntu noble/main amd64 libcrypt-dev amd64 1:4.4.36-4 [128 kB] 153s Get:4 http://ftpmaster.internal/ubuntu noble/main amd64 rpcsvc-proto amd64 1.4.2-0ubuntu6 [68.5 kB] 153s Get:5 http://ftpmaster.internal/ubuntu noble/main amd64 libc6-dev amd64 2.39-0ubuntu6 [2126 kB] 154s Get:6 http://ftpmaster.internal/ubuntu noble/main amd64 libisl23 amd64 0.26-3 [741 kB] 154s Get:7 http://ftpmaster.internal/ubuntu noble/main amd64 libmpc3 amd64 1.3.1-1 [54.1 kB] 154s Get:8 http://ftpmaster.internal/ubuntu noble/main amd64 cpp-13-x86-64-linux-gnu amd64 13.2.0-17ubuntu2 [11.2 MB] 154s Get:9 http://ftpmaster.internal/ubuntu noble/main amd64 cpp-13 amd64 13.2.0-17ubuntu2 [1030 B] 154s Get:10 http://ftpmaster.internal/ubuntu noble/main amd64 cpp-x86-64-linux-gnu amd64 4:13.2.0-7ubuntu1 [5326 B] 154s Get:11 http://ftpmaster.internal/ubuntu noble/main amd64 cpp amd64 4:13.2.0-7ubuntu1 [22.4 kB] 154s Get:12 http://ftpmaster.internal/ubuntu noble/main amd64 libcc1-0 amd64 14-20240303-1ubuntu1 [47.7 kB] 154s Get:13 http://ftpmaster.internal/ubuntu noble/main amd64 libgomp1 amd64 14-20240303-1ubuntu1 [147 kB] 154s Get:14 http://ftpmaster.internal/ubuntu noble/main amd64 libitm1 amd64 14-20240303-1ubuntu1 [29.1 kB] 154s Get:15 http://ftpmaster.internal/ubuntu noble/main amd64 libatomic1 amd64 14-20240303-1ubuntu1 [10.4 kB] 154s Get:16 http://ftpmaster.internal/ubuntu noble/main amd64 libasan8 amd64 14-20240303-1ubuntu1 [3026 kB] 154s Get:17 http://ftpmaster.internal/ubuntu noble/main amd64 liblsan0 amd64 14-20240303-1ubuntu1 [1310 kB] 154s Get:18 http://ftpmaster.internal/ubuntu noble/main amd64 libtsan2 amd64 14-20240303-1ubuntu1 [2732 kB] 154s Get:19 http://ftpmaster.internal/ubuntu noble/main amd64 libubsan1 amd64 14-20240303-1ubuntu1 [1172 kB] 154s Get:20 http://ftpmaster.internal/ubuntu noble/main amd64 libhwasan0 amd64 14-20240303-1ubuntu1 [1629 kB] 154s Get:21 http://ftpmaster.internal/ubuntu noble/main amd64 libquadmath0 amd64 14-20240303-1ubuntu1 [155 kB] 154s Get:22 http://ftpmaster.internal/ubuntu noble/main amd64 libgcc-13-dev amd64 13.2.0-17ubuntu2 [2687 kB] 154s Get:23 http://ftpmaster.internal/ubuntu noble/main amd64 gcc-13-x86-64-linux-gnu amd64 13.2.0-17ubuntu2 [21.9 MB] 154s Get:24 http://ftpmaster.internal/ubuntu noble/main amd64 gcc-13 amd64 13.2.0-17ubuntu2 [477 kB] 154s Get:25 http://ftpmaster.internal/ubuntu noble/main amd64 gcc-x86-64-linux-gnu amd64 4:13.2.0-7ubuntu1 [1212 B] 154s Get:26 http://ftpmaster.internal/ubuntu noble/main amd64 gcc amd64 4:13.2.0-7ubuntu1 [5018 B] 154s Get:27 http://ftpmaster.internal/ubuntu noble/main amd64 libstdc++-13-dev amd64 13.2.0-17ubuntu2 [2340 kB] 154s Get:28 http://ftpmaster.internal/ubuntu noble/main amd64 g++-13-x86-64-linux-gnu amd64 13.2.0-17ubuntu2 [12.5 MB] 154s Get:29 http://ftpmaster.internal/ubuntu noble/main amd64 g++-13 amd64 13.2.0-17ubuntu2 [14.5 kB] 154s Get:30 http://ftpmaster.internal/ubuntu noble/main amd64 g++-x86-64-linux-gnu amd64 4:13.2.0-7ubuntu1 [964 B] 154s Get:31 http://ftpmaster.internal/ubuntu noble/main amd64 g++ amd64 4:13.2.0-7ubuntu1 [1100 B] 154s Get:32 http://ftpmaster.internal/ubuntu noble/main amd64 build-essential amd64 12.10ubuntu1 [4928 B] 154s Get:33 http://ftpmaster.internal/ubuntu noble/main amd64 fonts-dejavu-mono all 2.37-8 [502 kB] 154s Get:34 http://ftpmaster.internal/ubuntu noble/main amd64 fonts-dejavu-core all 2.37-8 [835 kB] 154s Get:35 http://ftpmaster.internal/ubuntu noble/main amd64 fontconfig-config amd64 2.15.0-1ubuntu1 [36.9 kB] 154s Get:36 http://ftpmaster.internal/ubuntu noble/main amd64 libfontconfig1 amd64 2.15.0-1ubuntu1 [139 kB] 154s Get:37 http://ftpmaster.internal/ubuntu noble/main amd64 fontconfig amd64 2.15.0-1ubuntu1 [180 kB] 154s Get:38 http://ftpmaster.internal/ubuntu noble/main amd64 fonts-font-awesome all 5.0.10+really4.7.0~dfsg-4.1 [516 kB] 154s Get:39 http://ftpmaster.internal/ubuntu noble/universe amd64 fonts-glyphicons-halflings all 1.009~3.4.1+dfsg-3 [118 kB] 154s Get:40 http://ftpmaster.internal/ubuntu noble/main amd64 javascript-common all 11+nmu1 [5936 B] 154s Get:41 http://ftpmaster.internal/ubuntu noble/main amd64 libblas3 amd64 3.12.0-3 [238 kB] 154s Get:42 http://ftpmaster.internal/ubuntu noble/main amd64 libpixman-1-0 amd64 0.42.2-1 [268 kB] 154s Get:43 http://ftpmaster.internal/ubuntu noble/main amd64 libxcb-render0 amd64 1.15-1 [16.3 kB] 154s Get:44 http://ftpmaster.internal/ubuntu noble/main amd64 libxcb-shm0 amd64 1.15-1 [5740 B] 154s Get:45 http://ftpmaster.internal/ubuntu noble/main amd64 libxrender1 amd64 1:0.9.10-1.1 [20.0 kB] 154s Get:46 http://ftpmaster.internal/ubuntu noble/main amd64 libcairo2 amd64 1.18.0-1 [572 kB] 154s Get:47 http://ftpmaster.internal/ubuntu noble/main amd64 libdatrie1 amd64 0.2.13-3 [20.9 kB] 154s Get:48 http://ftpmaster.internal/ubuntu noble/main amd64 libdeflate0 amd64 1.19-1 [43.7 kB] 154s Get:49 http://ftpmaster.internal/ubuntu noble/main amd64 libgfortran5 amd64 14-20240303-1ubuntu1 [924 kB] 154s Get:50 http://ftpmaster.internal/ubuntu noble/main amd64 libgraphite2-3 amd64 1.3.14-2 [83.1 kB] 154s Get:51 http://ftpmaster.internal/ubuntu noble/main amd64 libharfbuzz0b amd64 8.3.0-2 [469 kB] 154s Get:52 http://ftpmaster.internal/ubuntu noble/main amd64 x11-common all 1:7.7+23ubuntu2 [23.4 kB] 154s Get:53 http://ftpmaster.internal/ubuntu noble/main amd64 libice6 amd64 2:1.0.10-1build2 [42.6 kB] 154s Get:54 http://ftpmaster.internal/ubuntu noble/main amd64 libjpeg-turbo8 amd64 2.1.5-2ubuntu1 [147 kB] 154s Get:55 http://ftpmaster.internal/ubuntu noble/main amd64 libjpeg8 amd64 8c-2ubuntu11 [2148 B] 154s Get:56 http://ftpmaster.internal/ubuntu noble/universe amd64 libjs-bootstrap all 3.4.1+dfsg-3 [129 kB] 154s Get:57 http://ftpmaster.internal/ubuntu noble/universe amd64 libjs-popper.js all 1.16.1+ds-6 [54.1 kB] 154s Get:58 http://ftpmaster.internal/ubuntu noble/universe amd64 libjs-bootstrap4 all 4.6.1+dfsg1-4 [537 kB] 154s Get:59 http://ftpmaster.internal/ubuntu noble/universe amd64 libjs-d3 all 3.5.17-4 [132 kB] 154s Get:60 http://ftpmaster.internal/ubuntu noble/universe amd64 libjs-es5-shim all 4.6.7-2 [39.8 kB] 154s Get:61 http://ftpmaster.internal/ubuntu noble/universe amd64 libjs-highlight.js all 9.18.5+dfsg1-2 [385 kB] 154s Get:62 http://ftpmaster.internal/ubuntu noble/main amd64 libjs-jquery all 3.6.1+dfsg+~3.5.14-1 [328 kB] 154s Get:63 http://ftpmaster.internal/ubuntu noble/universe amd64 libjs-jquery-datatables all 1.11.5+dfsg-2 [146 kB] 154s Get:64 http://ftpmaster.internal/ubuntu noble/universe amd64 libjs-sifter.js all 0.6.0+dfsg-3 [12.6 kB] 154s Get:65 http://ftpmaster.internal/ubuntu noble/universe amd64 libjs-microplugin.js all 0.0.3+dfsg-1.1 [3712 B] 154s Get:66 http://ftpmaster.internal/ubuntu noble/universe amd64 libjs-jquery-selectize.js all 0.12.6+dfsg-1.1 [51.0 kB] 154s Get:67 http://ftpmaster.internal/ubuntu noble/universe amd64 libjs-jquery-ui all 1.13.2+dfsg-1 [252 kB] 154s Get:68 http://ftpmaster.internal/ubuntu noble/universe amd64 libjs-json all 0~20221030+~1.0.8-1 [20.6 kB] 154s Get:69 http://ftpmaster.internal/ubuntu noble/main amd64 liblapack3 amd64 3.12.0-3 [2649 kB] 154s Get:70 http://ftpmaster.internal/ubuntu noble/main amd64 liblerc4 amd64 4.0.0+ds-4ubuntu1 [184 kB] 154s Get:71 http://ftpmaster.internal/ubuntu noble/main amd64 libthai-data all 0.1.29-2 [158 kB] 154s Get:72 http://ftpmaster.internal/ubuntu noble/main amd64 libthai0 amd64 0.1.29-2 [18.8 kB] 154s Get:73 http://ftpmaster.internal/ubuntu noble/main amd64 libpango-1.0-0 amd64 1.51.0+ds-4 [228 kB] 154s Get:74 http://ftpmaster.internal/ubuntu noble/main amd64 libpangoft2-1.0-0 amd64 1.51.0+ds-4 [42.1 kB] 154s Get:75 http://ftpmaster.internal/ubuntu noble/main amd64 libpangocairo-1.0-0 amd64 1.51.0+ds-4 [29.0 kB] 154s Get:76 http://ftpmaster.internal/ubuntu noble/main amd64 libpaper1 amd64 1.1.29 [13.4 kB] 154s Get:77 http://ftpmaster.internal/ubuntu noble/main amd64 libpaper-utils amd64 1.1.29 [8658 B] 154s Get:78 http://ftpmaster.internal/ubuntu noble/main amd64 libsharpyuv0 amd64 1.3.2-0.4 [15.6 kB] 154s Get:79 http://ftpmaster.internal/ubuntu noble/main amd64 libsm6 amd64 2:1.2.3-1build2 [16.7 kB] 154s Get:80 http://ftpmaster.internal/ubuntu noble/main amd64 libtcl8.6 amd64 8.6.13+dfsg-2 [984 kB] 154s Get:81 http://ftpmaster.internal/ubuntu noble/main amd64 libjbig0 amd64 2.1-6.1ubuntu1 [29.3 kB] 154s Get:82 http://ftpmaster.internal/ubuntu noble/main amd64 libwebp7 amd64 1.3.2-0.4 [230 kB] 154s Get:83 http://ftpmaster.internal/ubuntu noble/main amd64 libtiff6 amd64 4.5.1+git230720-3ubuntu1 [232 kB] 154s Get:84 http://ftpmaster.internal/ubuntu noble/main amd64 libxft2 amd64 2.3.6-1 [44.5 kB] 154s Get:85 http://ftpmaster.internal/ubuntu noble/main amd64 libxss1 amd64 1:1.2.3-1build2 [8476 B] 154s Get:86 http://ftpmaster.internal/ubuntu noble/main amd64 libtk8.6 amd64 8.6.14-1 [779 kB] 154s Get:87 http://ftpmaster.internal/ubuntu noble/main amd64 libxt6 amd64 1:1.2.1-1.1 [173 kB] 154s Get:88 http://ftpmaster.internal/ubuntu noble/main amd64 zip amd64 3.0-13 [176 kB] 154s Get:89 http://ftpmaster.internal/ubuntu noble/main amd64 unzip amd64 6.0-28ubuntu3 [174 kB] 154s Get:90 http://ftpmaster.internal/ubuntu noble/main amd64 xdg-utils all 1.1.3-4.1ubuntu3 [62.0 kB] 154s Get:91 http://ftpmaster.internal/ubuntu noble/universe amd64 r-base-core amd64 4.3.2-1build1 [27.0 MB] 154s Get:92 http://ftpmaster.internal/ubuntu noble/universe amd64 r-cran-littler amd64 0.3.19-1 [94.1 kB] 154s Get:93 http://ftpmaster.internal/ubuntu noble/universe amd64 littler all 0.3.19-1 [2472 B] 154s Get:94 http://ftpmaster.internal/ubuntu noble/universe amd64 node-bootstrap-sass all 3.4.3-2 [187 kB] 154s Get:95 http://ftpmaster.internal/ubuntu noble/universe amd64 node-html5shiv all 3.7.3+dfsg-5 [13.5 kB] 154s Get:96 http://ftpmaster.internal/ubuntu noble/universe amd64 node-normalize.css all 8.0.1-5 [10.8 kB] 154s Get:97 http://ftpmaster.internal/ubuntu noble/universe amd64 r-cran-base64enc amd64 0.1-3-3 [27.6 kB] 154s Get:98 http://ftpmaster.internal/ubuntu noble/universe amd64 r-cran-rlang amd64 1.1.3-1 [1663 kB] 154s Get:99 http://ftpmaster.internal/ubuntu noble/universe amd64 r-cran-fastmap amd64 1.1.1-1 [70.5 kB] 154s Get:100 http://ftpmaster.internal/ubuntu noble/universe amd64 r-cran-cachem amd64 1.0.8-1 [72.1 kB] 154s Get:101 http://ftpmaster.internal/ubuntu noble/universe amd64 r-cran-digest amd64 0.6.34-1 [186 kB] 154s Get:102 http://ftpmaster.internal/ubuntu noble/universe amd64 r-cran-ellipsis amd64 0.3.2-2 [35.6 kB] 154s Get:103 http://ftpmaster.internal/ubuntu noble/universe amd64 r-cran-htmltools amd64 0.5.7-1 [369 kB] 154s Get:104 http://ftpmaster.internal/ubuntu noble/universe amd64 r-cran-jquerylib all 0.1.4+dfsg-4 [13.5 kB] 154s Get:105 http://ftpmaster.internal/ubuntu noble/universe amd64 r-cran-jsonlite amd64 1.8.8+dfsg-1 [441 kB] 154s Get:106 http://ftpmaster.internal/ubuntu noble/universe amd64 r-cran-cli amd64 3.6.2-1 [1380 kB] 154s Get:107 http://ftpmaster.internal/ubuntu noble/universe amd64 r-cran-glue amd64 1.7.0-1 [154 kB] 154s Get:108 http://ftpmaster.internal/ubuntu noble/universe amd64 r-cran-lifecycle all 1.0.4+dfsg-1 [110 kB] 154s Get:109 http://ftpmaster.internal/ubuntu noble/universe amd64 r-cran-memoise all 2.0.1-1 [53.9 kB] 154s Get:110 http://ftpmaster.internal/ubuntu noble/universe amd64 r-cran-mime amd64 0.12-1 [35.8 kB] 154s Get:111 http://ftpmaster.internal/ubuntu noble/universe amd64 r-cran-fs amd64 1.6.3+dfsg-1 [229 kB] 154s Get:112 http://ftpmaster.internal/ubuntu noble/universe amd64 r-cran-r6 all 2.5.1-1 [99.0 kB] 154s Get:113 http://ftpmaster.internal/ubuntu noble/universe amd64 r-cran-rappdirs amd64 0.3.3-1 [47.5 kB] 154s Get:114 http://ftpmaster.internal/ubuntu noble/universe amd64 r-cran-sass amd64 0.4.8+dfsg-1 [996 kB] 154s Get:115 http://ftpmaster.internal/ubuntu noble/universe amd64 r-cran-bslib all 0.6.1+dfsg-1 [5138 kB] 154s Get:116 http://ftpmaster.internal/ubuntu noble/universe amd64 r-cran-codetools all 0.2-19-1 [90.5 kB] 154s Get:117 http://ftpmaster.internal/ubuntu noble/universe amd64 r-cran-commonmark amd64 1.9.1-1 [131 kB] 154s Get:118 http://ftpmaster.internal/ubuntu noble/universe amd64 r-cran-crayon all 1.5.2-1 [164 kB] 154s Get:119 http://ftpmaster.internal/ubuntu noble/universe amd64 r-cran-fontawesome all 0.5.2-1 [1300 kB] 154s Get:120 http://ftpmaster.internal/ubuntu noble/universe amd64 r-cran-globals all 0.16.2-1 [117 kB] 154s Get:121 http://ftpmaster.internal/ubuntu noble/universe amd64 r-cran-listenv all 0.9.1+dfsg-1 [112 kB] 154s Get:122 http://ftpmaster.internal/ubuntu noble/universe amd64 r-cran-parallelly amd64 1.37.1-1 [365 kB] 154s Get:123 http://ftpmaster.internal/ubuntu noble/universe amd64 r-cran-future all 1.33.1+dfsg-1 [634 kB] 154s Get:124 http://ftpmaster.internal/ubuntu noble/universe amd64 r-cran-future.apply all 1.11.1+dfsg-1 [171 kB] 154s Get:125 http://ftpmaster.internal/ubuntu noble/universe amd64 r-cran-pkgkitten all 0.2.3-1 [25.1 kB] 154s Get:126 http://ftpmaster.internal/ubuntu noble/universe amd64 r-cran-rcpp amd64 1.0.12-1 [1981 kB] 154s Get:127 http://ftpmaster.internal/ubuntu noble/universe amd64 r-cran-later amd64 1.3.2+dfsg-1 [123 kB] 154s Get:128 http://ftpmaster.internal/ubuntu noble/universe amd64 r-cran-magrittr amd64 2.0.3-1 [154 kB] 154s Get:129 http://ftpmaster.internal/ubuntu noble/universe amd64 r-cran-promises amd64 1.2.1+dfsg-1 [284 kB] 154s Get:130 http://ftpmaster.internal/ubuntu noble/universe amd64 r-cran-httpuv amd64 1.6.14+dfsg-1 [510 kB] 154s Get:131 http://ftpmaster.internal/ubuntu noble/universe amd64 r-cran-pbapply all 1.7-2-1 [102 kB] 154s Get:132 http://ftpmaster.internal/ubuntu noble/universe amd64 r-cran-xtable all 1:1.8-4-2 [689 kB] 154s Get:133 http://ftpmaster.internal/ubuntu noble/universe amd64 r-cran-sourcetools amd64 0.1.7-1-1 [48.1 kB] 154s Get:134 http://ftpmaster.internal/ubuntu noble/universe amd64 r-cran-withr all 2.5.0-1 [225 kB] 154s Get:135 http://ftpmaster.internal/ubuntu noble/universe amd64 libjs-twitter-bootstrap-datepicker all 1.3.1+dfsg1-4.1 [28.5 kB] 154s Get:136 http://ftpmaster.internal/ubuntu noble/universe amd64 r-cran-shiny all 1.8.0+dfsg-1 [2762 kB] 155s Preconfiguring packages ... 155s Fetched 128 MB in 1s (137 MB/s) 155s Selecting previously unselected package libc-dev-bin. 155s (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 ... 71420 files and directories currently installed.) 155s Preparing to unpack .../000-libc-dev-bin_2.39-0ubuntu6_amd64.deb ... 155s Unpacking libc-dev-bin (2.39-0ubuntu6) ... 155s Selecting previously unselected package linux-libc-dev:amd64. 155s Preparing to unpack .../001-linux-libc-dev_6.8.0-11.11_amd64.deb ... 155s Unpacking linux-libc-dev:amd64 (6.8.0-11.11) ... 155s Selecting previously unselected package libcrypt-dev:amd64. 155s Preparing to unpack .../002-libcrypt-dev_1%3a4.4.36-4_amd64.deb ... 155s Unpacking libcrypt-dev:amd64 (1:4.4.36-4) ... 155s Selecting previously unselected package rpcsvc-proto. 155s Preparing to unpack .../003-rpcsvc-proto_1.4.2-0ubuntu6_amd64.deb ... 155s Unpacking rpcsvc-proto (1.4.2-0ubuntu6) ... 155s Selecting previously unselected package libc6-dev:amd64. 155s Preparing to unpack .../004-libc6-dev_2.39-0ubuntu6_amd64.deb ... 155s Unpacking libc6-dev:amd64 (2.39-0ubuntu6) ... 156s Selecting previously unselected package libisl23:amd64. 156s Preparing to unpack .../005-libisl23_0.26-3_amd64.deb ... 156s Unpacking libisl23:amd64 (0.26-3) ... 156s Selecting previously unselected package libmpc3:amd64. 156s Preparing to unpack .../006-libmpc3_1.3.1-1_amd64.deb ... 156s Unpacking libmpc3:amd64 (1.3.1-1) ... 156s Selecting previously unselected package cpp-13-x86-64-linux-gnu. 156s Preparing to unpack .../007-cpp-13-x86-64-linux-gnu_13.2.0-17ubuntu2_amd64.deb ... 156s Unpacking cpp-13-x86-64-linux-gnu (13.2.0-17ubuntu2) ... 156s Selecting previously unselected package cpp-13. 156s Preparing to unpack .../008-cpp-13_13.2.0-17ubuntu2_amd64.deb ... 156s Unpacking cpp-13 (13.2.0-17ubuntu2) ... 156s Selecting previously unselected package cpp-x86-64-linux-gnu. 156s Preparing to unpack .../009-cpp-x86-64-linux-gnu_4%3a13.2.0-7ubuntu1_amd64.deb ... 156s Unpacking cpp-x86-64-linux-gnu (4:13.2.0-7ubuntu1) ... 156s Selecting previously unselected package cpp. 156s Preparing to unpack .../010-cpp_4%3a13.2.0-7ubuntu1_amd64.deb ... 156s Unpacking cpp (4:13.2.0-7ubuntu1) ... 156s Selecting previously unselected package libcc1-0:amd64. 156s Preparing to unpack .../011-libcc1-0_14-20240303-1ubuntu1_amd64.deb ... 156s Unpacking libcc1-0:amd64 (14-20240303-1ubuntu1) ... 156s Selecting previously unselected package libgomp1:amd64. 156s Preparing to unpack .../012-libgomp1_14-20240303-1ubuntu1_amd64.deb ... 156s Unpacking libgomp1:amd64 (14-20240303-1ubuntu1) ... 156s Selecting previously unselected package libitm1:amd64. 156s Preparing to unpack .../013-libitm1_14-20240303-1ubuntu1_amd64.deb ... 156s Unpacking libitm1:amd64 (14-20240303-1ubuntu1) ... 156s Selecting previously unselected package libatomic1:amd64. 156s Preparing to unpack .../014-libatomic1_14-20240303-1ubuntu1_amd64.deb ... 156s Unpacking libatomic1:amd64 (14-20240303-1ubuntu1) ... 156s Selecting previously unselected package libasan8:amd64. 156s Preparing to unpack .../015-libasan8_14-20240303-1ubuntu1_amd64.deb ... 156s Unpacking libasan8:amd64 (14-20240303-1ubuntu1) ... 156s Selecting previously unselected package liblsan0:amd64. 156s Preparing to unpack .../016-liblsan0_14-20240303-1ubuntu1_amd64.deb ... 156s Unpacking liblsan0:amd64 (14-20240303-1ubuntu1) ... 156s Selecting previously unselected package libtsan2:amd64. 156s Preparing to unpack .../017-libtsan2_14-20240303-1ubuntu1_amd64.deb ... 156s Unpacking libtsan2:amd64 (14-20240303-1ubuntu1) ... 156s Selecting previously unselected package libubsan1:amd64. 156s Preparing to unpack .../018-libubsan1_14-20240303-1ubuntu1_amd64.deb ... 156s Unpacking libubsan1:amd64 (14-20240303-1ubuntu1) ... 156s Selecting previously unselected package libhwasan0:amd64. 156s Preparing to unpack .../019-libhwasan0_14-20240303-1ubuntu1_amd64.deb ... 156s Unpacking libhwasan0:amd64 (14-20240303-1ubuntu1) ... 156s Selecting previously unselected package libquadmath0:amd64. 156s Preparing to unpack .../020-libquadmath0_14-20240303-1ubuntu1_amd64.deb ... 156s Unpacking libquadmath0:amd64 (14-20240303-1ubuntu1) ... 156s Selecting previously unselected package libgcc-13-dev:amd64. 156s Preparing to unpack .../021-libgcc-13-dev_13.2.0-17ubuntu2_amd64.deb ... 156s Unpacking libgcc-13-dev:amd64 (13.2.0-17ubuntu2) ... 157s Selecting previously unselected package gcc-13-x86-64-linux-gnu. 157s Preparing to unpack .../022-gcc-13-x86-64-linux-gnu_13.2.0-17ubuntu2_amd64.deb ... 157s Unpacking gcc-13-x86-64-linux-gnu (13.2.0-17ubuntu2) ... 157s Selecting previously unselected package gcc-13. 157s Preparing to unpack .../023-gcc-13_13.2.0-17ubuntu2_amd64.deb ... 157s Unpacking gcc-13 (13.2.0-17ubuntu2) ... 157s Selecting previously unselected package gcc-x86-64-linux-gnu. 157s Preparing to unpack .../024-gcc-x86-64-linux-gnu_4%3a13.2.0-7ubuntu1_amd64.deb ... 157s Unpacking gcc-x86-64-linux-gnu (4:13.2.0-7ubuntu1) ... 157s Selecting previously unselected package gcc. 157s Preparing to unpack .../025-gcc_4%3a13.2.0-7ubuntu1_amd64.deb ... 157s Unpacking gcc (4:13.2.0-7ubuntu1) ... 157s Selecting previously unselected package libstdc++-13-dev:amd64. 157s Preparing to unpack .../026-libstdc++-13-dev_13.2.0-17ubuntu2_amd64.deb ... 157s Unpacking libstdc++-13-dev:amd64 (13.2.0-17ubuntu2) ... 157s Selecting previously unselected package g++-13-x86-64-linux-gnu. 157s Preparing to unpack .../027-g++-13-x86-64-linux-gnu_13.2.0-17ubuntu2_amd64.deb ... 157s Unpacking g++-13-x86-64-linux-gnu (13.2.0-17ubuntu2) ... 158s Selecting previously unselected package g++-13. 158s Preparing to unpack .../028-g++-13_13.2.0-17ubuntu2_amd64.deb ... 158s Unpacking g++-13 (13.2.0-17ubuntu2) ... 158s Selecting previously unselected package g++-x86-64-linux-gnu. 158s Preparing to unpack .../029-g++-x86-64-linux-gnu_4%3a13.2.0-7ubuntu1_amd64.deb ... 158s Unpacking g++-x86-64-linux-gnu (4:13.2.0-7ubuntu1) ... 158s Selecting previously unselected package g++. 158s Preparing to unpack .../030-g++_4%3a13.2.0-7ubuntu1_amd64.deb ... 158s Unpacking g++ (4:13.2.0-7ubuntu1) ... 158s Selecting previously unselected package build-essential. 158s Preparing to unpack .../031-build-essential_12.10ubuntu1_amd64.deb ... 158s Unpacking build-essential (12.10ubuntu1) ... 158s Selecting previously unselected package fonts-dejavu-mono. 158s Preparing to unpack .../032-fonts-dejavu-mono_2.37-8_all.deb ... 158s Unpacking fonts-dejavu-mono (2.37-8) ... 158s Selecting previously unselected package fonts-dejavu-core. 158s Preparing to unpack .../033-fonts-dejavu-core_2.37-8_all.deb ... 158s Unpacking fonts-dejavu-core (2.37-8) ... 158s Selecting previously unselected package fontconfig-config. 158s Preparing to unpack .../034-fontconfig-config_2.15.0-1ubuntu1_amd64.deb ... 158s Unpacking fontconfig-config (2.15.0-1ubuntu1) ... 158s Selecting previously unselected package libfontconfig1:amd64. 158s Preparing to unpack .../035-libfontconfig1_2.15.0-1ubuntu1_amd64.deb ... 158s Unpacking libfontconfig1:amd64 (2.15.0-1ubuntu1) ... 158s Selecting previously unselected package fontconfig. 158s Preparing to unpack .../036-fontconfig_2.15.0-1ubuntu1_amd64.deb ... 158s Unpacking fontconfig (2.15.0-1ubuntu1) ... 158s Selecting previously unselected package fonts-font-awesome. 158s Preparing to unpack .../037-fonts-font-awesome_5.0.10+really4.7.0~dfsg-4.1_all.deb ... 158s Unpacking fonts-font-awesome (5.0.10+really4.7.0~dfsg-4.1) ... 158s Selecting previously unselected package fonts-glyphicons-halflings. 158s Preparing to unpack .../038-fonts-glyphicons-halflings_1.009~3.4.1+dfsg-3_all.deb ... 158s Unpacking fonts-glyphicons-halflings (1.009~3.4.1+dfsg-3) ... 158s Selecting previously unselected package javascript-common. 158s Preparing to unpack .../039-javascript-common_11+nmu1_all.deb ... 158s Unpacking javascript-common (11+nmu1) ... 158s Selecting previously unselected package libblas3:amd64. 158s Preparing to unpack .../040-libblas3_3.12.0-3_amd64.deb ... 158s Unpacking libblas3:amd64 (3.12.0-3) ... 158s Selecting previously unselected package libpixman-1-0:amd64. 158s Preparing to unpack .../041-libpixman-1-0_0.42.2-1_amd64.deb ... 158s Unpacking libpixman-1-0:amd64 (0.42.2-1) ... 158s Selecting previously unselected package libxcb-render0:amd64. 158s Preparing to unpack .../042-libxcb-render0_1.15-1_amd64.deb ... 158s Unpacking libxcb-render0:amd64 (1.15-1) ... 158s Selecting previously unselected package libxcb-shm0:amd64. 158s Preparing to unpack .../043-libxcb-shm0_1.15-1_amd64.deb ... 158s Unpacking libxcb-shm0:amd64 (1.15-1) ... 158s Selecting previously unselected package libxrender1:amd64. 158s Preparing to unpack .../044-libxrender1_1%3a0.9.10-1.1_amd64.deb ... 158s Unpacking libxrender1:amd64 (1:0.9.10-1.1) ... 158s Selecting previously unselected package libcairo2:amd64. 158s Preparing to unpack .../045-libcairo2_1.18.0-1_amd64.deb ... 158s Unpacking libcairo2:amd64 (1.18.0-1) ... 158s Selecting previously unselected package libdatrie1:amd64. 158s Preparing to unpack .../046-libdatrie1_0.2.13-3_amd64.deb ... 158s Unpacking libdatrie1:amd64 (0.2.13-3) ... 158s Selecting previously unselected package libdeflate0:amd64. 158s Preparing to unpack .../047-libdeflate0_1.19-1_amd64.deb ... 158s Unpacking libdeflate0:amd64 (1.19-1) ... 158s Selecting previously unselected package libgfortran5:amd64. 158s Preparing to unpack .../048-libgfortran5_14-20240303-1ubuntu1_amd64.deb ... 158s Unpacking libgfortran5:amd64 (14-20240303-1ubuntu1) ... 158s Selecting previously unselected package libgraphite2-3:amd64. 159s Preparing to unpack .../049-libgraphite2-3_1.3.14-2_amd64.deb ... 159s Unpacking libgraphite2-3:amd64 (1.3.14-2) ... 159s Selecting previously unselected package libharfbuzz0b:amd64. 159s Preparing to unpack .../050-libharfbuzz0b_8.3.0-2_amd64.deb ... 159s Unpacking libharfbuzz0b:amd64 (8.3.0-2) ... 159s Selecting previously unselected package x11-common. 159s Preparing to unpack .../051-x11-common_1%3a7.7+23ubuntu2_all.deb ... 159s Unpacking x11-common (1:7.7+23ubuntu2) ... 159s Selecting previously unselected package libice6:amd64. 159s Preparing to unpack .../052-libice6_2%3a1.0.10-1build2_amd64.deb ... 159s Unpacking libice6:amd64 (2:1.0.10-1build2) ... 159s Selecting previously unselected package libjpeg-turbo8:amd64. 159s Preparing to unpack .../053-libjpeg-turbo8_2.1.5-2ubuntu1_amd64.deb ... 159s Unpacking libjpeg-turbo8:amd64 (2.1.5-2ubuntu1) ... 159s Selecting previously unselected package libjpeg8:amd64. 159s Preparing to unpack .../054-libjpeg8_8c-2ubuntu11_amd64.deb ... 159s Unpacking libjpeg8:amd64 (8c-2ubuntu11) ... 159s Selecting previously unselected package libjs-bootstrap. 159s Preparing to unpack .../055-libjs-bootstrap_3.4.1+dfsg-3_all.deb ... 159s Unpacking libjs-bootstrap (3.4.1+dfsg-3) ... 159s Selecting previously unselected package libjs-popper.js. 159s Preparing to unpack .../056-libjs-popper.js_1.16.1+ds-6_all.deb ... 159s Unpacking libjs-popper.js (1.16.1+ds-6) ... 159s Selecting previously unselected package libjs-bootstrap4. 159s Preparing to unpack .../057-libjs-bootstrap4_4.6.1+dfsg1-4_all.deb ... 159s Unpacking libjs-bootstrap4 (4.6.1+dfsg1-4) ... 159s Selecting previously unselected package libjs-d3. 159s Preparing to unpack .../058-libjs-d3_3.5.17-4_all.deb ... 159s Unpacking libjs-d3 (3.5.17-4) ... 159s Selecting previously unselected package libjs-es5-shim. 159s Preparing to unpack .../059-libjs-es5-shim_4.6.7-2_all.deb ... 159s Unpacking libjs-es5-shim (4.6.7-2) ... 159s Selecting previously unselected package libjs-highlight.js. 159s Preparing to unpack .../060-libjs-highlight.js_9.18.5+dfsg1-2_all.deb ... 159s Unpacking libjs-highlight.js (9.18.5+dfsg1-2) ... 159s Selecting previously unselected package libjs-jquery. 159s Preparing to unpack .../061-libjs-jquery_3.6.1+dfsg+~3.5.14-1_all.deb ... 159s Unpacking libjs-jquery (3.6.1+dfsg+~3.5.14-1) ... 159s Selecting previously unselected package libjs-jquery-datatables. 159s Preparing to unpack .../062-libjs-jquery-datatables_1.11.5+dfsg-2_all.deb ... 159s Unpacking libjs-jquery-datatables (1.11.5+dfsg-2) ... 159s Selecting previously unselected package libjs-sifter.js. 159s Preparing to unpack .../063-libjs-sifter.js_0.6.0+dfsg-3_all.deb ... 159s Unpacking libjs-sifter.js (0.6.0+dfsg-3) ... 159s Selecting previously unselected package libjs-microplugin.js. 159s Preparing to unpack .../064-libjs-microplugin.js_0.0.3+dfsg-1.1_all.deb ... 159s Unpacking libjs-microplugin.js (0.0.3+dfsg-1.1) ... 159s Selecting previously unselected package libjs-jquery-selectize.js. 159s Preparing to unpack .../065-libjs-jquery-selectize.js_0.12.6+dfsg-1.1_all.deb ... 159s Unpacking libjs-jquery-selectize.js (0.12.6+dfsg-1.1) ... 159s Selecting previously unselected package libjs-jquery-ui. 159s Preparing to unpack .../066-libjs-jquery-ui_1.13.2+dfsg-1_all.deb ... 159s Unpacking libjs-jquery-ui (1.13.2+dfsg-1) ... 159s Selecting previously unselected package libjs-json. 159s Preparing to unpack .../067-libjs-json_0~20221030+~1.0.8-1_all.deb ... 159s Unpacking libjs-json (0~20221030+~1.0.8-1) ... 159s Selecting previously unselected package liblapack3:amd64. 159s Preparing to unpack .../068-liblapack3_3.12.0-3_amd64.deb ... 159s Unpacking liblapack3:amd64 (3.12.0-3) ... 159s Selecting previously unselected package liblerc4:amd64. 159s Preparing to unpack .../069-liblerc4_4.0.0+ds-4ubuntu1_amd64.deb ... 159s Unpacking liblerc4:amd64 (4.0.0+ds-4ubuntu1) ... 159s Selecting previously unselected package libthai-data. 159s Preparing to unpack .../070-libthai-data_0.1.29-2_all.deb ... 159s Unpacking libthai-data (0.1.29-2) ... 159s Selecting previously unselected package libthai0:amd64. 159s Preparing to unpack .../071-libthai0_0.1.29-2_amd64.deb ... 159s Unpacking libthai0:amd64 (0.1.29-2) ... 159s Selecting previously unselected package libpango-1.0-0:amd64. 159s Preparing to unpack .../072-libpango-1.0-0_1.51.0+ds-4_amd64.deb ... 159s Unpacking libpango-1.0-0:amd64 (1.51.0+ds-4) ... 159s Selecting previously unselected package libpangoft2-1.0-0:amd64. 159s Preparing to unpack .../073-libpangoft2-1.0-0_1.51.0+ds-4_amd64.deb ... 159s Unpacking libpangoft2-1.0-0:amd64 (1.51.0+ds-4) ... 159s Selecting previously unselected package libpangocairo-1.0-0:amd64. 159s Preparing to unpack .../074-libpangocairo-1.0-0_1.51.0+ds-4_amd64.deb ... 159s Unpacking libpangocairo-1.0-0:amd64 (1.51.0+ds-4) ... 159s Selecting previously unselected package libpaper1:amd64. 159s Preparing to unpack .../075-libpaper1_1.1.29_amd64.deb ... 159s Unpacking libpaper1:amd64 (1.1.29) ... 159s Selecting previously unselected package libpaper-utils. 159s Preparing to unpack .../076-libpaper-utils_1.1.29_amd64.deb ... 159s Unpacking libpaper-utils (1.1.29) ... 159s Selecting previously unselected package libsharpyuv0:amd64. 159s Preparing to unpack .../077-libsharpyuv0_1.3.2-0.4_amd64.deb ... 159s Unpacking libsharpyuv0:amd64 (1.3.2-0.4) ... 160s Selecting previously unselected package libsm6:amd64. 160s Preparing to unpack .../078-libsm6_2%3a1.2.3-1build2_amd64.deb ... 160s Unpacking libsm6:amd64 (2:1.2.3-1build2) ... 160s Selecting previously unselected package libtcl8.6:amd64. 160s Preparing to unpack .../079-libtcl8.6_8.6.13+dfsg-2_amd64.deb ... 160s Unpacking libtcl8.6:amd64 (8.6.13+dfsg-2) ... 160s Selecting previously unselected package libjbig0:amd64. 160s Preparing to unpack .../080-libjbig0_2.1-6.1ubuntu1_amd64.deb ... 160s Unpacking libjbig0:amd64 (2.1-6.1ubuntu1) ... 160s Selecting previously unselected package libwebp7:amd64. 160s Preparing to unpack .../081-libwebp7_1.3.2-0.4_amd64.deb ... 160s Unpacking libwebp7:amd64 (1.3.2-0.4) ... 160s Selecting previously unselected package libtiff6:amd64. 160s Preparing to unpack .../082-libtiff6_4.5.1+git230720-3ubuntu1_amd64.deb ... 160s Unpacking libtiff6:amd64 (4.5.1+git230720-3ubuntu1) ... 160s Selecting previously unselected package libxft2:amd64. 160s Preparing to unpack .../083-libxft2_2.3.6-1_amd64.deb ... 160s Unpacking libxft2:amd64 (2.3.6-1) ... 160s Selecting previously unselected package libxss1:amd64. 160s Preparing to unpack .../084-libxss1_1%3a1.2.3-1build2_amd64.deb ... 160s Unpacking libxss1:amd64 (1:1.2.3-1build2) ... 160s Selecting previously unselected package libtk8.6:amd64. 160s Preparing to unpack .../085-libtk8.6_8.6.14-1_amd64.deb ... 160s Unpacking libtk8.6:amd64 (8.6.14-1) ... 160s Selecting previously unselected package libxt6:amd64. 160s Preparing to unpack .../086-libxt6_1%3a1.2.1-1.1_amd64.deb ... 160s Unpacking libxt6:amd64 (1:1.2.1-1.1) ... 160s Selecting previously unselected package zip. 160s Preparing to unpack .../087-zip_3.0-13_amd64.deb ... 160s Unpacking zip (3.0-13) ... 160s Selecting previously unselected package unzip. 160s Preparing to unpack .../088-unzip_6.0-28ubuntu3_amd64.deb ... 160s Unpacking unzip (6.0-28ubuntu3) ... 160s Selecting previously unselected package xdg-utils. 160s Preparing to unpack .../089-xdg-utils_1.1.3-4.1ubuntu3_all.deb ... 160s Unpacking xdg-utils (1.1.3-4.1ubuntu3) ... 160s Selecting previously unselected package r-base-core. 160s Preparing to unpack .../090-r-base-core_4.3.2-1build1_amd64.deb ... 160s Unpacking r-base-core (4.3.2-1build1) ... 160s Selecting previously unselected package r-cran-littler. 160s Preparing to unpack .../091-r-cran-littler_0.3.19-1_amd64.deb ... 160s Unpacking r-cran-littler (0.3.19-1) ... 160s Selecting previously unselected package littler. 160s Preparing to unpack .../092-littler_0.3.19-1_all.deb ... 160s Unpacking littler (0.3.19-1) ... 160s Selecting previously unselected package node-bootstrap-sass. 160s Preparing to unpack .../093-node-bootstrap-sass_3.4.3-2_all.deb ... 160s Unpacking node-bootstrap-sass (3.4.3-2) ... 160s Selecting previously unselected package node-html5shiv. 160s Preparing to unpack .../094-node-html5shiv_3.7.3+dfsg-5_all.deb ... 160s Unpacking node-html5shiv (3.7.3+dfsg-5) ... 160s Selecting previously unselected package node-normalize.css. 160s Preparing to unpack .../095-node-normalize.css_8.0.1-5_all.deb ... 160s Unpacking node-normalize.css (8.0.1-5) ... 160s Selecting previously unselected package r-cran-base64enc. 160s Preparing to unpack .../096-r-cran-base64enc_0.1-3-3_amd64.deb ... 160s Unpacking r-cran-base64enc (0.1-3-3) ... 160s Selecting previously unselected package r-cran-rlang. 160s Preparing to unpack .../097-r-cran-rlang_1.1.3-1_amd64.deb ... 160s Unpacking r-cran-rlang (1.1.3-1) ... 161s Selecting previously unselected package r-cran-fastmap. 161s Preparing to unpack .../098-r-cran-fastmap_1.1.1-1_amd64.deb ... 161s Unpacking r-cran-fastmap (1.1.1-1) ... 161s Selecting previously unselected package r-cran-cachem. 161s Preparing to unpack .../099-r-cran-cachem_1.0.8-1_amd64.deb ... 161s Unpacking r-cran-cachem (1.0.8-1) ... 161s Selecting previously unselected package r-cran-digest. 161s Preparing to unpack .../100-r-cran-digest_0.6.34-1_amd64.deb ... 161s Unpacking r-cran-digest (0.6.34-1) ... 161s Selecting previously unselected package r-cran-ellipsis. 161s Preparing to unpack .../101-r-cran-ellipsis_0.3.2-2_amd64.deb ... 161s Unpacking r-cran-ellipsis (0.3.2-2) ... 161s Selecting previously unselected package r-cran-htmltools. 161s Preparing to unpack .../102-r-cran-htmltools_0.5.7-1_amd64.deb ... 161s Unpacking r-cran-htmltools (0.5.7-1) ... 161s Selecting previously unselected package r-cran-jquerylib. 161s Preparing to unpack .../103-r-cran-jquerylib_0.1.4+dfsg-4_all.deb ... 161s Unpacking r-cran-jquerylib (0.1.4+dfsg-4) ... 161s Selecting previously unselected package r-cran-jsonlite. 161s Preparing to unpack .../104-r-cran-jsonlite_1.8.8+dfsg-1_amd64.deb ... 161s Unpacking r-cran-jsonlite (1.8.8+dfsg-1) ... 161s Selecting previously unselected package r-cran-cli. 161s Preparing to unpack .../105-r-cran-cli_3.6.2-1_amd64.deb ... 161s Unpacking r-cran-cli (3.6.2-1) ... 161s Selecting previously unselected package r-cran-glue. 161s Preparing to unpack .../106-r-cran-glue_1.7.0-1_amd64.deb ... 161s Unpacking r-cran-glue (1.7.0-1) ... 161s Selecting previously unselected package r-cran-lifecycle. 161s Preparing to unpack .../107-r-cran-lifecycle_1.0.4+dfsg-1_all.deb ... 161s Unpacking r-cran-lifecycle (1.0.4+dfsg-1) ... 161s Selecting previously unselected package r-cran-memoise. 161s Preparing to unpack .../108-r-cran-memoise_2.0.1-1_all.deb ... 161s Unpacking r-cran-memoise (2.0.1-1) ... 161s Selecting previously unselected package r-cran-mime. 161s Preparing to unpack .../109-r-cran-mime_0.12-1_amd64.deb ... 161s Unpacking r-cran-mime (0.12-1) ... 161s Selecting previously unselected package r-cran-fs. 161s Preparing to unpack .../110-r-cran-fs_1.6.3+dfsg-1_amd64.deb ... 161s Unpacking r-cran-fs (1.6.3+dfsg-1) ... 161s Selecting previously unselected package r-cran-r6. 161s Preparing to unpack .../111-r-cran-r6_2.5.1-1_all.deb ... 161s Unpacking r-cran-r6 (2.5.1-1) ... 161s Selecting previously unselected package r-cran-rappdirs. 161s Preparing to unpack .../112-r-cran-rappdirs_0.3.3-1_amd64.deb ... 161s Unpacking r-cran-rappdirs (0.3.3-1) ... 161s Selecting previously unselected package r-cran-sass. 161s Preparing to unpack .../113-r-cran-sass_0.4.8+dfsg-1_amd64.deb ... 161s Unpacking r-cran-sass (0.4.8+dfsg-1) ... 161s Selecting previously unselected package r-cran-bslib. 161s Preparing to unpack .../114-r-cran-bslib_0.6.1+dfsg-1_all.deb ... 161s Unpacking r-cran-bslib (0.6.1+dfsg-1) ... 161s Selecting previously unselected package r-cran-codetools. 161s Preparing to unpack .../115-r-cran-codetools_0.2-19-1_all.deb ... 161s Unpacking r-cran-codetools (0.2-19-1) ... 161s Selecting previously unselected package r-cran-commonmark. 161s Preparing to unpack .../116-r-cran-commonmark_1.9.1-1_amd64.deb ... 161s Unpacking r-cran-commonmark (1.9.1-1) ... 161s Selecting previously unselected package r-cran-crayon. 161s Preparing to unpack .../117-r-cran-crayon_1.5.2-1_all.deb ... 161s Unpacking r-cran-crayon (1.5.2-1) ... 161s Selecting previously unselected package r-cran-fontawesome. 161s Preparing to unpack .../118-r-cran-fontawesome_0.5.2-1_all.deb ... 161s Unpacking r-cran-fontawesome (0.5.2-1) ... 161s Selecting previously unselected package r-cran-globals. 161s Preparing to unpack .../119-r-cran-globals_0.16.2-1_all.deb ... 161s Unpacking r-cran-globals (0.16.2-1) ... 161s Selecting previously unselected package r-cran-listenv. 161s Preparing to unpack .../120-r-cran-listenv_0.9.1+dfsg-1_all.deb ... 161s Unpacking r-cran-listenv (0.9.1+dfsg-1) ... 161s Selecting previously unselected package r-cran-parallelly. 161s Preparing to unpack .../121-r-cran-parallelly_1.37.1-1_amd64.deb ... 161s Unpacking r-cran-parallelly (1.37.1-1) ... 161s Selecting previously unselected package r-cran-future. 162s Preparing to unpack .../122-r-cran-future_1.33.1+dfsg-1_all.deb ... 162s Unpacking r-cran-future (1.33.1+dfsg-1) ... 162s Selecting previously unselected package r-cran-future.apply. 162s Preparing to unpack .../123-r-cran-future.apply_1.11.1+dfsg-1_all.deb ... 162s Unpacking r-cran-future.apply (1.11.1+dfsg-1) ... 162s Selecting previously unselected package r-cran-pkgkitten. 162s Preparing to unpack .../124-r-cran-pkgkitten_0.2.3-1_all.deb ... 162s Unpacking r-cran-pkgkitten (0.2.3-1) ... 162s Selecting previously unselected package r-cran-rcpp. 162s Preparing to unpack .../125-r-cran-rcpp_1.0.12-1_amd64.deb ... 162s Unpacking r-cran-rcpp (1.0.12-1) ... 162s Selecting previously unselected package r-cran-later. 162s Preparing to unpack .../126-r-cran-later_1.3.2+dfsg-1_amd64.deb ... 162s Unpacking r-cran-later (1.3.2+dfsg-1) ... 162s Selecting previously unselected package r-cran-magrittr. 162s Preparing to unpack .../127-r-cran-magrittr_2.0.3-1_amd64.deb ... 162s Unpacking r-cran-magrittr (2.0.3-1) ... 162s Selecting previously unselected package r-cran-promises. 162s Preparing to unpack .../128-r-cran-promises_1.2.1+dfsg-1_amd64.deb ... 162s Unpacking r-cran-promises (1.2.1+dfsg-1) ... 162s Selecting previously unselected package r-cran-httpuv. 162s Preparing to unpack .../129-r-cran-httpuv_1.6.14+dfsg-1_amd64.deb ... 162s Unpacking r-cran-httpuv (1.6.14+dfsg-1) ... 162s Selecting previously unselected package r-cran-pbapply. 162s Preparing to unpack .../130-r-cran-pbapply_1.7-2-1_all.deb ... 162s Unpacking r-cran-pbapply (1.7-2-1) ... 162s Selecting previously unselected package r-cran-xtable. 162s Preparing to unpack .../131-r-cran-xtable_1%3a1.8-4-2_all.deb ... 162s Unpacking r-cran-xtable (1:1.8-4-2) ... 162s Selecting previously unselected package r-cran-sourcetools. 162s Preparing to unpack .../132-r-cran-sourcetools_0.1.7-1-1_amd64.deb ... 162s Unpacking r-cran-sourcetools (0.1.7-1-1) ... 162s Selecting previously unselected package r-cran-withr. 162s Preparing to unpack .../133-r-cran-withr_2.5.0-1_all.deb ... 162s Unpacking r-cran-withr (2.5.0-1) ... 162s Selecting previously unselected package libjs-twitter-bootstrap-datepicker. 162s Preparing to unpack .../134-libjs-twitter-bootstrap-datepicker_1.3.1+dfsg1-4.1_all.deb ... 162s Unpacking libjs-twitter-bootstrap-datepicker (1.3.1+dfsg1-4.1) ... 162s Selecting previously unselected package r-cran-shiny. 162s Preparing to unpack .../135-r-cran-shiny_1.8.0+dfsg-1_all.deb ... 162s Unpacking r-cran-shiny (1.8.0+dfsg-1) ... 162s Setting up libjs-json (0~20221030+~1.0.8-1) ... 162s Setting up javascript-common (11+nmu1) ... 162s Setting up libgraphite2-3:amd64 (1.3.14-2) ... 162s Setting up libpixman-1-0:amd64 (0.42.2-1) ... 162s Setting up libsharpyuv0:amd64 (1.3.2-0.4) ... 162s Setting up libpaper1:amd64 (1.1.29) ... 162s 162s Creating config file /etc/papersize with new version 162s Setting up liblerc4:amd64 (4.0.0+ds-4ubuntu1) ... 162s Setting up libxrender1:amd64 (1:0.9.10-1.1) ... 162s Setting up libdatrie1:amd64 (0.2.13-3) ... 162s Setting up libjs-popper.js (1.16.1+ds-6) ... 162s Setting up libxcb-render0:amd64 (1.15-1) ... 162s Setting up libjs-sifter.js (0.6.0+dfsg-3) ... 162s Setting up fonts-glyphicons-halflings (1.009~3.4.1+dfsg-3) ... 162s Setting up unzip (6.0-28ubuntu3) ... 162s Setting up x11-common (1:7.7+23ubuntu2) ... 163s Setting up node-html5shiv (3.7.3+dfsg-5) ... 163s Setting up libdeflate0:amd64 (1.19-1) ... 163s Setting up linux-libc-dev:amd64 (6.8.0-11.11) ... 163s Setting up libjs-microplugin.js (0.0.3+dfsg-1.1) ... 163s Setting up libxcb-shm0:amd64 (1.15-1) ... 163s Setting up libpaper-utils (1.1.29) ... 163s Setting up libgomp1:amd64 (14-20240303-1ubuntu1) ... 163s Setting up libjbig0:amd64 (2.1-6.1ubuntu1) ... 163s Setting up libjs-es5-shim (4.6.7-2) ... 163s Setting up zip (3.0-13) ... 163s Setting up libblas3:amd64 (3.12.0-3) ... 163s update-alternatives: using /usr/lib/x86_64-linux-gnu/blas/libblas.so.3 to provide /usr/lib/x86_64-linux-gnu/libblas.so.3 (libblas.so.3-x86_64-linux-gnu) in auto mode 163s Setting up rpcsvc-proto (1.4.2-0ubuntu6) ... 163s Setting up libquadmath0:amd64 (14-20240303-1ubuntu1) ... 163s Setting up libjs-d3 (3.5.17-4) ... 163s Setting up fonts-dejavu-mono (2.37-8) ... 163s Setting up libmpc3:amd64 (1.3.1-1) ... 163s Setting up libatomic1:amd64 (14-20240303-1ubuntu1) ... 163s Setting up libtcl8.6:amd64 (8.6.13+dfsg-2) ... 163s Setting up fonts-dejavu-core (2.37-8) ... 163s Setting up libjpeg-turbo8:amd64 (2.1.5-2ubuntu1) ... 163s Setting up libgfortran5:amd64 (14-20240303-1ubuntu1) ... 163s Setting up libwebp7:amd64 (1.3.2-0.4) ... 163s Setting up libubsan1:amd64 (14-20240303-1ubuntu1) ... 163s Setting up libjs-highlight.js (9.18.5+dfsg1-2) ... 163s Setting up libhwasan0:amd64 (14-20240303-1ubuntu1) ... 163s Setting up libcrypt-dev:amd64 (1:4.4.36-4) ... 163s Setting up libasan8:amd64 (14-20240303-1ubuntu1) ... 163s Setting up libharfbuzz0b:amd64 (8.3.0-2) ... 163s Setting up libthai-data (0.1.29-2) ... 163s Setting up node-bootstrap-sass (3.4.3-2) ... 163s Setting up libxss1:amd64 (1:1.2.3-1build2) ... 163s Setting up libjs-bootstrap4 (4.6.1+dfsg1-4) ... 163s Setting up libtsan2:amd64 (14-20240303-1ubuntu1) ... 163s Setting up libjs-jquery (3.6.1+dfsg+~3.5.14-1) ... 163s Setting up libisl23:amd64 (0.26-3) ... 163s Setting up libc-dev-bin (2.39-0ubuntu6) ... 163s Setting up node-normalize.css (8.0.1-5) ... 163s Setting up fonts-font-awesome (5.0.10+really4.7.0~dfsg-4.1) ... 163s Setting up xdg-utils (1.1.3-4.1ubuntu3) ... 163s update-alternatives: using /usr/bin/xdg-open to provide /usr/bin/open (open) in auto mode 163s Setting up libcc1-0:amd64 (14-20240303-1ubuntu1) ... 163s Setting up liblsan0:amd64 (14-20240303-1ubuntu1) ... 163s Setting up libjs-bootstrap (3.4.1+dfsg-3) ... 163s Setting up libitm1:amd64 (14-20240303-1ubuntu1) ... 163s Setting up libjs-jquery-selectize.js (0.12.6+dfsg-1.1) ... 163s Setting up libjpeg8:amd64 (8c-2ubuntu11) ... 163s Setting up libice6:amd64 (2:1.0.10-1build2) ... 163s Setting up liblapack3:amd64 (3.12.0-3) ... 163s update-alternatives: using /usr/lib/x86_64-linux-gnu/lapack/liblapack.so.3 to provide /usr/lib/x86_64-linux-gnu/liblapack.so.3 (liblapack.so.3-x86_64-linux-gnu) in auto mode 163s Setting up cpp-13-x86-64-linux-gnu (13.2.0-17ubuntu2) ... 163s Setting up fontconfig-config (2.15.0-1ubuntu1) ... 163s Setting up libjs-twitter-bootstrap-datepicker (1.3.1+dfsg1-4.1) ... 163s Setting up libjs-jquery-datatables (1.11.5+dfsg-2) ... 163s Setting up libthai0:amd64 (0.1.29-2) ... 163s Setting up libjs-jquery-ui (1.13.2+dfsg-1) ... 163s Setting up libgcc-13-dev:amd64 (13.2.0-17ubuntu2) ... 163s Setting up libtiff6:amd64 (4.5.1+git230720-3ubuntu1) ... 163s Setting up libc6-dev:amd64 (2.39-0ubuntu6) ... 163s Setting up libfontconfig1:amd64 (2.15.0-1ubuntu1) ... 163s Setting up libsm6:amd64 (2:1.2.3-1build2) ... 163s Setting up libstdc++-13-dev:amd64 (13.2.0-17ubuntu2) ... 163s Setting up cpp-x86-64-linux-gnu (4:13.2.0-7ubuntu1) ... 163s Setting up fontconfig (2.15.0-1ubuntu1) ... 165s Regenerating fonts cache... done. 165s Setting up libxft2:amd64 (2.3.6-1) ... 165s Setting up cpp-13 (13.2.0-17ubuntu2) ... 165s Setting up gcc-13-x86-64-linux-gnu (13.2.0-17ubuntu2) ... 165s Setting up libtk8.6:amd64 (8.6.14-1) ... 165s Setting up libpango-1.0-0:amd64 (1.51.0+ds-4) ... 165s Setting up libcairo2:amd64 (1.18.0-1) ... 165s Setting up gcc-13 (13.2.0-17ubuntu2) ... 165s Setting up libxt6:amd64 (1:1.2.1-1.1) ... 165s Setting up cpp (4:13.2.0-7ubuntu1) ... 165s Setting up libpangoft2-1.0-0:amd64 (1.51.0+ds-4) ... 165s Setting up libpangocairo-1.0-0:amd64 (1.51.0+ds-4) ... 165s Setting up g++-13-x86-64-linux-gnu (13.2.0-17ubuntu2) ... 165s Setting up gcc-x86-64-linux-gnu (4:13.2.0-7ubuntu1) ... 165s Setting up gcc (4:13.2.0-7ubuntu1) ... 165s Setting up r-base-core (4.3.2-1build1) ... 165s 165s Creating config file /etc/R/Renviron with new version 165s Setting up r-cran-crayon (1.5.2-1) ... 165s Setting up r-cran-sourcetools (0.1.7-1-1) ... 165s Setting up r-cran-pbapply (1.7-2-1) ... 165s Setting up g++-x86-64-linux-gnu (4:13.2.0-7ubuntu1) ... 165s Setting up r-cran-commonmark (1.9.1-1) ... 165s Setting up r-cran-r6 (2.5.1-1) ... 165s Setting up r-cran-pkgkitten (0.2.3-1) ... 165s Setting up r-cran-magrittr (2.0.3-1) ... 165s Setting up r-cran-rappdirs (0.3.3-1) ... 165s Setting up r-cran-littler (0.3.19-1) ... 165s Setting up r-cran-fs (1.6.3+dfsg-1) ... 165s Setting up r-cran-rcpp (1.0.12-1) ... 165s Setting up r-cran-codetools (0.2-19-1) ... 165s Setting up g++-13 (13.2.0-17ubuntu2) ... 165s Setting up r-cran-rlang (1.1.3-1) ... 165s Setting up r-cran-listenv (0.9.1+dfsg-1) ... 165s Setting up littler (0.3.19-1) ... 165s Setting up r-cran-withr (2.5.0-1) ... 165s Setting up r-cran-mime (0.12-1) ... 165s Setting up r-cran-base64enc (0.1-3-3) ... 165s Setting up r-cran-digest (0.6.34-1) ... 165s Setting up r-cran-glue (1.7.0-1) ... 165s Setting up r-cran-xtable (1:1.8-4-2) ... 165s Setting up r-cran-cli (3.6.2-1) ... 165s Setting up r-cran-lifecycle (1.0.4+dfsg-1) ... 165s Setting up r-cran-fastmap (1.1.1-1) ... 165s Setting up r-cran-jsonlite (1.8.8+dfsg-1) ... 165s Setting up r-cran-parallelly (1.37.1-1) ... 165s Setting up r-cran-later (1.3.2+dfsg-1) ... 165s Setting up g++ (4:13.2.0-7ubuntu1) ... 165s update-alternatives: using /usr/bin/g++ to provide /usr/bin/c++ (c++) in auto mode 165s Setting up r-cran-cachem (1.0.8-1) ... 165s Setting up build-essential (12.10ubuntu1) ... 165s Setting up r-cran-globals (0.16.2-1) ... 165s Setting up r-cran-ellipsis (0.3.2-2) ... 165s Setting up r-cran-future (1.33.1+dfsg-1) ... 165s Setting up r-cran-future.apply (1.11.1+dfsg-1) ... 165s Setting up r-cran-memoise (2.0.1-1) ... 165s Setting up r-cran-promises (1.2.1+dfsg-1) ... 165s Setting up r-cran-htmltools (0.5.7-1) ... 165s Setting up r-cran-sass (0.4.8+dfsg-1) ... 165s Setting up r-cran-httpuv (1.6.14+dfsg-1) ... 165s Setting up r-cran-fontawesome (0.5.2-1) ... 165s Setting up r-cran-jquerylib (0.1.4+dfsg-4) ... 165s Setting up r-cran-bslib (0.6.1+dfsg-1) ... 165s Setting up r-cran-shiny (1.8.0+dfsg-1) ... 165s Processing triggers for install-info (7.1-3) ... 166s Processing triggers for libc-bin (2.39-0ubuntu6) ... 166s Processing triggers for man-db (2.12.0-3) ... 170s Reading package lists... 170s Building dependency tree... 170s Reading state information... 170s Starting pkgProblemResolver with broken count: 0 170s Starting 2 pkgProblemResolver with broken count: 0 170s Done 171s The following NEW packages will be installed: 171s autopkgtest-satdep 171s 0 upgraded, 1 newly installed, 0 to remove and 0 not upgraded. 171s Need to get 0 B/696 B of archives. 171s After this operation, 0 B of additional disk space will be used. 171s Get:1 /tmp/autopkgtest.6yOvjE/2-autopkgtest-satdep.deb autopkgtest-satdep amd64 0 [696 B] 171s Selecting previously unselected package autopkgtest-satdep. 171s (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 ... 82042 files and directories currently installed.) 171s Preparing to unpack .../2-autopkgtest-satdep.deb ... 171s Unpacking autopkgtest-satdep (0) ... 171s Setting up autopkgtest-satdep (0) ... 173s (Reading database ... 82042 files and directories currently installed.) 173s Removing autopkgtest-satdep (0) ... 173s autopkgtest [10:47:17]: test run-unit-test: [----------------------- 173s BEGIN TEST tests.R 173s 173s R version 4.3.2 (2023-10-31) -- "Eye Holes" 173s Copyright (C) 2023 The R Foundation for Statistical Computing 173s Platform: x86_64-pc-linux-gnu (64-bit) 173s 173s R is free software and comes with ABSOLUTELY NO WARRANTY. 173s You are welcome to redistribute it under certain conditions. 173s Type 'license()' or 'licence()' for distribution details. 173s 173s R is a collaborative project with many contributors. 173s Type 'contributors()' for more information and 173s 'citation()' on how to cite R or R packages in publications. 173s 173s Type 'demo()' for some demos, 'help()' for on-line help, or 173s 'help.start()' for an HTML browser interface to help. 173s Type 'q()' to quit R. 173s 173s > #devtools::install_github("psolymos/pbapply") 173s > 173s > ## --- standard examples --- 173s > 173s > library(pbapply) 173s > 173s > example(apply) 173s 173s apply> ## Compute row and column sums for a matrix: 173s apply> x <- cbind(x1 = 3, x2 = c(4:1, 2:5)) 173s 173s apply> dimnames(x)[[1]] <- letters[1:8] 173s 173s apply> apply(x, 2, mean, trim = .2) 173s x1 x2 173s 3 3 173s 173s apply> col.sums <- apply(x, 2, sum) 173s 173s apply> row.sums <- apply(x, 1, sum) 173s 173s apply> rbind(cbind(x, Rtot = row.sums), Ctot = c(col.sums, sum(col.sums))) 173s x1 x2 Rtot 173s a 3 4 7 173s b 3 3 6 173s c 3 2 5 173s d 3 1 4 173s e 3 2 5 173s f 3 3 6 173s g 3 4 7 173s h 3 5 8 173s Ctot 24 24 48 173s 173s apply> stopifnot( apply(x, 2, is.vector)) 173s 173s apply> ## Sort the columns of a matrix 173s apply> apply(x, 2, sort) 173s x1 x2 173s [1,] 3 1 173s [2,] 3 2 173s [3,] 3 2 173s [4,] 3 3 173s [5,] 3 3 173s [6,] 3 4 173s [7,] 3 4 173s [8,] 3 5 173s 173s apply> ## keeping named dimnames 173s apply> names(dimnames(x)) <- c("row", "col") 173s 173s apply> x3 <- array(x, dim = c(dim(x),3), 173s apply+ dimnames = c(dimnames(x), list(C = paste0("cop.",1:3)))) 173s 173s apply> identical(x, apply( x, 2, identity)) 173s [1] TRUE 173s 173s apply> identical(x3, apply(x3, 2:3, identity)) 173s [1] TRUE 173s 173s apply> ## Don't show: 173s apply> xN <- x; dimnames(xN) <- list(row=NULL, col=NULL) 173s 173s apply> x2 <- x; names(dimnames(x2)) <- NULL 173s 173s apply> fXY <- function(u) c(X=u[1], Y=u[2]) 173s 173s apply> ax1 <- apply(x, 1, fXY) 173s 173s apply> ax2 <- apply(x2,1, fXY) 173s 173s apply> stopifnot(identical(dimnames(ax1), list(col=c("X.x1", "Y.x2"), row=letters[1:8])), 173s apply+ identical(dimnames(ax2), unname(dimnames(ax1))), 173s apply+ identical( x, apply( x, 2, identity)), 173s apply+ identical(xN, apply(xN, 2, identity)), 173s apply+ identical(dimnames(x), 173s apply+ dimnames(apply(x, 2, format))), 173s apply+ identical(x3, apply(x3, 2:3, identity)), 173s apply+ identical(dimnames(apply(x3, 2:1, identity)), 173s apply+ dimnames(x3)[3:1])) 173s 173s apply> rm(xN, x2, fXY, ax1, ax2) 173s 173s apply> ## End(Don't show) 173s apply> ##- function with extra args: 173s apply> cave <- function(x, c1, c2) c(mean(x[c1]), mean(x[c2])) 173s 173s apply> apply(x, 1, cave, c1 = "x1", c2 = c("x1","x2")) 173s row 173s a b c d e f g h 173s [1,] 3.0 3 3.0 3 3.0 3 3.0 3 173s [2,] 3.5 3 2.5 2 2.5 3 3.5 4 173s 173s apply> ma <- matrix(c(1:4, 1, 6:8), nrow = 2) 173s 173s apply> ma 173s [,1] [,2] [,3] [,4] 173s [1,] 1 3 1 7 173s [2,] 2 4 6 8 173s 173s apply> apply(ma, 1, table) #--> a list of length 2 173s [[1]] 173s 173s 1 3 7 173s 2 1 1 173s 173s [[2]] 173s 173s 2 4 6 8 173s 1 1 1 1 173s 173s 173s apply> apply(ma, 1, stats::quantile) # 5 x n matrix with rownames 173s [,1] [,2] 173s 0% 1 2.0 173s 25% 1 3.5 173s 50% 2 5.0 173s 75% 4 6.5 173s 100% 7 8.0 173s 173s apply> stopifnot(dim(ma) == dim(apply(ma, 1:2, sum))) 173s 173s apply> ## Example with different lengths for each call 173s apply> z <- array(1:24, dim = 2:4) 173s 173s apply> zseq <- apply(z, 1:2, function(x) seq_len(max(x))) 173s 173s apply> zseq ## a 2 x 3 matrix 173s [,1] [,2] [,3] 173s [1,] integer,19 integer,21 integer,23 173s [2,] integer,20 integer,22 integer,24 173s 173s apply> typeof(zseq) ## list 173s [1] "list" 173s 173s apply> dim(zseq) ## 2 3 173s [1] 2 3 173s 173s apply> zseq[1,] 173s [[1]] 173s [1] 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 173s 173s [[2]] 173s [1] 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 173s 173s [[3]] 173s [1] 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 173s 173s 173s apply> apply(z, 3, function(x) seq_len(max(x))) 173s [[1]] 173s [1] 1 2 3 4 5 6 173s 173s [[2]] 173s [1] 1 2 3 4 5 6 7 8 9 10 11 12 173s 173s [[3]] 173s [1] 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 173s 173s [[4]] 173s [1] 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 173s 173s 173s apply> # a list without a dim attribute 173s apply> 173s apply> 173s apply> 173s > example(lapply) 173s 173s lapply> require(stats); require(graphics) 173s 173s lapply> x <- list(a = 1:10, beta = exp(-3:3), logic = c(TRUE,FALSE,FALSE,TRUE)) 173s 173s lapply> # compute the list mean for each list element 173s lapply> lapply(x, mean) 173s $a 173s [1] 5.5 173s 173s $beta 173s [1] 4.535125 173s 173s $logic 173s [1] 0.5 173s 173s 173s lapply> # median and quartiles for each list element 173s lapply> lapply(x, quantile, probs = 1:3/4) 173s $a 173s 25% 50% 75% 173s 3.25 5.50 7.75 173s 173s $beta 173s 25% 50% 75% 173s 0.2516074 1.0000000 5.0536690 173s 173s $logic 173s 25% 50% 75% 173s 0.0 0.5 1.0 173s 173s 173s lapply> sapply(x, quantile) 173s a beta logic 173s 0% 1.00 0.04978707 0.0 173s 25% 3.25 0.25160736 0.0 173s 50% 5.50 1.00000000 0.5 173s 75% 7.75 5.05366896 1.0 173s 100% 10.00 20.08553692 1.0 173s 173s lapply> i39 <- sapply(3:9, seq) # list of vectors 173s 173s lapply> sapply(i39, fivenum) 173s [,1] [,2] [,3] [,4] [,5] [,6] [,7] 173s [1,] 1.0 1.0 1 1.0 1.0 1.0 1 173s [2,] 1.5 1.5 2 2.0 2.5 2.5 3 173s [3,] 2.0 2.5 3 3.5 4.0 4.5 5 173s [4,] 2.5 3.5 4 5.0 5.5 6.5 7 173s [5,] 3.0 4.0 5 6.0 7.0 8.0 9 173s 173s lapply> vapply(i39, fivenum, 173s lapply+ c(Min. = 0, "1st Qu." = 0, Median = 0, "3rd Qu." = 0, Max. = 0)) 173s [,1] [,2] [,3] [,4] [,5] [,6] [,7] 173s Min. 1.0 1.0 1 1.0 1.0 1.0 1 173s 1st Qu. 1.5 1.5 2 2.0 2.5 2.5 3 173s Median 2.0 2.5 3 3.5 4.0 4.5 5 173s 3rd Qu. 2.5 3.5 4 5.0 5.5 6.5 7 173s Max. 3.0 4.0 5 6.0 7.0 8.0 9 173s 173s lapply> ## sapply(*, "array") -- artificial example 173s lapply> (v <- structure(10*(5:8), names = LETTERS[1:4])) 173s A B C D 173s 50 60 70 80 173s 173s lapply> f2 <- function(x, y) outer(rep(x, length.out = 3), y) 173s 173s lapply> (a2 <- sapply(v, f2, y = 2*(1:5), simplify = "array")) 173s , , A 173s 173s [,1] [,2] [,3] [,4] [,5] 173s [1,] 100 200 300 400 500 173s [2,] 100 200 300 400 500 173s [3,] 100 200 300 400 500 173s 173s , , B 173s 173s [,1] [,2] [,3] [,4] [,5] 173s [1,] 120 240 360 480 600 173s [2,] 120 240 360 480 600 173s [3,] 120 240 360 480 600 173s 173s , , C 173s 173s [,1] [,2] [,3] [,4] [,5] 173s [1,] 140 280 420 560 700 173s [2,] 140 280 420 560 700 173s [3,] 140 280 420 560 700 173s 173s , , D 173s 173s [,1] [,2] [,3] [,4] [,5] 173s [1,] 160 320 480 640 800 173s [2,] 160 320 480 640 800 173s [3,] 160 320 480 640 800 173s 173s 173s lapply> a.2 <- vapply(v, f2, outer(1:3, 1:5), y = 2*(1:5)) 173s 173s lapply> stopifnot(dim(a2) == c(3,5,4), all.equal(a2, a.2), 173s lapply+ identical(dimnames(a2), list(NULL,NULL,LETTERS[1:4]))) 173s 173s lapply> hist(replicate(100, mean(rexp(10)))) 174s 174s lapply> ## use of replicate() with parameters: 174s lapply> foo <- function(x = 1, y = 2) c(x, y) 174s 174s lapply> # does not work: bar <- function(n, ...) replicate(n, foo(...)) 174s lapply> bar <- function(n, x) replicate(n, foo(x = x)) 174s 174s lapply> bar(5, x = 3) 174s [,1] [,2] [,3] [,4] [,5] 174s [1,] 3 3 3 3 3 174s [2,] 2 2 2 2 2 174s > 174s > ## run examples without progress bar 174s > pboptions(type = "none") 174s > example(splitpb, run.dontrun = TRUE) 174s 174s spltpb> ## define 1 job / worker at a time and repeat 174s spltpb> splitpb(10, 4) 174s [[1]] 174s [1] 1 2 3 4 174s 174s [[2]] 174s [1] 5 6 7 8 174s 174s [[3]] 174s [1] 9 10 174s 174s 174s spltpb> ## compare this to the no-progress-bar split 174s spltpb> ## that defines all the jubs / worker up front 174s spltpb> parallel::splitIndices(10, 4) 174s [[1]] 174s [1] 1 2 3 174s 174s [[2]] 174s [1] 4 5 174s 174s [[3]] 174s [1] 6 7 174s 174s [[4]] 174s [1] 8 9 10 174s 174s 174s spltpb> ## cap the length of the output 174s spltpb> splitpb(20, 2, nout = NULL) 174s [[1]] 174s [1] 1 2 174s 174s [[2]] 174s [1] 3 4 174s 174s [[3]] 174s [1] 5 6 174s 174s [[4]] 174s [1] 7 8 174s 174s [[5]] 174s [1] 9 10 174s 174s [[6]] 174s [1] 11 12 174s 174s [[7]] 174s [1] 13 14 174s 174s [[8]] 174s [1] 15 16 174s 174s [[9]] 174s [1] 17 18 174s 174s [[10]] 174s [1] 19 20 174s 174s 174s spltpb> splitpb(20, 2, nout = 5) 174s [[1]] 174s [1] 1 2 3 4 174s 174s [[2]] 174s [1] 5 6 7 8 174s 174s [[3]] 174s [1] 9 10 11 12 174s 174s [[4]] 174s [1] 13 14 15 16 174s 174s [[5]] 174s [1] 17 18 19 20 174s 174s > example(timerProgressBar, run.dontrun = TRUE) 174s 174s tmrPrB> ## increase sluggishness to admire the progress bar longer 174s tmrPrB> sluggishness <- 0.02 174s 174s tmrPrB> test_fun <- function(...) 174s tmrPrB+ { 174s tmrPrB+ pb <- timerProgressBar(...) 174s tmrPrB+ on.exit(close(pb)) 174s tmrPrB+ for (i in seq(0, 1, 0.05)) { 174s tmrPrB+ Sys.sleep(sluggishness) 174s tmrPrB+ setTimerProgressBar(pb, i) 174s tmrPrB+ } 174s tmrPrB+ invisible(NULL) 174s tmrPrB+ } 174s 174s tmrPrB> ## check the different styles 174s tmrPrB> test_fun(width = 35, char = "+", style = 1) 174s | | 0 % elapsed=00s | | 0 % elapsed=00s |++ | 5 % elapsed=00s, remaining~01s |++++ | 10% elapsed=00s, remaining~01s |++++++ | 15% elapsed=00s, remaining~00s |+++++++ | 20% elapsed=00s, remaining~00s |+++++++++ | 25% elapsed=00s, remaining~00s |+++++++++++ | 30% elapsed=00s, remaining~00s |+++++++++++++ | 35% elapsed=00s, remaining~00s |++++++++++++++ | 40% elapsed=00s, remaining~00s |++++++++++++++++ | 45% elapsed=00s, remaining~00s |++++++++++++++++++ | 50% elapsed=00s, remaining~00s |++++++++++++++++++++ | 55% elapsed=00s, remaining~00s |++++++++++++++++++++++ | 60% elapsed=00s, remaining~00s |+++++++++++++++++++++++ | 65% elapsed=00s, remaining~00s |+++++++++++++++++++++++++ | 70% elapsed=00s, remaining~00s |+++++++++++++++++++++++++++ | 75% elapsed=00s, remaining~00s |++++++++++++++++++++++++++++ | 80% elapsed=00s, remaining~00s |++++++++++++++++++++++++++++++ | 85% elapsed=00s, remaining~00s |++++++++++++++++++++++++++++++++ | 90% elapsed=00s, remaining~00s |++++++++++++++++++++++++++++++++++ | 95% elapsed=00s, remaining~00s |+++++++++++++++++++++++++++++++++++| 100% elapsed=00s, remaining~00s 174s 174s tmrPrB> test_fun(style = 2) 174s / 0 % elapsed=00s / 0 % elapsed=00s - 5 % elapsed=00s, remaining~01s \ 10% elapsed=00s, remaining~01s | 15% elapsed=00s, remaining~00s / 20% elapsed=00s, remaining~00s - 25% elapsed=00s, remaining~00s \ 30% elapsed=00s, remaining~00s | 35% elapsed=00s, remaining~00s / 40% elapsed=00s, remaining~00s - 45% elapsed=00s, remaining~00s \ 50% elapsed=00s, remaining~00s | 55% elapsed=00s, remaining~00s / 60% elapsed=00s, remaining~00s - 65% elapsed=00s, remaining~00s \ 70% elapsed=00s, remaining~00s | 75% elapsed=00s, remaining~00s / 80% elapsed=00s, remaining~00s - 85% elapsed=00s, remaining~00s \ 90% elapsed=00s, remaining~00s | 95% elapsed=00s, remaining~00s / 100% elapsed=00s, remaining~00s 174s 174s tmrPrB> test_fun(width = 50, char = ".", style = 3) 175s | | 0 % ~calculating | | 0 % ~calculating |... | 5 % ~01s |..... | 10% ~01s |........ | 15% ~00s |.......... | 20% ~00s |............. | 25% ~00s |................ | 30% ~00s |.................. | 35% ~00s |.................... | 40% ~00s |....................... | 45% ~00s |......................... | 50% ~00s |............................ | 55% ~00s |............................... | 60% ~00s |................................. | 65% ~00s |................................... | 70% ~00s |...................................... | 75% ~00s |........................................ | 80% ~00s |........................................... | 85% ~00s |............................................. | 90% ~00s |................................................ | 95% ~00s |..................................................| 100% elapsed=00s 175s 175s tmrPrB> test_fun(style = 4) 175s / 0 % ~calculating / 0 % ~calculating - 5 % ~01s \ 10% ~01s | 15% ~00s / 20% ~00s - 25% ~00s \ 30% ~00s | 35% ~00s / 40% ~00s - 45% ~00s \ 50% ~00s | 55% ~00s / 60% ~00s - 65% ~00s \ 70% ~00s | 75% ~00s / 80% ~00s - 85% ~00s \ 90% ~00s | 95% ~00s / 100% elapsed=00s 175s 175s tmrPrB> test_fun(width = 35, char = "[=-]", style = 5) 176s [-----------------------------------] 0 % elapsed=00s [-----------------------------------] 0 % elapsed=00s [==---------------------------------] 5 % elapsed=00s, remaining~01s [====-------------------------------] 10% elapsed=00s, remaining~01s [======-----------------------------] 15% elapsed=00s, remaining~00s [=======----------------------------] 20% elapsed=00s, remaining~00s [=========--------------------------] 25% elapsed=00s, remaining~00s [===========------------------------] 30% elapsed=00s, remaining~00s [=============----------------------] 35% elapsed=00s, remaining~00s [==============---------------------] 40% elapsed=00s, remaining~00s [================-------------------] 45% elapsed=00s, remaining~00s [==================-----------------] 50% elapsed=00s, remaining~00s [====================---------------] 55% elapsed=00s, remaining~00s [======================-------------] 60% elapsed=00s, remaining~00s [=======================------------] 65% elapsed=00s, remaining~00s [=========================----------] 70% elapsed=00s, remaining~00s [===========================--------] 75% elapsed=00s, remaining~00s [============================-------] 80% elapsed=00s, remaining~00s [==============================-----] 85% elapsed=00s, remaining~00s [================================---] 90% elapsed=00s, remaining~00s [==================================-] 95% elapsed=00s, remaining~00s [===================================] 100% elapsed=00s, remaining~00s 176s 176s tmrPrB> test_fun(width = 50, char = "{*.}", style = 6) 176s {..................................................} 0 % ~calculating {..................................................} 0 % ~calculating {***...............................................} 5 % ~01s {*****.............................................} 10% ~01s {********..........................................} 15% ~00s {**********........................................} 20% ~00s {*************.....................................} 25% ~00s {****************..................................} 30% ~00s {******************................................} 35% ~00s {********************..............................} 40% ~00s {***********************...........................} 45% ~00s {*************************.........................} 50% ~00s {****************************......................} 55% ~00s {*******************************...................} 60% ~00s {*********************************.................} 65% ~00s {***********************************...............} 70% ~00s {**************************************............} 75% ~00s {****************************************..........} 80% ~00s {*******************************************.......} 85% ~00s {*********************************************.....} 90% ~00s {************************************************..} 95% ~00s {**************************************************} 100% elapsed=00s 176s 176s tmrPrB> ## no bar only percent and elapsed 176s tmrPrB> test_fun(width = 0, char = " ", style = 6) 177s 0 % ~calculating 0 % ~calculating 5 % ~01s 10% ~01s 15% ~00s 20% ~00s 25% ~00s 30% ~00s 35% ~00s 40% ~00s 45% ~00s 50% ~00s 55% ~00s 60% ~00s 65% ~00s 70% ~00s 75% ~00s 80% ~00s 85% ~00s 90% ~00s 95% ~00s 100% elapsed=00s 177s 177s tmrPrB> ## this should produce a progress bar based on min_time 177s tmrPrB> (elapsed <- system.time(test_fun(width = 35, min_time = 0))["elapsed"]) 177s | | 0 % elapsed=00s | | 0 % elapsed=00s |== | 5 % elapsed=00s, remaining~01s |==== | 10% elapsed=00s, remaining~01s |====== | 15% elapsed=00s, remaining~00s |======= | 20% elapsed=00s, remaining~00s |========= | 25% elapsed=00s, remaining~00s |=========== | 30% elapsed=00s, remaining~00s |============= | 35% elapsed=00s, remaining~00s |============== | 40% elapsed=00s, remaining~00s |================ | 45% elapsed=00s, remaining~00s |================== | 50% elapsed=00s, remaining~00s |==================== | 55% elapsed=00s, remaining~00s |====================== | 60% elapsed=00s, remaining~00s |======================= | 65% elapsed=00s, remaining~00s |========================= | 70% elapsed=00s, remaining~00s |=========================== | 75% elapsed=00s, remaining~00s |============================ | 80% elapsed=00s, remaining~00s |============================== | 85% elapsed=00s, remaining~00s |================================ | 90% elapsed=00s, remaining~00s |================================== | 95% elapsed=00s, remaining~00s |===================================| 100% elapsed=00s, remaining~00s 177s elapsed 177s 0.443 177s 177s tmrPrB> ## this should not produce a progress bar based on min_time 177s tmrPrB> system.time(test_fun(min_time = 2 * elapsed))["elapsed"] 177s elapsed 177s 0.438 177s 177s tmrPrB> ## time formatting 177s tmrPrB> getTimeAsString(NULL) 177s [1] "calculating" 177s 177s tmrPrB> getTimeAsString(15) 177s [1] "15s" 177s 177s tmrPrB> getTimeAsString(65) 177s [1] "01m 05s" 177s 177s tmrPrB> getTimeAsString(6005) 177s [1] "01h 40m 05s" 177s 177s tmrPrB> ## example usage of getTimeAsString, use sluggishness <- 1 177s tmrPrB> n <- 10 177s 177s tmrPrB> t0 <- proc.time()[3] 177s 177s tmrPrB> ETA <- NULL 177s 177s tmrPrB> for (i in seq_len(n)) { 177s tmrPrB+ cat(i, "/", n, "- ETA:", getTimeAsString(ETA)) 177s tmrPrB+ flush.console() 177s tmrPrB+ Sys.sleep(sluggishness) 177s tmrPrB+ dt <- proc.time()[3] - t0 177s tmrPrB+ cat(" - elapsed:", getTimeAsString(dt), "\n") 177s tmrPrB+ ETA <- (n - i) * dt / i 177s tmrPrB+ } 177s 1 / 10 - ETA: calculating - elapsed: 00s 177s 2 / 10 - ETA: 00s - elapsed: 00s 178s 3 / 10 - ETA: 00s - elapsed: 00s 178s 4 / 10 - ETA: 00s - elapsed: 00s 178s 5 / 10 - ETA: 00s - elapsed: 00s 178s 6 / 10 - ETA: 00s - elapsed: 00s 178s 7 / 10 - ETA: 00s - elapsed: 00s 178s 8 / 10 - ETA: 00s - elapsed: 00s 178s 9 / 10 - ETA: 00s - elapsed: 00s 178s 10 / 10 - ETA: 00s - elapsed: 00s 178s > example(pbapply, run.dontrun = TRUE) 178s 178s pbpply> ## --- simple linear model simulation --- 178s pbpply> set.seed(1234) 178s 178s pbpply> n <- 200 178s 178s pbpply> x <- rnorm(n) 178s 178s pbpply> y <- rnorm(n, crossprod(t(model.matrix(~ x)), c(0, 1)), sd = 0.5) 178s 178s pbpply> d <- data.frame(y, x) 178s 178s pbpply> ## model fitting and bootstrap 178s pbpply> mod <- lm(y ~ x, d) 178s 178s pbpply> ndat <- model.frame(mod) 178s 178s pbpply> B <- 100 178s 178s pbpply> bid <- sapply(1:B, function(i) sample(nrow(ndat), nrow(ndat), TRUE)) 178s 178s pbpply> fun <- function(z) { 178s pbpply+ if (missing(z)) 178s pbpply+ z <- sample(nrow(ndat), nrow(ndat), TRUE) 178s pbpply+ coef(lm(mod$call$formula, data=ndat[z,])) 178s pbpply+ } 178s 178s pbpply> ## standard '*apply' functions 178s pbpply> system.time(res1 <- lapply(1:B, function(i) fun(bid[,i]))) 178s user system elapsed 178s 0.096 0.003 0.102 178s 178s pbpply> system.time(res2 <- sapply(1:B, function(i) fun(bid[,i]))) 178s user system elapsed 178s 0.087 0.000 0.090 178s 178s pbpply> system.time(res3 <- apply(bid, 2, fun)) 178s user system elapsed 178s 0.072 0.000 0.074 178s 178s pbpply> system.time(res4 <- replicate(B, fun())) 178s user system elapsed 178s 0.071 0.000 0.074 178s 178s pbpply> ## 'pb*apply' functions 178s pbpply> ## try different settings: 178s pbpply> ## "none", "txt", "tk", "win", "timer" 178s pbpply> op <- pboptions(type = "timer") # default 178s 178s pbpply> system.time(res1pb <- pblapply(1:B, function(i) fun(bid[,i]))) 178s | | 0 % ~calculating |+ | 1 % ~00s |+ | 2 % ~00s |++ | 3 % ~00s |++ | 4 % ~00s |+++ | 5 % ~00s |+++ | 6 % ~00s |++++ | 7 % ~00s |++++ | 8 % ~00s |+++++ | 9 % ~00s |+++++ | 10% ~00s |++++++ | 11% ~00s |++++++ | 12% ~00s |+++++++ | 13% ~00s |+++++++ | 14% ~00s |++++++++ | 15% ~00s |++++++++ | 16% ~00s |+++++++++ | 17% ~00s |+++++++++ | 18% ~00s |++++++++++ | 19% ~00s |++++++++++ | 20% ~00s |+++++++++++ | 21% ~00s |+++++++++++ | 22% ~00s |++++++++++++ | 23% ~00s |++++++++++++ | 24% ~00s |+++++++++++++ | 25% ~00s |+++++++++++++ | 26% ~00s |++++++++++++++ | 27% ~00s |++++++++++++++ | 28% ~00s |+++++++++++++++ | 29% ~00s |+++++++++++++++ | 30% ~00s |++++++++++++++++ | 31% ~00s |++++++++++++++++ | 32% ~00s |+++++++++++++++++ | 33% ~00s |+++++++++++++++++ | 34% ~00s |++++++++++++++++++ | 35% ~00s |++++++++++++++++++ | 36% ~00s |+++++++++++++++++++ | 37% ~00s |+++++++++++++++++++ | 38% ~00s |++++++++++++++++++++ | 39% ~00s |++++++++++++++++++++ | 40% ~00s |+++++++++++++++++++++ | 41% ~00s |+++++++++++++++++++++ | 42% ~00s |++++++++++++++++++++++ | 43% ~00s |++++++++++++++++++++++ | 44% ~00s |+++++++++++++++++++++++ | 45% ~00s |+++++++++++++++++++++++ | 46% ~00s |++++++++++++++++++++++++ | 47% ~00s |++++++++++++++++++++++++ | 48% ~00s |+++++++++++++++++++++++++ | 49% ~00s |+++++++++++++++++++++++++ | 50% ~00s |++++++++++++++++++++++++++ | 51% ~00s |++++++++++++++++++++++++++ | 52% ~00s |+++++++++++++++++++++++++++ | 53% ~00s |+++++++++++++++++++++++++++ | 54% ~00s |++++++++++++++++++++++++++++ | 55% ~00s |++++++++++++++++++++++++++++ | 56% ~00s |+++++++++++++++++++++++++++++ | 57% ~00s |+++++++++++++++++++++++++++++ | 58% ~00s |++++++++++++++++++++++++++++++ | 59% ~00s |++++++++++++++++++++++++++++++ | 60% ~00s |+++++++++++++++++++++++++++++++ | 61% ~00s |+++++++++++++++++++++++++++++++ | 62% ~00s |++++++++++++++++++++++++++++++++ | 63% ~00s |++++++++++++++++++++++++++++++++ | 64% ~00s |+++++++++++++++++++++++++++++++++ | 65% ~00s |+++++++++++++++++++++++++++++++++ | 66% ~00s |++++++++++++++++++++++++++++++++++ | 67% ~00s |++++++++++++++++++++++++++++++++++ | 68% ~00s |+++++++++++++++++++++++++++++++++++ | 69% ~00s |+++++++++++++++++++++++++++++++++++ | 70% ~00s |++++++++++++++++++++++++++++++++++++ | 71% ~00s |++++++++++++++++++++++++++++++++++++ | 72% ~00s |+++++++++++++++++++++++++++++++++++++ | 73% ~00s |+++++++++++++++++++++++++++++++++++++ | 74% ~00s |++++++++++++++++++++++++++++++++++++++ | 75% ~00s |++++++++++++++++++++++++++++++++++++++ | 76% ~00s |+++++++++++++++++++++++++++++++++++++++ | 77% ~00s |+++++++++++++++++++++++++++++++++++++++ | 78% ~00s |++++++++++++++++++++++++++++++++++++++++ | 79% ~00s |++++++++++++++++++++++++++++++++++++++++ | 80% ~00s |+++++++++++++++++++++++++++++++++++++++++ | 81% ~00s |+++++++++++++++++++++++++++++++++++++++++ | 82% ~00s |++++++++++++++++++++++++++++++++++++++++++ | 83% ~00s |++++++++++++++++++++++++++++++++++++++++++ | 84% ~00s |+++++++++++++++++++++++++++++++++++++++++++ | 85% ~00s |+++++++++++++++++++++++++++++++++++++++++++ | 86% ~00s |++++++++++++++++++++++++++++++++++++++++++++ | 87% ~00s |++++++++++++++++++++++++++++++++++++++++++++ | 88% ~00s |+++++++++++++++++++++++++++++++++++++++++++++ | 89% ~00s |+++++++++++++++++++++++++++++++++++++++++++++ | 90% ~00s |++++++++++++++++++++++++++++++++++++++++++++++ | 91% ~00s |++++++++++++++++++++++++++++++++++++++++++++++ | 92% ~00s |+++++++++++++++++++++++++++++++++++++++++++++++ | 93% ~00s |+++++++++++++++++++++++++++++++++++++++++++++++ | 94% ~00s |++++++++++++++++++++++++++++++++++++++++++++++++ | 95% ~00s |++++++++++++++++++++++++++++++++++++++++++++++++ | 96% ~00s |+++++++++++++++++++++++++++++++++++++++++++++++++ | 97% ~00s |+++++++++++++++++++++++++++++++++++++++++++++++++ | 98% ~00s |++++++++++++++++++++++++++++++++++++++++++++++++++| 99% ~00s |++++++++++++++++++++++++++++++++++++++++++++++++++| 100% elapsed=00s 178s user system elapsed 178s 0.087 0.008 0.105 178s 178s pbpply> pboptions(op) 178s 178s pbpply> pboptions(type = "txt") 178s 178s pbpply> system.time(res2pb <- pbsapply(1:B, function(i) fun(bid[,i]))) 178s | | | 0% | | | 1% | |+ | 2% | |++ | 3% | |++ | 4% | |++ | 5% | |+++ | 6% | |++++ | 7% | |++++ | 8% | |++++ | 9% | |+++++ | 10% | |++++++ | 11% | |++++++ | 12% | |++++++ | 13% | |+++++++ | 14% | |++++++++ | 15% | |++++++++ | 16% | |++++++++ | 17% | |+++++++++ | 18% | |++++++++++ | 19% | |++++++++++ | 20% | |++++++++++ | 21% | |+++++++++++ | 22% | |++++++++++++ | 23% | |++++++++++++ | 24% | |++++++++++++ | 25% | |+++++++++++++ | 26% | |++++++++++++++ | 27% | |++++++++++++++ | 28% | |++++++++++++++ | 29% | |+++++++++++++++ | 30% | |++++++++++++++++ | 31% | |++++++++++++++++ | 32% | |++++++++++++++++ | 33% | |+++++++++++++++++ | 34% | |++++++++++++++++++ | 35% | |++++++++++++++++++ | 36% | |++++++++++++++++++ | 37% | |+++++++++++++++++++ | 38% | |++++++++++++++++++++ | 39% | |++++++++++++++++++++ | 40% | |++++++++++++++++++++ | 41% | |+++++++++++++++++++++ | 42% | |++++++++++++++++++++++ | 43% | |++++++++++++++++++++++ | 44% | |++++++++++++++++++++++ | 45% | |+++++++++++++++++++++++ | 46% | |++++++++++++++++++++++++ | 47% | |++++++++++++++++++++++++ | 48% | |++++++++++++++++++++++++ | 49% | |+++++++++++++++++++++++++ | 50% | |++++++++++++++++++++++++++ | 51% | |++++++++++++++++++++++++++ | 52% | |++++++++++++++++++++++++++ | 53% | |+++++++++++++++++++++++++++ | 54% | |++++++++++++++++++++++++++++ | 55% | |++++++++++++++++++++++++++++ | 56% | |++++++++++++++++++++++++++++ | 57% | |+++++++++++++++++++++++++++++ | 58% | |++++++++++++++++++++++++++++++ | 59% | |++++++++++++++++++++++++++++++ | 60% | |++++++++++++++++++++++++++++++ | 61% | |+++++++++++++++++++++++++++++++ | 62% | |++++++++++++++++++++++++++++++++ | 63% | |++++++++++++++++++++++++++++++++ | 64% | |++++++++++++++++++++++++++++++++ | 65% | |+++++++++++++++++++++++++++++++++ | 66% | |++++++++++++++++++++++++++++++++++ | 67% | |++++++++++++++++++++++++++++++++++ | 68% | |++++++++++++++++++++++++++++++++++ | 69% | |+++++++++++++++++++++++++++++++++++ | 70% | |++++++++++++++++++++++++++++++++++++ | 71% | |++++++++++++++++++++++++++++++++++++ | 72% | |++++++++++++++++++++++++++++++++++++ | 73% | |+++++++++++++++++++++++++++++++++++++ | 74% | |++++++++++++++++++++++++++++++++++++++ | 75% | |++++++++++++++++++++++++++++++++++++++ | 76% | |++++++++++++++++++++++++++++++++++++++ | 77% | |+++++++++++++++++++++++++++++++++++++++ | 78% | |++++++++++++++++++++++++++++++++++++++++ | 79% | |++++++++++++++++++++++++++++++++++++++++ | 80% | |++++++++++++++++++++++++++++++++++++++++ | 81% | |+++++++++++++++++++++++++++++++++++++++++ | 82% | |++++++++++++++++++++++++++++++++++++++++++ | 83% | |++++++++++++++++++++++++++++++++++++++++++ | 84% | |++++++++++++++++++++++++++++++++++++++++++ | 85% | |+++++++++++++++++++++++++++++++++++++++++++ | 86% | |++++++++++++++++++++++++++++++++++++++++++++ | 87% | |++++++++++++++++++++++++++++++++++++++++++++ | 88% | |++++++++++++++++++++++++++++++++++++++++++++ | 89% | |+++++++++++++++++++++++++++++++++++++++++++++ | 90% | |++++++++++++++++++++++++++++++++++++++++++++++ | 91% | |++++++++++++++++++++++++++++++++++++++++++++++ | 92% | |++++++++++++++++++++++++++++++++++++++++++++++ | 93% | |+++++++++++++++++++++++++++++++++++++++++++++++ | 94% | |++++++++++++++++++++++++++++++++++++++++++++++++ | 95% | |++++++++++++++++++++++++++++++++++++++++++++++++ | 96% | |++++++++++++++++++++++++++++++++++++++++++++++++ | 97% | |+++++++++++++++++++++++++++++++++++++++++++++++++ | 98% | |++++++++++++++++++++++++++++++++++++++++++++++++++| 99% | |++++++++++++++++++++++++++++++++++++++++++++++++++| 100% 178s user system elapsed 178s 0.076 0.008 0.089 178s 178s pbpply> pboptions(op) 178s 178s pbpply> pboptions(type = "txt", style = 1, char = "=") 178s 178s pbpply> system.time(res3pb <- pbapply(bid, 2, fun)) 179s ================================================== 179s user system elapsed 179s 0.079 0.000 0.084 179s 179s pbpply> pboptions(op) 179s 179s pbpply> pboptions(type = "txt", char = ":") 179s 179s pbpply> system.time(res4pb <- pbreplicate(B, fun())) 179s | | | 0% | | | 1% | |: | 2% | |:: | 3% | |:: | 4% | |:: | 5% | |::: | 6% | |:::: | 7% | |:::: | 8% | |:::: | 9% | |::::: | 10% | |:::::: | 11% | |:::::: | 12% | |:::::: | 13% | |::::::: | 14% | |:::::::: | 15% | |:::::::: | 16% | |:::::::: | 17% | |::::::::: | 18% | |:::::::::: | 19% | |:::::::::: | 20% | |:::::::::: | 21% | |::::::::::: | 22% | |:::::::::::: | 23% | |:::::::::::: | 24% | |:::::::::::: | 25% | |::::::::::::: | 26% | |:::::::::::::: | 27% | |:::::::::::::: | 28% | |:::::::::::::: | 29% | |::::::::::::::: | 30% | |:::::::::::::::: | 31% | |:::::::::::::::: | 32% | |:::::::::::::::: | 33% | |::::::::::::::::: | 34% | |:::::::::::::::::: | 35% | |:::::::::::::::::: | 36% | |:::::::::::::::::: | 37% | |::::::::::::::::::: | 38% | |:::::::::::::::::::: | 39% | |:::::::::::::::::::: | 40% | |:::::::::::::::::::: | 41% | |::::::::::::::::::::: | 42% | |:::::::::::::::::::::: | 43% | |:::::::::::::::::::::: | 44% | |:::::::::::::::::::::: | 45% | |::::::::::::::::::::::: | 46% | |:::::::::::::::::::::::: | 47% | |:::::::::::::::::::::::: | 48% | |:::::::::::::::::::::::: | 49% | |::::::::::::::::::::::::: | 50% | |:::::::::::::::::::::::::: | 51% | |:::::::::::::::::::::::::: | 52% | |:::::::::::::::::::::::::: | 53% | |::::::::::::::::::::::::::: | 54% | |:::::::::::::::::::::::::::: | 55% | |:::::::::::::::::::::::::::: | 56% | |:::::::::::::::::::::::::::: | 57% | |::::::::::::::::::::::::::::: | 58% | |:::::::::::::::::::::::::::::: | 59% | |:::::::::::::::::::::::::::::: | 60% | |:::::::::::::::::::::::::::::: | 61% | |::::::::::::::::::::::::::::::: | 62% | |:::::::::::::::::::::::::::::::: | 63% | |:::::::::::::::::::::::::::::::: | 64% | |:::::::::::::::::::::::::::::::: | 65% | |::::::::::::::::::::::::::::::::: | 66% | |:::::::::::::::::::::::::::::::::: | 67% | |:::::::::::::::::::::::::::::::::: | 68% | |:::::::::::::::::::::::::::::::::: | 69% | |::::::::::::::::::::::::::::::::::: | 70% | |:::::::::::::::::::::::::::::::::::: | 71% | |:::::::::::::::::::::::::::::::::::: | 72% | |:::::::::::::::::::::::::::::::::::: | 73% | |::::::::::::::::::::::::::::::::::::: | 74% | |:::::::::::::::::::::::::::::::::::::: | 75% | |:::::::::::::::::::::::::::::::::::::: | 76% | |:::::::::::::::::::::::::::::::::::::: | 77% | |::::::::::::::::::::::::::::::::::::::: | 78% | |:::::::::::::::::::::::::::::::::::::::: | 79% | |:::::::::::::::::::::::::::::::::::::::: | 80% | |:::::::::::::::::::::::::::::::::::::::: | 81% | |::::::::::::::::::::::::::::::::::::::::: | 82% | |:::::::::::::::::::::::::::::::::::::::::: | 83% | |:::::::::::::::::::::::::::::::::::::::::: | 84% | |:::::::::::::::::::::::::::::::::::::::::: | 85% | |::::::::::::::::::::::::::::::::::::::::::: | 86% | |:::::::::::::::::::::::::::::::::::::::::::: | 87% | |:::::::::::::::::::::::::::::::::::::::::::: | 88% | |:::::::::::::::::::::::::::::::::::::::::::: | 89% | |::::::::::::::::::::::::::::::::::::::::::::: | 90% | |:::::::::::::::::::::::::::::::::::::::::::::: | 91% | |:::::::::::::::::::::::::::::::::::::::::::::: | 92% | |:::::::::::::::::::::::::::::::::::::::::::::: | 93% | |::::::::::::::::::::::::::::::::::::::::::::::: | 94% | |:::::::::::::::::::::::::::::::::::::::::::::::: | 95% | |:::::::::::::::::::::::::::::::::::::::::::::::: | 96% | |:::::::::::::::::::::::::::::::::::::::::::::::: | 97% | |::::::::::::::::::::::::::::::::::::::::::::::::: | 98% | |::::::::::::::::::::::::::::::::::::::::::::::::::| 99% | |::::::::::::::::::::::::::::::::::::::::::::::::::| 100% 179s user system elapsed 179s 0.079 0.015 0.100 179s 179s pbpply> pboptions(op) 179s 179s pbpply> ## parallel evaluation using the parallel package 179s pbpply> ## (n = 2000 and B = 1000 will give visible timing differences) 179s pbpply> 179s pbpply> library(parallel) 179s 179s pbpply> cl <- makeCluster(2L) 179s 179s pbpply> clusterExport(cl, c("fun", "mod", "ndat", "bid")) 179s 179s pbpply> ## parallel with no progress bar: snow type cluster 179s pbpply> ## (RNG is set in the main process to define the object bid) 179s pbpply> system.time(res1cl <- parLapply(cl = cl, 1:B, function(i) fun(bid[,i]))) 179s user system elapsed 179s 0.003 0.000 0.141 179s 179s pbpply> system.time(res2cl <- parSapply(cl = cl, 1:B, function(i) fun(bid[,i]))) 179s user system elapsed 179s 0.003 0.000 0.043 179s 179s pbpply> system.time(res3cl <- parApply(cl, bid, 2, fun)) 180s user system elapsed 180s 0.004 0.000 0.084 180s 180s pbpply> ## parallel with progress bar: snow type cluster 180s pbpply> ## (RNG is set in the main process to define the object bid) 180s pbpply> system.time(res1pbcl <- pblapply(1:B, function(i) fun(bid[,i]), cl = cl)) 180s user system elapsed 180s 0.002 0.000 0.084 180s 180s pbpply> system.time(res2pbcl <- pbsapply(1:B, function(i) fun(bid[,i]), cl = cl)) 180s user system elapsed 180s 0.004 0.000 0.068 180s 180s pbpply> ## (RNG needs to be set when not using bid) 180s pbpply> parallel::clusterSetRNGStream(cl, iseed = 0L) 180s 180s pbpply> system.time(res4pbcl <- pbreplicate(B, fun(), cl = cl)) 180s user system elapsed 180s 0.001 0.000 0.051 180s 180s pbpply> system.time(res3pbcl <- pbapply(bid, 2, fun, cl = cl)) 180s user system elapsed 180s 0.003 0.000 0.048 180s 180s pbpply> stopCluster(cl) 180s 180s pbpply> if (.Platform$OS.type != "windows") { 180s pbpply+ ## parallel with no progress bar: multicore type forking 180s pbpply+ ## (mc.set.seed = TRUE in parallel::mclapply by default) 180s pbpply+ system.time(res2mc <- mclapply(1:B, function(i) fun(bid[,i]), mc.cores = 2L)) 180s pbpply+ ## parallel with progress bar: multicore type forking 180s pbpply+ ## (mc.set.seed = TRUE in parallel::mclapply by default) 180s pbpply+ system.time(res1pbmc <- pblapply(1:B, function(i) fun(bid[,i]), cl = 2L)) 180s pbpply+ system.time(res2pbmc <- pbsapply(1:B, function(i) fun(bid[,i]), cl = 2L)) 180s pbpply+ system.time(res4pbmc <- pbreplicate(B, fun(), cl = 2L)) 180s pbpply+ } 180s user system elapsed 180s 0.003 0.004 0.080 180s 180s pbpply> ## --- Examples taken from standard '*apply' functions --- 180s pbpply> 180s pbpply> ## --- sapply, lapply, and replicate --- 180s pbpply> 180s pbpply> require(stats); require(graphics) 180s 180s pbpply> x <- list(a = 1:10, beta = exp(-3:3), logic = c(TRUE,FALSE,FALSE,TRUE)) 180s 180s pbpply> # compute the list mean for each list element 180s pbpply> pblapply(x, mean) 180s $a 180s [1] 5.5 180s 180s $beta 180s [1] 4.535125 180s 180s $logic 180s [1] 0.5 180s 180s 180s pbpply> pbwalk(x, mean) 180s 180s pbpply> # median and quartiles for each list element 180s pbpply> pblapply(x, quantile, probs = 1:3/4) 180s $a 180s 25% 50% 75% 180s 3.25 5.50 7.75 180s 180s $beta 180s 25% 50% 75% 180s 0.2516074 1.0000000 5.0536690 180s 180s $logic 180s 25% 50% 75% 180s 0.0 0.5 1.0 180s 180s 180s pbpply> pbsapply(x, quantile) 180s a beta logic 180s 0% 1.00 0.04978707 0.0 180s 25% 3.25 0.25160736 0.0 180s 50% 5.50 1.00000000 0.5 180s 75% 7.75 5.05366896 1.0 180s 100% 10.00 20.08553692 1.0 180s 180s pbpply> i39 <- sapply(3:9, seq) # list of vectors 180s 180s pbpply> pbsapply(i39, fivenum) 180s [,1] [,2] [,3] [,4] [,5] [,6] [,7] 180s [1,] 1.0 1.0 1 1.0 1.0 1.0 1 180s [2,] 1.5 1.5 2 2.0 2.5 2.5 3 180s [3,] 2.0 2.5 3 3.5 4.0 4.5 5 180s [4,] 2.5 3.5 4 5.0 5.5 6.5 7 180s [5,] 3.0 4.0 5 6.0 7.0 8.0 9 180s 180s pbpply> pbvapply(i39, fivenum, 180s pbpply+ c(Min. = 0, "1st Qu." = 0, Median = 0, "3rd Qu." = 0, Max. = 0)) 180s [,1] [,2] [,3] [,4] [,5] [,6] [,7] 180s Min. 1.0 1.0 1 1.0 1.0 1.0 1 180s 1st Qu. 1.5 1.5 2 2.0 2.5 2.5 3 180s Median 2.0 2.5 3 3.5 4.0 4.5 5 180s 3rd Qu. 2.5 3.5 4 5.0 5.5 6.5 7 180s Max. 3.0 4.0 5 6.0 7.0 8.0 9 180s 180s pbpply> ## sapply(*, "array") -- artificial example 180s pbpply> (v <- structure(10*(5:8), names = LETTERS[1:4])) 180s A B C D 180s 50 60 70 80 180s 180s pbpply> f2 <- function(x, y) outer(rep(x, length.out = 3), y) 180s 180s pbpply> (a2 <- pbsapply(v, f2, y = 2*(1:5), simplify = "array")) 180s , , A 180s 180s [,1] [,2] [,3] [,4] [,5] 180s [1,] 100 200 300 400 500 180s [2,] 100 200 300 400 500 180s [3,] 100 200 300 400 500 180s 180s , , B 180s 180s [,1] [,2] [,3] [,4] [,5] 180s [1,] 120 240 360 480 600 180s [2,] 120 240 360 480 600 180s [3,] 120 240 360 480 600 180s 180s , , C 180s 180s [,1] [,2] [,3] [,4] [,5] 180s [1,] 140 280 420 560 700 180s [2,] 140 280 420 560 700 180s [3,] 140 280 420 560 700 180s 180s , , D 180s 180s [,1] [,2] [,3] [,4] [,5] 180s [1,] 160 320 480 640 800 180s [2,] 160 320 480 640 800 180s [3,] 160 320 480 640 800 180s 180s 180s pbpply> a.2 <- pbvapply(v, f2, outer(1:3, 1:5), y = 2*(1:5)) 180s 180s pbpply> stopifnot(dim(a2) == c(3,5,4), all.equal(a2, a.2), 180s pbpply+ identical(dimnames(a2), list(NULL,NULL,LETTERS[1:4]))) 180s 180s pbpply> summary(pbreplicate(100, mean(rexp(10)))) 180s Min. 1st Qu. Median Mean 3rd Qu. Max. 180s 0.4786 0.7273 0.9091 0.9666 1.1917 2.3021 180s 180s pbpply> ## use of replicate() with parameters: 180s pbpply> foo <- function(x = 1, y = 2) c(x, y) 180s 180s pbpply> # does not work: bar <- function(n, ...) replicate(n, foo(...)) 180s pbpply> bar <- function(n, x) pbreplicate(n, foo(x = x)) 180s 180s pbpply> bar(5, x = 3) 180s [,1] [,2] [,3] [,4] [,5] 180s [1,] 3 3 3 3 3 180s [2,] 2 2 2 2 2 180s 180s pbpply> ## --- apply --- 180s pbpply> 180s pbpply> ## Compute row and column sums for a matrix: 180s pbpply> x <- cbind(x1 = 3, x2 = c(4:1, 2:5)) 180s 180s pbpply> dimnames(x)[[1]] <- letters[1:8] 180s 180s pbpply> pbapply(x, 2, mean, trim = .2) 180s x1 x2 180s 3 3 180s 180s pbpply> col.sums <- pbapply(x, 2, sum) 180s 180s pbpply> row.sums <- pbapply(x, 1, sum) 180s 180s pbpply> rbind(cbind(x, Rtot = row.sums), Ctot = c(col.sums, sum(col.sums))) 180s x1 x2 Rtot 180s a 3 4 7 180s b 3 3 6 180s c 3 2 5 180s d 3 1 4 180s e 3 2 5 180s f 3 3 6 180s g 3 4 7 180s h 3 5 8 180s Ctot 24 24 48 180s 180s pbpply> stopifnot( pbapply(x, 2, is.vector)) 180s 180s pbpply> ## Sort the columns of a matrix 180s pbpply> pbapply(x, 2, sort) 180s x1 x2 180s [1,] 3 1 180s [2,] 3 2 180s [3,] 3 2 180s [4,] 3 3 180s [5,] 3 3 180s [6,] 3 4 180s [7,] 3 4 180s [8,] 3 5 180s 180s pbpply> ## keeping named dimnames 180s pbpply> names(dimnames(x)) <- c("row", "col") 180s 180s pbpply> x3 <- array(x, dim = c(dim(x),3), 180s pbpply+ dimnames = c(dimnames(x), list(C = paste0("cop.",1:3)))) 180s 180s pbpply> identical(x, pbapply( x, 2, identity)) 180s [1] TRUE 180s 180s pbpply> identical(x3, pbapply(x3, 2:3, identity)) 180s [1] TRUE 180s 180s pbpply> ##- function with extra args: 180s pbpply> cave <- function(x, c1, c2) c(mean(x[c1]), mean(x[c2])) 180s 180s pbpply> pbapply(x, 1, cave, c1 = "x1", c2 = c("x1","x2")) 180s row 180s a b c d e f g h 180s [1,] 3.0 3 3.0 3 3.0 3 3.0 3 180s [2,] 3.5 3 2.5 2 2.5 3 3.5 4 180s 180s pbpply> ma <- matrix(c(1:4, 1, 6:8), nrow = 2) 180s 180s pbpply> ma 180s [,1] [,2] [,3] [,4] 180s [1,] 1 3 1 7 180s [2,] 2 4 6 8 180s 180s pbpply> pbapply(ma, 1, table) #--> a list of length 2 180s [[1]] 180s 180s 1 3 7 180s 2 1 1 180s 180s [[2]] 180s 180s 2 4 6 8 180s 1 1 1 1 180s 180s 180s pbpply> pbapply(ma, 1, stats::quantile) # 5 x n matrix with rownames 180s [,1] [,2] 180s 0% 1 2.0 180s 25% 1 3.5 180s 50% 2 5.0 180s 75% 4 6.5 180s 100% 7 8.0 180s 180s pbpply> stopifnot(dim(ma) == dim(pbapply(ma, 1:2, sum))) 180s 180s pbpply> ## Example with different lengths for each call 180s pbpply> z <- array(1:24, dim = 2:4) 180s 180s pbpply> zseq <- pbapply(z, 1:2, function(x) seq_len(max(x))) 180s 180s pbpply> zseq ## a 2 x 3 matrix 180s [,1] [,2] [,3] 180s [1,] integer,19 integer,21 integer,23 180s [2,] integer,20 integer,22 integer,24 180s 180s pbpply> typeof(zseq) ## list 180s [1] "list" 180s 180s pbpply> dim(zseq) ## 2 3 180s [1] 2 3 180s 180s pbpply> zseq[1,] 180s [[1]] 180s [1] 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 180s 180s [[2]] 180s [1] 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 180s 180s [[3]] 180s [1] 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 180s 180s 180s pbpply> pbapply(z, 3, function(x) seq_len(max(x))) 180s [[1]] 180s [1] 1 2 3 4 5 6 180s 180s [[2]] 180s [1] 1 2 3 4 5 6 7 8 9 10 11 12 180s 180s [[3]] 180s [1] 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 180s 180s [[4]] 180s [1] 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 180s 180s 180s pbpply> # a list without a dim attribute 180s pbpply> 180s pbpply> ## --- mapply and .mapply --- 180s pbpply> 180s pbpply> pbmapply(rep, 1:4, 4:1) 180s [[1]] 180s [1] 1 1 1 1 180s 180s [[2]] 180s [1] 2 2 2 180s 180s [[3]] 180s [1] 3 3 180s 180s [[4]] 180s [1] 4 180s 180s 180s pbpply> pbmapply(rep, times = 1:4, x = 4:1) 181s [[1]] 181s [1] 4 181s 181s [[2]] 181s [1] 3 3 181s 181s [[3]] 181s [1] 2 2 2 181s 181s [[4]] 181s [1] 1 1 1 1 181s 181s 181s pbpply> pbmapply(rep, times = 1:4, MoreArgs = list(x = 42)) 181s [[1]] 181s [1] 42 181s 181s [[2]] 181s [1] 42 42 181s 181s [[3]] 181s [1] 42 42 42 181s 181s [[4]] 181s [1] 42 42 42 42 181s 181s 181s pbpply> pbmapply(function(x, y) seq_len(x) + y, 181s pbpply+ c(a = 1, b = 2, c = 3), # names from first 181s pbpply+ c(A = 10, B = 0, C = -10)) 181s $a 181s [1] 11 181s 181s $b 181s [1] 1 2 181s 181s $c 181s [1] -9 -8 -7 181s 181s 181s pbpply> word <- function(C, k) paste(rep.int(C, k), collapse = "") 181s 181s pbpply> utils::str(pbmapply(word, LETTERS[1:6], 6:1, SIMPLIFY = FALSE)) 181s List of 6 181s $ A: chr "AAAAAA" 181s $ B: chr "BBBBB" 181s $ C: chr "CCCC" 181s $ D: chr "DDD" 181s $ E: chr "EE" 181s $ F: chr "F" 181s 181s pbpply> pb.mapply(rep, 181s pbpply+ dots = list(1:4, 4:1), 181s pbpply+ MoreArgs = list()) 181s [[1]] 181s [1] 1 1 1 1 181s 181s [[2]] 181s [1] 2 2 2 181s 181s [[3]] 181s [1] 3 3 181s 181s [[4]] 181s [1] 4 181s 181s 181s pbpply> pb.mapply(rep, 181s pbpply+ dots = list(times = 1:4, x = 4:1), 181s pbpply+ MoreArgs = list()) 181s [[1]] 181s [1] 4 181s 181s [[2]] 181s [1] 3 3 181s 181s [[3]] 181s [1] 2 2 2 181s 181s [[4]] 181s [1] 1 1 1 1 181s 181s 181s pbpply> pb.mapply(rep, 181s pbpply+ dots = list(times = 1:4), 181s pbpply+ MoreArgs = list(x = 42)) 181s [[1]] 181s [1] 42 181s 181s [[2]] 181s [1] 42 42 181s 181s [[3]] 181s [1] 42 42 42 181s 181s [[4]] 181s [1] 42 42 42 42 181s 181s 181s pbpply> pb.mapply(function(x, y) seq_len(x) + y, 181s pbpply+ dots = list(c(a = 1, b = 2, c = 3), # names from first 181s pbpply+ c(A = 10, B = 0, C = -10)), 181s pbpply+ MoreArgs = list()) 181s [[1]] 181s [1] 11 181s 181s [[2]] 181s [1] 1 2 181s 181s [[3]] 181s [1] -9 -8 -7 181s 181s 181s pbpply> ## --- Map --- 181s pbpply> 181s pbpply> pbMap(`+`, 1, 1 : 3) ; 1 + 1:3 181s [[1]] 181s [1] 2 181s 181s [[2]] 181s [1] 3 181s 181s [[3]] 181s [1] 4 181s 181s [1] 2 3 4 181s 181s pbpply> ## --- eapply --- 181s pbpply> 181s pbpply> env <- new.env(hash = FALSE) 181s 181s pbpply> env$a <- 1:10 181s 181s pbpply> env$beta <- exp(-3:3) 181s 181s pbpply> env$logic <- c(TRUE, FALSE, FALSE, TRUE) 181s 181s pbpply> pbeapply(env, mean) 181s $logic 181s [1] 0.5 181s 181s $beta 181s [1] 4.535125 181s 181s $a 181s [1] 5.5 181s 181s 181s pbpply> unlist(pbeapply(env, mean, USE.NAMES = FALSE)) 181s [1] 0.500000 4.535125 5.500000 181s 181s pbpply> pbeapply(env, quantile, probs = 1:3/4) 181s $logic 181s 25% 50% 75% 181s 0.0 0.5 1.0 181s 181s $beta 181s 25% 50% 75% 181s 0.2516074 1.0000000 5.0536690 181s 181s $a 181s 25% 50% 75% 181s 3.25 5.50 7.75 181s 181s 181s pbpply> pbeapply(env, quantile) 181s $logic 181s 0% 25% 50% 75% 100% 181s 0.0 0.0 0.5 1.0 1.0 181s 181s $beta 181s 0% 25% 50% 75% 100% 181s 0.04978707 0.25160736 1.00000000 5.05366896 20.08553692 181s 181s $a 181s 0% 25% 50% 75% 100% 181s 1.00 3.25 5.50 7.75 10.00 181s 181s 181s pbpply> ## --- tapply --- 181s pbpply> 181s pbpply> require(stats) 181s 181s pbpply> groups <- as.factor(rbinom(32, n = 5, prob = 0.4)) 181s 181s pbpply> pbtapply(groups, groups, length) #- is almost the same as 181s 10 11 13 14 18 181s 1 1 1 1 1 181s 181s pbpply> table(groups) 181s groups 181s 10 11 13 14 18 181s 1 1 1 1 1 181s 181s pbpply> ## contingency table from data.frame : array with named dimnames 181s pbpply> pbtapply(warpbreaks$breaks, warpbreaks[,-1], sum) 181s tension 181s wool L M H 181s A 401 216 221 181s B 254 259 169 181s 181s pbpply> pbtapply(warpbreaks$breaks, warpbreaks[, 3, drop = FALSE], sum) 181s tension 181s L M H 181s 655 475 390 181s 181s pbpply> n <- 17; fac <- factor(rep_len(1:3, n), levels = 1:5) 181s 181s pbpply> table(fac) 181s fac 181s 1 2 3 4 5 181s 6 6 5 0 0 181s 181s pbpply> pbtapply(1:n, fac, sum) 181s 1 2 3 4 5 181s 51 57 45 NA NA 181s 181s pbpply> pbtapply(1:n, fac, sum, default = 0) # maybe more desirable 181s 1 2 3 4 5 181s 51 57 45 0 0 181s 181s pbpply> pbtapply(1:n, fac, sum, simplify = FALSE) 181s $`1` 181s [1] 51 181s 181s $`2` 181s [1] 57 181s 181s $`3` 181s [1] 45 181s 181s $`4` 181s NULL 181s 181s $`5` 181s NULL 181s 181s 181s pbpply> pbtapply(1:n, fac, range) 181s $`1` 181s [1] 1 16 181s 181s $`2` 181s [1] 2 17 181s 181s $`3` 181s [1] 3 15 181s 181s $`4` 181s NULL 181s 181s $`5` 181s NULL 181s 181s 181s pbpply> pbtapply(1:n, fac, quantile) 181s $`1` 181s 0% 25% 50% 75% 100% 181s 1.00 4.75 8.50 12.25 16.00 181s 181s $`2` 181s 0% 25% 50% 75% 100% 181s 2.00 5.75 9.50 13.25 17.00 181s 181s $`3` 181s 0% 25% 50% 75% 100% 181s 3 6 9 12 15 181s 181s $`4` 181s NULL 181s 181s $`5` 181s NULL 181s 181s 181s pbpply> pbtapply(1:n, fac, length) ## NA's 181s 1 2 3 4 5 181s 6 6 5 NA NA 181s 181s pbpply> pbtapply(1:n, fac, length, default = 0) # == table(fac) 181s 1 2 3 4 5 181s 6 6 5 0 0 181s 181s pbpply> ## example of ... argument: find quarterly means 181s pbpply> pbtapply(presidents, cycle(presidents), mean, na.rm = TRUE) 181s 1 2 3 4 181s 58.44828 56.43333 57.22222 53.07143 181s 181s pbpply> ind <- list(c(1, 2, 2), c("A", "A", "B")) 181s 181s pbpply> table(ind) 181s ind.2 181s ind.1 A B 181s 1 1 0 181s 2 1 1 181s 181s pbpply> pbtapply(1:3, ind) #-> the split vector 181s [1] 1 2 4 181s 181s pbpply> pbtapply(1:3, ind, sum) 181s A B 181s 1 1 NA 181s 2 2 3 181s 181s pbpply> ## Some assertions (not held by all patch propsals): 181s pbpply> nq <- names(quantile(1:5)) 181s 181s pbpply> stopifnot( 181s pbpply+ identical(pbtapply(1:3, ind), c(1L, 2L, 4L)), 181s pbpply+ identical(pbtapply(1:3, ind, sum), 181s pbpply+ matrix(c(1L, 2L, NA, 3L), 2, dimnames = list(c("1", "2"), c("A", "B")))), 181s pbpply+ identical(pbtapply(1:n, fac, quantile)[-1], 181s pbpply+ array(list(`2` = structure(c(2, 5.75, 9.5, 13.25, 17), .Names = nq), 181s pbpply+ `3` = structure(c(3, 6, 9, 12, 15), .Names = nq), 181s pbpply+ `4` = NULL, `5` = NULL), dim=4, dimnames=list(as.character(2:5))))) 181s 181s pbpply> ## --- by --- 181s pbpply> 181s pbpply> pbby(warpbreaks[, 1:2], warpbreaks[,"tension"], summary) 181s warpbreaks[, "tension"]: L 181s breaks wool 181s Min. :14.00 A:9 181s 1st Qu.:26.00 B:9 181s Median :29.50 181s Mean :36.39 181s 3rd Qu.:49.25 181s Max. :70.00 181s ------------------------------------------------------------ 181s warpbreaks[, "tension"]: M 181s breaks wool 181s Min. :12.00 A:9 181s 1st Qu.:18.25 B:9 181s Median :27.00 181s Mean :26.39 181s 3rd Qu.:33.75 181s Max. :42.00 181s ------------------------------------------------------------ 181s warpbreaks[, "tension"]: H 181s breaks wool 181s Min. :10.00 A:9 181s 1st Qu.:15.25 B:9 181s Median :20.50 181s Mean :21.67 181s 3rd Qu.:25.50 181s Max. :43.00 181s 181s pbpply> pbby(warpbreaks[, 1], warpbreaks[, -1], summary) 181s wool: A 181s tension: L 181s Min. 1st Qu. Median Mean 3rd Qu. Max. 181s 25.00 26.00 51.00 44.56 54.00 70.00 181s ------------------------------------------------------------ 181s wool: B 181s tension: L 181s Min. 1st Qu. Median Mean 3rd Qu. Max. 181s 14.00 20.00 29.00 28.22 31.00 44.00 181s ------------------------------------------------------------ 181s wool: A 181s tension: M 181s Min. 1st Qu. Median Mean 3rd Qu. Max. 181s 12 18 21 24 30 36 181s ------------------------------------------------------------ 181s wool: B 181s tension: M 181s Min. 1st Qu. Median Mean 3rd Qu. Max. 181s 16.00 21.00 28.00 28.78 39.00 42.00 181s ------------------------------------------------------------ 181s wool: A 181s tension: H 181s Min. 1st Qu. Median Mean 3rd Qu. Max. 181s 10.00 18.00 24.00 24.56 28.00 43.00 181s ------------------------------------------------------------ 181s wool: B 181s tension: H 181s Min. 1st Qu. Median Mean 3rd Qu. Max. 181s 13.00 15.00 17.00 18.78 21.00 28.00 181s 181s pbpply> pbby(warpbreaks, warpbreaks[,"tension"], 181s pbpply+ function(x) lm(breaks ~ wool, data = x)) 181s warpbreaks[, "tension"]: L 181s 181s Call: 181s lm(formula = breaks ~ wool, data = x) 181s 181s Coefficients: 181s (Intercept) woolB 181s 44.56 -16.33 181s 181s ------------------------------------------------------------ 181s warpbreaks[, "tension"]: M 181s 181s Call: 181s lm(formula = breaks ~ wool, data = x) 181s 181s Coefficients: 181s (Intercept) woolB 181s 24.000 4.778 181s 181s ------------------------------------------------------------ 181s warpbreaks[, "tension"]: H 181s 181s Call: 181s lm(formula = breaks ~ wool, data = x) 181s 181s Coefficients: 181s (Intercept) woolB 181s 24.556 -5.778 181s 181s 181s pbpply> tmp <- with(warpbreaks, 181s pbpply+ pbby(warpbreaks, tension, 181s pbpply+ function(x) lm(breaks ~ wool, data = x))) 181s 181s pbpply> sapply(tmp, coef) 181s L M H 181s (Intercept) 44.55556 24.000000 24.555556 181s woolB -16.33333 4.777778 -5.777778 181s > example(pboptions, run.dontrun = TRUE) 181s 181s pbptns> ## increase sluggishness to admire the progress bar longer 181s pbptns> sluggishness <- 0.01 181s 181s pbptns> ## for loop 181s pbptns> fun1 <- function() { 181s pbptns+ pb <- startpb(0, 10) 181s pbptns+ on.exit(closepb(pb)) 181s pbptns+ for (i in 1:10) { 181s pbptns+ Sys.sleep(sluggishness) 181s pbptns+ setpb(pb, i) 181s pbptns+ } 181s pbptns+ invisible(NULL) 181s pbptns+ } 181s 181s pbptns> ## while loop 181s pbptns> fun2 <- function() { 181s pbptns+ pb <- startpb(0, 10-1) 181s pbptns+ on.exit(closepb(pb)) 181s pbptns+ i <- 1 181s pbptns+ while (i < 10) { 181s pbptns+ Sys.sleep(sluggishness) 181s pbptns+ setpb(pb, i) 181s pbptns+ i <- i + 1 181s pbptns+ } 181s pbptns+ invisible(NULL) 181s pbptns+ } 181s 181s pbptns> ## using original settings 181s pbptns> fun1() 181s 181s pbptns> ## resetting pboptions 181s pbptns> opb <- pboptions(style = 1, char = ">") 181s 181s pbptns> ## check new settings 181s pbptns> getOption("pboptions") 181s $type 181s [1] "none" 181s 181s $char 181s [1] ">" 181s 181s $txt.width 181s [1] 50 181s 181s $gui.width 181s [1] 300 181s 181s $style 181s [1] 1 181s 181s $initial 181s [1] 0 181s 181s $title 181s [1] "R progress bar" 181s 181s $label 181s [1] "" 181s 181s $nout 181s [1] 100 181s 181s $min_time 181s [1] 0 181s 181s $use_lb 181s [1] FALSE 181s 181s 181s pbptns> ## running again with new settings 181s pbptns> fun2() 181s 181s pbptns> ## resetting original 181s pbptns> pboptions(opb) 181s 181s pbptns> ## check reset 181s pbptns> getOption("pboptions") 181s $type 181s [1] "none" 181s 181s $char 181s [1] "+" 181s 181s $txt.width 181s [1] 50 181s 181s $gui.width 181s [1] 300 181s 181s $style 181s [1] 3 181s 181s $initial 181s [1] 0 181s 181s $title 181s [1] "R progress bar" 181s 181s $label 181s [1] "" 181s 181s $nout 181s [1] 100 181s 181s $min_time 181s [1] 0 181s 181s $use_lb 181s [1] FALSE 181s 181s 181s pbptns> fun1() 181s 181s pbptns> ## dealing with nested progress bars 181s pbptns> ## when only one the 1st one is needed 181s pbptns> f <- function(x) Sys.sleep(sluggishness) 181s 181s pbptns> g <- function(x) pblapply(1:10, f) 181s 181s pbptns> tmp <- lapply(1:10, g) # undesirable 182s 182s pbptns> ## here is the desirable solution 182s pbptns> h <- function(x) { 182s pbptns+ opb <- pboptions(type="none") 182s pbptns+ on.exit(pboptions(opb)) 182s pbptns+ pblapply(1:10, f) 182s pbptns+ } 182s 182s pbptns> tmp <- pblapply(1:10, h) 183s 183s pbptns> ## list available pb types 183s pbptns> pbtypes() 183s [1] "timer" "txt" "tk" "none" "shiny" 183s > 183s > ## run examples with progress bar 183s > pboptions(type = "timer") 183s > example(splitpb, run.dontrun = TRUE) 183s 183s spltpb> ## define 1 job / worker at a time and repeat 183s spltpb> splitpb(10, 4) 183s [[1]] 183s [1] 1 2 3 4 183s 183s [[2]] 183s [1] 5 6 7 8 183s 183s [[3]] 183s [1] 9 10 183s 183s 183s spltpb> ## compare this to the no-progress-bar split 183s spltpb> ## that defines all the jubs / worker up front 183s spltpb> parallel::splitIndices(10, 4) 183s [[1]] 183s [1] 1 2 3 183s 183s [[2]] 183s [1] 4 5 183s 183s [[3]] 183s [1] 6 7 183s 183s [[4]] 183s [1] 8 9 10 183s 183s 183s spltpb> ## cap the length of the output 183s spltpb> splitpb(20, 2, nout = NULL) 183s [[1]] 183s [1] 1 2 183s 183s [[2]] 183s [1] 3 4 183s 183s [[3]] 183s [1] 5 6 183s 183s [[4]] 183s [1] 7 8 183s 183s [[5]] 183s [1] 9 10 183s 183s [[6]] 183s [1] 11 12 183s 183s [[7]] 183s [1] 13 14 183s 183s [[8]] 183s [1] 15 16 183s 183s [[9]] 183s [1] 17 18 183s 183s [[10]] 183s [1] 19 20 183s 183s 183s spltpb> splitpb(20, 2, nout = 5) 183s [[1]] 183s [1] 1 2 3 4 183s 183s [[2]] 183s [1] 5 6 7 8 183s 183s [[3]] 183s [1] 9 10 11 12 183s 183s [[4]] 183s [1] 13 14 15 16 183s 183s [[5]] 183s [1] 17 18 19 20 183s 183s > example(timerProgressBar, run.dontrun = TRUE) 183s 183s tmrPrB> ## increase sluggishness to admire the progress bar longer 183s tmrPrB> sluggishness <- 0.02 183s 183s tmrPrB> test_fun <- function(...) 183s tmrPrB+ { 183s tmrPrB+ pb <- timerProgressBar(...) 183s tmrPrB+ on.exit(close(pb)) 183s tmrPrB+ for (i in seq(0, 1, 0.05)) { 183s tmrPrB+ Sys.sleep(sluggishness) 183s tmrPrB+ setTimerProgressBar(pb, i) 183s tmrPrB+ } 183s tmrPrB+ invisible(NULL) 183s tmrPrB+ } 183s 183s tmrPrB> ## check the different styles 183s tmrPrB> test_fun(width = 35, char = "+", style = 1) 183s | | 0 % elapsed=00s | | 0 % elapsed=00s |++ | 5 % elapsed=00s, remaining~01s |++++ | 10% elapsed=00s, remaining~01s |++++++ | 15% elapsed=00s, remaining~00s |+++++++ | 20% elapsed=00s, remaining~00s |+++++++++ | 25% elapsed=00s, remaining~00s |+++++++++++ | 30% elapsed=00s, remaining~00s |+++++++++++++ | 35% elapsed=00s, remaining~00s |++++++++++++++ | 40% elapsed=00s, remaining~00s |++++++++++++++++ | 45% elapsed=00s, remaining~00s |++++++++++++++++++ | 50% elapsed=00s, remaining~00s |++++++++++++++++++++ | 55% elapsed=00s, remaining~00s |++++++++++++++++++++++ | 60% elapsed=00s, remaining~00s |+++++++++++++++++++++++ | 65% elapsed=00s, remaining~00s |+++++++++++++++++++++++++ | 70% elapsed=00s, remaining~00s |+++++++++++++++++++++++++++ | 75% elapsed=00s, remaining~00s |++++++++++++++++++++++++++++ | 80% elapsed=00s, remaining~00s |++++++++++++++++++++++++++++++ | 85% elapsed=00s, remaining~00s |++++++++++++++++++++++++++++++++ | 90% elapsed=00s, remaining~00s |++++++++++++++++++++++++++++++++++ | 95% elapsed=00s, remaining~00s |+++++++++++++++++++++++++++++++++++| 100% elapsed=00s, remaining~00s 183s 183s tmrPrB> test_fun(style = 2) 184s / 0 % elapsed=00s / 0 % elapsed=00s - 5 % elapsed=00s, remaining~01s \ 10% elapsed=00s, remaining~01s | 15% elapsed=00s, remaining~00s / 20% elapsed=00s, remaining~00s - 25% elapsed=00s, remaining~00s \ 30% elapsed=00s, remaining~00s | 35% elapsed=00s, remaining~00s / 40% elapsed=00s, remaining~00s - 45% elapsed=00s, remaining~00s \ 50% elapsed=00s, remaining~00s | 55% elapsed=00s, remaining~00s / 60% elapsed=00s, remaining~00s - 65% elapsed=00s, remaining~00s \ 70% elapsed=00s, remaining~00s | 75% elapsed=00s, remaining~00s / 80% elapsed=00s, remaining~00s - 85% elapsed=00s, remaining~00s \ 90% elapsed=00s, remaining~00s | 95% elapsed=00s, remaining~00s / 100% elapsed=00s, remaining~00s 184s 184s tmrPrB> test_fun(width = 50, char = ".", style = 3) 184s | | 0 % ~calculating | | 0 % ~calculating |... | 5 % ~01s |..... | 10% ~01s |........ | 15% ~00s |.......... | 20% ~00s |............. | 25% ~00s |................ | 30% ~00s |.................. | 35% ~00s |.................... | 40% ~00s |....................... | 45% ~00s |......................... | 50% ~00s |............................ | 55% ~00s |............................... | 60% ~00s |................................. | 65% ~00s |................................... | 70% ~00s |...................................... | 75% ~00s |........................................ | 80% ~00s |........................................... | 85% ~00s |............................................. | 90% ~00s |................................................ | 95% ~00s |..................................................| 100% elapsed=00s 184s 184s tmrPrB> test_fun(style = 4) 185s / 0 % ~calculating / 0 % ~calculating - 5 % ~01s \ 10% ~01s | 15% ~00s / 20% ~00s - 25% ~00s \ 30% ~00s | 35% ~00s / 40% ~00s - 45% ~00s \ 50% ~00s | 55% ~00s / 60% ~00s - 65% ~00s \ 70% ~00s | 75% ~00s / 80% ~00s - 85% ~00s \ 90% ~00s | 95% ~00s / 100% elapsed=00s 185s 185s tmrPrB> test_fun(width = 35, char = "[=-]", style = 5) 185s [-----------------------------------] 0 % elapsed=00s [-----------------------------------] 0 % elapsed=00s [==---------------------------------] 5 % elapsed=00s, remaining~01s [====-------------------------------] 10% elapsed=00s, remaining~01s [======-----------------------------] 15% elapsed=00s, remaining~00s [=======----------------------------] 20% elapsed=00s, remaining~00s [=========--------------------------] 25% elapsed=00s, remaining~00s [===========------------------------] 30% elapsed=00s, remaining~00s [=============----------------------] 35% elapsed=00s, remaining~00s [==============---------------------] 40% elapsed=00s, remaining~00s [================-------------------] 45% elapsed=00s, remaining~00s [==================-----------------] 50% elapsed=00s, remaining~00s [====================---------------] 55% elapsed=00s, remaining~00s [======================-------------] 60% elapsed=00s, remaining~00s [=======================------------] 65% elapsed=00s, remaining~00s [=========================----------] 70% elapsed=00s, remaining~00s [===========================--------] 75% elapsed=00s, remaining~00s [============================-------] 80% elapsed=00s, remaining~00s [==============================-----] 85% elapsed=00s, remaining~00s [================================---] 90% elapsed=00s, remaining~00s [==================================-] 95% elapsed=00s, remaining~00s [===================================] 100% elapsed=00s, remaining~00s 185s 185s tmrPrB> test_fun(width = 50, char = "{*.}", style = 6) 185s {..................................................} 0 % ~calculating {..................................................} 0 % ~calculating {***...............................................} 5 % ~01s {*****.............................................} 10% ~01s {********..........................................} 15% ~00s {**********........................................} 20% ~00s {*************.....................................} 25% ~00s {****************..................................} 30% ~00s {******************................................} 35% ~00s {********************..............................} 40% ~00s {***********************...........................} 45% ~00s {*************************.........................} 50% ~00s {****************************......................} 55% ~00s {*******************************...................} 60% ~00s {*********************************.................} 65% ~00s {***********************************...............} 70% ~00s {**************************************............} 75% ~00s {****************************************..........} 80% ~00s {*******************************************.......} 85% ~00s {*********************************************.....} 90% ~00s {************************************************..} 95% ~00s {**************************************************} 100% elapsed=00s 185s 185s tmrPrB> ## no bar only percent and elapsed 185s tmrPrB> test_fun(width = 0, char = " ", style = 6) 186s 0 % ~calculating 0 % ~calculating 5 % ~01s 10% ~01s 15% ~00s 20% ~00s 25% ~00s 30% ~00s 35% ~00s 40% ~00s 45% ~00s 50% ~00s 55% ~00s 60% ~00s 65% ~00s 70% ~00s 75% ~00s 80% ~00s 85% ~00s 90% ~00s 95% ~00s 100% elapsed=00s 186s 186s tmrPrB> ## this should produce a progress bar based on min_time 186s tmrPrB> (elapsed <- system.time(test_fun(width = 35, min_time = 0))["elapsed"]) 186s | | 0 % elapsed=00s | | 0 % elapsed=00s |== | 5 % elapsed=00s, remaining~01s |==== | 10% elapsed=00s, remaining~01s |====== | 15% elapsed=00s, remaining~00s |======= | 20% elapsed=00s, remaining~00s |========= | 25% elapsed=00s, remaining~00s |=========== | 30% elapsed=00s, remaining~00s |============= | 35% elapsed=00s, remaining~00s |============== | 40% elapsed=00s, remaining~00s |================ | 45% elapsed=00s, remaining~00s |================== | 50% elapsed=00s, remaining~00s |==================== | 55% elapsed=00s, remaining~00s |====================== | 60% elapsed=00s, remaining~00s |======================= | 65% elapsed=00s, remaining~00s |========================= | 70% elapsed=00s, remaining~00s |=========================== | 75% elapsed=00s, remaining~00s |============================ | 80% elapsed=00s, remaining~00s |============================== | 85% elapsed=00s, remaining~00s |================================ | 90% elapsed=00s, remaining~00s |================================== | 95% elapsed=00s, remaining~00s |===================================| 100% elapsed=00s, remaining~00s 186s elapsed 186s 0.433 186s 186s tmrPrB> ## this should not produce a progress bar based on min_time 186s tmrPrB> system.time(test_fun(min_time = 2 * elapsed))["elapsed"] 187s elapsed 187s 0.429 187s 187s tmrPrB> ## time formatting 187s tmrPrB> getTimeAsString(NULL) 187s [1] "calculating" 187s 187s tmrPrB> getTimeAsString(15) 187s [1] "15s" 187s 187s tmrPrB> getTimeAsString(65) 187s [1] "01m 05s" 187s 187s tmrPrB> getTimeAsString(6005) 187s [1] "01h 40m 05s" 187s 187s tmrPrB> ## example usage of getTimeAsString, use sluggishness <- 1 187s tmrPrB> n <- 10 187s 187s tmrPrB> t0 <- proc.time()[3] 187s 187s tmrPrB> ETA <- NULL 187s 187s tmrPrB> for (i in seq_len(n)) { 187s tmrPrB+ cat(i, "/", n, "- ETA:", getTimeAsString(ETA)) 187s tmrPrB+ flush.console() 187s tmrPrB+ Sys.sleep(sluggishness) 187s tmrPrB+ dt <- proc.time()[3] - t0 187s tmrPrB+ cat(" - elapsed:", getTimeAsString(dt), "\n") 187s tmrPrB+ ETA <- (n - i) * dt / i 187s tmrPrB+ } 187s 1 / 10 - ETA: calculating - elapsed: 00s 187s 2 / 10 - ETA: 00s - elapsed: 00s 187s 3 / 10 - ETA: 00s - elapsed: 00s 187s 4 / 10 - ETA: 00s - elapsed: 00s 187s 5 / 10 - ETA: 00s - elapsed: 00s 187s 6 / 10 - ETA: 00s - elapsed: 00s 187s 7 / 10 - ETA: 00s - elapsed: 00s 187s 8 / 10 - ETA: 00s - elapsed: 00s 187s 9 / 10 - ETA: 00s - elapsed: 00s 187s 10 / 10 - ETA: 00s - elapsed: 00s 187s > example(pbapply, run.dontrun = TRUE) 187s 187s pbpply> ## --- simple linear model simulation --- 187s pbpply> set.seed(1234) 187s 187s pbpply> n <- 200 187s 187s pbpply> x <- rnorm(n) 187s 187s pbpply> y <- rnorm(n, crossprod(t(model.matrix(~ x)), c(0, 1)), sd = 0.5) 187s 187s pbpply> d <- data.frame(y, x) 187s 187s pbpply> ## model fitting and bootstrap 187s pbpply> mod <- lm(y ~ x, d) 187s 187s pbpply> ndat <- model.frame(mod) 187s 187s pbpply> B <- 100 187s 187s pbpply> bid <- sapply(1:B, function(i) sample(nrow(ndat), nrow(ndat), TRUE)) 187s 187s pbpply> fun <- function(z) { 187s pbpply+ if (missing(z)) 187s pbpply+ z <- sample(nrow(ndat), nrow(ndat), TRUE) 187s pbpply+ coef(lm(mod$call$formula, data=ndat[z,])) 187s pbpply+ } 187s 187s pbpply> ## standard '*apply' functions 187s pbpply> system.time(res1 <- lapply(1:B, function(i) fun(bid[,i]))) 187s user system elapsed 187s 0.077 0.000 0.078 187s 187s pbpply> system.time(res2 <- sapply(1:B, function(i) fun(bid[,i]))) 187s user system elapsed 187s 0.065 0.000 0.066 187s 187s pbpply> system.time(res3 <- apply(bid, 2, fun)) 187s user system elapsed 187s 0.063 0.000 0.064 187s 187s pbpply> system.time(res4 <- replicate(B, fun())) 188s user system elapsed 188s 0.067 0.000 0.068 188s 188s pbpply> ## 'pb*apply' functions 188s pbpply> ## try different settings: 188s pbpply> ## "none", "txt", "tk", "win", "timer" 188s pbpply> op <- pboptions(type = "timer") # default 188s 188s pbpply> system.time(res1pb <- pblapply(1:B, function(i) fun(bid[,i]))) 188s | | 0 % ~calculating |+ | 1 % ~00s |+ | 2 % ~00s |++ | 3 % ~00s |++ | 4 % ~00s |+++ | 5 % ~00s |+++ | 6 % ~00s |++++ | 7 % ~00s |++++ | 8 % ~00s |+++++ | 9 % ~00s |+++++ | 10% ~00s |++++++ | 11% ~00s |++++++ | 12% ~00s |+++++++ | 13% ~00s |+++++++ | 14% ~00s |++++++++ | 15% ~00s |++++++++ | 16% ~00s |+++++++++ | 17% ~00s |+++++++++ | 18% ~00s |++++++++++ | 19% ~00s |++++++++++ | 20% ~00s |+++++++++++ | 21% ~00s |+++++++++++ | 22% ~00s |++++++++++++ | 23% ~00s |++++++++++++ | 24% ~00s |+++++++++++++ | 25% ~00s |+++++++++++++ | 26% ~00s |++++++++++++++ | 27% ~00s |++++++++++++++ | 28% ~00s |+++++++++++++++ | 29% ~00s |+++++++++++++++ | 30% ~00s |++++++++++++++++ | 31% ~00s |++++++++++++++++ | 32% ~00s |+++++++++++++++++ | 33% ~00s |+++++++++++++++++ | 34% ~00s |++++++++++++++++++ | 35% ~00s |++++++++++++++++++ | 36% ~00s |+++++++++++++++++++ | 37% ~00s |+++++++++++++++++++ | 38% ~00s |++++++++++++++++++++ | 39% ~00s |++++++++++++++++++++ | 40% ~00s |+++++++++++++++++++++ | 41% ~00s |+++++++++++++++++++++ | 42% ~00s |++++++++++++++++++++++ | 43% ~00s |++++++++++++++++++++++ | 44% ~00s |+++++++++++++++++++++++ | 45% ~00s |+++++++++++++++++++++++ | 46% ~00s |++++++++++++++++++++++++ | 47% ~00s |++++++++++++++++++++++++ | 48% ~00s |+++++++++++++++++++++++++ | 49% ~00s |+++++++++++++++++++++++++ | 50% ~00s |++++++++++++++++++++++++++ | 51% ~00s |++++++++++++++++++++++++++ | 52% ~00s |+++++++++++++++++++++++++++ | 53% ~00s |+++++++++++++++++++++++++++ | 54% ~00s |++++++++++++++++++++++++++++ | 55% ~00s |++++++++++++++++++++++++++++ | 56% ~00s |+++++++++++++++++++++++++++++ | 57% ~00s |+++++++++++++++++++++++++++++ | 58% ~00s |++++++++++++++++++++++++++++++ | 59% ~00s |++++++++++++++++++++++++++++++ | 60% ~00s |+++++++++++++++++++++++++++++++ | 61% ~00s |+++++++++++++++++++++++++++++++ | 62% ~00s |++++++++++++++++++++++++++++++++ | 63% ~00s |++++++++++++++++++++++++++++++++ | 64% ~00s |+++++++++++++++++++++++++++++++++ | 65% ~00s |+++++++++++++++++++++++++++++++++ | 66% ~00s |++++++++++++++++++++++++++++++++++ | 67% ~00s |++++++++++++++++++++++++++++++++++ | 68% ~00s |+++++++++++++++++++++++++++++++++++ | 69% ~00s |+++++++++++++++++++++++++++++++++++ | 70% ~00s |++++++++++++++++++++++++++++++++++++ | 71% ~00s |++++++++++++++++++++++++++++++++++++ | 72% ~00s |+++++++++++++++++++++++++++++++++++++ | 73% ~00s |+++++++++++++++++++++++++++++++++++++ | 74% ~00s |++++++++++++++++++++++++++++++++++++++ | 75% ~00s |++++++++++++++++++++++++++++++++++++++ | 76% ~00s |+++++++++++++++++++++++++++++++++++++++ | 77% ~00s |+++++++++++++++++++++++++++++++++++++++ | 78% ~00s |++++++++++++++++++++++++++++++++++++++++ | 79% ~00s |++++++++++++++++++++++++++++++++++++++++ | 80% ~00s |+++++++++++++++++++++++++++++++++++++++++ | 81% ~00s |+++++++++++++++++++++++++++++++++++++++++ | 82% ~00s |++++++++++++++++++++++++++++++++++++++++++ | 83% ~00s |++++++++++++++++++++++++++++++++++++++++++ | 84% ~00s |+++++++++++++++++++++++++++++++++++++++++++ | 85% ~00s |+++++++++++++++++++++++++++++++++++++++++++ | 86% ~00s |++++++++++++++++++++++++++++++++++++++++++++ | 87% ~00s |++++++++++++++++++++++++++++++++++++++++++++ | 88% ~00s |+++++++++++++++++++++++++++++++++++++++++++++ | 89% ~00s |+++++++++++++++++++++++++++++++++++++++++++++ | 90% ~00s |++++++++++++++++++++++++++++++++++++++++++++++ | 91% ~00s |++++++++++++++++++++++++++++++++++++++++++++++ | 92% ~00s |+++++++++++++++++++++++++++++++++++++++++++++++ | 93% ~00s |+++++++++++++++++++++++++++++++++++++++++++++++ | 94% ~00s |++++++++++++++++++++++++++++++++++++++++++++++++ | 95% ~00s |++++++++++++++++++++++++++++++++++++++++++++++++ | 96% ~00s |+++++++++++++++++++++++++++++++++++++++++++++++++ | 97% ~00s |+++++++++++++++++++++++++++++++++++++++++++++++++ | 98% ~00s |++++++++++++++++++++++++++++++++++++++++++++++++++| 99% ~00s |++++++++++++++++++++++++++++++++++++++++++++++++++| 100% elapsed=00s 188s user system elapsed 188s 0.081 0.004 0.091 188s 188s pbpply> pboptions(op) 188s 188s pbpply> pboptions(type = "txt") 188s 188s pbpply> system.time(res2pb <- pbsapply(1:B, function(i) fun(bid[,i]))) 188s | | | 0% | | | 1% | |+ | 2% | |++ | 3% | |++ | 4% | |++ | 5% | |+++ | 6% | |++++ | 7% | |++++ | 8% | |++++ | 9% | |+++++ | 10% | |++++++ | 11% | |++++++ | 12% | |++++++ | 13% | |+++++++ | 14% | |++++++++ | 15% | |++++++++ | 16% | |++++++++ | 17% | |+++++++++ | 18% | |++++++++++ | 19% | |++++++++++ | 20% | |++++++++++ | 21% | |+++++++++++ | 22% | |++++++++++++ | 23% | |++++++++++++ | 24% | |++++++++++++ | 25% | |+++++++++++++ | 26% | |++++++++++++++ | 27% | |++++++++++++++ | 28% | |++++++++++++++ | 29% | |+++++++++++++++ | 30% | |++++++++++++++++ | 31% | |++++++++++++++++ | 32% | |++++++++++++++++ | 33% | |+++++++++++++++++ | 34% | |++++++++++++++++++ | 35% | |++++++++++++++++++ | 36% | |++++++++++++++++++ | 37% | |+++++++++++++++++++ | 38% | |++++++++++++++++++++ | 39% | |++++++++++++++++++++ | 40% | |++++++++++++++++++++ | 41% | |+++++++++++++++++++++ | 42% | |++++++++++++++++++++++ | 43% | |++++++++++++++++++++++ | 44% | |++++++++++++++++++++++ | 45% | |+++++++++++++++++++++++ | 46% | |++++++++++++++++++++++++ | 47% | |++++++++++++++++++++++++ | 48% | |++++++++++++++++++++++++ | 49% | |+++++++++++++++++++++++++ | 50% | |++++++++++++++++++++++++++ | 51% | |++++++++++++++++++++++++++ | 52% | |++++++++++++++++++++++++++ | 53% | |+++++++++++++++++++++++++++ | 54% | |++++++++++++++++++++++++++++ | 55% | |++++++++++++++++++++++++++++ | 56% | |++++++++++++++++++++++++++++ | 57% | |+++++++++++++++++++++++++++++ | 58% | |++++++++++++++++++++++++++++++ | 59% | |++++++++++++++++++++++++++++++ | 60% | |++++++++++++++++++++++++++++++ | 61% | |+++++++++++++++++++++++++++++++ | 62% | |++++++++++++++++++++++++++++++++ | 63% | |++++++++++++++++++++++++++++++++ | 64% | |++++++++++++++++++++++++++++++++ | 65% | |+++++++++++++++++++++++++++++++++ | 66% | |++++++++++++++++++++++++++++++++++ | 67% | |++++++++++++++++++++++++++++++++++ | 68% | |++++++++++++++++++++++++++++++++++ | 69% | |+++++++++++++++++++++++++++++++++++ | 70% | |++++++++++++++++++++++++++++++++++++ | 71% | |++++++++++++++++++++++++++++++++++++ | 72% | |++++++++++++++++++++++++++++++++++++ | 73% | |+++++++++++++++++++++++++++++++++++++ | 74% | |++++++++++++++++++++++++++++++++++++++ | 75% | |++++++++++++++++++++++++++++++++++++++ | 76% | |++++++++++++++++++++++++++++++++++++++ | 77% | |+++++++++++++++++++++++++++++++++++++++ | 78% | |++++++++++++++++++++++++++++++++++++++++ | 79% | |++++++++++++++++++++++++++++++++++++++++ | 80% | |++++++++++++++++++++++++++++++++++++++++ | 81% | |+++++++++++++++++++++++++++++++++++++++++ | 82% | |++++++++++++++++++++++++++++++++++++++++++ | 83% | |++++++++++++++++++++++++++++++++++++++++++ | 84% | |++++++++++++++++++++++++++++++++++++++++++ | 85% | |+++++++++++++++++++++++++++++++++++++++++++ | 86% | |++++++++++++++++++++++++++++++++++++++++++++ | 87% | |++++++++++++++++++++++++++++++++++++++++++++ | 88% | |++++++++++++++++++++++++++++++++++++++++++++ | 89% | |+++++++++++++++++++++++++++++++++++++++++++++ | 90% | |++++++++++++++++++++++++++++++++++++++++++++++ | 91% | |++++++++++++++++++++++++++++++++++++++++++++++ | 92% | |++++++++++++++++++++++++++++++++++++++++++++++ | 93% | |+++++++++++++++++++++++++++++++++++++++++++++++ | 94% | |++++++++++++++++++++++++++++++++++++++++++++++++ | 95% | |++++++++++++++++++++++++++++++++++++++++++++++++ | 96% | |++++++++++++++++++++++++++++++++++++++++++++++++ | 97% | |+++++++++++++++++++++++++++++++++++++++++++++++++ | 98% | |++++++++++++++++++++++++++++++++++++++++++++++++++| 99% | |++++++++++++++++++++++++++++++++++++++++++++++++++| 100% 188s user system elapsed 188s 0.085 0.000 0.089 188s 188s pbpply> pboptions(op) 188s 188s pbpply> pboptions(type = "txt", style = 1, char = "=") 188s 188s pbpply> system.time(res3pb <- pbapply(bid, 2, fun)) 188s ================================================== 188s user system elapsed 188s 0.083 0.000 0.084 188s 188s pbpply> pboptions(op) 188s 188s pbpply> pboptions(type = "txt", char = ":") 188s 188s pbpply> system.time(res4pb <- pbreplicate(B, fun())) 188s | | | 0% | | | 1% | |: | 2% | |:: | 3% | |:: | 4% | |:: | 5% | |::: | 6% | |:::: | 7% | |:::: | 8% | |:::: | 9% | |::::: | 10% | |:::::: | 11% | |:::::: | 12% | |:::::: | 13% | |::::::: | 14% | |:::::::: | 15% | |:::::::: | 16% | |:::::::: | 17% | |::::::::: | 18% | |:::::::::: | 19% | |:::::::::: | 20% | |:::::::::: | 21% | |::::::::::: | 22% | |:::::::::::: | 23% | |:::::::::::: | 24% | |:::::::::::: | 25% | |::::::::::::: | 26% | |:::::::::::::: | 27% | |:::::::::::::: | 28% | |:::::::::::::: | 29% | |::::::::::::::: | 30% | |:::::::::::::::: | 31% | |:::::::::::::::: | 32% | |:::::::::::::::: | 33% | |::::::::::::::::: | 34% | |:::::::::::::::::: | 35% | |:::::::::::::::::: | 36% | |:::::::::::::::::: | 37% | |::::::::::::::::::: | 38% | |:::::::::::::::::::: | 39% | |:::::::::::::::::::: | 40% | |:::::::::::::::::::: | 41% | |::::::::::::::::::::: | 42% | |:::::::::::::::::::::: | 43% | |:::::::::::::::::::::: | 44% | |:::::::::::::::::::::: | 45% | |::::::::::::::::::::::: | 46% | |:::::::::::::::::::::::: | 47% | |:::::::::::::::::::::::: | 48% | |:::::::::::::::::::::::: | 49% | |::::::::::::::::::::::::: | 50% | |:::::::::::::::::::::::::: | 51% | |:::::::::::::::::::::::::: | 52% | |:::::::::::::::::::::::::: | 53% | |::::::::::::::::::::::::::: | 54% | |:::::::::::::::::::::::::::: | 55% | |:::::::::::::::::::::::::::: | 56% | |:::::::::::::::::::::::::::: | 57% | |::::::::::::::::::::::::::::: | 58% | |:::::::::::::::::::::::::::::: | 59% | |:::::::::::::::::::::::::::::: | 60% | |:::::::::::::::::::::::::::::: | 61% | |::::::::::::::::::::::::::::::: | 62% | |:::::::::::::::::::::::::::::::: | 63% | |:::::::::::::::::::::::::::::::: | 64% | |:::::::::::::::::::::::::::::::: | 65% | |::::::::::::::::::::::::::::::::: | 66% | |:::::::::::::::::::::::::::::::::: | 67% | |:::::::::::::::::::::::::::::::::: | 68% | |:::::::::::::::::::::::::::::::::: | 69% | |::::::::::::::::::::::::::::::::::: | 70% | |:::::::::::::::::::::::::::::::::::: | 71% | |:::::::::::::::::::::::::::::::::::: | 72% | |:::::::::::::::::::::::::::::::::::: | 73% | |::::::::::::::::::::::::::::::::::::: | 74% | |:::::::::::::::::::::::::::::::::::::: | 75% | |:::::::::::::::::::::::::::::::::::::: | 76% | |:::::::::::::::::::::::::::::::::::::: | 77% | |::::::::::::::::::::::::::::::::::::::: | 78% | |:::::::::::::::::::::::::::::::::::::::: | 79% | |:::::::::::::::::::::::::::::::::::::::: | 80% | |:::::::::::::::::::::::::::::::::::::::: | 81% | |::::::::::::::::::::::::::::::::::::::::: | 82% | |:::::::::::::::::::::::::::::::::::::::::: | 83% | |:::::::::::::::::::::::::::::::::::::::::: | 84% | |:::::::::::::::::::::::::::::::::::::::::: | 85% | |::::::::::::::::::::::::::::::::::::::::::: | 86% | |:::::::::::::::::::::::::::::::::::::::::::: | 87% | |:::::::::::::::::::::::::::::::::::::::::::: | 88% | |:::::::::::::::::::::::::::::::::::::::::::: | 89% | |::::::::::::::::::::::::::::::::::::::::::::: | 90% | |:::::::::::::::::::::::::::::::::::::::::::::: | 91% | |:::::::::::::::::::::::::::::::::::::::::::::: | 92% | |:::::::::::::::::::::::::::::::::::::::::::::: | 93% | |::::::::::::::::::::::::::::::::::::::::::::::: | 94% | |:::::::::::::::::::::::::::::::::::::::::::::::: | 95% | |:::::::::::::::::::::::::::::::::::::::::::::::: | 96% | |:::::::::::::::::::::::::::::::::::::::::::::::: | 97% | |::::::::::::::::::::::::::::::::::::::::::::::::: | 98% | |::::::::::::::::::::::::::::::::::::::::::::::::::| 99% | |::::::::::::::::::::::::::::::::::::::::::::::::::| 100% 188s user system elapsed 188s 0.083 0.000 0.089 188s 188s pbpply> pboptions(op) 188s 188s pbpply> ## parallel evaluation using the parallel package 188s pbpply> ## (n = 2000 and B = 1000 will give visible timing differences) 188s pbpply> 188s pbpply> library(parallel) 188s 188s pbpply> cl <- makeCluster(2L) 188s 188s pbpply> clusterExport(cl, c("fun", "mod", "ndat", "bid")) 188s 188s pbpply> ## parallel with no progress bar: snow type cluster 188s pbpply> ## (RNG is set in the main process to define the object bid) 188s pbpply> system.time(res1cl <- parLapply(cl = cl, 1:B, function(i) fun(bid[,i]))) 189s user system elapsed 189s 0.003 0.000 0.133 189s 189s pbpply> system.time(res2cl <- parSapply(cl = cl, 1:B, function(i) fun(bid[,i]))) 189s user system elapsed 189s 0.004 0.000 0.054 189s 189s pbpply> system.time(res3cl <- parApply(cl, bid, 2, fun)) 189s user system elapsed 189s 0.004 0.000 0.044 189s 189s pbpply> ## parallel with progress bar: snow type cluster 189s pbpply> ## (RNG is set in the main process to define the object bid) 189s pbpply> system.time(res1pbcl <- pblapply(1:B, function(i) fun(bid[,i]), cl = cl)) 191s | | 0 % ~calculating |+ | 2 % ~02s |++ | 4 % ~02s |+++ | 6 % ~02s |++++ | 8 % ~01s |+++++ | 10% ~01s |++++++ | 12% ~01s |+++++++ | 14% ~02s |++++++++ | 16% ~02s |+++++++++ | 18% ~02s |++++++++++ | 20% ~02s |+++++++++++ | 22% ~02s |++++++++++++ | 24% ~02s |+++++++++++++ | 26% ~02s |++++++++++++++ | 28% ~02s |+++++++++++++++ | 30% ~01s |++++++++++++++++ | 32% ~01s |+++++++++++++++++ | 34% ~01s |++++++++++++++++++ | 36% ~01s |+++++++++++++++++++ | 38% ~01s |++++++++++++++++++++ | 40% ~01s |+++++++++++++++++++++ | 42% ~01s |++++++++++++++++++++++ | 44% ~01s |+++++++++++++++++++++++ | 46% ~01s |++++++++++++++++++++++++ | 48% ~01s |+++++++++++++++++++++++++ | 50% ~01s |++++++++++++++++++++++++++ | 52% ~01s |+++++++++++++++++++++++++++ | 54% ~01s |++++++++++++++++++++++++++++ | 56% ~01s |+++++++++++++++++++++++++++++ | 58% ~01s |++++++++++++++++++++++++++++++ | 60% ~01s |+++++++++++++++++++++++++++++++ | 62% ~01s |++++++++++++++++++++++++++++++++ | 64% ~01s |+++++++++++++++++++++++++++++++++ | 66% ~01s |++++++++++++++++++++++++++++++++++ | 68% ~01s |+++++++++++++++++++++++++++++++++++ | 70% ~01s |++++++++++++++++++++++++++++++++++++ | 72% ~01s |+++++++++++++++++++++++++++++++++++++ | 74% ~01s |++++++++++++++++++++++++++++++++++++++ | 76% ~01s |+++++++++++++++++++++++++++++++++++++++ | 78% ~00s |++++++++++++++++++++++++++++++++++++++++ | 80% ~00s |+++++++++++++++++++++++++++++++++++++++++ | 82% ~00s |++++++++++++++++++++++++++++++++++++++++++ | 84% ~00s |+++++++++++++++++++++++++++++++++++++++++++ | 86% ~00s |++++++++++++++++++++++++++++++++++++++++++++ | 88% ~00s |+++++++++++++++++++++++++++++++++++++++++++++ | 90% ~00s |++++++++++++++++++++++++++++++++++++++++++++++ | 92% ~00s |+++++++++++++++++++++++++++++++++++++++++++++++ | 94% ~00s |++++++++++++++++++++++++++++++++++++++++++++++++ | 96% ~00s |+++++++++++++++++++++++++++++++++++++++++++++++++ | 98% ~00s |++++++++++++++++++++++++++++++++++++++++++++++++++| 100% elapsed=02s 191s user system elapsed 191s 0.122 0.024 2.248 191s 191s pbpply> system.time(res2pbcl <- pbsapply(1:B, function(i) fun(bid[,i]), cl = cl)) 193s | | 0 % ~calculating |+ | 2 % ~02s |++ | 4 % ~02s |+++ | 6 % ~02s |++++ | 8 % ~02s |+++++ | 10% ~02s |++++++ | 12% ~02s |+++++++ | 14% ~02s |++++++++ | 16% ~02s |+++++++++ | 18% ~02s |++++++++++ | 20% ~02s |+++++++++++ | 22% ~02s |++++++++++++ | 24% ~02s |+++++++++++++ | 26% ~02s |++++++++++++++ | 28% ~02s |+++++++++++++++ | 30% ~02s |++++++++++++++++ | 32% ~02s |+++++++++++++++++ | 34% ~02s |++++++++++++++++++ | 36% ~01s |+++++++++++++++++++ | 38% ~01s |++++++++++++++++++++ | 40% ~01s |+++++++++++++++++++++ | 42% ~01s |++++++++++++++++++++++ | 44% ~01s |+++++++++++++++++++++++ | 46% ~01s |++++++++++++++++++++++++ | 48% ~01s |+++++++++++++++++++++++++ | 50% ~01s |++++++++++++++++++++++++++ | 52% ~01s |+++++++++++++++++++++++++++ | 54% ~01s |++++++++++++++++++++++++++++ | 56% ~01s |+++++++++++++++++++++++++++++ | 58% ~01s |++++++++++++++++++++++++++++++ | 60% ~01s |+++++++++++++++++++++++++++++++ | 62% ~01s |++++++++++++++++++++++++++++++++ | 64% ~01s |+++++++++++++++++++++++++++++++++ | 66% ~01s |++++++++++++++++++++++++++++++++++ | 68% ~01s |+++++++++++++++++++++++++++++++++++ | 70% ~01s |++++++++++++++++++++++++++++++++++++ | 72% ~01s |+++++++++++++++++++++++++++++++++++++ | 74% ~01s |++++++++++++++++++++++++++++++++++++++ | 76% ~01s |+++++++++++++++++++++++++++++++++++++++ | 78% ~01s |++++++++++++++++++++++++++++++++++++++++ | 80% ~00s |+++++++++++++++++++++++++++++++++++++++++ | 82% ~00s |++++++++++++++++++++++++++++++++++++++++++ | 84% ~00s |+++++++++++++++++++++++++++++++++++++++++++ | 86% ~00s |++++++++++++++++++++++++++++++++++++++++++++ | 88% ~00s |+++++++++++++++++++++++++++++++++++++++++++++ | 90% ~00s |++++++++++++++++++++++++++++++++++++++++++++++ | 92% ~00s |+++++++++++++++++++++++++++++++++++++++++++++++ | 94% ~00s |++++++++++++++++++++++++++++++++++++++++++++++++ | 96% ~00s |+++++++++++++++++++++++++++++++++++++++++++++++++ | 98% ~00s |++++++++++++++++++++++++++++++++++++++++++++++++++| 100% elapsed=02s 193s user system elapsed 193s 0.119 0.032 2.347 193s 193s pbpply> ## (RNG needs to be set when not using bid) 193s pbpply> parallel::clusterSetRNGStream(cl, iseed = 0L) 193s 193s pbpply> system.time(res4pbcl <- pbreplicate(B, fun(), cl = cl)) 194s | | 0 % ~calculating |+ | 2 % ~00s |++ | 4 % ~00s |+++ | 6 % ~00s |++++ | 8 % ~00s |+++++ | 10% ~00s |++++++ | 12% ~00s |+++++++ | 14% ~00s |++++++++ | 16% ~00s |+++++++++ | 18% ~00s |++++++++++ | 20% ~00s |+++++++++++ | 22% ~00s |++++++++++++ | 24% ~00s |+++++++++++++ | 26% ~00s |++++++++++++++ | 28% ~00s |+++++++++++++++ | 30% ~00s |++++++++++++++++ | 32% ~00s |+++++++++++++++++ | 34% ~00s |++++++++++++++++++ | 36% ~00s |+++++++++++++++++++ | 38% ~00s |++++++++++++++++++++ | 40% ~00s |+++++++++++++++++++++ | 42% ~00s |++++++++++++++++++++++ | 44% ~00s |+++++++++++++++++++++++ | 46% ~00s |++++++++++++++++++++++++ | 48% ~00s |+++++++++++++++++++++++++ | 50% ~00s |++++++++++++++++++++++++++ | 52% ~00s |+++++++++++++++++++++++++++ | 54% ~00s |++++++++++++++++++++++++++++ | 56% ~00s |+++++++++++++++++++++++++++++ | 58% ~00s |++++++++++++++++++++++++++++++ | 60% ~00s |+++++++++++++++++++++++++++++++ | 62% ~00s |++++++++++++++++++++++++++++++++ | 64% ~00s |+++++++++++++++++++++++++++++++++ | 66% ~00s |++++++++++++++++++++++++++++++++++ | 68% ~00s |+++++++++++++++++++++++++++++++++++ | 70% ~00s |++++++++++++++++++++++++++++++++++++ | 72% ~00s |+++++++++++++++++++++++++++++++++++++ | 74% ~00s |++++++++++++++++++++++++++++++++++++++ | 76% ~00s |+++++++++++++++++++++++++++++++++++++++ | 78% ~00s |++++++++++++++++++++++++++++++++++++++++ | 80% ~00s |+++++++++++++++++++++++++++++++++++++++++ | 82% ~00s |++++++++++++++++++++++++++++++++++++++++++ | 84% ~00s |+++++++++++++++++++++++++++++++++++++++++++ | 86% ~00s |++++++++++++++++++++++++++++++++++++++++++++ | 88% ~00s |+++++++++++++++++++++++++++++++++++++++++++++ | 90% ~00s |++++++++++++++++++++++++++++++++++++++++++++++ | 92% ~00s |+++++++++++++++++++++++++++++++++++++++++++++++ | 94% ~00s |++++++++++++++++++++++++++++++++++++++++++++++++ | 96% ~00s |+++++++++++++++++++++++++++++++++++++++++++++++++ | 98% ~00s |++++++++++++++++++++++++++++++++++++++++++++++++++| 100% elapsed=00s 194s user system elapsed 194s 0.025 0.014 0.118 194s 194s pbpply> system.time(res3pbcl <- pbapply(bid, 2, fun, cl = cl)) 196s | | 0 % ~calculating |+ | 2 % ~02s |++ | 4 % ~02s |+++ | 6 % ~02s |++++ | 8 % ~02s |+++++ | 10% ~02s |++++++ | 12% ~02s |+++++++ | 14% ~02s |++++++++ | 16% ~02s |+++++++++ | 18% ~02s |++++++++++ | 20% ~02s |+++++++++++ | 22% ~02s |++++++++++++ | 24% ~02s |+++++++++++++ | 26% ~02s |++++++++++++++ | 28% ~02s |+++++++++++++++ | 30% ~02s |++++++++++++++++ | 32% ~02s |+++++++++++++++++ | 34% ~02s |++++++++++++++++++ | 36% ~01s |+++++++++++++++++++ | 38% ~01s |++++++++++++++++++++ | 40% ~01s |+++++++++++++++++++++ | 42% ~01s |++++++++++++++++++++++ | 44% ~01s |+++++++++++++++++++++++ | 46% ~01s |++++++++++++++++++++++++ | 48% ~01s |+++++++++++++++++++++++++ | 50% ~01s |++++++++++++++++++++++++++ | 52% ~01s |+++++++++++++++++++++++++++ | 54% ~01s |++++++++++++++++++++++++++++ | 56% ~01s |+++++++++++++++++++++++++++++ | 58% ~01s |++++++++++++++++++++++++++++++ | 60% ~01s |+++++++++++++++++++++++++++++++ | 62% ~01s |++++++++++++++++++++++++++++++++ | 64% ~01s |+++++++++++++++++++++++++++++++++ | 66% ~01s |++++++++++++++++++++++++++++++++++ | 68% ~01s |+++++++++++++++++++++++++++++++++++ | 70% ~01s |++++++++++++++++++++++++++++++++++++ | 72% ~01s |+++++++++++++++++++++++++++++++++++++ | 74% ~01s |++++++++++++++++++++++++++++++++++++++ | 76% ~01s |+++++++++++++++++++++++++++++++++++++++ | 78% ~00s |++++++++++++++++++++++++++++++++++++++++ | 80% ~00s |+++++++++++++++++++++++++++++++++++++++++ | 82% ~00s |++++++++++++++++++++++++++++++++++++++++++ | 84% ~00s |+++++++++++++++++++++++++++++++++++++++++++ | 86% ~00s |++++++++++++++++++++++++++++++++++++++++++++ | 88% ~00s |+++++++++++++++++++++++++++++++++++++++++++++ | 90% ~00s |++++++++++++++++++++++++++++++++++++++++++++++ | 92% ~00s |+++++++++++++++++++++++++++++++++++++++++++++++ | 94% ~00s |++++++++++++++++++++++++++++++++++++++++++++++++ | 96% ~00s |+++++++++++++++++++++++++++++++++++++++++++++++++ | 98% ~00s |++++++++++++++++++++++++++++++++++++++++++++++++++| 100% elapsed=02s 196s user system elapsed 196s 0.137 0.021 2.286 196s 196s pbpply> stopCluster(cl) 196s 196s pbpply> if (.Platform$OS.type != "windows") { 196s pbpply+ ## parallel with no progress bar: multicore type forking 196s pbpply+ ## (mc.set.seed = TRUE in parallel::mclapply by default) 196s pbpply+ system.time(res2mc <- mclapply(1:B, function(i) fun(bid[,i]), mc.cores = 2L)) 196s pbpply+ ## parallel with progress bar: multicore type forking 196s pbpply+ ## (mc.set.seed = TRUE in parallel::mclapply by default) 196s pbpply+ system.time(res1pbmc <- pblapply(1:B, function(i) fun(bid[,i]), cl = 2L)) 196s pbpply+ system.time(res2pbmc <- pbsapply(1:B, function(i) fun(bid[,i]), cl = 2L)) 196s pbpply+ system.time(res4pbmc <- pbreplicate(B, fun(), cl = 2L)) 196s pbpply+ } 197s | | 0 % ~calculating |+ | 2 % ~01s |++ | 4 % ~01s |+++ | 6 % ~01s |++++ | 8 % ~01s |+++++ | 10% ~01s |++++++ | 12% ~01s |+++++++ | 14% ~01s |++++++++ | 16% ~01s |+++++++++ | 18% ~01s |++++++++++ | 20% ~01s |+++++++++++ | 22% ~01s |++++++++++++ | 24% ~00s |+++++++++++++ | 26% ~00s |++++++++++++++ | 28% ~00s |+++++++++++++++ | 30% ~00s |++++++++++++++++ | 32% ~00s |+++++++++++++++++ | 34% ~00s |++++++++++++++++++ | 36% ~00s |+++++++++++++++++++ | 38% ~00s |++++++++++++++++++++ | 40% ~00s |+++++++++++++++++++++ | 42% ~00s |++++++++++++++++++++++ | 44% ~00s |+++++++++++++++++++++++ | 46% ~00s |++++++++++++++++++++++++ | 48% ~00s |+++++++++++++++++++++++++ | 50% ~00s |++++++++++++++++++++++++++ | 52% ~00s |+++++++++++++++++++++++++++ | 54% ~00s |++++++++++++++++++++++++++++ | 56% ~00s |+++++++++++++++++++++++++++++ | 58% ~00s |++++++++++++++++++++++++++++++ | 60% ~00s |+++++++++++++++++++++++++++++++ | 62% ~00s |++++++++++++++++++++++++++++++++ | 64% ~00s |+++++++++++++++++++++++++++++++++ | 66% ~00s |++++++++++++++++++++++++++++++++++ | 68% ~00s |+++++++++++++++++++++++++++++++++++ | 70% ~00s |++++++++++++++++++++++++++++++++++++ | 72% ~00s |+++++++++++++++++++++++++++++++++++++ | 74% ~00s |++++++++++++++++++++++++++++++++++++++ | 76% ~00s |+++++++++++++++++++++++++++++++++++++++ | 78% ~00s |++++++++++++++++++++++++++++++++++++++++ | 80% ~00s |+++++++++++++++++++++++++++++++++++++++++ | 82% ~00s |++++++++++++++++++++++++++++++++++++++++++ | 84% ~00s |+++++++++++++++++++++++++++++++++++++++++++ | 86% ~00s |++++++++++++++++++++++++++++++++++++++++++++ | 88% ~00s |+++++++++++++++++++++++++++++++++++++++++++++ | 90% ~00s |++++++++++++++++++++++++++++++++++++++++++++++ | 92% ~00s |+++++++++++++++++++++++++++++++++++++++++++++++ | 94% ~00s |++++++++++++++++++++++++++++++++++++++++++++++++ | 96% ~00s |+++++++++++++++++++++++++++++++++++++++++++++++++ | 98% ~00s |++++++++++++++++++++++++++++++++++++++++++++++++++| 100% elapsed=01s 198s | | 0 % ~calculating |+ | 2 % ~01s |++ | 4 % ~01s |+++ | 6 % ~01s |++++ | 8 % ~01s |+++++ | 10% ~01s |++++++ | 12% ~01s |+++++++ | 14% ~01s |++++++++ | 16% ~01s |+++++++++ | 18% ~01s |++++++++++ | 20% ~01s |+++++++++++ | 22% ~01s |++++++++++++ | 24% ~01s |+++++++++++++ | 26% ~01s |++++++++++++++ | 28% ~01s |+++++++++++++++ | 30% ~01s |++++++++++++++++ | 32% ~01s |+++++++++++++++++ | 34% ~00s |++++++++++++++++++ | 36% ~00s |+++++++++++++++++++ | 38% ~00s |++++++++++++++++++++ | 40% ~00s |+++++++++++++++++++++ | 42% ~00s |++++++++++++++++++++++ | 44% ~00s |+++++++++++++++++++++++ | 46% ~00s |++++++++++++++++++++++++ | 48% ~00s |+++++++++++++++++++++++++ | 50% ~00s |++++++++++++++++++++++++++ | 52% ~00s |+++++++++++++++++++++++++++ | 54% ~00s |++++++++++++++++++++++++++++ | 56% ~00s |+++++++++++++++++++++++++++++ | 58% ~00s |++++++++++++++++++++++++++++++ | 60% ~00s |+++++++++++++++++++++++++++++++ | 62% ~00s |++++++++++++++++++++++++++++++++ | 64% ~00s |+++++++++++++++++++++++++++++++++ | 66% ~00s |++++++++++++++++++++++++++++++++++ | 68% ~00s |+++++++++++++++++++++++++++++++++++ | 70% ~00s |++++++++++++++++++++++++++++++++++++ | 72% ~00s |+++++++++++++++++++++++++++++++++++++ | 74% ~00s |++++++++++++++++++++++++++++++++++++++ | 76% ~00s |+++++++++++++++++++++++++++++++++++++++ | 78% ~00s |++++++++++++++++++++++++++++++++++++++++ | 80% ~00s |+++++++++++++++++++++++++++++++++++++++++ | 82% ~00s |++++++++++++++++++++++++++++++++++++++++++ | 84% ~00s |+++++++++++++++++++++++++++++++++++++++++++ | 86% ~00s |++++++++++++++++++++++++++++++++++++++++++++ | 88% ~00s |+++++++++++++++++++++++++++++++++++++++++++++ | 90% ~00s |++++++++++++++++++++++++++++++++++++++++++++++ | 92% ~00s |+++++++++++++++++++++++++++++++++++++++++++++++ | 94% ~00s |++++++++++++++++++++++++++++++++++++++++++++++++ | 96% ~00s |+++++++++++++++++++++++++++++++++++++++++++++++++ | 98% ~00s |++++++++++++++++++++++++++++++++++++++++++++++++++| 100% elapsed=01s 198s | | 0 % ~calculating |+ | 2 % ~00s |++ | 4 % ~01s |+++ | 6 % ~01s |++++ | 8 % ~01s |+++++ | 10% ~01s |++++++ | 12% ~01s |+++++++ | 14% ~01s |++++++++ | 16% ~01s |+++++++++ | 18% ~01s |++++++++++ | 20% ~01s |+++++++++++ | 22% ~01s |++++++++++++ | 24% ~01s |+++++++++++++ | 26% ~01s |++++++++++++++ | 28% ~01s |+++++++++++++++ | 30% ~01s |++++++++++++++++ | 32% ~01s |+++++++++++++++++ | 34% ~01s |++++++++++++++++++ | 36% ~01s |+++++++++++++++++++ | 38% ~00s |++++++++++++++++++++ | 40% ~00s |+++++++++++++++++++++ | 42% ~00s |++++++++++++++++++++++ | 44% ~00s |+++++++++++++++++++++++ | 46% ~00s |++++++++++++++++++++++++ | 48% ~00s |+++++++++++++++++++++++++ | 50% ~00s |++++++++++++++++++++++++++ | 52% ~00s |+++++++++++++++++++++++++++ | 54% ~00s |++++++++++++++++++++++++++++ | 56% ~00s |+++++++++++++++++++++++++++++ | 58% ~00s |++++++++++++++++++++++++++++++ | 60% ~00s |+++++++++++++++++++++++++++++++ | 62% ~00s |++++++++++++++++++++++++++++++++ | 64% ~00s |+++++++++++++++++++++++++++++++++ | 66% ~00s |++++++++++++++++++++++++++++++++++ | 68% ~00s |+++++++++++++++++++++++++++++++++++ | 70% ~00s |++++++++++++++++++++++++++++++++++++ | 72% ~00s |+++++++++++++++++++++++++++++++++++++ | 74% ~00s |++++++++++++++++++++++++++++++++++++++ | 76% ~00s |+++++++++++++++++++++++++++++++++++++++ | 78% ~00s |++++++++++++++++++++++++++++++++++++++++ | 80% ~00s |+++++++++++++++++++++++++++++++++++++++++ | 82% ~00s |++++++++++++++++++++++++++++++++++++++++++ | 84% ~00s |+++++++++++++++++++++++++++++++++++++++++++ | 86% ~00s |++++++++++++++++++++++++++++++++++++++++++++ | 88% ~00s |+++++++++++++++++++++++++++++++++++++++++++++ | 90% ~00s |++++++++++++++++++++++++++++++++++++++++++++++ | 92% ~00s |+++++++++++++++++++++++++++++++++++++++++++++++ | 94% ~00s |++++++++++++++++++++++++++++++++++++++++++++++++ | 96% ~00s |+++++++++++++++++++++++++++++++++++++++++++++++++ | 98% ~00s |++++++++++++++++++++++++++++++++++++++++++++++++++| 100% elapsed=01s 198s user system elapsed 198s 0.288 1.090 0.749 198s 198s pbpply> ## --- Examples taken from standard '*apply' functions --- 198s pbpply> 198s pbpply> ## --- sapply, lapply, and replicate --- 198s pbpply> 198s pbpply> require(stats); require(graphics) 198s 198s pbpply> x <- list(a = 1:10, beta = exp(-3:3), logic = c(TRUE,FALSE,FALSE,TRUE)) 198s 198s pbpply> # compute the list mean for each list element 198s pbpply> pblapply(x, mean) 198s | | 0 % ~calculating |+++++++++++++++++ | 33% ~00s |++++++++++++++++++++++++++++++++++ | 67% ~00s |++++++++++++++++++++++++++++++++++++++++++++++++++| 100% elapsed=00s 198s $a 198s [1] 5.5 198s 198s $beta 198s [1] 4.535125 198s 198s $logic 198s [1] 0.5 198s 198s 198s pbpply> pbwalk(x, mean) 198s | | 0 % ~calculating |+++++++++++++++++ | 33% ~00s |++++++++++++++++++++++++++++++++++ | 67% ~00s |++++++++++++++++++++++++++++++++++++++++++++++++++| 100% elapsed=00s 198s 198s pbpply> # median and quartiles for each list element 198s pbpply> pblapply(x, quantile, probs = 1:3/4) 198s | | 0 % ~calculating |+++++++++++++++++ | 33% ~00s |++++++++++++++++++++++++++++++++++ | 67% ~00s |++++++++++++++++++++++++++++++++++++++++++++++++++| 100% elapsed=00s 198s $a 198s 25% 50% 75% 198s 3.25 5.50 7.75 198s 198s $beta 198s 25% 50% 75% 198s 0.2516074 1.0000000 5.0536690 198s 198s $logic 198s 25% 50% 75% 198s 0.0 0.5 1.0 198s 198s 198s pbpply> pbsapply(x, quantile) 198s | | 0 % ~calculating |+++++++++++++++++ | 33% ~00s |++++++++++++++++++++++++++++++++++ | 67% ~00s |++++++++++++++++++++++++++++++++++++++++++++++++++| 100% elapsed=00s 198s a beta logic 198s 0% 1.00 0.04978707 0.0 198s 25% 3.25 0.25160736 0.0 198s 50% 5.50 1.00000000 0.5 198s 75% 7.75 5.05366896 1.0 198s 100% 10.00 20.08553692 1.0 198s 198s pbpply> i39 <- sapply(3:9, seq) # list of vectors 198s 198s pbpply> pbsapply(i39, fivenum) 198s | | 0 % ~calculating |++++++++ | 14% ~00s |+++++++++++++++ | 29% ~00s |++++++++++++++++++++++ | 43% ~00s |+++++++++++++++++++++++++++++ | 57% ~00s |++++++++++++++++++++++++++++++++++++ | 71% ~00s |+++++++++++++++++++++++++++++++++++++++++++ | 86% ~00s |++++++++++++++++++++++++++++++++++++++++++++++++++| 100% elapsed=00s 198s [,1] [,2] [,3] [,4] [,5] [,6] [,7] 198s [1,] 1.0 1.0 1 1.0 1.0 1.0 1 198s [2,] 1.5 1.5 2 2.0 2.5 2.5 3 198s [3,] 2.0 2.5 3 3.5 4.0 4.5 5 198s [4,] 2.5 3.5 4 5.0 5.5 6.5 7 198s [5,] 3.0 4.0 5 6.0 7.0 8.0 9 198s 198s pbpply> pbvapply(i39, fivenum, 198s pbpply+ c(Min. = 0, "1st Qu." = 0, Median = 0, "3rd Qu." = 0, Max. = 0)) 198s | | 0 % ~calculating |++++++++ | 14% ~00s |+++++++++++++++ | 29% ~00s |++++++++++++++++++++++ | 43% ~00s |+++++++++++++++++++++++++++++ | 57% ~00s |++++++++++++++++++++++++++++++++++++ | 71% ~00s |+++++++++++++++++++++++++++++++++++++++++++ | 86% ~00s |++++++++++++++++++++++++++++++++++++++++++++++++++| 100% elapsed=00s 198s [,1] [,2] [,3] [,4] [,5] [,6] [,7] 198s Min. 1.0 1.0 1 1.0 1.0 1.0 1 198s 1st Qu. 1.5 1.5 2 2.0 2.5 2.5 3 198s Median 2.0 2.5 3 3.5 4.0 4.5 5 198s 3rd Qu. 2.5 3.5 4 5.0 5.5 6.5 7 198s Max. 3.0 4.0 5 6.0 7.0 8.0 9 198s 198s pbpply> ## sapply(*, "array") -- artificial example 198s pbpply> (v <- structure(10*(5:8), names = LETTERS[1:4])) 198s A B C D 198s 50 60 70 80 198s 198s pbpply> f2 <- function(x, y) outer(rep(x, length.out = 3), y) 198s 198s pbpply> (a2 <- pbsapply(v, f2, y = 2*(1:5), simplify = "array")) 198s | | 0 % ~calculating |+++++++++++++ | 25% ~00s |+++++++++++++++++++++++++ | 50% ~00s |++++++++++++++++++++++++++++++++++++++ | 75% ~00s |++++++++++++++++++++++++++++++++++++++++++++++++++| 100% elapsed=00s 198s , , A 198s 198s [,1] [,2] [,3] [,4] [,5] 198s [1,] 100 200 300 400 500 198s [2,] 100 200 300 400 500 198s [3,] 100 200 300 400 500 198s 198s , , B 198s 198s [,1] [,2] [,3] [,4] [,5] 198s [1,] 120 240 360 480 600 198s [2,] 120 240 360 480 600 198s [3,] 120 240 360 480 600 198s 198s , , C 198s 198s [,1] [,2] [,3] [,4] [,5] 198s [1,] 140 280 420 560 700 198s [2,] 140 280 420 560 700 198s [3,] 140 280 420 560 700 198s 198s , , D 198s 198s [,1] [,2] [,3] [,4] [,5] 198s [1,] 160 320 480 640 800 198s [2,] 160 320 480 640 800 198s [3,] 160 320 480 640 800 198s 198s 198s pbpply> a.2 <- pbvapply(v, f2, outer(1:3, 1:5), y = 2*(1:5)) 198s | | 0 % ~calculating |+++++++++++++ | 25% ~00s |+++++++++++++++++++++++++ | 50% ~00s |++++++++++++++++++++++++++++++++++++++ | 75% ~00s |++++++++++++++++++++++++++++++++++++++++++++++++++| 100% elapsed=00s 198s 198s pbpply> stopifnot(dim(a2) == c(3,5,4), all.equal(a2, a.2), 198s pbpply+ identical(dimnames(a2), list(NULL,NULL,LETTERS[1:4]))) 198s 198s pbpply> summary(pbreplicate(100, mean(rexp(10)))) 198s | | 0 % ~calculating |+ | 1 % ~00s |+ | 2 % ~00s |++ | 3 % ~00s |++ | 4 % ~00s |+++ | 5 % ~00s |+++ | 6 % ~00s |++++ | 7 % ~00s |++++ | 8 % ~00s |+++++ | 9 % ~00s |+++++ | 10% ~00s |++++++ | 11% ~00s |++++++ | 12% ~00s |+++++++ | 13% ~00s |+++++++ | 14% ~00s |++++++++ | 15% ~00s |++++++++ | 16% ~00s |+++++++++ | 17% ~00s |+++++++++ | 18% ~00s |++++++++++ | 19% ~00s |++++++++++ | 20% ~00s |+++++++++++ | 21% ~00s |+++++++++++ | 22% ~00s |++++++++++++ | 23% ~00s |++++++++++++ | 24% ~00s |+++++++++++++ | 25% ~00s |+++++++++++++ | 26% ~00s |++++++++++++++ | 27% ~00s |++++++++++++++ | 28% ~00s |+++++++++++++++ | 29% ~00s |+++++++++++++++ | 30% ~00s |++++++++++++++++ | 31% ~00s |++++++++++++++++ | 32% ~00s |+++++++++++++++++ | 33% ~00s |+++++++++++++++++ | 34% ~00s |++++++++++++++++++ | 35% ~00s |++++++++++++++++++ | 36% ~00s |+++++++++++++++++++ | 37% ~00s |+++++++++++++++++++ | 38% ~00s |++++++++++++++++++++ | 39% ~00s |++++++++++++++++++++ | 40% ~00s |+++++++++++++++++++++ | 41% ~00s |+++++++++++++++++++++ | 42% ~00s |++++++++++++++++++++++ | 43% ~00s |++++++++++++++++++++++ | 44% ~00s |+++++++++++++++++++++++ | 45% ~00s |+++++++++++++++++++++++ | 46% ~00s |++++++++++++++++++++++++ | 47% ~00s |++++++++++++++++++++++++ | 48% ~00s |+++++++++++++++++++++++++ | 49% ~00s |+++++++++++++++++++++++++ | 50% ~00s |++++++++++++++++++++++++++ | 51% ~00s |++++++++++++++++++++++++++ | 52% ~00s |+++++++++++++++++++++++++++ | 53% ~00s |+++++++++++++++++++++++++++ | 54% ~00s |++++++++++++++++++++++++++++ | 55% ~00s |++++++++++++++++++++++++++++ | 56% ~00s |+++++++++++++++++++++++++++++ | 57% ~00s |+++++++++++++++++++++++++++++ | 58% ~00s |++++++++++++++++++++++++++++++ | 59% ~00s |++++++++++++++++++++++++++++++ | 60% ~00s |+++++++++++++++++++++++++++++++ | 61% ~00s |+++++++++++++++++++++++++++++++ | 62% ~00s |++++++++++++++++++++++++++++++++ | 63% ~00s |++++++++++++++++++++++++++++++++ | 64% ~00s |+++++++++++++++++++++++++++++++++ | 65% ~00s |+++++++++++++++++++++++++++++++++ | 66% ~00s |++++++++++++++++++++++++++++++++++ | 67% ~00s |++++++++++++++++++++++++++++++++++ | 68% ~00s |+++++++++++++++++++++++++++++++++++ | 69% ~00s |+++++++++++++++++++++++++++++++++++ | 70% ~00s |++++++++++++++++++++++++++++++++++++ | 71% ~00s |++++++++++++++++++++++++++++++++++++ | 72% ~00s |+++++++++++++++++++++++++++++++++++++ | 73% ~00s |+++++++++++++++++++++++++++++++++++++ | 74% ~00s |++++++++++++++++++++++++++++++++++++++ | 75% ~00s |++++++++++++++++++++++++++++++++++++++ | 76% ~00s |+++++++++++++++++++++++++++++++++++++++ | 77% ~00s |+++++++++++++++++++++++++++++++++++++++ | 78% ~00s |++++++++++++++++++++++++++++++++++++++++ | 79% ~00s |++++++++++++++++++++++++++++++++++++++++ | 80% ~00s |+++++++++++++++++++++++++++++++++++++++++ | 81% ~00s |+++++++++++++++++++++++++++++++++++++++++ | 82% ~00s |++++++++++++++++++++++++++++++++++++++++++ | 83% ~00s |++++++++++++++++++++++++++++++++++++++++++ | 84% ~00s |+++++++++++++++++++++++++++++++++++++++++++ | 85% ~00s |+++++++++++++++++++++++++++++++++++++++++++ | 86% ~00s |++++++++++++++++++++++++++++++++++++++++++++ | 87% ~00s |++++++++++++++++++++++++++++++++++++++++++++ | 88% ~00s |+++++++++++++++++++++++++++++++++++++++++++++ | 89% ~00s |+++++++++++++++++++++++++++++++++++++++++++++ | 90% ~00s |++++++++++++++++++++++++++++++++++++++++++++++ | 91% ~00s |++++++++++++++++++++++++++++++++++++++++++++++ | 92% ~00s |+++++++++++++++++++++++++++++++++++++++++++++++ | 93% ~00s |+++++++++++++++++++++++++++++++++++++++++++++++ | 94% ~00s |++++++++++++++++++++++++++++++++++++++++++++++++ | 95% ~00s |++++++++++++++++++++++++++++++++++++++++++++++++ | 96% ~00s |+++++++++++++++++++++++++++++++++++++++++++++++++ | 97% ~00s |+++++++++++++++++++++++++++++++++++++++++++++++++ | 98% ~00s |++++++++++++++++++++++++++++++++++++++++++++++++++| 99% ~00s |++++++++++++++++++++++++++++++++++++++++++++++++++| 100% elapsed=00s 198s Min. 1st Qu. Median Mean 3rd Qu. Max. 198s 0.4786 0.7273 0.9091 0.9666 1.1917 2.3021 198s 198s pbpply> ## use of replicate() with parameters: 198s pbpply> foo <- function(x = 1, y = 2) c(x, y) 198s 198s pbpply> # does not work: bar <- function(n, ...) replicate(n, foo(...)) 198s pbpply> bar <- function(n, x) pbreplicate(n, foo(x = x)) 198s 198s pbpply> bar(5, x = 3) 198s | | 0 % ~calculating |++++++++++ | 20% ~00s |++++++++++++++++++++ | 40% ~00s |++++++++++++++++++++++++++++++ | 60% ~00s |++++++++++++++++++++++++++++++++++++++++ | 80% ~00s |++++++++++++++++++++++++++++++++++++++++++++++++++| 100% elapsed=00s 198s [,1] [,2] [,3] [,4] [,5] 198s [1,] 3 3 3 3 3 198s [2,] 2 2 2 2 2 198s 198s pbpply> ## --- apply --- 198s pbpply> 198s pbpply> ## Compute row and column sums for a matrix: 198s pbpply> x <- cbind(x1 = 3, x2 = c(4:1, 2:5)) 198s 198s pbpply> dimnames(x)[[1]] <- letters[1:8] 198s 198s pbpply> pbapply(x, 2, mean, trim = .2) 198s | | 0 % ~calculating |+++++++++++++++++++++++++ | 50% ~00s |++++++++++++++++++++++++++++++++++++++++++++++++++| 100% elapsed=00s 198s x1 x2 198s 3 3 198s 198s pbpply> col.sums <- pbapply(x, 2, sum) 198s | | 0 % ~calculating |+++++++++++++++++++++++++ | 50% ~00s |++++++++++++++++++++++++++++++++++++++++++++++++++| 100% elapsed=00s 198s 198s pbpply> row.sums <- pbapply(x, 1, sum) 198s | | 0 % ~calculating |+++++++ | 12% ~00s |+++++++++++++ | 25% ~00s |+++++++++++++++++++ | 38% ~00s |+++++++++++++++++++++++++ | 50% ~00s |++++++++++++++++++++++++++++++++ | 62% ~00s |++++++++++++++++++++++++++++++++++++++ | 75% ~00s |++++++++++++++++++++++++++++++++++++++++++++ | 88% ~00s |++++++++++++++++++++++++++++++++++++++++++++++++++| 100% elapsed=00s 198s 198s pbpply> rbind(cbind(x, Rtot = row.sums), Ctot = c(col.sums, sum(col.sums))) 198s x1 x2 Rtot 198s a 3 4 7 198s b 3 3 6 198s c 3 2 5 198s d 3 1 4 198s e 3 2 5 198s f 3 3 6 198s g 3 4 7 198s h 3 5 8 198s Ctot 24 24 48 198s 198s pbpply> stopifnot( pbapply(x, 2, is.vector)) 198s | | 0 % ~calculating |+++++++++++++++++++++++++ | 50% ~00s |++++++++++++++++++++++++++++++++++++++++++++++++++| 100% elapsed=00s 198s 198s pbpply> ## Sort the columns of a matrix 198s pbpply> pbapply(x, 2, sort) 198s | | 0 % ~calculating |+++++++++++++++++++++++++ | 50% ~00s |++++++++++++++++++++++++++++++++++++++++++++++++++| 100% elapsed=00s 198s x1 x2 198s [1,] 3 1 198s [2,] 3 2 198s [3,] 3 2 198s [4,] 3 3 198s [5,] 3 3 198s [6,] 3 4 198s [7,] 3 4 198s [8,] 3 5 198s 198s pbpply> ## keeping named dimnames 198s pbpply> names(dimnames(x)) <- c("row", "col") 198s 198s pbpply> x3 <- array(x, dim = c(dim(x),3), 198s pbpply+ dimnames = c(dimnames(x), list(C = paste0("cop.",1:3)))) 198s 198s pbpply> identical(x, pbapply( x, 2, identity)) 198s | | 0 % ~calculating |+++++++++++++++++++++++++ | 50% ~00s |++++++++++++++++++++++++++++++++++++++++++++++++++| 100% elapsed=00s 198s [1] TRUE 198s 198s pbpply> identical(x3, pbapply(x3, 2:3, identity)) 198s | | 0 % ~calculating |+++++++++ | 17% ~00s |+++++++++++++++++ | 33% ~00s |+++++++++++++++++++++++++ | 50% ~00s |++++++++++++++++++++++++++++++++++ | 67% ~00s |++++++++++++++++++++++++++++++++++++++++++ | 83% ~00s |++++++++++++++++++++++++++++++++++++++++++++++++++| 100% elapsed=00s 198s [1] TRUE 198s 198s pbpply> ##- function with extra args: 198s pbpply> cave <- function(x, c1, c2) c(mean(x[c1]), mean(x[c2])) 198s 198s pbpply> pbapply(x, 1, cave, c1 = "x1", c2 = c("x1","x2")) 198s | | 0 % ~calculating |+++++++ | 12% ~00s |+++++++++++++ | 25% ~00s |+++++++++++++++++++ | 38% ~00s |+++++++++++++++++++++++++ | 50% ~00s |++++++++++++++++++++++++++++++++ | 62% ~00s |++++++++++++++++++++++++++++++++++++++ | 75% ~00s |++++++++++++++++++++++++++++++++++++++++++++ | 88% ~00s |++++++++++++++++++++++++++++++++++++++++++++++++++| 100% elapsed=00s 198s row 198s a b c d e f g h 198s [1,] 3.0 3 3.0 3 3.0 3 3.0 3 198s [2,] 3.5 3 2.5 2 2.5 3 3.5 4 198s 198s pbpply> ma <- matrix(c(1:4, 1, 6:8), nrow = 2) 198s 198s pbpply> ma 198s [,1] [,2] [,3] [,4] 198s [1,] 1 3 1 7 198s [2,] 2 4 6 8 198s 198s pbpply> pbapply(ma, 1, table) #--> a list of length 2 198s | | 0 % ~calculating |+++++++++++++++++++++++++ | 50% ~00s |++++++++++++++++++++++++++++++++++++++++++++++++++| 100% elapsed=00s 198s [[1]] 198s 198s 1 3 7 198s 2 1 1 198s 198s [[2]] 198s 198s 2 4 6 8 198s 1 1 1 1 198s 198s 198s pbpply> pbapply(ma, 1, stats::quantile) # 5 x n matrix with rownames 198s | | 0 % ~calculating |+++++++++++++++++++++++++ | 50% ~00s |++++++++++++++++++++++++++++++++++++++++++++++++++| 100% elapsed=00s 198s [,1] [,2] 198s 0% 1 2.0 198s 25% 1 3.5 198s 50% 2 5.0 198s 75% 4 6.5 198s 100% 7 8.0 198s 198s pbpply> stopifnot(dim(ma) == dim(pbapply(ma, 1:2, sum))) 198s | | 0 % ~calculating |+++++++ | 12% ~00s |+++++++++++++ | 25% ~00s |+++++++++++++++++++ | 38% ~00s |+++++++++++++++++++++++++ | 50% ~00s |++++++++++++++++++++++++++++++++ | 62% ~00s |++++++++++++++++++++++++++++++++++++++ | 75% ~00s |++++++++++++++++++++++++++++++++++++++++++++ | 88% ~00s |++++++++++++++++++++++++++++++++++++++++++++++++++| 100% elapsed=00s 198s 198s pbpply> ## Example with different lengths for each call 198s pbpply> z <- array(1:24, dim = 2:4) 198s 198s pbpply> zseq <- pbapply(z, 1:2, function(x) seq_len(max(x))) 198s | | 0 % ~calculating |+++++++++ | 17% ~00s |+++++++++++++++++ | 33% ~00s |+++++++++++++++++++++++++ | 50% ~00s |++++++++++++++++++++++++++++++++++ | 67% ~00s |++++++++++++++++++++++++++++++++++++++++++ | 83% ~00s |++++++++++++++++++++++++++++++++++++++++++++++++++| 100% elapsed=00s 198s 198s pbpply> zseq ## a 2 x 3 matrix 198s [,1] [,2] [,3] 198s [1,] integer,19 integer,21 integer,23 198s [2,] integer,20 integer,22 integer,24 198s 198s pbpply> typeof(zseq) ## list 198s [1] "list" 198s 198s pbpply> dim(zseq) ## 2 3 198s [1] 2 3 198s 198s pbpply> zseq[1,] 198s [[1]] 198s [1] 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 198s 198s [[2]] 198s [1] 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 198s 198s [[3]] 198s [1] 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 198s 198s 198s pbpply> pbapply(z, 3, function(x) seq_len(max(x))) 198s | | 0 % ~calculating |+++++++++++++ | 25% ~00s |+++++++++++++++++++++++++ | 50% ~00s |++++++++++++++++++++++++++++++++++++++ | 75% ~00s |++++++++++++++++++++++++++++++++++++++++++++++++++| 100% elapsed=00s 198s [[1]] 198s [1] 1 2 3 4 5 6 198s 198s [[2]] 198s [1] 1 2 3 4 5 6 7 8 9 10 11 12 198s 198s [[3]] 198s [1] 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 198s 198s [[4]] 198s [1] 1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 198s 198s 198s pbpply> # a list without a dim attribute 198s pbpply> 198s pbpply> ## --- mapply and .mapply --- 198s pbpply> 198s pbpply> pbmapply(rep, 1:4, 4:1) 198s | | 0 % ~calculating |+++++++++++++ | 25% ~00s |+++++++++++++++++++++++++ | 50% ~00s |++++++++++++++++++++++++++++++++++++++ | 75% ~00s |++++++++++++++++++++++++++++++++++++++++++++++++++| 100% elapsed=00s 198s [[1]] 198s [1] 1 1 1 1 198s 198s [[2]] 198s [1] 2 2 2 198s 198s [[3]] 198s [1] 3 3 198s 198s [[4]] 198s [1] 4 198s 198s 198s pbpply> pbmapply(rep, times = 1:4, x = 4:1) 198s | | 0 % ~calculating |+++++++++++++ | 25% ~00s |+++++++++++++++++++++++++ | 50% ~00s |++++++++++++++++++++++++++++++++++++++ | 75% ~00s |++++++++++++++++++++++++++++++++++++++++++++++++++| 100% elapsed=00s 198s [[1]] 198s [1] 4 198s 198s [[2]] 198s [1] 3 3 198s 198s [[3]] 198s [1] 2 2 2 198s 198s [[4]] 198s [1] 1 1 1 1 198s 198s 198s pbpply> pbmapply(rep, times = 1:4, MoreArgs = list(x = 42)) 198s | | 0 % ~calculating |+++++++++++++ | 25% ~00s |+++++++++++++++++++++++++ | 50% ~00s |++++++++++++++++++++++++++++++++++++++ | 75% ~00s |++++++++++++++++++++++++++++++++++++++++++++++++++| 100% elapsed=00s 198s [[1]] 198s [1] 42 198s 198s [[2]] 198s [1] 42 42 198s 198s [[3]] 198s [1] 42 42 42 198s 198s [[4]] 198s [1] 42 42 42 42 198s 198s 198s pbpply> pbmapply(function(x, y) seq_len(x) + y, 198s pbpply+ c(a = 1, b = 2, c = 3), # names from first 198s pbpply+ c(A = 10, B = 0, C = -10)) 198s | | 0 % ~calculating |+++++++++++++++++ | 33% ~00s |++++++++++++++++++++++++++++++++++ | 67% ~00s |++++++++++++++++++++++++++++++++++++++++++++++++++| 100% elapsed=00s 198s $a 198s [1] 11 198s 198s $b 198s [1] 1 2 198s 198s $c 198s [1] -9 -8 -7 198s 198s 198s pbpply> word <- function(C, k) paste(rep.int(C, k), collapse = "") 198s 198s pbpply> utils::str(pbmapply(word, LETTERS[1:6], 6:1, SIMPLIFY = FALSE)) 198s | | 0 % ~calculating |+++++++++ | 17% ~00s |+++++++++++++++++ | 33% ~00s |+++++++++++++++++++++++++ | 50% ~00s |++++++++++++++++++++++++++++++++++ | 67% ~00s |++++++++++++++++++++++++++++++++++++++++++ | 83% ~00s |++++++++++++++++++++++++++++++++++++++++++++++++++| 100% elapsed=00s 198s List of 6 198s $ A: chr "AAAAAA" 198s $ B: chr "BBBBB" 198s $ C: chr "CCCC" 198s $ D: chr "DDD" 198s $ E: chr "EE" 198s $ F: chr "F" 198s 198s pbpply> pb.mapply(rep, 198s pbpply+ dots = list(1:4, 4:1), 198s pbpply+ MoreArgs = list()) 198s | | 0 % ~calculating |+++++++++++++ | 25% ~00s |+++++++++++++++++++++++++ | 50% ~00s |++++++++++++++++++++++++++++++++++++++ | 75% ~00s |++++++++++++++++++++++++++++++++++++++++++++++++++| 100% elapsed=00s 198s [[1]] 198s [1] 1 1 1 1 198s 198s [[2]] 198s [1] 2 2 2 198s 198s [[3]] 198s [1] 3 3 198s 198s [[4]] 198s [1] 4 198s 198s 198s pbpply> pb.mapply(rep, 198s pbpply+ dots = list(times = 1:4, x = 4:1), 198s pbpply+ MoreArgs = list()) 198s | | 0 % ~calculating |+++++++++++++ | 25% ~00s |+++++++++++++++++++++++++ | 50% ~00s |++++++++++++++++++++++++++++++++++++++ | 75% ~00s |++++++++++++++++++++++++++++++++++++++++++++++++++| 100% elapsed=00s 198s [[1]] 198s [1] 4 198s 198s [[2]] 198s [1] 3 3 198s 198s [[3]] 198s [1] 2 2 2 198s 198s [[4]] 198s [1] 1 1 1 1 198s 198s 198s pbpply> pb.mapply(rep, 198s pbpply+ dots = list(times = 1:4), 198s pbpply+ MoreArgs = list(x = 42)) 198s | | 0 % ~calculating |+++++++++++++ | 25% ~00s |+++++++++++++++++++++++++ | 50% ~00s |++++++++++++++++++++++++++++++++++++++ | 75% ~00s |++++++++++++++++++++++++++++++++++++++++++++++++++| 100% elapsed=00s 198s [[1]] 198s [1] 42 198s 198s [[2]] 198s [1] 42 42 198s 198s [[3]] 198s [1] 42 42 42 198s 198s [[4]] 198s [1] 42 42 42 42 198s 198s 198s pbpply> pb.mapply(function(x, y) seq_len(x) + y, 198s pbpply+ dots = list(c(a = 1, b = 2, c = 3), # names from first 198s pbpply+ c(A = 10, B = 0, C = -10)), 198s pbpply+ MoreArgs = list()) 198s | | 0 % ~calculating |+++++++++++++++++ | 33% ~00s |++++++++++++++++++++++++++++++++++ | 67% ~00s |++++++++++++++++++++++++++++++++++++++++++++++++++| 100% elapsed=00s 198s [[1]] 198s [1] 11 198s 198s [[2]] 198s [1] 1 2 198s 198s [[3]] 198s [1] -9 -8 -7 198s 198s 198s pbpply> ## --- Map --- 198s pbpply> 198s pbpply> pbMap(`+`, 1, 1 : 3) ; 1 + 1:3 198s | | 0 % ~calculating |+++++++++++++++++ | 33% ~00s |++++++++++++++++++++++++++++++++++ | 67% ~00s |++++++++++++++++++++++++++++++++++++++++++++++++++| 100% elapsed=00s 198s [[1]] 198s [1] 2 198s 198s [[2]] 198s [1] 3 198s 198s [[3]] 198s [1] 4 198s 198s [1] 2 3 4 198s 198s pbpply> ## --- eapply --- 198s pbpply> 198s pbpply> env <- new.env(hash = FALSE) 198s 198s pbpply> env$a <- 1:10 198s 198s pbpply> env$beta <- exp(-3:3) 198s 198s pbpply> env$logic <- c(TRUE, FALSE, FALSE, TRUE) 198s 198s pbpply> pbeapply(env, mean) 198s | | 0 % ~calculating |+++++++++++++++++ | 33% ~00s |++++++++++++++++++++++++++++++++++ | 67% ~00s |++++++++++++++++++++++++++++++++++++++++++++++++++| 100% elapsed=00s 198s $logic 198s [1] 0.5 198s 198s $beta 198s [1] 4.535125 198s 198s $a 198s [1] 5.5 198s 198s 198s pbpply> unlist(pbeapply(env, mean, USE.NAMES = FALSE)) 198s | | 0 % ~calculating |+++++++++++++++++ | 33% ~00s |++++++++++++++++++++++++++++++++++ | 67% ~00s |++++++++++++++++++++++++++++++++++++++++++++++++++| 100% elapsed=00s 198s [1] 0.500000 4.535125 5.500000 198s 198s pbpply> pbeapply(env, quantile, probs = 1:3/4) 198s | | 0 % ~calculating |+++++++++++++++++ | 33% ~00s |++++++++++++++++++++++++++++++++++ | 67% ~00s |++++++++++++++++++++++++++++++++++++++++++++++++++| 100% elapsed=00s 198s $logic 198s 25% 50% 75% 198s 0.0 0.5 1.0 198s 198s $beta 198s 25% 50% 75% 198s 0.2516074 1.0000000 5.0536690 198s 198s $a 198s 25% 50% 75% 198s 3.25 5.50 7.75 198s 198s 198s pbpply> pbeapply(env, quantile) 198s | | 0 % ~calculating |+++++++++++++++++ | 33% ~00s |++++++++++++++++++++++++++++++++++ | 67% ~00s |++++++++++++++++++++++++++++++++++++++++++++++++++| 100% elapsed=00s 198s $logic 198s 0% 25% 50% 75% 100% 198s 0.0 0.0 0.5 1.0 1.0 198s 198s $beta 198s 0% 25% 50% 75% 100% 198s 0.04978707 0.25160736 1.00000000 5.05366896 20.08553692 198s 198s $a 198s 0% 25% 50% 75% 100% 198s 1.00 3.25 5.50 7.75 10.00 198s 198s 198s pbpply> ## --- tapply --- 198s pbpply> 198s pbpply> require(stats) 198s 198s pbpply> groups <- as.factor(rbinom(32, n = 5, prob = 0.4)) 198s 198s pbpply> pbtapply(groups, groups, length) #- is almost the same as 198s | | 0 % ~calculating |++++++++++ | 20% ~00s |++++++++++++++++++++ | 40% ~00s |++++++++++++++++++++++++++++++ | 60% ~00s |++++++++++++++++++++++++++++++++++++++++ | 80% ~00s |++++++++++++++++++++++++++++++++++++++++++++++++++| 100% elapsed=00s 198s 10 11 13 14 18 198s 1 1 1 1 1 198s 198s pbpply> table(groups) 198s groups 198s 10 11 13 14 18 198s 1 1 1 1 1 198s 198s pbpply> ## contingency table from data.frame : array with named dimnames 198s pbpply> pbtapply(warpbreaks$breaks, warpbreaks[,-1], sum) 198s | | 0 % ~calculating |+++++++++ | 17% ~00s |+++++++++++++++++ | 33% ~00s |+++++++++++++++++++++++++ | 50% ~00s |++++++++++++++++++++++++++++++++++ | 67% ~00s |++++++++++++++++++++++++++++++++++++++++++ | 83% ~00s |++++++++++++++++++++++++++++++++++++++++++++++++++| 100% elapsed=00s 198s tension 198s wool L M H 198s A 401 216 221 198s B 254 259 169 198s 198s pbpply> pbtapply(warpbreaks$breaks, warpbreaks[, 3, drop = FALSE], sum) 198s | | 0 % ~calculating |+++++++++++++++++ | 33% ~00s |++++++++++++++++++++++++++++++++++ | 67% ~00s |++++++++++++++++++++++++++++++++++++++++++++++++++| 100% elapsed=00s 198s tension 198s L M H 198s 655 475 390 198s 198s pbpply> n <- 17; fac <- factor(rep_len(1:3, n), levels = 1:5) 198s 198s pbpply> table(fac) 198s fac 198s 1 2 3 4 5 198s 6 6 5 0 0 198s 198s pbpply> pbtapply(1:n, fac, sum) 198s | | 0 % ~calculating |+++++++++++++++++ | 33% ~00s |++++++++++++++++++++++++++++++++++ | 67% ~00s |++++++++++++++++++++++++++++++++++++++++++++++++++| 100% elapsed=00s 198s 1 2 3 4 5 198s 51 57 45 NA NA 198s 198s pbpply> pbtapply(1:n, fac, sum, default = 0) # maybe more desirable 198s | | 0 % ~calculating |+++++++++++++++++ | 33% ~00s |++++++++++++++++++++++++++++++++++ | 67% ~00s |++++++++++++++++++++++++++++++++++++++++++++++++++| 100% elapsed=00s 198s 1 2 3 4 5 198s 51 57 45 0 0 198s 198s pbpply> pbtapply(1:n, fac, sum, simplify = FALSE) 198s | | 0 % ~calculating |+++++++++++++++++ | 33% ~00s |++++++++++++++++++++++++++++++++++ | 67% ~00s |++++++++++++++++++++++++++++++++++++++++++++++++++| 100% elapsed=00s 198s $`1` 198s [1] 51 198s 198s $`2` 198s [1] 57 198s 198s $`3` 198s [1] 45 198s 198s $`4` 198s NULL 198s 198s $`5` 198s NULL 198s 198s 198s pbpply> pbtapply(1:n, fac, range) 198s | | 0 % ~calculating |+++++++++++++++++ | 33% ~00s |++++++++++++++++++++++++++++++++++ | 67% ~00s |++++++++++++++++++++++++++++++++++++++++++++++++++| 100% elapsed=00s 198s $`1` 198s [1] 1 16 198s 198s $`2` 198s [1] 2 17 198s 198s $`3` 198s [1] 3 15 198s 198s $`4` 198s NULL 198s 198s $`5` 198s NULL 198s 198s 198s pbpply> pbtapply(1:n, fac, quantile) 198s | | 0 % ~calculating |+++++++++++++++++ | 33% ~00s |++++++++++++++++++++++++++++++++++ | 67% ~00s |++++++++++++++++++++++++++++++++++++++++++++++++++| 100% elapsed=00s 198s $`1` 198s 0% 25% 50% 75% 100% 198s 1.00 4.75 8.50 12.25 16.00 198s 198s $`2` 198s 0% 25% 50% 75% 100% 198s 2.00 5.75 9.50 13.25 17.00 198s 198s $`3` 198s 0% 25% 50% 75% 100% 198s 3 6 9 12 15 198s 198s $`4` 198s NULL 198s 198s $`5` 198s NULL 198s 198s 198s pbpply> pbtapply(1:n, fac, length) ## NA's 199s | | 0 % ~calculating |+++++++++++++++++ | 33% ~00s |++++++++++++++++++++++++++++++++++ | 67% ~00s |++++++++++++++++++++++++++++++++++++++++++++++++++| 100% elapsed=00s 199s 1 2 3 4 5 199s 6 6 5 NA NA 199s 199s pbpply> pbtapply(1:n, fac, length, default = 0) # == table(fac) 199s | | 0 % ~calculating |+++++++++++++++++ | 33% ~00s |++++++++++++++++++++++++++++++++++ | 67% ~00s |++++++++++++++++++++++++++++++++++++++++++++++++++| 100% elapsed=00s 199s 1 2 3 4 5 199s 6 6 5 0 0 199s 199s pbpply> ## example of ... argument: find quarterly means 199s pbpply> pbtapply(presidents, cycle(presidents), mean, na.rm = TRUE) 199s | | 0 % ~calculating |+++++++++++++ | 25% ~00s |+++++++++++++++++++++++++ | 50% ~00s |++++++++++++++++++++++++++++++++++++++ | 75% ~00s |++++++++++++++++++++++++++++++++++++++++++++++++++| 100% elapsed=00s 199s 1 2 3 4 199s 58.44828 56.43333 57.22222 53.07143 199s 199s pbpply> ind <- list(c(1, 2, 2), c("A", "A", "B")) 199s 199s pbpply> table(ind) 199s ind.2 199s ind.1 A B 199s 1 1 0 199s 2 1 1 199s 199s pbpply> pbtapply(1:3, ind) #-> the split vector 199s [1] 1 2 4 199s 199s pbpply> pbtapply(1:3, ind, sum) 199s | | 0 % ~calculating |+++++++++++++++++ | 33% ~00s |++++++++++++++++++++++++++++++++++ | 67% ~00s |++++++++++++++++++++++++++++++++++++++++++++++++++| 100% elapsed=00s 199s A B 199s 1 1 NA 199s 2 2 3 199s 199s pbpply> ## Some assertions (not held by all patch propsals): 199s pbpply> nq <- names(quantile(1:5)) 199s 199s pbpply> stopifnot( 199s pbpply+ identical(pbtapply(1:3, ind), c(1L, 2L, 4L)), 199s pbpply+ identical(pbtapply(1:3, ind, sum), 199s pbpply+ matrix(c(1L, 2L, NA, 3L), 2, dimnames = list(c("1", "2"), c("A", "B")))), 199s pbpply+ identical(pbtapply(1:n, fac, quantile)[-1], 199s pbpply+ array(list(`2` = structure(c(2, 5.75, 9.5, 13.25, 17), .Names = nq), 199s pbpply+ `3` = structure(c(3, 6, 9, 12, 15), .Names = nq), 199s pbpply+ `4` = NULL, `5` = NULL), dim=4, dimnames=list(as.character(2:5))))) 199s | | 0 % ~calculating |+++++++++++++++++ | 33% ~00s |++++++++++++++++++++++++++++++++++ | 67% ~00s |++++++++++++++++++++++++++++++++++++++++++++++++++| 100% elapsed=00s 199s | | 0 % ~calculating |+++++++++++++++++ | 33% ~00s |++++++++++++++++++++++++++++++++++ | 67% ~00s |++++++++++++++++++++++++++++++++++++++++++++++++++| 100% elapsed=00s 199s 199s pbpply> ## --- by --- 199s pbpply> 199s pbpply> pbby(warpbreaks[, 1:2], warpbreaks[,"tension"], summary) 199s | | 0 % ~calculating |+++++++++++++++++ | 33% ~00s |++++++++++++++++++++++++++++++++++ | 67% ~00s |++++++++++++++++++++++++++++++++++++++++++++++++++| 100% elapsed=00s 199s warpbreaks[, "tension"]: L 199s breaks wool 199s Min. :14.00 A:9 199s 1st Qu.:26.00 B:9 199s Median :29.50 199s Mean :36.39 199s 3rd Qu.:49.25 199s Max. :70.00 199s ------------------------------------------------------------ 199s warpbreaks[, "tension"]: M 199s breaks wool 199s Min. :12.00 A:9 199s 1st Qu.:18.25 B:9 199s Median :27.00 199s Mean :26.39 199s 3rd Qu.:33.75 199s Max. :42.00 199s ------------------------------------------------------------ 199s warpbreaks[, "tension"]: H 199s breaks wool 199s Min. :10.00 A:9 199s 1st Qu.:15.25 B:9 199s Median :20.50 199s Mean :21.67 199s 3rd Qu.:25.50 199s Max. :43.00 199s 199s pbpply> pbby(warpbreaks[, 1], warpbreaks[, -1], summary) 199s | | 0 % ~calculating |+++++++++ | 17% ~00s |+++++++++++++++++ | 33% ~00s |+++++++++++++++++++++++++ | 50% ~00s |++++++++++++++++++++++++++++++++++ | 67% ~00s |++++++++++++++++++++++++++++++++++++++++++ | 83% ~00s |++++++++++++++++++++++++++++++++++++++++++++++++++| 100% elapsed=00s 199s wool: A 199s tension: L 199s Min. 1st Qu. Median Mean 3rd Qu. Max. 199s 25.00 26.00 51.00 44.56 54.00 70.00 199s ------------------------------------------------------------ 199s wool: B 199s tension: L 199s Min. 1st Qu. Median Mean 3rd Qu. Max. 199s 14.00 20.00 29.00 28.22 31.00 44.00 199s ------------------------------------------------------------ 199s wool: A 199s tension: M 199s Min. 1st Qu. Median Mean 3rd Qu. Max. 199s 12 18 21 24 30 36 199s ------------------------------------------------------------ 199s wool: B 199s tension: M 199s Min. 1st Qu. Median Mean 3rd Qu. Max. 199s 16.00 21.00 28.00 28.78 39.00 42.00 199s ------------------------------------------------------------ 199s wool: A 199s tension: H 199s Min. 1st Qu. Median Mean 3rd Qu. Max. 199s 10.00 18.00 24.00 24.56 28.00 43.00 199s ------------------------------------------------------------ 199s wool: B 199s tension: H 199s Min. 1st Qu. Median Mean 3rd Qu. Max. 199s 13.00 15.00 17.00 18.78 21.00 28.00 199s 199s pbpply> pbby(warpbreaks, warpbreaks[,"tension"], 199s pbpply+ function(x) lm(breaks ~ wool, data = x)) 199s | | 0 % ~calculating |+++++++++++++++++ | 33% ~00s |++++++++++++++++++++++++++++++++++ | 67% ~00s |++++++++++++++++++++++++++++++++++++++++++++++++++| 100% elapsed=00s 199s warpbreaks[, "tension"]: L 199s 199s Call: 199s lm(formula = breaks ~ wool, data = x) 199s 199s Coefficients: 199s (Intercept) woolB 199s 44.56 -16.33 199s 199s ------------------------------------------------------------ 199s warpbreaks[, "tension"]: M 199s 199s Call: 199s lm(formula = breaks ~ wool, data = x) 199s 199s Coefficients: 199s (Intercept) woolB 199s 24.000 4.778 199s 199s ------------------------------------------------------------ 199s warpbreaks[, "tension"]: H 199s 199s Call: 199s lm(formula = breaks ~ wool, data = x) 199s 199s Coefficients: 199s (Intercept) woolB 199s 24.556 -5.778 199s 199s 199s pbpply> tmp <- with(warpbreaks, 199s pbpply+ pbby(warpbreaks, tension, 199s pbpply+ function(x) lm(breaks ~ wool, data = x))) 199s | | 0 % ~calculating |+++++++++++++++++ | 33% ~00s |++++++++++++++++++++++++++++++++++ | 67% ~00s |++++++++++++++++++++++++++++++++++++++++++++++++++| 100% elapsed=00s 199s 199s pbpply> sapply(tmp, coef) 199s L M H 199s (Intercept) 44.55556 24.000000 24.555556 199s woolB -16.33333 4.777778 -5.777778 199s > example(pboptions, run.dontrun = TRUE) 199s 199s pbptns> ## increase sluggishness to admire the progress bar longer 199s pbptns> sluggishness <- 0.01 199s 199s pbptns> ## for loop 199s pbptns> fun1 <- function() { 199s pbptns+ pb <- startpb(0, 10) 199s pbptns+ on.exit(closepb(pb)) 199s pbptns+ for (i in 1:10) { 199s pbptns+ Sys.sleep(sluggishness) 199s pbptns+ setpb(pb, i) 199s pbptns+ } 199s pbptns+ invisible(NULL) 199s pbptns+ } 199s 199s pbptns> ## while loop 199s pbptns> fun2 <- function() { 199s pbptns+ pb <- startpb(0, 10-1) 199s pbptns+ on.exit(closepb(pb)) 199s pbptns+ i <- 1 199s pbptns+ while (i < 10) { 199s pbptns+ Sys.sleep(sluggishness) 199s pbptns+ setpb(pb, i) 199s pbptns+ i <- i + 1 199s pbptns+ } 199s pbptns+ invisible(NULL) 199s pbptns+ } 199s 199s pbptns> ## using original settings 199s pbptns> fun1() 199s | | 0 % ~calculating |+++++ | 10% ~00s |++++++++++ | 20% ~00s |+++++++++++++++ | 30% ~00s |++++++++++++++++++++ | 40% ~00s |+++++++++++++++++++++++++ | 50% ~00s |++++++++++++++++++++++++++++++ | 60% ~00s |+++++++++++++++++++++++++++++++++++ | 70% ~00s |++++++++++++++++++++++++++++++++++++++++ | 80% ~00s |+++++++++++++++++++++++++++++++++++++++++++++ | 90% ~00s |++++++++++++++++++++++++++++++++++++++++++++++++++| 100% elapsed=00s 199s 199s pbptns> ## resetting pboptions 199s pbptns> opb <- pboptions(style = 1, char = ">") 199s 199s pbptns> ## check new settings 199s pbptns> getOption("pboptions") 199s $type 199s [1] "timer" 199s 199s $char 199s [1] ">" 199s 199s $txt.width 199s [1] 50 199s 199s $gui.width 199s [1] 300 199s 199s $style 199s [1] 1 199s 199s $initial 199s [1] 0 199s 199s $title 199s [1] "R progress bar" 199s 199s $label 199s [1] "" 199s 199s $nout 199s [1] 100 199s 199s $min_time 199s [1] 0 199s 199s $use_lb 199s [1] FALSE 199s 199s 199s pbptns> ## running again with new settings 199s pbptns> fun2() 199s | | 0 % elapsed=00s |>>>>>> | 11% elapsed=00s, remaining~00s |>>>>>>>>>>>> | 22% elapsed=00s, remaining~00s |>>>>>>>>>>>>>>>>> | 33% elapsed=00s, remaining~00s |>>>>>>>>>>>>>>>>>>>>>>> | 44% elapsed=00s, remaining~00s |>>>>>>>>>>>>>>>>>>>>>>>>>>>> | 56% elapsed=00s, remaining~00s |>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> | 67% elapsed=00s, remaining~00s |>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> | 78% elapsed=00s, remaining~00s |>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>> | 89% elapsed=00s, remaining~00s |>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>>| 100% elapsed=00s, remaining~00s 199s 199s pbptns> ## resetting original 199s pbptns> pboptions(opb) 199s 199s pbptns> ## check reset 199s pbptns> getOption("pboptions") 199s $type 199s [1] "timer" 199s 199s $char 199s [1] "+" 199s 199s $txt.width 199s [1] 50 199s 199s $gui.width 199s [1] 300 199s 199s $style 199s [1] 3 199s 199s $initial 199s [1] 0 199s 199s $title 199s [1] "R progress bar" 199s 199s $label 199s [1] "" 199s 199s $nout 199s [1] 100 199s 199s $min_time 199s [1] 0 199s 199s $use_lb 199s [1] FALSE 199s 199s 199s pbptns> fun1() 199s | | 0 % ~calculating |+++++ | 10% ~00s |++++++++++ | 20% ~00s |+++++++++++++++ | 30% ~00s |++++++++++++++++++++ | 40% ~00s |+++++++++++++++++++++++++ | 50% ~00s |++++++++++++++++++++++++++++++ | 60% ~00s |+++++++++++++++++++++++++++++++++++ | 70% ~00s |++++++++++++++++++++++++++++++++++++++++ | 80% ~00s |+++++++++++++++++++++++++++++++++++++++++++++ | 90% ~00s |++++++++++++++++++++++++++++++++++++++++++++++++++| 100% elapsed=00s 199s 199s pbptns> ## dealing with nested progress bars 199s pbptns> ## when only one the 1st one is needed 199s pbptns> f <- function(x) Sys.sleep(sluggishness) 199s 199s pbptns> g <- function(x) pblapply(1:10, f) 199s 199s pbptns> tmp <- lapply(1:10, g) # undesirable 199s | | 0 % ~calculating |+++++ | 10% ~00s |++++++++++ | 20% ~00s |+++++++++++++++ | 30% ~00s |++++++++++++++++++++ | 40% ~00s |+++++++++++++++++++++++++ | 50% ~00s |++++++++++++++++++++++++++++++ | 60% ~00s |+++++++++++++++++++++++++++++++++++ | 70% ~00s |++++++++++++++++++++++++++++++++++++++++ | 80% ~00s |+++++++++++++++++++++++++++++++++++++++++++++ | 90% ~00s |++++++++++++++++++++++++++++++++++++++++++++++++++| 100% elapsed=00s 199s | | 0 % ~calculating |+++++ | 10% ~00s |++++++++++ | 20% ~00s |+++++++++++++++ | 30% ~00s |++++++++++++++++++++ | 40% ~00s |+++++++++++++++++++++++++ | 50% ~00s |++++++++++++++++++++++++++++++ | 60% ~00s |+++++++++++++++++++++++++++++++++++ | 70% ~00s |++++++++++++++++++++++++++++++++++++++++ | 80% ~00s |+++++++++++++++++++++++++++++++++++++++++++++ | 90% ~00s |++++++++++++++++++++++++++++++++++++++++++++++++++| 100% elapsed=00s 199s | | 0 % ~calculating |+++++ | 10% ~00s |++++++++++ | 20% ~00s |+++++++++++++++ | 30% ~00s |++++++++++++++++++++ | 40% ~00s |+++++++++++++++++++++++++ | 50% ~00s |++++++++++++++++++++++++++++++ | 60% ~00s |+++++++++++++++++++++++++++++++++++ | 70% ~00s |++++++++++++++++++++++++++++++++++++++++ | 80% ~00s |+++++++++++++++++++++++++++++++++++++++++++++ | 90% ~00s |++++++++++++++++++++++++++++++++++++++++++++++++++| 100% elapsed=00s 199s | | 0 % ~calculating |+++++ | 10% ~00s |++++++++++ | 20% ~00s |+++++++++++++++ | 30% ~00s |++++++++++++++++++++ | 40% ~00s |+++++++++++++++++++++++++ | 50% ~00s |++++++++++++++++++++++++++++++ | 60% ~00s |+++++++++++++++++++++++++++++++++++ | 70% ~00s |++++++++++++++++++++++++++++++++++++++++ | 80% ~00s |+++++++++++++++++++++++++++++++++++++++++++++ | 90% ~00s |++++++++++++++++++++++++++++++++++++++++++++++++++| 100% elapsed=00s 199s | | 0 % ~calculating |+++++ | 10% ~00s |++++++++++ | 20% ~00s |+++++++++++++++ | 30% ~00s |++++++++++++++++++++ | 40% ~00s |+++++++++++++++++++++++++ | 50% ~00s |++++++++++++++++++++++++++++++ | 60% ~00s |+++++++++++++++++++++++++++++++++++ | 70% ~00s |++++++++++++++++++++++++++++++++++++++++ | 80% ~00s |+++++++++++++++++++++++++++++++++++++++++++++ | 90% ~00s |++++++++++++++++++++++++++++++++++++++++++++++++++| 100% elapsed=00s 200s | | 0 % ~calculating |+++++ | 10% ~00s |++++++++++ | 20% ~00s |+++++++++++++++ | 30% ~00s |++++++++++++++++++++ | 40% ~00s |+++++++++++++++++++++++++ | 50% ~00s |++++++++++++++++++++++++++++++ | 60% ~00s |+++++++++++++++++++++++++++++++++++ | 70% ~00s |++++++++++++++++++++++++++++++++++++++++ | 80% ~00s |+++++++++++++++++++++++++++++++++++++++++++++ | 90% ~00s |++++++++++++++++++++++++++++++++++++++++++++++++++| 100% elapsed=00s 200s | | 0 % ~calculating |+++++ | 10% ~00s |++++++++++ | 20% ~00s |+++++++++++++++ | 30% ~00s |++++++++++++++++++++ | 40% ~00s |+++++++++++++++++++++++++ | 50% ~00s |++++++++++++++++++++++++++++++ | 60% ~00s |+++++++++++++++++++++++++++++++++++ | 70% ~00s |++++++++++++++++++++++++++++++++++++++++ | 80% ~00s |+++++++++++++++++++++++++++++++++++++++++++++ | 90% ~00s |++++++++++++++++++++++++++++++++++++++++++++++++++| 100% elapsed=00s 200s | | 0 % ~calculating |+++++ | 10% ~00s |++++++++++ | 20% ~00s |+++++++++++++++ | 30% ~00s |++++++++++++++++++++ | 40% ~00s |+++++++++++++++++++++++++ | 50% ~00s |++++++++++++++++++++++++++++++ | 60% ~00s |+++++++++++++++++++++++++++++++++++ | 70% ~00s |++++++++++++++++++++++++++++++++++++++++ | 80% ~00s |+++++++++++++++++++++++++++++++++++++++++++++ | 90% ~00s |++++++++++++++++++++++++++++++++++++++++++++++++++| 100% elapsed=00s 200s | | 0 % ~calculating |+++++ | 10% ~00s |++++++++++ | 20% ~00s |+++++++++++++++ | 30% ~00s |++++++++++++++++++++ | 40% ~00s |+++++++++++++++++++++++++ | 50% ~00s |++++++++++++++++++++++++++++++ | 60% ~00s |+++++++++++++++++++++++++++++++++++ | 70% ~00s |++++++++++++++++++++++++++++++++++++++++ | 80% ~00s |+++++++++++++++++++++++++++++++++++++++++++++ | 90% ~00s |++++++++++++++++++++++++++++++++++++++++++++++++++| 100% elapsed=00s 200s | | 0 % ~calculating |+++++ | 10% ~00s |++++++++++ | 20% ~00s |+++++++++++++++ | 30% ~00s |++++++++++++++++++++ | 40% ~00s |+++++++++++++++++++++++++ | 50% ~00s |++++++++++++++++++++++++++++++ | 60% ~00s |+++++++++++++++++++++++++++++++++++ | 70% ~00s |++++++++++++++++++++++++++++++++++++++++ | 80% ~00s |+++++++++++++++++++++++++++++++++++++++++++++ | 90% ~00s |++++++++++++++++++++++++++++++++++++++++++++++++++| 100% elapsed=00s 200s 200s pbptns> ## here is the desirable solution 200s pbptns> h <- function(x) { 200s pbptns+ opb <- pboptions(type="none") 200s pbptns+ on.exit(pboptions(opb)) 200s pbptns+ pblapply(1:10, f) 200s pbptns+ } 200s 200s pbptns> tmp <- pblapply(1:10, h) 201s | | 0 % ~calculating |+++++ | 10% ~01s |++++++++++ | 20% ~01s |+++++++++++++++ | 30% ~01s |++++++++++++++++++++ | 40% ~01s |+++++++++++++++++++++++++ | 50% ~01s |++++++++++++++++++++++++++++++ | 60% ~00s |+++++++++++++++++++++++++++++++++++ | 70% ~00s |++++++++++++++++++++++++++++++++++++++++ | 80% ~00s |+++++++++++++++++++++++++++++++++++++++++++++ | 90% ~00s |++++++++++++++++++++++++++++++++++++++++++++++++++| 100% elapsed=01s 201s 201s pbptns> ## list available pb types 201s pbptns> pbtypes() 201s [1] "timer" "txt" "tk" "none" "shiny" 201s > 201s > ## check potential changes in formal arguments 201s > check_args <- function(fun1, fun2, cl=TRUE) { 201s + f1 <- formals(fun1) 201s + f2 <- formals(fun2) 201s + args1 <- names(f1) 201s + args2cl <- names(f2) 201s + args2 <- if (cl) 201s + args2cl[seq_len(length(args2cl)-1L)] else args2cl 201s + vals1 <- unname(f1) 201s + vals2cl <- unname(f2) 201s + vals2 <- if (cl) 201s + vals2cl[seq_len(length(vals2cl)-1L)] else vals2cl 201s + if (length(args1) != length(args2)) { 201s + msg <- c("Number of arguments is different:\n - fun1 [", 201s + length(args1), "]: ", paste0(args1, collapse=", "), 201s + "\n - fun2 [", 201s + length(args2), "]: ", paste0(args2, collapse=", ")) 201s + stop(paste0(msg, collapse="")) 201s + } 201s + if (!all(args1 == args2)) { 201s + msg <- c("Argument mismatches:\n - in fun1 but not fun2: ", 201s + paste0(setdiff(args1, args2), collapse=", "), 201s + "\n - in fun2 but not fun1: ", 201s + paste0(setdiff(args2, args1), collapse=", ")) 201s + stop(paste0(msg, collapse="")) 201s + } 201s + if (!all(sapply(1:length(vals1),function(i) identical(vals1[[i]], vals2[[i]])))) { 201s + msg <- c("Number of arguments is different:\n - fun1: ", 201s + paste0(vals1, collapse=", "), 201s + "\n - fun2: ", 201s + paste0(vals2, collapse=", ")) 201s + stop(paste0(msg, collapse="")) 201s + } 201s + invisible(TRUE) 201s + } 201s > 201s > check_args(lapply, pblapply) 201s > check_args(lapply, pbwalk) 201s > check_args(apply, pbapply) 201s > check_args(sapply, pbsapply) 201s > check_args(replicate, pbreplicate) 201s > check_args(tapply, pbtapply) 201s > check_args(eapply, pbeapply) 201s > check_args(vapply, pbvapply) 201s > check_args(by, pbby) 201s > 201s > check_args(mapply, pbmapply, cl=FALSE) 201s > check_args(Map, pbMap, cl=FALSE) 201s > check_args(.mapply, pb.mapply, cl=FALSE) 201s > 201s > ## --- test for NULL case in lapply --- 201s > 201s > l <- list(a = 1, 2, c = -1) 201s > f <- function(z) if (z < 0) return(NULL) else return(2 * z) 201s > r1 <- lapply(l, f) 201s > r2 <- pblapply(l, f) 201s | | 0 % ~calculating |+++++++++++++++++ | 33% ~00s |++++++++++++++++++++++++++++++++++ | 67% ~00s |++++++++++++++++++++++++++++++++++++++++++++++++++| 100% elapsed=00s 201s > r1 201s $a 201s [1] 2 201s 201s [[2]] 201s [1] 4 201s 201s $c 201s NULL 201s 201s > r2 201s $a 201s [1] 2 201s 201s [[2]] 201s [1] 4 201s 201s $c 201s NULL 201s 201s > stopifnot(identical(r1, r2)) 201s > 201s > ## --- timings --- 201s > 201s > if (FALSE) { 201s + 201s + #library(plyr) 201s + ## from http://ryouready.wordpress.com/2010/01/11/progress-bars-in-r-part-ii-a-wrapper-for-apply-functions/#comment-122 201s + lapply_pb <- 201s + function(X, FUN, ...) 201s + { 201s + env <- environment() 201s + pb_Total <- length(X) 201s + counter <- 0 201s + pb <- txtProgressBar(min = 0, max = pb_Total, style = 3) 201s + wrapper <- function(...){ 201s + curVal <- get("counter", envir = env) 201s + assign("counter", curVal +1 ,envir = env) 201s + setTxtProgressBar(get("pb", envir = env), curVal + 1) 201s + FUN(...) 201s + } 201s + res <- lapply(X, wrapper, ...) 201s + close(pb) 201s + res 201s + } 201s + 201s + i <- seq_len(100) 201s + t1 <- system.time(lapply(i, function(i) Sys.sleep(0.1))) 201s + t2 <- system.time(lapply_pb(i, function(i) Sys.sleep(0.1))) 201s + #t3 <- system.time(l_ply(i, function(i) Sys.sleep(0.1), .progress="text")) 201s + t4 <- system.time(pblapply(i, function(i) Sys.sleep(0.1))) 201s + 201s + } 201s > 201s > ## --- knitr related tests --- 201s > 201s > if (FALSE) { 201s + 201s + sink("~/repos/pbapply/tests/pb.Rmd") 201s + cat("--- 201s + title: \"Test pbapply with knitr\" 201s + date: \"`r format(Sys.time(), '%B %d, %Y')`\" 201s + output: pdf_document 201s + --- 201s + 201s + # Introduction 201s + 201s + Play nice! 201s + 201s + ```{r setup} 201s + library(knitr) 201s + library(pbapply) 201s + interactive() 201s + getOption(\"knitr.in.progress\") 201s + is.null(getOption(\"knitr.in.progress\")) 201s + pboptions()$type 201s + ``` 201s + 201s + ```{r chunk} 201s + pbsapply(1:100, function(z) {Sys.sleep(0.01); sqrt(z)}) 201s + ``` 201s + ") 201s + sink() 201s + #knitr::knit("~/repos/pbapply/tests/pb.Rmd", "~/repos/pbapply/tests/pb.md") 201s + unlink("~/repos/pbapply/tests/pb.Rmd") 201s + unlink("~/repos/pbapply/tests/pb.md") 201s + 201s + } 201s > 201s > ## --- tests for issue #17: single core in cl --- 201s > 201s > f <- function(i) Sys.sleep(0.1) 201s > 201s > library(parallel) 201s > cl <- makeCluster(1L) 201s > 201s > pblapply(1:10, f, cl = cl) 202s | | 0 % ~calculating |+++++ | 10% ~01s |++++++++++ | 20% ~01s |+++++++++++++++ | 30% ~01s |++++++++++++++++++++ | 40% ~01s |+++++++++++++++++++++++++ | 50% ~01s |++++++++++++++++++++++++++++++ | 60% ~00s |+++++++++++++++++++++++++++++++++++ | 70% ~00s |++++++++++++++++++++++++++++++++++++++++ | 80% ~00s |+++++++++++++++++++++++++++++++++++++++++++++ | 90% ~00s |++++++++++++++++++++++++++++++++++++++++++++++++++| 100% elapsed=01s 202s [[1]] 202s NULL 202s 202s [[2]] 202s NULL 202s 202s [[3]] 202s NULL 202s 202s [[4]] 202s NULL 202s 202s [[5]] 202s NULL 202s 202s [[6]] 202s NULL 202s 202s [[7]] 202s NULL 202s 202s [[8]] 202s NULL 202s 202s [[9]] 202s NULL 202s 202s [[10]] 202s NULL 202s 202s > 202s > stopCluster(cl) 202s > 202s > ## --- tests for issue #33: return empty list for empty vector --- 202s > 202s > tmp1 <- lapply(character(0), identity) 202s > tmp2 <- pblapply(character(0), identity) 202s > stopifnot(length(tmp1) == length(tmp2)) 202s > stopifnot(identical(tmp1, tmp2)) 202s > 202s > tmp1 <- sapply(character(0), identity) 202s > tmp2 <- pbsapply(character(0), identity) 202s > stopifnot(length(tmp1) == length(tmp2)) 202s > stopifnot(identical(tmp1, tmp2)) 202s > 202s > tmp1 <- apply(matrix(numeric(0), 0, 0), 1, identity) 202s > tmp2 <- pbapply(matrix(numeric(0), 0, 0), 1, identity) 202s > stopifnot(length(tmp1) == length(tmp2)) 202s > stopifnot(identical(tmp1, tmp2)) 202s > 202s > tmp1 <- apply(matrix(numeric(0), 0, 0), 2, identity) 202s > tmp2 <- pbapply(matrix(numeric(0), 0, 0), 2, identity) 202s > stopifnot(length(tmp1) == length(tmp2)) 202s > stopifnot(identical(tmp1, tmp2)) 202s > 202s > ## --- tests for issue #48: pbwalk --- 202s > 202s > tmp <- tempdir() 202s > # f <- function(i, dir) { 202s > # x <- rnorm(100) 202s > # png(file.path(dir, paste0("plot-", i, ".png"))) 202s > # hist(x, col=i) 202s > # dev.off() 202s > # x 202s > # } 202s > f <- function(i, dir) { 202s + x <- data.frame(i=i, j=rnorm(5)) 202s + write.csv(x, row.names=FALSE, file=file.path(dir, paste0("file-", i, ".csv"))) 202s + x 202s + } 202s > # pblapply(1:3, f, dir=tmp) 202s > pbwalk(1:3, f, dir=tmp) 202s | | 0 % ~calculating |+++++++++++++++++ | 33% ~00s |++++++++++++++++++++++++++++++++++ | 67% ~00s |++++++++++++++++++++++++++++++++++++++++++++++++++| 100% elapsed=00s 202s > # unlink(file.path(tmp, paste0("plot-", 1:3, ".png"))) 202s > unlink(file.path(tmp, paste0("file-", 1:3, ".csv"))) 202s > 202s > pbwalk(1:3, f, dir=tmp, cl=2) 202s | | 0 % ~calculating |+++++++++++++++++++++++++ | 50% ~00s |++++++++++++++++++++++++++++++++++++++++++++++++++| 100% elapsed=00s 202s > # unlink(file.path(tmp, paste0("plot-", 1:3, ".png"))) 202s > unlink(file.path(tmp, paste0("file-", 1:3, ".csv"))) 202s > 202s > cl <- parallel::makeCluster(2) 202s > pbwalk(1:3, f, dir=tmp, cl=cl) 203s | | 0 % ~calculating |+++++++++++++++++++++++++ | 50% ~00s |++++++++++++++++++++++++++++++++++++++++++++++++++| 100% elapsed=00s 203s > parallel::stopCluster(cl) 203s > # unlink(file.path(tmp, paste0("plot-", 1:3, ".png"))) 203s > unlink(file.path(tmp, paste0("file-", 1:3, ".csv"))) 203s > 203s > ## this could be a quartz issue ... 203s > # f <- function(i, dir) { 203s > # x <- rnorm(100) 203s > # png(file.path(dir, paste0("plot-", i, ".png"))) 203s > # hist(x, col=i) 203s > # dev.off() 203s > # x 203s > # } 203s > ## all this works 203s > # f(1, tmp) 203s > # pbapply::pblapply(1:3, f, dir=tmp) 203s > # pbapply::pbwalk(1:3, f, dir=tmp) 203s > # unlink(file.path(tmp, paste0("plot-", 1:3, ".png"))) 203s > ## all this does not 203s > # pbapply::pbwalk(1:3, f, dir=tmp, cl=2) 203s > # parallel::mclapply(1:3, f, dir=tmp, mc.cores=2) 203s > 203s > 203s > library(future) 203s > 203s > l <- list(a = 1, 2, c = -1) 203s > f <- function(z) { 203s + Sys.sleep(0.1) 203s + if (z < 0) return(NULL) else return(2 * z) 203s + } 203s > 203s > plan(sequential) 203s > r2 <- pblapply(l, f, cl = "future") 203s Loading required namespace: future.apply 203s | | 0 % ~calculating |+++++++++++++++++ | 33% ~00s |++++++++++++++++++++++++++++++++++ | 67% ~00s |++++++++++++++++++++++++++++++++++++++++++++++++++| 100% elapsed=00s 203s > 203s > plan(multisession, workers = 2) 204s > r2 <- pblapply(l, f, cl = "future") 204s | | 0 % ~calculating |+++++++++++++++++++++++++ | 50% ~00s |++++++++++++++++++++++++++++++++++++++++++++++++++| 100% elapsed=00s 204s > 204s > cl <- parallel::makeCluster(2) 204s > plan(cluster, workers = cl) 204s > r2 <- pblapply(l, f, cl = "future") 205s | | 0 % ~calculating |+++++++++++++++++++++++++ | 50% ~00s |++++++++++++++++++++++++++++++++++++++++++++++++++| 100% elapsed=00s 205s > parallel::stopCluster(cl) 205s > plan(sequential) 205s > 205s autopkgtest [10:47:49]: test run-unit-test: -----------------------] 205s run-unit-test PASS 205s autopkgtest [10:47:49]: test run-unit-test: - - - - - - - - - - results - - - - - - - - - - 205s autopkgtest [10:47:49]: test pkg-r-autopkgtest: preparing testbed 208s Note, using file '/tmp/autopkgtest.6yOvjE/3-autopkgtest-satdep.dsc' to get the build dependencies 208s Reading package lists... 208s Building dependency tree... 208s Reading state information... 208s Starting pkgProblemResolver with broken count: 0 208s Starting 2 pkgProblemResolver with broken count: 0 208s Done 209s The following NEW packages will be installed: 209s dctrl-tools gfortran gfortran-13 gfortran-13-x86-64-linux-gnu 209s gfortran-x86-64-linux-gnu icu-devtools libblas-dev libbz2-dev 209s libgfortran-13-dev libicu-dev libjpeg-dev libjpeg-turbo8-dev libjpeg8-dev 209s liblapack-dev liblzma-dev libncurses-dev libpcre2-16-0 libpcre2-32-0 209s libpcre2-dev libpcre2-posix3 libpkgconf3 libpng-dev libreadline-dev 209s pkg-config pkg-r-autopkgtest pkgconf pkgconf-bin r-base-dev r-cran-backports 209s r-cran-base64url r-cran-batchtools r-cran-brew r-cran-checkmate 209s r-cran-data.table r-cran-future.batchtools r-cran-hms r-cran-pkgconfig 209s r-cran-prettyunits r-cran-progress r-cran-stringi r-cran-vctrs zlib1g-dev 209s 0 upgraded, 42 newly installed, 0 to remove and 0 not upgraded. 209s Need to get 39.8 MB of archives. 209s After this operation, 141 MB of additional disk space will be used. 209s Get:1 http://ftpmaster.internal/ubuntu noble/main amd64 dctrl-tools amd64 2.24-3build2 [66.9 kB] 209s Get:2 http://ftpmaster.internal/ubuntu noble/main amd64 libgfortran-13-dev amd64 13.2.0-17ubuntu2 [942 kB] 209s Get:3 http://ftpmaster.internal/ubuntu noble/main amd64 gfortran-13-x86-64-linux-gnu amd64 13.2.0-17ubuntu2 [11.6 MB] 209s Get:4 http://ftpmaster.internal/ubuntu noble/main amd64 gfortran-13 amd64 13.2.0-17ubuntu2 [10.3 kB] 209s Get:5 http://ftpmaster.internal/ubuntu noble/main amd64 gfortran-x86-64-linux-gnu amd64 4:13.2.0-7ubuntu1 [1024 B] 209s Get:6 http://ftpmaster.internal/ubuntu noble/main amd64 gfortran amd64 4:13.2.0-7ubuntu1 [1176 B] 209s Get:7 http://ftpmaster.internal/ubuntu noble/main amd64 icu-devtools amd64 74.2-1ubuntu1 [212 kB] 209s Get:8 http://ftpmaster.internal/ubuntu noble/main amd64 libblas-dev amd64 3.12.0-3 [170 kB] 209s Get:9 http://ftpmaster.internal/ubuntu noble/main amd64 libbz2-dev amd64 1.0.8-5ubuntu1 [33.6 kB] 209s Get:10 http://ftpmaster.internal/ubuntu noble/main amd64 libicu-dev amd64 74.2-1ubuntu1 [11.9 MB] 209s Get:11 http://ftpmaster.internal/ubuntu noble/main amd64 libjpeg-turbo8-dev amd64 2.1.5-2ubuntu1 [294 kB] 209s Get:12 http://ftpmaster.internal/ubuntu noble/main amd64 libjpeg8-dev amd64 8c-2ubuntu11 [1484 B] 209s Get:13 http://ftpmaster.internal/ubuntu noble/main amd64 libjpeg-dev amd64 8c-2ubuntu11 [1482 B] 209s Get:14 http://ftpmaster.internal/ubuntu noble/main amd64 liblapack-dev amd64 3.12.0-3 [5196 kB] 209s Get:15 http://ftpmaster.internal/ubuntu noble/main amd64 libncurses-dev amd64 6.4+20240113-1ubuntu1 [384 kB] 209s Get:16 http://ftpmaster.internal/ubuntu noble/main amd64 libpcre2-16-0 amd64 10.42-4ubuntu1 [211 kB] 209s Get:17 http://ftpmaster.internal/ubuntu noble/main amd64 libpcre2-32-0 amd64 10.42-4ubuntu1 [198 kB] 209s Get:18 http://ftpmaster.internal/ubuntu noble/main amd64 libpcre2-posix3 amd64 10.42-4ubuntu1 [6808 B] 209s Get:19 http://ftpmaster.internal/ubuntu noble/main amd64 libpcre2-dev amd64 10.42-4ubuntu1 [743 kB] 209s Get:20 http://ftpmaster.internal/ubuntu noble/main amd64 libpkgconf3 amd64 1.8.1-2 [31.1 kB] 209s Get:21 http://ftpmaster.internal/ubuntu noble/main amd64 zlib1g-dev amd64 1:1.3.dfsg-3ubuntu1 [896 kB] 209s Get:22 http://ftpmaster.internal/ubuntu noble/main amd64 libpng-dev amd64 1.6.43-1 [264 kB] 209s Get:23 http://ftpmaster.internal/ubuntu noble/main amd64 libreadline-dev amd64 8.2-3 [167 kB] 209s Get:24 http://ftpmaster.internal/ubuntu noble/main amd64 pkgconf-bin amd64 1.8.1-2 [20.7 kB] 209s Get:25 http://ftpmaster.internal/ubuntu noble/main amd64 pkgconf amd64 1.8.1-2 [16.8 kB] 209s Get:26 http://ftpmaster.internal/ubuntu noble/main amd64 pkg-config amd64 1.8.1-2 [7170 B] 209s Get:27 http://ftpmaster.internal/ubuntu noble/main amd64 liblzma-dev amd64 5.4.5-0.3 [205 kB] 209s Get:28 http://ftpmaster.internal/ubuntu noble/universe amd64 r-base-dev all 4.3.2-1build1 [4336 B] 209s Get:29 http://ftpmaster.internal/ubuntu noble/universe amd64 pkg-r-autopkgtest all 20231212ubuntu1 [6448 B] 209s Get:30 http://ftpmaster.internal/ubuntu noble/universe amd64 r-cran-backports amd64 1.4.1-1 [101 kB] 209s Get:31 http://ftpmaster.internal/ubuntu noble/universe amd64 r-cran-base64url amd64 1.4-2build1 [26.5 kB] 209s Get:32 http://ftpmaster.internal/ubuntu noble/universe amd64 r-cran-brew all 1.0-10-1 [77.7 kB] 209s Get:33 http://ftpmaster.internal/ubuntu noble/universe amd64 r-cran-checkmate amd64 2.3.1-1 [713 kB] 209s Get:34 http://ftpmaster.internal/ubuntu noble/universe amd64 r-cran-data.table amd64 1.14.10+dfsg-1 [1837 kB] 209s Get:35 http://ftpmaster.internal/ubuntu noble/universe amd64 r-cran-pkgconfig all 2.0.3-2build1 [19.7 kB] 209s Get:36 http://ftpmaster.internal/ubuntu noble/universe amd64 r-cran-vctrs amd64 0.6.5-1 [1335 kB] 209s Get:37 http://ftpmaster.internal/ubuntu noble/universe amd64 r-cran-hms all 1.1.3-1 [96.5 kB] 209s Get:38 http://ftpmaster.internal/ubuntu noble/universe amd64 r-cran-prettyunits all 1.2.0-1 [162 kB] 209s Get:39 http://ftpmaster.internal/ubuntu noble/universe amd64 r-cran-progress all 1.2.3-1 [91.9 kB] 209s Get:40 http://ftpmaster.internal/ubuntu noble/universe amd64 r-cran-stringi amd64 1.8.3-1 [873 kB] 209s Get:41 http://ftpmaster.internal/ubuntu noble/universe amd64 r-cran-batchtools amd64 0.9.17+dfsg-1 [712 kB] 209s Get:42 http://ftpmaster.internal/ubuntu noble/universe amd64 r-cran-future.batchtools all 0.12.1+dfsg-1 [185 kB] 210s Fetched 39.8 MB in 0s (86.3 MB/s) 210s Selecting previously unselected package dctrl-tools. 210s (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 ... 82042 files and directories currently installed.) 210s Preparing to unpack .../00-dctrl-tools_2.24-3build2_amd64.deb ... 210s Unpacking dctrl-tools (2.24-3build2) ... 210s Selecting previously unselected package libgfortran-13-dev:amd64. 210s Preparing to unpack .../01-libgfortran-13-dev_13.2.0-17ubuntu2_amd64.deb ... 210s Unpacking libgfortran-13-dev:amd64 (13.2.0-17ubuntu2) ... 210s Selecting previously unselected package gfortran-13-x86-64-linux-gnu. 210s Preparing to unpack .../02-gfortran-13-x86-64-linux-gnu_13.2.0-17ubuntu2_amd64.deb ... 210s Unpacking gfortran-13-x86-64-linux-gnu (13.2.0-17ubuntu2) ... 210s Selecting previously unselected package gfortran-13. 210s Preparing to unpack .../03-gfortran-13_13.2.0-17ubuntu2_amd64.deb ... 210s Unpacking gfortran-13 (13.2.0-17ubuntu2) ... 210s Selecting previously unselected package gfortran-x86-64-linux-gnu. 210s Preparing to unpack .../04-gfortran-x86-64-linux-gnu_4%3a13.2.0-7ubuntu1_amd64.deb ... 210s Unpacking gfortran-x86-64-linux-gnu (4:13.2.0-7ubuntu1) ... 210s Selecting previously unselected package gfortran. 210s Preparing to unpack .../05-gfortran_4%3a13.2.0-7ubuntu1_amd64.deb ... 210s Unpacking gfortran (4:13.2.0-7ubuntu1) ... 210s Selecting previously unselected package icu-devtools. 210s Preparing to unpack .../06-icu-devtools_74.2-1ubuntu1_amd64.deb ... 210s Unpacking icu-devtools (74.2-1ubuntu1) ... 210s Selecting previously unselected package libblas-dev:amd64. 210s Preparing to unpack .../07-libblas-dev_3.12.0-3_amd64.deb ... 210s Unpacking libblas-dev:amd64 (3.12.0-3) ... 210s Selecting previously unselected package libbz2-dev:amd64. 210s Preparing to unpack .../08-libbz2-dev_1.0.8-5ubuntu1_amd64.deb ... 210s Unpacking libbz2-dev:amd64 (1.0.8-5ubuntu1) ... 210s Selecting previously unselected package libicu-dev:amd64. 210s Preparing to unpack .../09-libicu-dev_74.2-1ubuntu1_amd64.deb ... 210s Unpacking libicu-dev:amd64 (74.2-1ubuntu1) ... 210s Selecting previously unselected package libjpeg-turbo8-dev:amd64. 210s Preparing to unpack .../10-libjpeg-turbo8-dev_2.1.5-2ubuntu1_amd64.deb ... 210s Unpacking libjpeg-turbo8-dev:amd64 (2.1.5-2ubuntu1) ... 210s Selecting previously unselected package libjpeg8-dev:amd64. 210s Preparing to unpack .../11-libjpeg8-dev_8c-2ubuntu11_amd64.deb ... 210s Unpacking libjpeg8-dev:amd64 (8c-2ubuntu11) ... 211s Selecting previously unselected package libjpeg-dev:amd64. 211s Preparing to unpack .../12-libjpeg-dev_8c-2ubuntu11_amd64.deb ... 211s Unpacking libjpeg-dev:amd64 (8c-2ubuntu11) ... 211s Selecting previously unselected package liblapack-dev:amd64. 211s Preparing to unpack .../13-liblapack-dev_3.12.0-3_amd64.deb ... 211s Unpacking liblapack-dev:amd64 (3.12.0-3) ... 211s Selecting previously unselected package libncurses-dev:amd64. 211s Preparing to unpack .../14-libncurses-dev_6.4+20240113-1ubuntu1_amd64.deb ... 211s Unpacking libncurses-dev:amd64 (6.4+20240113-1ubuntu1) ... 211s Selecting previously unselected package libpcre2-16-0:amd64. 211s Preparing to unpack .../15-libpcre2-16-0_10.42-4ubuntu1_amd64.deb ... 211s Unpacking libpcre2-16-0:amd64 (10.42-4ubuntu1) ... 211s Selecting previously unselected package libpcre2-32-0:amd64. 211s Preparing to unpack .../16-libpcre2-32-0_10.42-4ubuntu1_amd64.deb ... 211s Unpacking libpcre2-32-0:amd64 (10.42-4ubuntu1) ... 211s Selecting previously unselected package libpcre2-posix3:amd64. 211s Preparing to unpack .../17-libpcre2-posix3_10.42-4ubuntu1_amd64.deb ... 211s Unpacking libpcre2-posix3:amd64 (10.42-4ubuntu1) ... 211s Selecting previously unselected package libpcre2-dev:amd64. 211s Preparing to unpack .../18-libpcre2-dev_10.42-4ubuntu1_amd64.deb ... 211s Unpacking libpcre2-dev:amd64 (10.42-4ubuntu1) ... 211s Selecting previously unselected package libpkgconf3:amd64. 211s Preparing to unpack .../19-libpkgconf3_1.8.1-2_amd64.deb ... 211s Unpacking libpkgconf3:amd64 (1.8.1-2) ... 211s Selecting previously unselected package zlib1g-dev:amd64. 211s Preparing to unpack .../20-zlib1g-dev_1%3a1.3.dfsg-3ubuntu1_amd64.deb ... 211s Unpacking zlib1g-dev:amd64 (1:1.3.dfsg-3ubuntu1) ... 211s Selecting previously unselected package libpng-dev:amd64. 211s Preparing to unpack .../21-libpng-dev_1.6.43-1_amd64.deb ... 211s Unpacking libpng-dev:amd64 (1.6.43-1) ... 211s Selecting previously unselected package libreadline-dev:amd64. 211s Preparing to unpack .../22-libreadline-dev_8.2-3_amd64.deb ... 211s Unpacking libreadline-dev:amd64 (8.2-3) ... 211s Selecting previously unselected package pkgconf-bin. 211s Preparing to unpack .../23-pkgconf-bin_1.8.1-2_amd64.deb ... 211s Unpacking pkgconf-bin (1.8.1-2) ... 211s Selecting previously unselected package pkgconf:amd64. 211s Preparing to unpack .../24-pkgconf_1.8.1-2_amd64.deb ... 211s Unpacking pkgconf:amd64 (1.8.1-2) ... 211s Selecting previously unselected package pkg-config:amd64. 211s Preparing to unpack .../25-pkg-config_1.8.1-2_amd64.deb ... 211s Unpacking pkg-config:amd64 (1.8.1-2) ... 211s Selecting previously unselected package liblzma-dev:amd64. 211s Preparing to unpack .../26-liblzma-dev_5.4.5-0.3_amd64.deb ... 211s Unpacking liblzma-dev:amd64 (5.4.5-0.3) ... 211s Selecting previously unselected package r-base-dev. 211s Preparing to unpack .../27-r-base-dev_4.3.2-1build1_all.deb ... 211s Unpacking r-base-dev (4.3.2-1build1) ... 211s Selecting previously unselected package pkg-r-autopkgtest. 211s Preparing to unpack .../28-pkg-r-autopkgtest_20231212ubuntu1_all.deb ... 211s Unpacking pkg-r-autopkgtest (20231212ubuntu1) ... 211s Selecting previously unselected package r-cran-backports. 211s Preparing to unpack .../29-r-cran-backports_1.4.1-1_amd64.deb ... 211s Unpacking r-cran-backports (1.4.1-1) ... 211s Selecting previously unselected package r-cran-base64url. 211s Preparing to unpack .../30-r-cran-base64url_1.4-2build1_amd64.deb ... 211s Unpacking r-cran-base64url (1.4-2build1) ... 211s Selecting previously unselected package r-cran-brew. 211s Preparing to unpack .../31-r-cran-brew_1.0-10-1_all.deb ... 211s Unpacking r-cran-brew (1.0-10-1) ... 211s Selecting previously unselected package r-cran-checkmate. 211s Preparing to unpack .../32-r-cran-checkmate_2.3.1-1_amd64.deb ... 211s Unpacking r-cran-checkmate (2.3.1-1) ... 211s Selecting previously unselected package r-cran-data.table. 211s Preparing to unpack .../33-r-cran-data.table_1.14.10+dfsg-1_amd64.deb ... 211s Unpacking r-cran-data.table (1.14.10+dfsg-1) ... 211s Selecting previously unselected package r-cran-pkgconfig. 211s Preparing to unpack .../34-r-cran-pkgconfig_2.0.3-2build1_all.deb ... 211s Unpacking r-cran-pkgconfig (2.0.3-2build1) ... 211s Selecting previously unselected package r-cran-vctrs. 211s Preparing to unpack .../35-r-cran-vctrs_0.6.5-1_amd64.deb ... 211s Unpacking r-cran-vctrs (0.6.5-1) ... 211s Selecting previously unselected package r-cran-hms. 211s Preparing to unpack .../36-r-cran-hms_1.1.3-1_all.deb ... 211s Unpacking r-cran-hms (1.1.3-1) ... 211s Selecting previously unselected package r-cran-prettyunits. 211s Preparing to unpack .../37-r-cran-prettyunits_1.2.0-1_all.deb ... 211s Unpacking r-cran-prettyunits (1.2.0-1) ... 211s Selecting previously unselected package r-cran-progress. 211s Preparing to unpack .../38-r-cran-progress_1.2.3-1_all.deb ... 211s Unpacking r-cran-progress (1.2.3-1) ... 212s Selecting previously unselected package r-cran-stringi. 212s Preparing to unpack .../39-r-cran-stringi_1.8.3-1_amd64.deb ... 212s Unpacking r-cran-stringi (1.8.3-1) ... 212s Selecting previously unselected package r-cran-batchtools. 212s Preparing to unpack .../40-r-cran-batchtools_0.9.17+dfsg-1_amd64.deb ... 212s Unpacking r-cran-batchtools (0.9.17+dfsg-1) ... 212s Selecting previously unselected package r-cran-future.batchtools. 212s Preparing to unpack .../41-r-cran-future.batchtools_0.12.1+dfsg-1_all.deb ... 212s Unpacking r-cran-future.batchtools (0.12.1+dfsg-1) ... 212s Setting up libjpeg-turbo8-dev:amd64 (2.1.5-2ubuntu1) ... 212s Setting up libncurses-dev:amd64 (6.4+20240113-1ubuntu1) ... 212s Setting up r-cran-backports (1.4.1-1) ... 212s Setting up r-cran-prettyunits (1.2.0-1) ... 212s Setting up r-cran-checkmate (2.3.1-1) ... 212s Setting up libreadline-dev:amd64 (8.2-3) ... 212s Setting up r-cran-data.table (1.14.10+dfsg-1) ... 212s Setting up libpcre2-16-0:amd64 (10.42-4ubuntu1) ... 212s Setting up r-cran-pkgconfig (2.0.3-2build1) ... 212s Setting up libpcre2-32-0:amd64 (10.42-4ubuntu1) ... 212s Setting up r-cran-brew (1.0-10-1) ... 212s Setting up libpkgconf3:amd64 (1.8.1-2) ... 212s Setting up r-cran-stringi (1.8.3-1) ... 212s Setting up icu-devtools (74.2-1ubuntu1) ... 212s Setting up pkgconf-bin (1.8.1-2) ... 212s Setting up liblzma-dev:amd64 (5.4.5-0.3) ... 212s Setting up zlib1g-dev:amd64 (1:1.3.dfsg-3ubuntu1) ... 212s Setting up libpcre2-posix3:amd64 (10.42-4ubuntu1) ... 212s Setting up libjpeg8-dev:amd64 (8c-2ubuntu11) ... 212s Setting up libgfortran-13-dev:amd64 (13.2.0-17ubuntu2) ... 212s Setting up libicu-dev:amd64 (74.2-1ubuntu1) ... 212s Setting up r-cran-vctrs (0.6.5-1) ... 212s Setting up libblas-dev:amd64 (3.12.0-3) ... 212s update-alternatives: using /usr/lib/x86_64-linux-gnu/blas/libblas.so to provide /usr/lib/x86_64-linux-gnu/libblas.so (libblas.so-x86_64-linux-gnu) in auto mode 212s Setting up dctrl-tools (2.24-3build2) ... 212s Setting up libbz2-dev:amd64 (1.0.8-5ubuntu1) ... 212s Setting up r-cran-base64url (1.4-2build1) ... 212s Setting up libpcre2-dev:amd64 (10.42-4ubuntu1) ... 212s Setting up libpng-dev:amd64 (1.6.43-1) ... 212s Setting up libjpeg-dev:amd64 (8c-2ubuntu11) ... 212s Setting up gfortran-13-x86-64-linux-gnu (13.2.0-17ubuntu2) ... 212s Setting up pkgconf:amd64 (1.8.1-2) ... 212s Setting up gfortran-13 (13.2.0-17ubuntu2) ... 212s Setting up r-cran-hms (1.1.3-1) ... 212s Setting up liblapack-dev:amd64 (3.12.0-3) ... 212s update-alternatives: using /usr/lib/x86_64-linux-gnu/lapack/liblapack.so to provide /usr/lib/x86_64-linux-gnu/liblapack.so (liblapack.so-x86_64-linux-gnu) in auto mode 212s Setting up pkg-config:amd64 (1.8.1-2) ... 212s Setting up r-cran-progress (1.2.3-1) ... 212s Setting up gfortran-x86-64-linux-gnu (4:13.2.0-7ubuntu1) ... 212s Setting up gfortran (4:13.2.0-7ubuntu1) ... 212s update-alternatives: using /usr/bin/gfortran to provide /usr/bin/f95 (f95) in auto mode 212s 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 212s update-alternatives: using /usr/bin/gfortran to provide /usr/bin/f77 (f77) in auto mode 212s 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 212s Setting up r-cran-batchtools (0.9.17+dfsg-1) ... 212s Setting up r-base-dev (4.3.2-1build1) ... 212s Setting up r-cran-future.batchtools (0.12.1+dfsg-1) ... 212s Setting up pkg-r-autopkgtest (20231212ubuntu1) ... 212s Processing triggers for libc-bin (2.39-0ubuntu6) ... 212s Processing triggers for man-db (2.12.0-3) ... 212s Processing triggers for install-info (7.1-3) ... 220s Reading package lists... 220s Building dependency tree... 220s Reading state information... 220s Starting pkgProblemResolver with broken count: 0 221s Starting 2 pkgProblemResolver with broken count: 0 221s Done 221s The following NEW packages will be installed: 221s autopkgtest-satdep 221s 0 upgraded, 1 newly installed, 0 to remove and 0 not upgraded. 221s Need to get 0 B/704 B of archives. 221s After this operation, 0 B of additional disk space will be used. 221s Get:1 /tmp/autopkgtest.6yOvjE/4-autopkgtest-satdep.deb autopkgtest-satdep amd64 0 [704 B] 221s Selecting previously unselected package autopkgtest-satdep. 221s (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 ... 83837 files and directories currently installed.) 221s Preparing to unpack .../4-autopkgtest-satdep.deb ... 221s Unpacking autopkgtest-satdep (0) ... 221s Setting up autopkgtest-satdep (0) ... 223s (Reading database ... 83837 files and directories currently installed.) 223s Removing autopkgtest-satdep (0) ... 223s autopkgtest [10:48:07]: test pkg-r-autopkgtest: /usr/share/dh-r/pkg-r-autopkgtest 223s autopkgtest [10:48:07]: test pkg-r-autopkgtest: [----------------------- 223s Test: Try to load the R library pbapply 223s 223s R version 4.3.2 (2023-10-31) -- "Eye Holes" 223s Copyright (C) 2023 The R Foundation for Statistical Computing 223s Platform: x86_64-pc-linux-gnu (64-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('pbapply') 223s > 223s > 223s Other tests are currently unsupported! 223s They will be progressively added. 224s autopkgtest [10:48:08]: test pkg-r-autopkgtest: -----------------------] 224s pkg-r-autopkgtest PASS 224s autopkgtest [10:48:08]: test pkg-r-autopkgtest: - - - - - - - - - - results - - - - - - - - - - 224s autopkgtest [10:48:08]: @@@@@@@@@@@@@@@@@@@@ summary 224s run-unit-test PASS 224s pkg-r-autopkgtest PASS 234s Creating nova instance adt-noble-i386-r-cran-pbapply-20240323-103841-juju-7f2275-prod-proposed-migration-environment-2 from image adt/ubuntu-noble-amd64-server-20240323.img (UUID 5df8a563-0957-4fdd-8453-862df650aaf8)...