0s autopkgtest [05:19:56]: starting date and time: 2025-02-16 05:19:56+0000 0s autopkgtest [05:19:56]: git checkout: 325255d2 Merge branch 'pin-any-arch' into 'ubuntu/production' 0s autopkgtest [05:19:56]: host juju-7f2275-prod-proposed-migration-environment-20; command line: /home/ubuntu/autopkgtest/runner/autopkgtest --output-dir /tmp/autopkgtest-work.u_5ko4zv/out --timeout-copy=6000 --setup-commands /home/ubuntu/autopkgtest-cloud/worker-config-production/setup-canonical.sh --apt-pocket=proposed=src:glibc,src:iproute2,src:php-twig,src:postgresql-17,src:postgresql-common,src:roundcube --apt-upgrade octave-statistics --timeout-short=300 --timeout-copy=20000 --timeout-build=20000 '--env=ADT_TEST_TRIGGERS=glibc/2.41-1ubuntu1 iproute2/6.13.0-1ubuntu1 php-twig/3.19.0-1 postgresql-17/17.3-2 postgresql-common/273 roundcube/1.6.10+dfsg-1' -- ssh -s /home/ubuntu/autopkgtest/ssh-setup/nova -- --flavor autopkgtest-ppc64el --security-groups autopkgtest-juju-7f2275-prod-proposed-migration-environment-20@bos03-ppc64el-3.secgroup --name adt-plucky-ppc64el-octave-statistics-20250216-051956-juju-7f2275-prod-proposed-migration-environment-20-1b0431f3-1496-4789-bd4b-32efe8382e14 --image adt/ubuntu-plucky-ppc64el-server --keyname testbed-juju-7f2275-prod-proposed-migration-environment-20 --net-id=net_prod-proposed-migration-ppc64el -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,keyserver.ubuntu.com,launchpadlibrarian.net,launchpadcontent.net,launchpad.net,10.24.0.0/24,keystone.ps5.canonical.com,objectstorage.prodstack5.canonical.com,radosgw.ps5.canonical.com'"'"'' --mirror=http://ftpmaster.internal/ubuntu/ 118s autopkgtest [05:21:54]: testbed dpkg architecture: ppc64el 118s autopkgtest [05:21:54]: testbed apt version: 2.9.28 119s autopkgtest [05:21:55]: @@@@@@@@@@@@@@@@@@@@ test bed setup 119s autopkgtest [05:21:55]: testbed release detected to be: None 120s autopkgtest [05:21:56]: updating testbed package index (apt update) 120s Get:1 http://ftpmaster.internal/ubuntu plucky-proposed InRelease [110 kB] 120s Hit:2 http://ftpmaster.internal/ubuntu plucky InRelease 120s Hit:3 http://ftpmaster.internal/ubuntu plucky-updates InRelease 120s Hit:4 http://ftpmaster.internal/ubuntu plucky-security InRelease 120s Get:5 http://ftpmaster.internal/ubuntu plucky-proposed/universe Sources [810 kB] 121s Get:6 http://ftpmaster.internal/ubuntu plucky-proposed/main Sources [73.0 kB] 121s Get:7 http://ftpmaster.internal/ubuntu plucky-proposed/restricted Sources [3120 B] 121s Get:8 http://ftpmaster.internal/ubuntu plucky-proposed/multiverse Sources [13.1 kB] 121s Get:9 http://ftpmaster.internal/ubuntu plucky-proposed/main ppc64el Packages [167 kB] 121s Get:10 http://ftpmaster.internal/ubuntu plucky-proposed/restricted ppc64el Packages [760 B] 121s Get:11 http://ftpmaster.internal/ubuntu plucky-proposed/universe ppc64el Packages [902 kB] 121s Get:12 http://ftpmaster.internal/ubuntu plucky-proposed/multiverse ppc64el Packages [4228 B] 121s Fetched 2084 kB in 1s (1847 kB/s) 122s Reading package lists... 122s Reading package lists... 123s Building dependency tree... 123s Reading state information... 123s Calculating upgrade... 123s The following packages will be upgraded: 123s dash gcc-14-base libatomic1 libgcc-s1 libp11-kit0 libstdc++6 libtasn1-6 123s libxdmcp6 123s 8 upgraded, 0 newly installed, 0 to remove and 0 not upgraded. 123s Need to get 1476 kB of archives. 123s After this operation, 15.4 kB of additional disk space will be used. 123s Get:1 http://ftpmaster.internal/ubuntu plucky/main ppc64el dash ppc64el 0.5.12-12ubuntu1 [114 kB] 123s Get:2 http://ftpmaster.internal/ubuntu plucky/main ppc64el libatomic1 ppc64el 14.2.0-17ubuntu1 [10.7 kB] 123s Get:3 http://ftpmaster.internal/ubuntu plucky/main ppc64el gcc-14-base ppc64el 14.2.0-17ubuntu1 [53.6 kB] 123s Get:4 http://ftpmaster.internal/ubuntu plucky/main ppc64el libstdc++6 ppc64el 14.2.0-17ubuntu1 [886 kB] 123s Get:5 http://ftpmaster.internal/ubuntu plucky/main ppc64el libgcc-s1 ppc64el 14.2.0-17ubuntu1 [39.2 kB] 123s Get:6 http://ftpmaster.internal/ubuntu plucky/main ppc64el libp11-kit0 ppc64el 0.25.5-2ubuntu2 [305 kB] 123s Get:7 http://ftpmaster.internal/ubuntu plucky/main ppc64el libtasn1-6 ppc64el 4.20.0-2 [55.9 kB] 123s Get:8 http://ftpmaster.internal/ubuntu plucky/main ppc64el libxdmcp6 ppc64el 1:1.1.5-1 [11.6 kB] 124s Preconfiguring packages ... 124s Fetched 1476 kB in 1s (2437 kB/s) 124s (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 ... 106311 files and directories currently installed.) 124s Preparing to unpack .../dash_0.5.12-12ubuntu1_ppc64el.deb ... 124s Unpacking dash (0.5.12-12ubuntu1) over (0.5.12-9ubuntu1) ... 124s Setting up dash (0.5.12-12ubuntu1) ... 124s (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 ... 106311 files and directories currently installed.) 124s Preparing to unpack .../libatomic1_14.2.0-17ubuntu1_ppc64el.deb ... 124s Unpacking libatomic1:ppc64el (14.2.0-17ubuntu1) over (14.2.0-16ubuntu1) ... 124s Preparing to unpack .../gcc-14-base_14.2.0-17ubuntu1_ppc64el.deb ... 124s Unpacking gcc-14-base:ppc64el (14.2.0-17ubuntu1) over (14.2.0-16ubuntu1) ... 124s Setting up gcc-14-base:ppc64el (14.2.0-17ubuntu1) ... 124s (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 ... 106311 files and directories currently installed.) 124s Preparing to unpack .../libstdc++6_14.2.0-17ubuntu1_ppc64el.deb ... 124s Unpacking libstdc++6:ppc64el (14.2.0-17ubuntu1) over (14.2.0-16ubuntu1) ... 124s Setting up libstdc++6:ppc64el (14.2.0-17ubuntu1) ... 125s (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 ... 106311 files and directories currently installed.) 125s Preparing to unpack .../libgcc-s1_14.2.0-17ubuntu1_ppc64el.deb ... 125s Unpacking libgcc-s1:ppc64el (14.2.0-17ubuntu1) over (14.2.0-16ubuntu1) ... 125s Setting up libgcc-s1:ppc64el (14.2.0-17ubuntu1) ... 125s (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 ... 106311 files and directories currently installed.) 125s Preparing to unpack .../libp11-kit0_0.25.5-2ubuntu2_ppc64el.deb ... 125s Unpacking libp11-kit0:ppc64el (0.25.5-2ubuntu2) over (0.25.5-2ubuntu1) ... 125s Preparing to unpack .../libtasn1-6_4.20.0-2_ppc64el.deb ... 125s Unpacking libtasn1-6:ppc64el (4.20.0-2) over (4.19.0-3build1) ... 125s Preparing to unpack .../libxdmcp6_1%3a1.1.5-1_ppc64el.deb ... 125s Unpacking libxdmcp6:ppc64el (1:1.1.5-1) over (1:1.1.3-0ubuntu6) ... 125s Setting up libxdmcp6:ppc64el (1:1.1.5-1) ... 125s Setting up libp11-kit0:ppc64el (0.25.5-2ubuntu2) ... 125s Setting up libatomic1:ppc64el (14.2.0-17ubuntu1) ... 125s Setting up libtasn1-6:ppc64el (4.20.0-2) ... 125s Processing triggers for libc-bin (2.40-4ubuntu1) ... 125s Processing triggers for man-db (2.13.0-1) ... 125s Processing triggers for debianutils (5.21) ... 125s Reading package lists... 126s Building dependency tree... 126s Reading state information... 126s 0 upgraded, 0 newly installed, 0 to remove and 6 not upgraded. 126s autopkgtest [05:22:02]: upgrading testbed (apt dist-upgrade and autopurge) 126s Reading package lists... 126s Building dependency tree... 126s Reading state information... 126s Calculating upgrade...Starting pkgProblemResolver with broken count: 0 127s Starting 2 pkgProblemResolver with broken count: 0 127s Done 127s Entering ResolveByKeep 127s 127s The following packages will be upgraded: 127s iproute2 libc-bin libc-dev-bin libc6 libc6-dev locales 127s 6 upgraded, 0 newly installed, 0 to remove and 0 not upgraded. 127s Need to get 11.7 MB of archives. 127s After this operation, 358 kB of additional disk space will be used. 127s Get:1 http://ftpmaster.internal/ubuntu plucky-proposed/main ppc64el libc-dev-bin ppc64el 2.41-1ubuntu1 [25.3 kB] 128s Get:2 http://ftpmaster.internal/ubuntu plucky-proposed/main ppc64el libc6-dev ppc64el 2.41-1ubuntu1 [2046 kB] 128s Get:3 http://ftpmaster.internal/ubuntu plucky-proposed/main ppc64el locales all 2.41-1ubuntu1 [4246 kB] 128s Get:4 http://ftpmaster.internal/ubuntu plucky-proposed/main ppc64el libc6 ppc64el 2.41-1ubuntu1 [3243 kB] 128s Get:5 http://ftpmaster.internal/ubuntu plucky-proposed/main ppc64el libc-bin ppc64el 2.41-1ubuntu1 [742 kB] 128s Get:6 http://ftpmaster.internal/ubuntu plucky-proposed/main ppc64el iproute2 ppc64el 6.13.0-1ubuntu1 [1419 kB] 129s Preconfiguring packages ... 129s Fetched 11.7 MB in 1s (10.8 MB/s) 129s (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 ... 106311 files and directories currently installed.) 129s Preparing to unpack .../libc-dev-bin_2.41-1ubuntu1_ppc64el.deb ... 129s Unpacking libc-dev-bin (2.41-1ubuntu1) over (2.40-4ubuntu1) ... 129s Preparing to unpack .../libc6-dev_2.41-1ubuntu1_ppc64el.deb ... 129s Unpacking libc6-dev:ppc64el (2.41-1ubuntu1) over (2.40-4ubuntu1) ... 129s Preparing to unpack .../locales_2.41-1ubuntu1_all.deb ... 129s Unpacking locales (2.41-1ubuntu1) over (2.40-4ubuntu1) ... 129s Preparing to unpack .../libc6_2.41-1ubuntu1_ppc64el.deb ... 129s Checking for services that may need to be restarted... 129s Checking init scripts... 129s Checking for services that may need to be restarted... 129s Checking init scripts... 129s Stopping some services possibly affected by the upgrade (will be restarted later): 129s cron: stopping...done. 129s 129s Unpacking libc6:ppc64el (2.41-1ubuntu1) over (2.40-4ubuntu1) ... 130s Setting up libc6:ppc64el (2.41-1ubuntu1) ... 130s Checking for services that may need to be restarted... 130s Checking init scripts... 130s Restarting services possibly affected by the upgrade: 130s cron: restarting...done. 130s 130s Services restarted successfully. 130s (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 ... 106312 files and directories currently installed.) 130s Preparing to unpack .../libc-bin_2.41-1ubuntu1_ppc64el.deb ... 130s Unpacking libc-bin (2.41-1ubuntu1) over (2.40-4ubuntu1) ... 130s Setting up libc-bin (2.41-1ubuntu1) ... 130s (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 ... 106312 files and directories currently installed.) 130s Preparing to unpack .../iproute2_6.13.0-1ubuntu1_ppc64el.deb ... 130s Unpacking iproute2 (6.13.0-1ubuntu1) over (6.10.0-2ubuntu1) ... 130s Setting up iproute2 (6.13.0-1ubuntu1) ... 131s Setting up locales (2.41-1ubuntu1) ... 131s Installing new version of config file /etc/locale.alias ... 131s Generating locales (this might take a while)... 133s en_US.UTF-8... done 133s Generation complete. 133s Setting up libc-dev-bin (2.41-1ubuntu1) ... 133s Setting up libc6-dev:ppc64el (2.41-1ubuntu1) ... 133s Processing triggers for man-db (2.13.0-1) ... 134s Processing triggers for systemd (257.2-3ubuntu1) ... 135s Reading package lists... 135s Building dependency tree... 135s Reading state information... 135s Starting pkgProblemResolver with broken count: 0 135s Starting 2 pkgProblemResolver with broken count: 0 135s Done 135s 0 upgraded, 0 newly installed, 0 to remove and 0 not upgraded. 138s autopkgtest [05:22:14]: testbed running kernel: Linux 6.12.0-15-generic #15-Ubuntu SMP Tue Feb 4 16:32:08 UTC 2025 138s autopkgtest [05:22:14]: @@@@@@@@@@@@@@@@@@@@ apt-source octave-statistics 140s Get:1 http://ftpmaster.internal/ubuntu plucky/universe octave-statistics 1.7.2-1 (dsc) [2436 B] 140s Get:2 http://ftpmaster.internal/ubuntu plucky/universe octave-statistics 1.7.2-1 (tar) [1296 kB] 140s Get:3 http://ftpmaster.internal/ubuntu plucky/universe octave-statistics 1.7.2-1 (diff) [10.9 kB] 140s gpgv: Signature made Thu Feb 6 05:39:34 2025 UTC 140s gpgv: using RSA key 3F464391498FE874BDB5D98F2124AA1983785C90 140s gpgv: issuer "rafael@debian.org" 140s gpgv: Can't check signature: No public key 140s dpkg-source: warning: cannot verify inline signature for ./octave-statistics_1.7.2-1.dsc: no acceptable signature found 140s autopkgtest [05:22:16]: testing package octave-statistics version 1.7.2-1 141s autopkgtest [05:22:17]: build not needed 142s autopkgtest [05:22:18]: test command1: preparing testbed 142s Reading package lists... 142s Building dependency tree... 142s Reading state information... 142s Starting pkgProblemResolver with broken count: 0 142s Starting 2 pkgProblemResolver with broken count: 0 142s Done 143s The following NEW packages will be installed: 143s aglfn appstream autoconf automake autopoint autotools-dev cme comerr-dev cpp 143s cpp-14 cpp-14-powerpc64le-linux-gnu cpp-powerpc64le-linux-gnu debhelper 143s debugedit dh-autoreconf dh-octave dh-octave-autopkgtest 143s dh-strip-nondeterminism diffstat dwz fontconfig fontconfig-config 143s fonts-dejavu-core fonts-dejavu-mono fonts-freefont-otf g++ g++-14 143s g++-14-powerpc64le-linux-gnu g++-powerpc64le-linux-gnu gcc gcc-14 143s gcc-14-powerpc64le-linux-gnu gcc-powerpc64le-linux-gnu gettext gfortran 143s gfortran-14 gfortran-14-powerpc64le-linux-gnu gfortran-powerpc64le-linux-gnu 143s gnuplot-data gnuplot-nox hdf5-helpers intltool-debian krb5-multidev 143s libaec-dev libaec0 libalgorithm-c3-perl libaliased-perl libamd3 libaom3 143s libapp-cmd-perl libappstream5 libapt-pkg-perl libarchive-zip-perl 143s libarpack2t64 libarray-intspan-perl libasan8 libasound2-data libasound2t64 143s libavahi-client3 libavahi-common-data libavahi-common3 143s libb-hooks-endofscope-perl libb-hooks-op-check-perl libb2-1 143s libberkeleydb-perl libblas-dev libblas3 libboolean-perl libbrotli-dev 143s libcairo2 libcamd3 libcapture-tiny-perl libcarp-assert-more-perl libcc1-0 143s libccolamd3 libcgi-pm-perl libcholmod5 libclass-c3-perl 143s libclass-data-inheritable-perl libclass-inspector-perl libclass-load-perl 143s libclass-method-modifiers-perl libclass-xsaccessor-perl libclone-choose-perl 143s libclone-perl libcolamd3 libconfig-model-backend-yaml-perl 143s libconfig-model-dpkg-perl libconfig-model-perl libconfig-tiny-perl 143s libconst-fast-perl libconvert-binhex-perl libcpanel-json-xs-perl libcups2t64 143s libcurl4-openssl-dev libcxsparse4 libdata-dpath-perl 143s libdata-messagepack-perl libdata-optlist-perl libdata-section-perl 143s libdata-validate-domain-perl libdata-validate-ip-perl 143s libdata-validate-uri-perl libdatrie1 libde265-0 libdebhelper-perl 143s libdeflate0 libdevel-callchecker-perl libdevel-size-perl 143s libdevel-stacktrace-perl libdouble-conversion3 libdrm-radeon1 libduktape207 143s libdynaloader-functions-perl libegl-mesa0 libegl1 libemail-address-xs-perl 143s libencode-locale-perl liberror-perl libevent-2.1-7t64 143s libexception-class-perl libexporter-lite-perl libexporter-tiny-perl 143s libfftw3-bin libfftw3-dev libfftw3-double3 libfftw3-long3 libfftw3-single3 143s libfile-basedir-perl libfile-find-rule-perl libfile-homedir-perl 143s libfile-listing-perl libfile-sharedir-perl libfile-stripnondeterminism-perl 143s libfile-which-perl libflac12t64 libfltk-gl1.3t64 libfltk1.3t64 143s libfont-ttf-perl libfontconfig1 libfontenc1 libgbm1 libgcc-14-dev libgd3 143s libgetopt-long-descriptive-perl libgfortran-14-dev libgfortran5 libgl-dev 143s libgl1 libgl1-mesa-dri libgl2ps1.4 libglapi-mesa libglpk40 libglu1-mesa 143s libglvnd0 libglx-dev libglx-mesa0 libglx0 libgmp-dev libgmpxx4ldbl 143s libgnutls-dane0t64 libgnutls-openssl27t64 libgnutls28-dev libgomp1 143s libgraphicsmagick++-q16-12t64 libgraphicsmagick-q16-3t64 libgraphite2-3 143s libgssrpc4t64 libharfbuzz0b libhash-merge-perl libhdf5-310 libhdf5-cpp-310 143s libhdf5-dev libhdf5-fortran-310 libhdf5-hl-310 libhdf5-hl-cpp-310 143s libhdf5-hl-fortran-310 libheif-plugin-aomdec libheif-plugin-libde265 143s libheif1 libhtml-form-perl libhtml-html5-entities-perl libhtml-parser-perl 143s libhtml-tagset-perl libhtml-tokeparser-simple-perl libhtml-tree-perl 143s libhttp-cookies-perl libhttp-date-perl libhttp-message-perl 143s libhttp-negotiate-perl libhwy1t64 libice6 libidn2-dev libimagequant0 143s libimport-into-perl libindirect-perl libinput-bin libinput10 libio-html-perl 143s libio-interactive-perl libio-socket-ssl-perl libio-string-perl 143s libio-stringy-perl libio-tiecombine-perl libipc-run3-perl 143s libipc-system-simple-perl libisl23 libiterator-perl libiterator-util-perl 143s libitm1 libjack-jackd2-0 libjbig0 libjpeg-dev libjpeg-turbo8 143s libjpeg-turbo8-dev libjpeg8 libjpeg8-dev libjson-maybexs-perl libjson-perl 143s libjxl0.11 libkadm5clnt-mit12 libkadm5srv-mit12 libkdb5-10t64 libkrb5-dev 143s liblapack-dev liblapack3 liblcms2-2 libldap-dev liblerc4 143s liblist-compare-perl liblist-moreutils-perl liblist-moreutils-xs-perl 143s liblist-someutils-perl liblist-utilsby-perl liblog-any-adapter-screen-perl 143s liblog-any-perl liblog-log4perl-perl liblsan0 libltdl7 liblua5.4-0 143s liblwp-mediatypes-perl liblwp-protocol-https-perl libmailtools-perl 143s libmarkdown2 libmd4c0 libmime-tools-perl libmldbm-perl 143s libmodule-implementation-perl libmodule-pluggable-perl 143s libmodule-runtime-perl libmoo-perl libmoox-aliases-perl libmouse-perl 143s libmousex-nativetraits-perl libmousex-strictconstructor-perl libmp3lame0 143s libmpc3 libmpg123-0t64 libmro-compat-perl libmtdev1t64 143s libnamespace-clean-perl libncurses-dev libnet-domain-tld-perl 143s libnet-http-perl libnet-ipv6addr-perl libnet-netmask-perl 143s libnet-smtp-ssl-perl libnet-ssleay-perl libnetaddr-ip-perl libnghttp2-dev 143s libnumber-compare-perl libobject-pad-perl libogg0 libopengl0 libopus0 143s libp11-kit-dev libpackage-stash-perl libpango-1.0-0 libpangocairo-1.0-0 143s libpangoft2-1.0-0 libparams-classify-perl libparams-util-perl 143s libparams-validate-perl libparse-debcontrol-perl libparse-recdescent-perl 143s libpath-iterator-rule-perl libpath-tiny-perl libpcre2-16-0 143s libperlio-gzip-perl libperlio-utf8-strict-perl libpixman-1-0 libpkgconf3 143s libpod-constants-perl libpod-parser-perl libpod-pom-perl libportaudio2 143s libproc-processtable-perl libproxy1v5 libpsl-dev libqhull-r8.0 libqrupdate1 143s libqscintilla2-qt6-15 libqscintilla2-qt6-l10n libqt6core5compat6 143s libqt6core6t64 libqt6dbus6 libqt6gui6 libqt6help6 libqt6network6 143s libqt6opengl6 libqt6openglwidgets6 libqt6printsupport6 libqt6sql6 143s libqt6widgets6 libqt6xml6 libquadmath0 libraqm0 libreadline-dev 143s libregexp-common-perl libregexp-pattern-license-perl libregexp-pattern-perl 143s libregexp-wildcards-perl librole-tiny-perl librtmp-dev libsamplerate0 143s libsereal-decoder-perl libsereal-encoder-perl libset-intspan-perl 143s libsharpyuv0 libsm6 libsndfile1 libsoftware-copyright-perl 143s libsoftware-license-perl libsoftware-licensemoreutils-perl 143s libsort-versions-perl libspqr4 libssh2-1-dev libssl-dev libstdc++-14-dev 143s libstemmer0d libstrictures-perl libstring-copyright-perl 143s libstring-escape-perl libstring-license-perl libstring-rewriteprefix-perl 143s libsub-exporter-perl libsub-exporter-progressive-perl libsub-identify-perl 143s libsub-install-perl libsub-name-perl libsub-quote-perl libsub-uplevel-perl 143s libsuitesparseconfig7 libsyntax-keyword-try-perl libsz2 libtasn1-6-dev 143s libterm-readkey-perl libtest-exception-perl libtext-autoformat-perl 143s libtext-glob-perl libtext-levenshtein-damerau-perl 143s libtext-levenshteinxs-perl libtext-markdown-discount-perl 143s libtext-reform-perl libtext-template-perl libtext-unidecode-perl 143s libtext-xslate-perl libthai-data libthai0 libtiff6 libtime-duration-perl 143s libtime-moment-perl libtimedate-perl libtoml-tiny-perl libtool 143s libtry-tiny-perl libts0t64 libtsan2 libubsan1 libumfpack6 libunbound8 143s libunicode-utf8-perl liburi-perl libvariable-magic-perl libvorbis0a 143s libvorbisenc2 libvulkan1 libwacom-common libwacom9 libwayland-client0 143s libwayland-server0 libwebp7 libwebpmux3 libwmflite-0.2-7 143s libwww-mechanize-perl libwww-perl libwww-robotrules-perl libx11-dev 143s libx11-xcb1 libxau-dev libxaw7 libxcb-cursor0 libxcb-dri3-0 libxcb-glx0 143s libxcb-icccm4 libxcb-image0 libxcb-keysyms1 libxcb-present0 libxcb-randr0 143s libxcb-render-util0 libxcb-render0 libxcb-shape0 libxcb-shm0 libxcb-sync1 143s libxcb-util1 libxcb-xfixes0 libxcb-xinput0 libxcb-xkb1 libxcb1-dev 143s libxcursor1 libxdmcp-dev libxfixes3 libxfont2 libxft2 libxinerama1 143s libxkbcommon-x11-0 libxkbfile1 libxml-libxml-perl 143s libxml-namespacesupport-perl libxml-sax-base-perl libxml-sax-perl libxmu6 143s libxpm4 libxrandr2 libxrender1 libxs-parse-keyword-perl 143s libxs-parse-sublike-perl libxshmfence1 libxt6t64 libxxf86vm1 143s libyaml-libyaml-perl libyaml-pp-perl libyaml-tiny-perl libzstd-dev 143s licensecheck lintian lzip lzop m4 mesa-libgallium nettle-dev octave 143s octave-common octave-dev octave-io octave-statistics 143s octave-statistics-common patchutils perl-openssl-defaults pkgconf 143s pkgconf-bin po-debconf t1utils tex-common texinfo texinfo-lib unzip 143s x11-common x11-xkb-utils x11proto-dev xorg-sgml-doctools xserver-common 143s xtrans-dev xvfb zlib1g-dev 143s 0 upgraded, 475 newly installed, 0 to remove and 0 not upgraded. 143s Need to get 195 MB of archives. 143s After this operation, 732 MB of additional disk space will be used. 143s Get:1 http://ftpmaster.internal/ubuntu plucky/main ppc64el libstemmer0d ppc64el 2.2.0-4build1 [171 kB] 143s Get:2 http://ftpmaster.internal/ubuntu plucky/main ppc64el libappstream5 ppc64el 1.0.4-1 [272 kB] 143s Get:3 http://ftpmaster.internal/ubuntu plucky/main ppc64el appstream ppc64el 1.0.4-1 [78.3 kB] 143s Get:4 http://ftpmaster.internal/ubuntu plucky/main ppc64el m4 ppc64el 1.4.19-5 [280 kB] 143s Get:5 http://ftpmaster.internal/ubuntu plucky/main ppc64el autoconf all 2.72-3 [382 kB] 143s Get:6 http://ftpmaster.internal/ubuntu plucky/main ppc64el autotools-dev all 20220109.1 [44.9 kB] 143s Get:7 http://ftpmaster.internal/ubuntu plucky/main ppc64el automake all 1:1.17-3 [572 kB] 143s Get:8 http://ftpmaster.internal/ubuntu plucky/main ppc64el autopoint all 0.23.1-1 [619 kB] 143s Get:9 http://ftpmaster.internal/ubuntu plucky/main ppc64el libcapture-tiny-perl all 0.50-1 [20.7 kB] 143s Get:10 http://ftpmaster.internal/ubuntu plucky/main ppc64el libparams-util-perl ppc64el 1.102-3build1 [21.3 kB] 143s Get:11 http://ftpmaster.internal/ubuntu plucky/main ppc64el libsub-install-perl all 0.929-1 [9764 B] 143s Get:12 http://ftpmaster.internal/ubuntu plucky/main ppc64el libdata-optlist-perl all 0.114-1 [9708 B] 143s Get:13 http://ftpmaster.internal/ubuntu plucky/main ppc64el libb-hooks-op-check-perl ppc64el 0.22-3build2 [9884 B] 143s Get:14 http://ftpmaster.internal/ubuntu plucky/main ppc64el libdynaloader-functions-perl all 0.004-1 [11.4 kB] 143s Get:15 http://ftpmaster.internal/ubuntu plucky/main ppc64el libdevel-callchecker-perl ppc64el 0.009-1build1 [14.1 kB] 143s Get:16 http://ftpmaster.internal/ubuntu plucky/main ppc64el libparams-classify-perl ppc64el 0.015-2build6 [22.2 kB] 143s Get:17 http://ftpmaster.internal/ubuntu plucky/main ppc64el libmodule-runtime-perl all 0.016-2 [16.4 kB] 143s Get:18 http://ftpmaster.internal/ubuntu plucky/main ppc64el libtry-tiny-perl all 0.32-1 [21.2 kB] 143s Get:19 http://ftpmaster.internal/ubuntu plucky/main ppc64el libmodule-implementation-perl all 0.09-2 [12.0 kB] 143s Get:20 http://ftpmaster.internal/ubuntu plucky/main ppc64el libpackage-stash-perl all 0.40-1 [19.5 kB] 143s Get:21 http://ftpmaster.internal/ubuntu plucky/universe ppc64el libclass-load-perl all 0.25-2 [12.7 kB] 143s Get:22 http://ftpmaster.internal/ubuntu plucky/main ppc64el libio-stringy-perl all 2.113-2 [45.3 kB] 143s Get:23 http://ftpmaster.internal/ubuntu plucky/universe ppc64el libparams-validate-perl ppc64el 1.31-2build4 [55.4 kB] 143s Get:24 http://ftpmaster.internal/ubuntu plucky/main ppc64el libsub-exporter-perl all 0.990-1 [49.0 kB] 143s Get:25 http://ftpmaster.internal/ubuntu plucky/universe ppc64el libgetopt-long-descriptive-perl all 0.116-2 [25.0 kB] 143s Get:26 http://ftpmaster.internal/ubuntu plucky/universe ppc64el libio-tiecombine-perl all 1.005-3 [9464 B] 143s Get:27 http://ftpmaster.internal/ubuntu plucky/universe ppc64el libmodule-pluggable-perl all 5.2-5 [19.5 kB] 143s Get:28 http://ftpmaster.internal/ubuntu plucky/universe ppc64el libstring-rewriteprefix-perl all 0.009-1 [6310 B] 143s Get:29 http://ftpmaster.internal/ubuntu plucky/universe ppc64el libapp-cmd-perl all 0.337-2 [58.3 kB] 143s Get:30 http://ftpmaster.internal/ubuntu plucky/universe ppc64el libboolean-perl all 0.46-3 [8430 B] 143s Get:31 http://ftpmaster.internal/ubuntu plucky/universe ppc64el libsub-uplevel-perl all 0.2800-3 [11.6 kB] 143s Get:32 http://ftpmaster.internal/ubuntu plucky/universe ppc64el libtest-exception-perl all 0.43-3 [13.4 kB] 143s Get:33 http://ftpmaster.internal/ubuntu plucky/universe ppc64el libcarp-assert-more-perl all 2.8.0-1 [19.2 kB] 144s Get:34 http://ftpmaster.internal/ubuntu plucky/main ppc64el libfile-which-perl all 1.27-2 [12.5 kB] 144s Get:35 http://ftpmaster.internal/ubuntu plucky/main ppc64el libfile-homedir-perl all 1.006-2 [37.0 kB] 144s Get:36 http://ftpmaster.internal/ubuntu plucky/universe ppc64el libclone-choose-perl all 0.010-2 [7738 B] 144s Get:37 http://ftpmaster.internal/ubuntu plucky/universe ppc64el libhash-merge-perl all 0.302-1 [13.0 kB] 144s Get:38 http://ftpmaster.internal/ubuntu plucky/main ppc64el libjson-perl all 4.10000-1 [81.9 kB] 144s Get:39 http://ftpmaster.internal/ubuntu plucky/main ppc64el libexporter-tiny-perl all 1.006002-1 [36.8 kB] 144s Get:40 http://ftpmaster.internal/ubuntu plucky/universe ppc64el liblist-moreutils-xs-perl ppc64el 0.430-4build1 [43.2 kB] 144s Get:41 http://ftpmaster.internal/ubuntu plucky/universe ppc64el liblist-moreutils-perl all 0.430-2 [38.2 kB] 144s Get:42 http://ftpmaster.internal/ubuntu plucky/universe ppc64el liblog-log4perl-perl all 1.57-1 [345 kB] 144s Get:43 http://ftpmaster.internal/ubuntu plucky/main ppc64el libmouse-perl ppc64el 2.5.11-1build1 [138 kB] 144s Get:44 http://ftpmaster.internal/ubuntu plucky/universe ppc64el libmousex-nativetraits-perl all 1.09-3 [53.2 kB] 144s Get:45 http://ftpmaster.internal/ubuntu plucky/universe ppc64el libmousex-strictconstructor-perl all 0.02-3 [4582 B] 144s Get:46 http://ftpmaster.internal/ubuntu plucky/universe ppc64el libparse-recdescent-perl all 1.967015+dfsg-4 [139 kB] 144s Get:47 http://ftpmaster.internal/ubuntu plucky/main ppc64el libpath-tiny-perl all 0.146-1 [47.5 kB] 144s Get:48 http://ftpmaster.internal/ubuntu plucky/universe ppc64el libpod-pom-perl all 2.01-4 [61.3 kB] 144s Get:49 http://ftpmaster.internal/ubuntu plucky/main ppc64el libregexp-common-perl all 2024080801-1 [162 kB] 144s Get:50 http://ftpmaster.internal/ubuntu plucky/main ppc64el libyaml-tiny-perl all 1.76-1 [24.2 kB] 144s Get:51 http://ftpmaster.internal/ubuntu plucky/universe ppc64el libconfig-model-perl all 2.155-1 [356 kB] 144s Get:52 http://ftpmaster.internal/ubuntu plucky/universe ppc64el libyaml-pp-perl all 0.38.1-2 [107 kB] 144s Get:53 http://ftpmaster.internal/ubuntu plucky/universe ppc64el cme all 1.041-1 [65.4 kB] 144s Get:54 http://ftpmaster.internal/ubuntu plucky/main ppc64el libisl23 ppc64el 0.27-1 [882 kB] 144s Get:55 http://ftpmaster.internal/ubuntu plucky/main ppc64el libmpc3 ppc64el 1.3.1-1build2 [62.1 kB] 144s Get:56 http://ftpmaster.internal/ubuntu plucky/main ppc64el cpp-14-powerpc64le-linux-gnu ppc64el 14.2.0-17ubuntu1 [10.5 MB] 144s Get:57 http://ftpmaster.internal/ubuntu plucky/main ppc64el cpp-14 ppc64el 14.2.0-17ubuntu1 [1038 B] 144s Get:58 http://ftpmaster.internal/ubuntu plucky/main ppc64el cpp-powerpc64le-linux-gnu ppc64el 4:14.2.0-1ubuntu1 [5566 B] 144s Get:59 http://ftpmaster.internal/ubuntu plucky/main ppc64el cpp ppc64el 4:14.2.0-1ubuntu1 [22.4 kB] 144s Get:60 http://ftpmaster.internal/ubuntu plucky/main ppc64el libdebhelper-perl all 13.24.1ubuntu2 [95.4 kB] 144s Get:61 http://ftpmaster.internal/ubuntu plucky/main ppc64el libcc1-0 ppc64el 14.2.0-17ubuntu1 [48.1 kB] 144s Get:62 http://ftpmaster.internal/ubuntu plucky/main ppc64el libgomp1 ppc64el 14.2.0-17ubuntu1 [161 kB] 144s Get:63 http://ftpmaster.internal/ubuntu plucky/main ppc64el libitm1 ppc64el 14.2.0-17ubuntu1 [32.1 kB] 144s Get:64 http://ftpmaster.internal/ubuntu plucky/main ppc64el libasan8 ppc64el 14.2.0-17ubuntu1 [2945 kB] 144s Get:65 http://ftpmaster.internal/ubuntu plucky/main ppc64el liblsan0 ppc64el 14.2.0-17ubuntu1 [1322 kB] 144s Get:66 http://ftpmaster.internal/ubuntu plucky/main ppc64el libtsan2 ppc64el 14.2.0-17ubuntu1 [2696 kB] 144s Get:67 http://ftpmaster.internal/ubuntu plucky/main ppc64el libubsan1 ppc64el 14.2.0-17ubuntu1 [1191 kB] 144s Get:68 http://ftpmaster.internal/ubuntu plucky/main ppc64el libquadmath0 ppc64el 14.2.0-17ubuntu1 [158 kB] 144s Get:69 http://ftpmaster.internal/ubuntu plucky/main ppc64el libgcc-14-dev ppc64el 14.2.0-17ubuntu1 [1620 kB] 144s Get:70 http://ftpmaster.internal/ubuntu plucky/main ppc64el gcc-14-powerpc64le-linux-gnu ppc64el 14.2.0-17ubuntu1 [20.6 MB] 145s Get:71 http://ftpmaster.internal/ubuntu plucky/main ppc64el gcc-14 ppc64el 14.2.0-17ubuntu1 [536 kB] 145s Get:72 http://ftpmaster.internal/ubuntu plucky/main ppc64el gcc-powerpc64le-linux-gnu ppc64el 4:14.2.0-1ubuntu1 [1226 B] 145s Get:73 http://ftpmaster.internal/ubuntu plucky/main ppc64el gcc ppc64el 4:14.2.0-1ubuntu1 [5012 B] 145s Get:74 http://ftpmaster.internal/ubuntu plucky/main ppc64el libtool all 2.5.4-3build1 [168 kB] 145s Get:75 http://ftpmaster.internal/ubuntu plucky/main ppc64el dh-autoreconf all 20 [16.1 kB] 145s Get:76 http://ftpmaster.internal/ubuntu plucky/main ppc64el libarchive-zip-perl all 1.68-1 [90.2 kB] 145s Get:77 http://ftpmaster.internal/ubuntu plucky/main ppc64el libfile-stripnondeterminism-perl all 1.14.1-2 [20.3 kB] 145s Get:78 http://ftpmaster.internal/ubuntu plucky/main ppc64el dh-strip-nondeterminism all 1.14.1-2 [5064 B] 145s Get:79 http://ftpmaster.internal/ubuntu plucky/main ppc64el debugedit ppc64el 1:5.1-2 [52.4 kB] 145s Get:80 http://ftpmaster.internal/ubuntu plucky/main ppc64el dwz ppc64el 0.15-1build6 [142 kB] 145s Get:81 http://ftpmaster.internal/ubuntu plucky/main ppc64el gettext ppc64el 0.23.1-1 [1155 kB] 145s Get:82 http://ftpmaster.internal/ubuntu plucky/main ppc64el intltool-debian all 0.35.0+20060710.6 [23.2 kB] 145s Get:83 http://ftpmaster.internal/ubuntu plucky/main ppc64el po-debconf all 1.0.21+nmu1 [233 kB] 145s Get:84 http://ftpmaster.internal/ubuntu plucky/main ppc64el debhelper all 13.24.1ubuntu2 [895 kB] 145s Get:85 http://ftpmaster.internal/ubuntu plucky/universe ppc64el aglfn all 1.7+git20191031.4036a9c-2 [30.6 kB] 145s Get:86 http://ftpmaster.internal/ubuntu plucky/universe ppc64el gnuplot-data all 6.0.0+dfsg1-1ubuntu3 [75.3 kB] 145s Get:87 http://ftpmaster.internal/ubuntu plucky/main ppc64el fonts-dejavu-mono all 2.37-8 [502 kB] 145s Get:88 http://ftpmaster.internal/ubuntu plucky/main ppc64el fonts-dejavu-core all 2.37-8 [835 kB] 145s Get:89 http://ftpmaster.internal/ubuntu plucky/universe ppc64el fonts-freefont-otf all 20211204+svn4273-2 [4596 kB] 145s Get:90 http://ftpmaster.internal/ubuntu plucky/main ppc64el fontconfig-config ppc64el 2.15.0-1.1ubuntu2 [37.4 kB] 145s Get:91 http://ftpmaster.internal/ubuntu plucky/main ppc64el libfontconfig1 ppc64el 2.15.0-1.1ubuntu2 [190 kB] 145s Get:92 http://ftpmaster.internal/ubuntu plucky/main ppc64el libpixman-1-0 ppc64el 0.44.0-3 [334 kB] 145s Get:93 http://ftpmaster.internal/ubuntu plucky/main ppc64el libxcb-render0 ppc64el 1.17.0-2 [17.2 kB] 145s Get:94 http://ftpmaster.internal/ubuntu plucky/main ppc64el libxcb-shm0 ppc64el 1.17.0-2 [5980 B] 145s Get:95 http://ftpmaster.internal/ubuntu plucky/main ppc64el libxrender1 ppc64el 1:0.9.10-1.1build1 [23.1 kB] 145s Get:96 http://ftpmaster.internal/ubuntu plucky/main ppc64el libcairo2 ppc64el 1.18.2-2 [747 kB] 145s Get:97 http://ftpmaster.internal/ubuntu plucky/main ppc64el libsharpyuv0 ppc64el 1.5.0-0.1 [22.3 kB] 145s Get:98 http://ftpmaster.internal/ubuntu plucky/main ppc64el libaom3 ppc64el 3.12.0-1 [2940 kB] 145s Get:99 http://ftpmaster.internal/ubuntu plucky/main ppc64el libheif-plugin-aomdec ppc64el 1.19.5-1build1 [11.7 kB] 145s Get:100 http://ftpmaster.internal/ubuntu plucky/main ppc64el libde265-0 ppc64el 1.0.15-1build4 [284 kB] 145s Get:101 http://ftpmaster.internal/ubuntu plucky/main ppc64el libheif-plugin-libde265 ppc64el 1.19.5-1build1 [9188 B] 145s Get:102 http://ftpmaster.internal/ubuntu plucky/main ppc64el libheif1 ppc64el 1.19.5-1build1 [452 kB] 146s Get:103 http://ftpmaster.internal/ubuntu plucky/main ppc64el libimagequant0 ppc64el 2.18.0-1build1 [43.2 kB] 146s Get:104 http://ftpmaster.internal/ubuntu plucky/main ppc64el libjpeg-turbo8 ppc64el 2.1.5-3ubuntu2 [215 kB] 146s Get:105 http://ftpmaster.internal/ubuntu plucky/main ppc64el libjpeg8 ppc64el 8c-2ubuntu11 [2148 B] 146s Get:106 http://ftpmaster.internal/ubuntu plucky/main ppc64el libgraphite2-3 ppc64el 1.3.14-2ubuntu1 [84.6 kB] 146s Get:107 http://ftpmaster.internal/ubuntu plucky/main ppc64el libharfbuzz0b ppc64el 10.2.0-1 [598 kB] 146s Get:108 http://ftpmaster.internal/ubuntu plucky/main ppc64el libraqm0 ppc64el 0.10.2-1 [19.2 kB] 146s Get:109 http://ftpmaster.internal/ubuntu plucky/main ppc64el libdeflate0 ppc64el 1.23-1 [63.4 kB] 146s Get:110 http://ftpmaster.internal/ubuntu plucky/main ppc64el libjbig0 ppc64el 2.1-6.1ubuntu2 [35.9 kB] 146s Get:111 http://ftpmaster.internal/ubuntu plucky/main ppc64el liblerc4 ppc64el 4.0.0+ds-5ubuntu1 [298 kB] 146s Get:112 http://ftpmaster.internal/ubuntu plucky/main ppc64el libwebp7 ppc64el 1.5.0-0.1 [315 kB] 146s Get:113 http://ftpmaster.internal/ubuntu plucky/main ppc64el libtiff6 ppc64el 4.5.1+git230720-4ubuntu4 [272 kB] 146s Get:114 http://ftpmaster.internal/ubuntu plucky/main ppc64el libxpm4 ppc64el 1:3.5.17-1build2 [49.9 kB] 146s Get:115 http://ftpmaster.internal/ubuntu plucky/main ppc64el libgd3 ppc64el 2.3.3-12ubuntu3 [165 kB] 146s Get:116 http://ftpmaster.internal/ubuntu plucky/main ppc64el liblua5.4-0 ppc64el 5.4.7-1 [211 kB] 146s Get:117 http://ftpmaster.internal/ubuntu plucky/main ppc64el fontconfig ppc64el 2.15.0-1.1ubuntu2 [192 kB] 146s Get:118 http://ftpmaster.internal/ubuntu plucky/main ppc64el libthai-data all 0.1.29-2build1 [158 kB] 146s Get:119 http://ftpmaster.internal/ubuntu plucky/main ppc64el libdatrie1 ppc64el 0.2.13-3build1 [22.7 kB] 146s Get:120 http://ftpmaster.internal/ubuntu plucky/main ppc64el libthai0 ppc64el 0.1.29-2build1 [21.8 kB] 146s Get:121 http://ftpmaster.internal/ubuntu plucky/main ppc64el libpango-1.0-0 ppc64el 1.56.1-1 [277 kB] 146s Get:122 http://ftpmaster.internal/ubuntu plucky/main ppc64el libpangoft2-1.0-0 ppc64el 1.56.1-1 [58.6 kB] 146s Get:123 http://ftpmaster.internal/ubuntu plucky/main ppc64el libpangocairo-1.0-0 ppc64el 1.56.1-1 [30.6 kB] 146s Get:124 http://ftpmaster.internal/ubuntu plucky/main ppc64el libwebpmux3 ppc64el 1.5.0-0.1 [31.1 kB] 146s Get:125 http://ftpmaster.internal/ubuntu plucky/universe ppc64el gnuplot-nox ppc64el 6.0.0+dfsg1-1ubuntu3 [1225 kB] 146s Get:126 http://ftpmaster.internal/ubuntu plucky/universe ppc64el dh-octave-autopkgtest all 1.8.0 [10.1 kB] 146s Get:127 http://ftpmaster.internal/ubuntu plucky/main ppc64el libapt-pkg-perl ppc64el 0.1.40build8 [71.0 kB] 146s Get:128 http://ftpmaster.internal/ubuntu plucky/main ppc64el libarray-intspan-perl all 2.004-2 [25.0 kB] 146s Get:129 http://ftpmaster.internal/ubuntu plucky/main ppc64el libyaml-libyaml-perl ppc64el 0.903.0+ds-1 [32.8 kB] 146s Get:130 http://ftpmaster.internal/ubuntu plucky/universe ppc64el libconfig-model-backend-yaml-perl all 2.134-2 [10.5 kB] 146s Get:131 http://ftpmaster.internal/ubuntu plucky/universe ppc64el libexporter-lite-perl all 0.09-2 [9748 B] 146s Get:132 http://ftpmaster.internal/ubuntu plucky/main ppc64el libencode-locale-perl all 1.05-3 [11.6 kB] 146s Get:133 http://ftpmaster.internal/ubuntu plucky/main ppc64el libtimedate-perl all 2.3300-2 [34.0 kB] 146s Get:134 http://ftpmaster.internal/ubuntu plucky/main ppc64el libhttp-date-perl all 6.06-1 [10.2 kB] 146s Get:135 http://ftpmaster.internal/ubuntu plucky/main ppc64el libfile-listing-perl all 6.16-1 [11.3 kB] 146s Get:136 http://ftpmaster.internal/ubuntu plucky/main ppc64el libhtml-tagset-perl all 3.24-1 [14.1 kB] 146s Get:137 http://ftpmaster.internal/ubuntu plucky/main ppc64el liburi-perl all 5.30-1 [94.4 kB] 146s Get:138 http://ftpmaster.internal/ubuntu plucky/main ppc64el libhtml-parser-perl ppc64el 3.83-1build1 [91.8 kB] 146s Get:139 http://ftpmaster.internal/ubuntu plucky/main ppc64el libhtml-tree-perl all 5.07-3 [200 kB] 146s Get:140 http://ftpmaster.internal/ubuntu plucky/main ppc64el libclone-perl ppc64el 0.47-1 [11.1 kB] 146s Get:141 http://ftpmaster.internal/ubuntu plucky/main ppc64el libio-html-perl all 1.004-3 [15.9 kB] 146s Get:142 http://ftpmaster.internal/ubuntu plucky/main ppc64el liblwp-mediatypes-perl all 6.04-2 [20.1 kB] 146s Get:143 http://ftpmaster.internal/ubuntu plucky/main ppc64el libhttp-message-perl all 7.00-2ubuntu1 [75.9 kB] 146s Get:144 http://ftpmaster.internal/ubuntu plucky/main ppc64el libhttp-cookies-perl all 6.11-1 [18.2 kB] 146s Get:145 http://ftpmaster.internal/ubuntu plucky/main ppc64el libhttp-negotiate-perl all 6.01-2 [12.4 kB] 146s Get:146 http://ftpmaster.internal/ubuntu plucky/main ppc64el perl-openssl-defaults ppc64el 7build3 [6628 B] 146s Get:147 http://ftpmaster.internal/ubuntu plucky/main ppc64el libnet-ssleay-perl ppc64el 1.94-2 [323 kB] 146s Get:148 http://ftpmaster.internal/ubuntu plucky/main ppc64el libio-socket-ssl-perl all 2.089-1 [200 kB] 146s Get:149 http://ftpmaster.internal/ubuntu plucky/main ppc64el libnet-http-perl all 6.23-1 [22.3 kB] 146s Get:150 http://ftpmaster.internal/ubuntu plucky/main ppc64el liblwp-protocol-https-perl all 6.14-1 [9040 B] 146s Get:151 http://ftpmaster.internal/ubuntu plucky/main ppc64el libwww-robotrules-perl all 6.02-1 [12.6 kB] 146s Get:152 http://ftpmaster.internal/ubuntu plucky/main ppc64el libwww-perl all 6.77-1 [138 kB] 146s Get:153 http://ftpmaster.internal/ubuntu plucky/main ppc64el liberror-perl all 0.17029-2 [25.6 kB] 146s Get:154 http://ftpmaster.internal/ubuntu plucky/universe ppc64el libparse-debcontrol-perl all 2.005-6 [20.4 kB] 146s Get:155 http://ftpmaster.internal/ubuntu plucky/universe ppc64el libsoftware-copyright-perl all 0.012-2 [17.4 kB] 146s Get:156 http://ftpmaster.internal/ubuntu plucky/universe ppc64el libalgorithm-c3-perl all 0.11-2 [10.2 kB] 146s Get:157 http://ftpmaster.internal/ubuntu plucky/universe ppc64el libclass-c3-perl all 0.35-2 [18.4 kB] 146s Get:158 http://ftpmaster.internal/ubuntu plucky/universe ppc64el libmro-compat-perl all 0.15-2 [10.1 kB] 146s Get:159 http://ftpmaster.internal/ubuntu plucky/universe ppc64el libdata-section-perl all 0.200008-1 [11.6 kB] 146s Get:160 http://ftpmaster.internal/ubuntu plucky/universe ppc64el libtext-template-perl all 1.61-1 [48.5 kB] 146s Get:161 http://ftpmaster.internal/ubuntu plucky/universe ppc64el libsoftware-license-perl all 0.104006-1 [117 kB] 146s Get:162 http://ftpmaster.internal/ubuntu plucky/universe ppc64el libsoftware-licensemoreutils-perl all 1.009-1 [21.5 kB] 146s Get:163 http://ftpmaster.internal/ubuntu plucky/main ppc64el libsort-versions-perl all 1.62-3 [7378 B] 146s Get:164 http://ftpmaster.internal/ubuntu plucky/universe ppc64el libtext-reform-perl all 1.20-5 [35.4 kB] 147s Get:165 http://ftpmaster.internal/ubuntu plucky/universe ppc64el libtext-autoformat-perl all 1.750000-2 [29.8 kB] 147s Get:166 http://ftpmaster.internal/ubuntu plucky/universe ppc64el libtext-levenshtein-damerau-perl all 0.41-3 [10.8 kB] 147s Get:167 http://ftpmaster.internal/ubuntu plucky/universe ppc64el libtoml-tiny-perl all 0.18-1 [21.6 kB] 147s Get:168 http://ftpmaster.internal/ubuntu plucky/main ppc64el libclass-inspector-perl all 1.36-3 [15.4 kB] 147s Get:169 http://ftpmaster.internal/ubuntu plucky/main ppc64el libfile-sharedir-perl all 1.118-3 [14.0 kB] 147s Get:170 http://ftpmaster.internal/ubuntu plucky/main ppc64el libindirect-perl ppc64el 0.39-2build5 [22.9 kB] 147s Get:171 http://ftpmaster.internal/ubuntu plucky/main ppc64el libxs-parse-keyword-perl ppc64el 0.48-2 [64.7 kB] 147s Get:172 http://ftpmaster.internal/ubuntu plucky/main ppc64el libxs-parse-sublike-perl ppc64el 0.36-1 [47.0 kB] 147s Get:173 http://ftpmaster.internal/ubuntu plucky/main ppc64el libobject-pad-perl ppc64el 0.819-1 [140 kB] 147s Get:174 http://ftpmaster.internal/ubuntu plucky/main ppc64el libsyntax-keyword-try-perl ppc64el 0.30-1 [26.3 kB] 147s Get:175 http://ftpmaster.internal/ubuntu plucky/main ppc64el libio-interactive-perl all 1.026-1 [10.8 kB] 147s Get:176 http://ftpmaster.internal/ubuntu plucky/main ppc64el liblog-any-perl all 1.717-1 [73.2 kB] 147s Get:177 http://ftpmaster.internal/ubuntu plucky/main ppc64el liblog-any-adapter-screen-perl all 0.141-1 [12.9 kB] 147s Get:178 http://ftpmaster.internal/ubuntu plucky/main ppc64el libsub-exporter-progressive-perl all 0.001013-3 [6718 B] 147s Get:179 http://ftpmaster.internal/ubuntu plucky/main ppc64el libvariable-magic-perl ppc64el 0.64-1build1 [37.2 kB] 147s Get:180 http://ftpmaster.internal/ubuntu plucky/main ppc64el libb-hooks-endofscope-perl all 0.28-1 [15.8 kB] 147s Get:181 http://ftpmaster.internal/ubuntu plucky/main ppc64el libsub-identify-perl ppc64el 0.14-3build4 [10.1 kB] 147s Get:182 http://ftpmaster.internal/ubuntu plucky/main ppc64el libsub-name-perl ppc64el 0.28-1 [10.9 kB] 147s Get:183 http://ftpmaster.internal/ubuntu plucky/main ppc64el libnamespace-clean-perl all 0.27-2 [14.0 kB] 147s Get:184 http://ftpmaster.internal/ubuntu plucky/main ppc64el libnumber-compare-perl all 0.03-3 [5974 B] 147s Get:185 http://ftpmaster.internal/ubuntu plucky/main ppc64el libtext-glob-perl all 0.11-3 [6780 B] 147s Get:186 http://ftpmaster.internal/ubuntu plucky/main ppc64el libpath-iterator-rule-perl all 1.015-2 [39.9 kB] 147s Get:187 http://ftpmaster.internal/ubuntu plucky/main ppc64el libpod-parser-perl all 1.67-1 [80.6 kB] 147s Get:188 http://ftpmaster.internal/ubuntu plucky/main ppc64el libpod-constants-perl all 0.19-2 [16.3 kB] 147s Get:189 http://ftpmaster.internal/ubuntu plucky/main ppc64el libset-intspan-perl all 1.19-3 [24.8 kB] 147s Get:190 http://ftpmaster.internal/ubuntu plucky/main ppc64el libstring-copyright-perl all 0.003014-1 [20.5 kB] 147s Get:191 http://ftpmaster.internal/ubuntu plucky/main ppc64el libstring-escape-perl all 2010.002-3 [16.1 kB] 147s Get:192 http://ftpmaster.internal/ubuntu plucky/main ppc64el libregexp-pattern-license-perl all 3.11.2-1 [85.3 kB] 147s Get:193 http://ftpmaster.internal/ubuntu plucky/main ppc64el libregexp-pattern-perl all 0.2.14-2 [17.6 kB] 147s Get:194 http://ftpmaster.internal/ubuntu plucky/main ppc64el libstring-license-perl all 0.0.11-1ubuntu1 [34.3 kB] 147s Get:195 http://ftpmaster.internal/ubuntu plucky/main ppc64el licensecheck all 3.3.9-1ubuntu1 [37.7 kB] 147s Get:196 http://ftpmaster.internal/ubuntu plucky/main ppc64el diffstat ppc64el 1.67-1 [34.2 kB] 147s Get:197 http://ftpmaster.internal/ubuntu plucky/main ppc64el libberkeleydb-perl ppc64el 0.66-1 [120 kB] 147s Get:198 http://ftpmaster.internal/ubuntu plucky/main ppc64el libclass-xsaccessor-perl ppc64el 1.19-4build5 [35.1 kB] 147s Get:199 http://ftpmaster.internal/ubuntu plucky/main ppc64el libconfig-tiny-perl all 2.30-1 [14.7 kB] 147s Get:200 http://ftpmaster.internal/ubuntu plucky/main ppc64el libconst-fast-perl all 0.014-2 [8034 B] 147s Get:201 http://ftpmaster.internal/ubuntu plucky/main ppc64el libcpanel-json-xs-perl ppc64el 4.39-1 [120 kB] 147s Get:202 http://ftpmaster.internal/ubuntu plucky/main ppc64el libaliased-perl all 0.34-3 [12.8 kB] 147s Get:203 http://ftpmaster.internal/ubuntu plucky/main ppc64el libclass-data-inheritable-perl all 0.10-1 [8038 B] 147s Get:204 http://ftpmaster.internal/ubuntu plucky/main ppc64el libdevel-stacktrace-perl all 2.0500-1 [22.1 kB] 147s Get:205 http://ftpmaster.internal/ubuntu plucky/main ppc64el libexception-class-perl all 1.45-1 [28.6 kB] 147s Get:206 http://ftpmaster.internal/ubuntu plucky/main ppc64el libiterator-perl all 0.03+ds1-2 [18.8 kB] 147s Get:207 http://ftpmaster.internal/ubuntu plucky/main ppc64el libiterator-util-perl all 0.02+ds1-2 [14.1 kB] 147s Get:208 http://ftpmaster.internal/ubuntu plucky/main ppc64el libdata-dpath-perl all 0.60-1 [37.3 kB] 147s Get:209 http://ftpmaster.internal/ubuntu plucky/main ppc64el libnet-domain-tld-perl all 1.75-4 [29.0 kB] 147s Get:210 http://ftpmaster.internal/ubuntu plucky/main ppc64el libdata-validate-domain-perl all 0.15-1 [10.4 kB] 147s Get:211 http://ftpmaster.internal/ubuntu plucky/main ppc64el libnet-ipv6addr-perl all 1.02-1 [21.0 kB] 147s Get:212 http://ftpmaster.internal/ubuntu plucky/main ppc64el libnet-netmask-perl all 2.0002-2 [24.8 kB] 147s Get:213 http://ftpmaster.internal/ubuntu plucky/main ppc64el libnetaddr-ip-perl ppc64el 4.079+dfsg-2build5 [81.4 kB] 147s Get:214 http://ftpmaster.internal/ubuntu plucky/main ppc64el libdata-validate-ip-perl all 0.31-1 [17.2 kB] 147s Get:215 http://ftpmaster.internal/ubuntu plucky/main ppc64el libdata-validate-uri-perl all 0.07-3 [10.8 kB] 147s Get:216 http://ftpmaster.internal/ubuntu plucky/main ppc64el libdevel-size-perl ppc64el 0.84-1build1 [20.1 kB] 147s Get:217 http://ftpmaster.internal/ubuntu plucky/main ppc64el libemail-address-xs-perl ppc64el 1.05-1build5 [33.6 kB] 147s Get:218 http://ftpmaster.internal/ubuntu plucky/main ppc64el libipc-system-simple-perl all 1.30-2 [22.3 kB] 148s Get:219 http://ftpmaster.internal/ubuntu plucky/main ppc64el libfile-basedir-perl all 0.09-2 [14.4 kB] 148s Get:220 http://ftpmaster.internal/ubuntu plucky/main ppc64el libfile-find-rule-perl all 0.34-3 [24.4 kB] 148s Get:221 http://ftpmaster.internal/ubuntu plucky/main ppc64el libio-string-perl all 1.08-4 [11.1 kB] 148s Get:222 http://ftpmaster.internal/ubuntu plucky/main ppc64el libfont-ttf-perl all 1.06-2 [323 kB] 148s Get:223 http://ftpmaster.internal/ubuntu plucky/main ppc64el libhtml-html5-entities-perl all 0.004-3 [21.6 kB] 148s Get:224 http://ftpmaster.internal/ubuntu plucky/main ppc64el libhtml-tokeparser-simple-perl all 3.16-4 [38.0 kB] 148s Get:225 http://ftpmaster.internal/ubuntu plucky/main ppc64el libipc-run3-perl all 0.049-1 [28.8 kB] 148s Get:226 http://ftpmaster.internal/ubuntu plucky/main ppc64el libjson-maybexs-perl all 1.004008-1 [11.1 kB] 148s Get:227 http://ftpmaster.internal/ubuntu plucky/main ppc64el liblist-compare-perl all 0.55-2 [62.9 kB] 148s Get:228 http://ftpmaster.internal/ubuntu plucky/main ppc64el liblist-someutils-perl all 0.59-1 [30.4 kB] 148s Get:229 http://ftpmaster.internal/ubuntu plucky/main ppc64el liblist-utilsby-perl all 0.12-2 [14.9 kB] 148s Get:230 http://ftpmaster.internal/ubuntu plucky/main ppc64el libmldbm-perl all 2.05-4 [16.0 kB] 148s Get:231 http://ftpmaster.internal/ubuntu plucky/main ppc64el libclass-method-modifiers-perl all 2.15-1 [16.1 kB] 148s Get:232 http://ftpmaster.internal/ubuntu plucky/main ppc64el libimport-into-perl all 1.002005-2 [10.7 kB] 148s Get:233 http://ftpmaster.internal/ubuntu plucky/main ppc64el librole-tiny-perl all 2.002004-1 [16.3 kB] 148s Get:234 http://ftpmaster.internal/ubuntu plucky/main ppc64el libsub-quote-perl all 2.006008-1ubuntu1 [20.7 kB] 148s Get:235 http://ftpmaster.internal/ubuntu plucky/main ppc64el libmoo-perl all 2.005005-1 [47.4 kB] 148s Get:236 http://ftpmaster.internal/ubuntu plucky/main ppc64el libstrictures-perl all 2.000006-1 [16.3 kB] 148s Get:237 http://ftpmaster.internal/ubuntu plucky/main ppc64el libmoox-aliases-perl all 0.001006-2 [6796 B] 148s Get:238 http://ftpmaster.internal/ubuntu plucky/main ppc64el libperlio-gzip-perl ppc64el 0.20-1build5 [15.7 kB] 148s Get:239 http://ftpmaster.internal/ubuntu plucky/main ppc64el libperlio-utf8-strict-perl ppc64el 0.010-1build4 [12.0 kB] 148s Get:240 http://ftpmaster.internal/ubuntu plucky/main ppc64el libproc-processtable-perl ppc64el 0.636-1build4 [36.9 kB] 148s Get:241 http://ftpmaster.internal/ubuntu plucky/main ppc64el libregexp-wildcards-perl all 1.05-3 [12.9 kB] 148s Get:242 http://ftpmaster.internal/ubuntu plucky/main ppc64el libsereal-decoder-perl ppc64el 5.004+ds-1build4 [126 kB] 148s Get:243 http://ftpmaster.internal/ubuntu plucky/main ppc64el libsereal-encoder-perl ppc64el 5.004+ds-1build4 [120 kB] 148s Get:244 http://ftpmaster.internal/ubuntu plucky/main ppc64el libterm-readkey-perl ppc64el 2.38-2build5 [24.7 kB] 148s Get:245 http://ftpmaster.internal/ubuntu plucky/main ppc64el libtext-levenshteinxs-perl ppc64el 0.03-5build5 [8634 B] 148s Get:246 http://ftpmaster.internal/ubuntu plucky/main ppc64el libmarkdown2 ppc64el 2.2.7-2ubuntu1 [46.9 kB] 148s Get:247 http://ftpmaster.internal/ubuntu plucky/main ppc64el libtext-markdown-discount-perl ppc64el 0.18-1 [12.5 kB] 148s Get:248 http://ftpmaster.internal/ubuntu plucky/main ppc64el libdata-messagepack-perl ppc64el 1.02-1build5 [32.8 kB] 148s Get:249 http://ftpmaster.internal/ubuntu plucky/main ppc64el libtext-xslate-perl ppc64el 3.5.9-2build1 [165 kB] 148s Get:250 http://ftpmaster.internal/ubuntu plucky/main ppc64el libtime-duration-perl all 1.21-2 [12.3 kB] 148s Get:251 http://ftpmaster.internal/ubuntu plucky/main ppc64el libtime-moment-perl ppc64el 0.44-2build5 [76.5 kB] 148s Get:252 http://ftpmaster.internal/ubuntu plucky/main ppc64el libunicode-utf8-perl ppc64el 0.62-2build4 [19.6 kB] 148s Get:253 http://ftpmaster.internal/ubuntu plucky/main ppc64el libcgi-pm-perl all 4.67-1 [185 kB] 148s Get:254 http://ftpmaster.internal/ubuntu plucky/main ppc64el libhtml-form-perl all 6.12-1 [31.1 kB] 148s Get:255 http://ftpmaster.internal/ubuntu plucky/main ppc64el libwww-mechanize-perl all 2.18-1ubuntu1 [93.1 kB] 148s Get:256 http://ftpmaster.internal/ubuntu plucky/main ppc64el libxml-namespacesupport-perl all 1.12-2 [13.5 kB] 148s Get:257 http://ftpmaster.internal/ubuntu plucky/main ppc64el libxml-sax-base-perl all 1.09-3 [18.9 kB] 148s Get:258 http://ftpmaster.internal/ubuntu plucky/main ppc64el libxml-sax-perl all 1.02+dfsg-4 [52.4 kB] 148s Get:259 http://ftpmaster.internal/ubuntu plucky/main ppc64el libxml-libxml-perl ppc64el 2.0207+dfsg+really+2.0134-5build1 [311 kB] 148s Get:260 http://ftpmaster.internal/ubuntu plucky/main ppc64el lzip ppc64el 1.25-1 [90.5 kB] 148s Get:261 http://ftpmaster.internal/ubuntu plucky/main ppc64el lzop ppc64el 1.04-2build3 [87.3 kB] 148s Get:262 http://ftpmaster.internal/ubuntu plucky/main ppc64el patchutils ppc64el 0.4.2-1build3 [86.6 kB] 148s Get:263 http://ftpmaster.internal/ubuntu plucky/main ppc64el t1utils ppc64el 1.41-4build3 [69.7 kB] 148s Get:264 http://ftpmaster.internal/ubuntu plucky/main ppc64el unzip ppc64el 6.0-28ubuntu6 [200 kB] 148s Get:265 http://ftpmaster.internal/ubuntu plucky/main ppc64el lintian all 2.121.1ubuntu1 [1073 kB] 148s Get:266 http://ftpmaster.internal/ubuntu plucky/universe ppc64el libconfig-model-dpkg-perl all 3.010 [176 kB] 148s Get:267 http://ftpmaster.internal/ubuntu plucky/main ppc64el libconvert-binhex-perl all 1.125-3 [27.1 kB] 148s Get:268 http://ftpmaster.internal/ubuntu plucky/main ppc64el libnet-smtp-ssl-perl all 1.04-2 [6218 B] 148s Get:269 http://ftpmaster.internal/ubuntu plucky/main ppc64el libmailtools-perl all 2.22-1 [77.1 kB] 148s Get:270 http://ftpmaster.internal/ubuntu plucky/main ppc64el libmime-tools-perl all 5.515-1 [187 kB] 148s Get:271 http://ftpmaster.internal/ubuntu plucky/main ppc64el libsuitesparseconfig7 ppc64el 1:7.8.3+dfsg-3 [13.3 kB] 148s Get:272 http://ftpmaster.internal/ubuntu plucky/universe ppc64el libamd3 ppc64el 1:7.8.3+dfsg-3 [37.3 kB] 148s Get:273 http://ftpmaster.internal/ubuntu plucky/main ppc64el libblas3 ppc64el 3.12.1-2 [239 kB] 148s Get:274 http://ftpmaster.internal/ubuntu plucky/main ppc64el libgfortran5 ppc64el 14.2.0-17ubuntu1 [571 kB] 148s Get:275 http://ftpmaster.internal/ubuntu plucky/main ppc64el liblapack3 ppc64el 3.12.1-2 [2813 kB] 148s Get:276 http://ftpmaster.internal/ubuntu plucky/universe ppc64el libarpack2t64 ppc64el 3.9.1-4 [107 kB] 148s Get:277 http://ftpmaster.internal/ubuntu plucky/universe ppc64el libccolamd3 ppc64el 1:7.8.3+dfsg-3 [31.5 kB] 148s Get:278 http://ftpmaster.internal/ubuntu plucky/universe ppc64el libcamd3 ppc64el 1:7.8.3+dfsg-3 [30.8 kB] 148s Get:279 http://ftpmaster.internal/ubuntu plucky/main ppc64el libcolamd3 ppc64el 1:7.8.3+dfsg-3 [21.5 kB] 148s Get:280 http://ftpmaster.internal/ubuntu plucky/universe ppc64el libcholmod5 ppc64el 1:7.8.3+dfsg-3 [906 kB] 148s Get:281 http://ftpmaster.internal/ubuntu plucky/universe ppc64el libcxsparse4 ppc64el 1:7.8.3+dfsg-3 [97.6 kB] 149s Get:282 http://ftpmaster.internal/ubuntu plucky/main ppc64el libfftw3-double3 ppc64el 3.3.10-2fakesync1build1 [443 kB] 149s Get:283 http://ftpmaster.internal/ubuntu plucky/main ppc64el libfftw3-single3 ppc64el 3.3.10-2fakesync1build1 [450 kB] 149s Get:284 http://ftpmaster.internal/ubuntu plucky/main ppc64el libxfixes3 ppc64el 1:6.0.0-2build1 [11.8 kB] 149s Get:285 http://ftpmaster.internal/ubuntu plucky/main ppc64el libxcursor1 ppc64el 1:1.2.3-1 [27.4 kB] 149s Get:286 http://ftpmaster.internal/ubuntu plucky/main ppc64el libxft2 ppc64el 2.3.6-1build1 [61.5 kB] 149s Get:287 http://ftpmaster.internal/ubuntu plucky/main ppc64el libxinerama1 ppc64el 2:1.1.4-3build1 [6908 B] 149s Get:288 http://ftpmaster.internal/ubuntu plucky/universe ppc64el libfltk1.3t64 ppc64el 1.3.8-6.1build2 [698 kB] 149s Get:289 http://ftpmaster.internal/ubuntu plucky/main ppc64el libglvnd0 ppc64el 1.7.0-1build1 [72.4 kB] 149s Get:290 http://ftpmaster.internal/ubuntu plucky/main ppc64el libglapi-mesa ppc64el 24.3.4-3ubuntu1 [63.6 kB] 149s Get:291 http://ftpmaster.internal/ubuntu plucky/main ppc64el libx11-xcb1 ppc64el 2:1.8.10-2 [8008 B] 149s Get:292 http://ftpmaster.internal/ubuntu plucky/main ppc64el libxcb-dri3-0 ppc64el 1.17.0-2 [7842 B] 149s Get:293 http://ftpmaster.internal/ubuntu plucky/main ppc64el libxcb-glx0 ppc64el 1.17.0-2 [26.3 kB] 149s Get:294 http://ftpmaster.internal/ubuntu plucky/main ppc64el libxcb-present0 ppc64el 1.17.0-2 [6276 B] 149s Get:295 http://ftpmaster.internal/ubuntu plucky/main ppc64el libxcb-xfixes0 ppc64el 1.17.0-2 [10.7 kB] 149s Get:296 http://ftpmaster.internal/ubuntu plucky/main ppc64el libxxf86vm1 ppc64el 1:1.1.4-1build4 [11.1 kB] 149s Get:297 http://ftpmaster.internal/ubuntu plucky/main ppc64el libdrm-radeon1 ppc64el 2.4.123-1 [29.0 kB] 149s Get:298 http://ftpmaster.internal/ubuntu plucky/main ppc64el libxcb-randr0 ppc64el 1.17.0-2 [19.1 kB] 149s Get:299 http://ftpmaster.internal/ubuntu plucky/main ppc64el libxcb-sync1 ppc64el 1.17.0-2 [9804 B] 149s Get:300 http://ftpmaster.internal/ubuntu plucky/main ppc64el libxshmfence1 ppc64el 1.3-1build5 [4964 B] 149s Get:301 http://ftpmaster.internal/ubuntu plucky/main ppc64el mesa-libgallium ppc64el 24.3.4-3ubuntu1 [9441 kB] 149s Get:302 http://ftpmaster.internal/ubuntu plucky/main ppc64el libwayland-server0 ppc64el 1.23.1-1 [41.9 kB] 149s Get:303 http://ftpmaster.internal/ubuntu plucky/main ppc64el libgbm1 ppc64el 24.3.4-3ubuntu1 [39.1 kB] 149s Get:304 http://ftpmaster.internal/ubuntu plucky/main ppc64el libvulkan1 ppc64el 1.4.304.0-1 [163 kB] 149s Get:305 http://ftpmaster.internal/ubuntu plucky/main ppc64el libgl1-mesa-dri ppc64el 24.3.4-3ubuntu1 [35.0 kB] 149s Get:306 http://ftpmaster.internal/ubuntu plucky/main ppc64el libglx-mesa0 ppc64el 24.3.4-3ubuntu1 [176 kB] 150s Get:307 http://ftpmaster.internal/ubuntu plucky/main ppc64el libglx0 ppc64el 1.7.0-1build1 [42.7 kB] 150s Get:308 http://ftpmaster.internal/ubuntu plucky/main ppc64el libgl1 ppc64el 1.7.0-1build1 [107 kB] 150s Get:309 http://ftpmaster.internal/ubuntu plucky/universe ppc64el libfltk-gl1.3t64 ppc64el 1.3.8-6.1build2 [48.3 kB] 150s Get:310 http://ftpmaster.internal/ubuntu plucky/universe ppc64el libgl2ps1.4 ppc64el 1.4.2+dfsg1-2build1 [52.6 kB] 150s Get:311 http://ftpmaster.internal/ubuntu plucky/main ppc64el libltdl7 ppc64el 2.5.4-3build1 [50.3 kB] 150s Get:312 http://ftpmaster.internal/ubuntu plucky/universe ppc64el libglpk40 ppc64el 5.0-1build2 [467 kB] 150s Get:313 http://ftpmaster.internal/ubuntu plucky/main ppc64el libopengl0 ppc64el 1.7.0-1build1 [35.5 kB] 150s Get:314 http://ftpmaster.internal/ubuntu plucky/main ppc64el libglu1-mesa ppc64el 9.0.2-1.1build1 [276 kB] 150s Get:315 http://ftpmaster.internal/ubuntu plucky/universe ppc64el libhwy1t64 ppc64el 1.2.0-3ubuntu3 [240 kB] 150s Get:316 http://ftpmaster.internal/ubuntu plucky/main ppc64el liblcms2-2 ppc64el 2.16-2 [243 kB] 150s Get:317 http://ftpmaster.internal/ubuntu plucky/universe ppc64el libjxl0.11 ppc64el 0.11.1-1 [1418 kB] 150s Get:318 http://ftpmaster.internal/ubuntu plucky/main ppc64el libwmflite-0.2-7 ppc64el 0.2.13-1.1build3 [81.7 kB] 150s Get:319 http://ftpmaster.internal/ubuntu plucky/universe ppc64el libgraphicsmagick-q16-3t64 ppc64el 1.4+really1.3.45-1build2 [1610 kB] 150s Get:320 http://ftpmaster.internal/ubuntu plucky/universe ppc64el libgraphicsmagick++-q16-12t64 ppc64el 1.4+really1.3.45-1build2 [120 kB] 150s Get:321 http://ftpmaster.internal/ubuntu plucky/universe ppc64el libaec0 ppc64el 1.1.3-1 [30.1 kB] 150s Get:322 http://ftpmaster.internal/ubuntu plucky/universe ppc64el libsz2 ppc64el 1.1.3-1 [5566 B] 150s Get:323 http://ftpmaster.internal/ubuntu plucky/universe ppc64el libhdf5-310 ppc64el 1.14.5+repack-3 [1523 kB] 150s Get:324 http://ftpmaster.internal/ubuntu plucky/main ppc64el libasound2-data all 1.2.13-1build1 [21.1 kB] 150s Get:325 http://ftpmaster.internal/ubuntu plucky/main ppc64el libasound2t64 ppc64el 1.2.13-1build1 [496 kB] 150s Get:326 http://ftpmaster.internal/ubuntu plucky/main ppc64el libopus0 ppc64el 1.5.2-2 [3038 kB] 150s Get:327 http://ftpmaster.internal/ubuntu plucky/main ppc64el libsamplerate0 ppc64el 0.2.2-4build1 [1348 kB] 150s Get:328 http://ftpmaster.internal/ubuntu plucky/main ppc64el libjack-jackd2-0 ppc64el 1.9.22~dfsg-4 [332 kB] 150s Get:329 http://ftpmaster.internal/ubuntu plucky/universe ppc64el libportaudio2 ppc64el 19.6.0-1.2build3 [87.5 kB] 150s Get:330 http://ftpmaster.internal/ubuntu plucky/universe ppc64el libqhull-r8.0 ppc64el 2020.2-6build1 [225 kB] 150s Get:331 http://ftpmaster.internal/ubuntu plucky/universe ppc64el libqrupdate1 ppc64el 1.1.5-1 [49.4 kB] 150s Get:332 http://ftpmaster.internal/ubuntu plucky/universe ppc64el libqscintilla2-qt6-l10n all 2.14.1+dfsg-1build4 [56.4 kB] 150s Get:333 http://ftpmaster.internal/ubuntu plucky/universe ppc64el libb2-1 ppc64el 0.98.1-1.1build1 [18.2 kB] 150s Get:334 http://ftpmaster.internal/ubuntu plucky/universe ppc64el libdouble-conversion3 ppc64el 3.3.0-1build1 [45.7 kB] 150s Get:335 http://ftpmaster.internal/ubuntu plucky/main ppc64el libpcre2-16-0 ppc64el 10.42-4ubuntu3 [254 kB] 150s Get:336 http://ftpmaster.internal/ubuntu plucky/universe ppc64el libqt6core6t64 ppc64el 6.8.1+dfsg-0ubuntu4 [2244 kB] 150s Get:337 http://ftpmaster.internal/ubuntu plucky/main ppc64el libwayland-client0 ppc64el 1.23.1-1 [31.6 kB] 150s Get:338 http://ftpmaster.internal/ubuntu plucky/main ppc64el libegl-mesa0 ppc64el 24.3.4-3ubuntu1 [151 kB] 150s Get:339 http://ftpmaster.internal/ubuntu plucky/main ppc64el libegl1 ppc64el 1.7.0-1build1 [34.1 kB] 150s Get:340 http://ftpmaster.internal/ubuntu plucky/main ppc64el x11-common all 1:7.7+23ubuntu3 [21.7 kB] 150s Get:341 http://ftpmaster.internal/ubuntu plucky/main ppc64el libice6 ppc64el 2:1.1.1-1 [49.9 kB] 150s Get:342 http://ftpmaster.internal/ubuntu plucky/main ppc64el libmtdev1t64 ppc64el 1.1.7-1 [18.5 kB] 150s Get:343 http://ftpmaster.internal/ubuntu plucky/main ppc64el libwacom-common all 2.14.0-1 [103 kB] 150s Get:344 http://ftpmaster.internal/ubuntu plucky/main ppc64el libwacom9 ppc64el 2.14.0-1 [32.5 kB] 150s Get:345 http://ftpmaster.internal/ubuntu plucky/main ppc64el libinput-bin ppc64el 1.27.1-1 [24.1 kB] 150s Get:346 http://ftpmaster.internal/ubuntu plucky/main ppc64el libinput10 ppc64el 1.27.1-1 [167 kB] 150s Get:347 http://ftpmaster.internal/ubuntu plucky/universe ppc64el libmd4c0 ppc64el 0.5.2-2 [54.5 kB] 150s Get:348 http://ftpmaster.internal/ubuntu plucky/universe ppc64el libqt6dbus6 ppc64el 6.8.1+dfsg-0ubuntu4 [317 kB] 150s Get:349 http://ftpmaster.internal/ubuntu plucky/main ppc64el libsm6 ppc64el 2:1.2.4-1 [18.4 kB] 150s Get:350 http://ftpmaster.internal/ubuntu plucky/universe ppc64el libts0t64 ppc64el 1.22-1.1build1 [69.8 kB] 150s Get:351 http://ftpmaster.internal/ubuntu plucky/main ppc64el libxcb-util1 ppc64el 0.4.1-1 [11.2 kB] 150s Get:352 http://ftpmaster.internal/ubuntu plucky/main ppc64el libxcb-image0 ppc64el 0.4.0-2build1 [12.4 kB] 150s Get:353 http://ftpmaster.internal/ubuntu plucky/main ppc64el libxcb-render-util0 ppc64el 0.3.10-1 [11.5 kB] 150s Get:354 http://ftpmaster.internal/ubuntu plucky/universe ppc64el libxcb-cursor0 ppc64el 0.1.5-1 [11.8 kB] 150s Get:355 http://ftpmaster.internal/ubuntu plucky/main ppc64el libxcb-icccm4 ppc64el 0.4.2-1 [11.4 kB] 150s Get:356 http://ftpmaster.internal/ubuntu plucky/main ppc64el libxcb-keysyms1 ppc64el 0.4.1-1 [9172 B] 150s Get:357 http://ftpmaster.internal/ubuntu plucky/main ppc64el libxcb-shape0 ppc64el 1.17.0-2 [6310 B] 150s Get:358 http://ftpmaster.internal/ubuntu plucky/main ppc64el libxcb-xinput0 ppc64el 1.17.0-2 [36.9 kB] 150s Get:359 http://ftpmaster.internal/ubuntu plucky/main ppc64el libxcb-xkb1 ppc64el 1.17.0-2 [37.6 kB] 150s Get:360 http://ftpmaster.internal/ubuntu plucky/main ppc64el libxkbcommon-x11-0 ppc64el 1.7.0-2 [15.3 kB] 150s Get:361 http://ftpmaster.internal/ubuntu plucky/universe ppc64el libqt6gui6 ppc64el 6.8.1+dfsg-0ubuntu4 [4177 kB] 151s Get:362 http://ftpmaster.internal/ubuntu plucky/main ppc64el libavahi-common-data ppc64el 0.8-14ubuntu1 [30.5 kB] 151s Get:363 http://ftpmaster.internal/ubuntu plucky/main ppc64el libavahi-common3 ppc64el 0.8-14ubuntu1 [26.0 kB] 151s Get:364 http://ftpmaster.internal/ubuntu plucky/main ppc64el libavahi-client3 ppc64el 0.8-14ubuntu1 [31.0 kB] 151s Get:365 http://ftpmaster.internal/ubuntu plucky/main ppc64el libcups2t64 ppc64el 2.4.11-0ubuntu2 [347 kB] 151s Get:366 http://ftpmaster.internal/ubuntu plucky/universe ppc64el libqt6widgets6 ppc64el 6.8.1+dfsg-0ubuntu4 [3206 kB] 151s Get:367 http://ftpmaster.internal/ubuntu plucky/universe ppc64el libqt6printsupport6 ppc64el 6.8.1+dfsg-0ubuntu4 [244 kB] 151s Get:368 http://ftpmaster.internal/ubuntu plucky/universe ppc64el libqscintilla2-qt6-15 ppc64el 2.14.1+dfsg-1build4 [1295 kB] 151s Get:369 http://ftpmaster.internal/ubuntu plucky/universe ppc64el libqt6core5compat6 ppc64el 6.8.1-0ubuntu2 [171 kB] 151s Get:370 http://ftpmaster.internal/ubuntu plucky/universe ppc64el libqt6sql6 ppc64el 6.8.1+dfsg-0ubuntu4 [166 kB] 151s Get:371 http://ftpmaster.internal/ubuntu plucky/universe ppc64el libqt6help6 ppc64el 6.8.1-0ubuntu1 [225 kB] 151s Get:372 http://ftpmaster.internal/ubuntu plucky/main ppc64el libduktape207 ppc64el 2.7.0+tests-0ubuntu3 [158 kB] 151s Get:373 http://ftpmaster.internal/ubuntu plucky/main ppc64el libproxy1v5 ppc64el 0.5.9-1 [29.6 kB] 151s Get:374 http://ftpmaster.internal/ubuntu plucky/universe ppc64el libqt6network6 ppc64el 6.8.1+dfsg-0ubuntu4 [971 kB] 151s Get:375 http://ftpmaster.internal/ubuntu plucky/universe ppc64el libqt6opengl6 ppc64el 6.8.1+dfsg-0ubuntu4 [496 kB] 151s Get:376 http://ftpmaster.internal/ubuntu plucky/universe ppc64el libqt6openglwidgets6 ppc64el 6.8.1+dfsg-0ubuntu4 [45.1 kB] 151s Get:377 http://ftpmaster.internal/ubuntu plucky/universe ppc64el libqt6xml6 ppc64el 6.8.1+dfsg-0ubuntu4 [91.5 kB] 151s Get:378 http://ftpmaster.internal/ubuntu plucky/main ppc64el libogg0 ppc64el 1.3.5-3build1 [27.6 kB] 151s Get:379 http://ftpmaster.internal/ubuntu plucky/main ppc64el libflac12t64 ppc64el 1.4.3+ds-4 [241 kB] 151s Get:380 http://ftpmaster.internal/ubuntu plucky/main ppc64el libmp3lame0 ppc64el 3.100-6build1 [210 kB] 151s Get:381 http://ftpmaster.internal/ubuntu plucky/main ppc64el libmpg123-0t64 ppc64el 1.32.10-1 [202 kB] 151s Get:382 http://ftpmaster.internal/ubuntu plucky/main ppc64el libvorbis0a ppc64el 1.3.7-2 [142 kB] 151s Get:383 http://ftpmaster.internal/ubuntu plucky/main ppc64el libvorbisenc2 ppc64el 1.3.7-2 [86.2 kB] 151s Get:384 http://ftpmaster.internal/ubuntu plucky/main ppc64el libsndfile1 ppc64el 1.2.2-2 [319 kB] 151s Get:385 http://ftpmaster.internal/ubuntu plucky/universe ppc64el libspqr4 ppc64el 1:7.8.3+dfsg-3 [190 kB] 151s Get:386 http://ftpmaster.internal/ubuntu plucky/universe ppc64el libumfpack6 ppc64el 1:7.8.3+dfsg-3 [335 kB] 151s Get:387 http://ftpmaster.internal/ubuntu plucky/universe ppc64el libtext-unidecode-perl all 1.30-3 [105 kB] 151s Get:388 http://ftpmaster.internal/ubuntu plucky/universe ppc64el texinfo-lib ppc64el 7.1.1-1 [152 kB] 151s Get:389 http://ftpmaster.internal/ubuntu plucky/universe ppc64el tex-common all 6.18 [32.8 kB] 151s Get:390 http://ftpmaster.internal/ubuntu plucky/universe ppc64el texinfo all 7.1.1-1 [1272 kB] 151s Get:391 http://ftpmaster.internal/ubuntu plucky/universe ppc64el octave-common all 9.4.0-1 [6087 kB] 151s Get:392 http://ftpmaster.internal/ubuntu plucky/universe ppc64el octave ppc64el 9.4.0-1 [10.2 MB] 152s Get:393 http://ftpmaster.internal/ubuntu plucky/main ppc64el libncurses-dev ppc64el 6.5+20250125-2 [484 kB] 152s Get:394 http://ftpmaster.internal/ubuntu plucky/main ppc64el libreadline-dev ppc64el 8.2-6 [230 kB] 152s Get:395 http://ftpmaster.internal/ubuntu plucky/universe ppc64el libhdf5-fortran-310 ppc64el 1.14.5+repack-3 [118 kB] 152s Get:396 http://ftpmaster.internal/ubuntu plucky/universe ppc64el libhdf5-hl-310 ppc64el 1.14.5+repack-3 [74.9 kB] 152s Get:397 http://ftpmaster.internal/ubuntu plucky/universe ppc64el libhdf5-hl-fortran-310 ppc64el 1.14.5+repack-3 [34.9 kB] 152s Get:398 http://ftpmaster.internal/ubuntu plucky/universe ppc64el libhdf5-cpp-310 ppc64el 1.14.5+repack-3 [126 kB] 152s Get:399 http://ftpmaster.internal/ubuntu plucky/universe ppc64el libhdf5-hl-cpp-310 ppc64el 1.14.5+repack-3 [11.7 kB] 152s Get:400 http://ftpmaster.internal/ubuntu plucky/main ppc64el zlib1g-dev ppc64el 1:1.3.dfsg+really1.3.1-1ubuntu1 [902 kB] 152s Get:401 http://ftpmaster.internal/ubuntu plucky/main ppc64el libjpeg-turbo8-dev ppc64el 2.1.5-3ubuntu2 [358 kB] 152s Get:402 http://ftpmaster.internal/ubuntu plucky/main ppc64el libjpeg8-dev ppc64el 8c-2ubuntu11 [1484 B] 152s Get:403 http://ftpmaster.internal/ubuntu plucky/main ppc64el libjpeg-dev ppc64el 8c-2ubuntu11 [1486 B] 152s Get:404 http://ftpmaster.internal/ubuntu plucky/universe ppc64el libaec-dev ppc64el 1.1.3-1 [28.4 kB] 152s Get:405 http://ftpmaster.internal/ubuntu plucky/main ppc64el libbrotli-dev ppc64el 1.1.0-2build3 [427 kB] 152s Get:406 http://ftpmaster.internal/ubuntu plucky/main ppc64el libidn2-dev ppc64el 2.3.7-2build2 [124 kB] 152s Get:407 http://ftpmaster.internal/ubuntu plucky/main ppc64el comerr-dev ppc64el 2.1-1.47.2-1ubuntu1 [45.5 kB] 152s Get:408 http://ftpmaster.internal/ubuntu plucky/main ppc64el libgssrpc4t64 ppc64el 1.21.3-4ubuntu1 [65.1 kB] 152s Get:409 http://ftpmaster.internal/ubuntu plucky/main ppc64el libkadm5clnt-mit12 ppc64el 1.21.3-4ubuntu1 [44.0 kB] 152s Get:410 http://ftpmaster.internal/ubuntu plucky/main ppc64el libkdb5-10t64 ppc64el 1.21.3-4ubuntu1 [47.2 kB] 152s Get:411 http://ftpmaster.internal/ubuntu plucky/main ppc64el libkadm5srv-mit12 ppc64el 1.21.3-4ubuntu1 [61.5 kB] 152s Get:412 http://ftpmaster.internal/ubuntu plucky/main ppc64el krb5-multidev ppc64el 1.21.3-4ubuntu1 [125 kB] 152s Get:413 http://ftpmaster.internal/ubuntu plucky/main ppc64el libkrb5-dev ppc64el 1.21.3-4ubuntu1 [11.9 kB] 152s Get:414 http://ftpmaster.internal/ubuntu plucky/main ppc64el libldap-dev ppc64el 2.6.9+dfsg-1~exp2ubuntu1 [377 kB] 152s Get:415 http://ftpmaster.internal/ubuntu plucky/main ppc64el libpkgconf3 ppc64el 1.8.1-4 [37.1 kB] 152s Get:416 http://ftpmaster.internal/ubuntu plucky/main ppc64el pkgconf-bin ppc64el 1.8.1-4 [22.5 kB] 152s Get:417 http://ftpmaster.internal/ubuntu plucky/main ppc64el pkgconf ppc64el 1.8.1-4 [16.7 kB] 152s Get:418 http://ftpmaster.internal/ubuntu plucky/main ppc64el libnghttp2-dev ppc64el 1.64.0-1 [138 kB] 152s Get:419 http://ftpmaster.internal/ubuntu plucky/main ppc64el libpsl-dev ppc64el 0.21.2-1.1build1 [79.1 kB] 152s Get:420 http://ftpmaster.internal/ubuntu plucky/main ppc64el libgmpxx4ldbl ppc64el 2:6.3.0+dfsg-2ubuntu7 [10.2 kB] 152s Get:421 http://ftpmaster.internal/ubuntu plucky/main ppc64el libgmp-dev ppc64el 2:6.3.0+dfsg-2ubuntu7 [371 kB] 153s Get:422 http://ftpmaster.internal/ubuntu plucky/main ppc64el libevent-2.1-7t64 ppc64el 2.1.12-stable-10 [172 kB] 153s Get:423 http://ftpmaster.internal/ubuntu plucky/main ppc64el libunbound8 ppc64el 1.22.0-1ubuntu1 [555 kB] 153s Get:424 http://ftpmaster.internal/ubuntu plucky/main ppc64el libgnutls-dane0t64 ppc64el 3.8.9-2ubuntu1 [25.2 kB] 153s Get:425 http://ftpmaster.internal/ubuntu plucky/main ppc64el libgnutls-openssl27t64 ppc64el 3.8.9-2ubuntu1 [24.8 kB] 153s Get:426 http://ftpmaster.internal/ubuntu plucky/main ppc64el libp11-kit-dev ppc64el 0.25.5-2ubuntu2 [23.5 kB] 153s Get:427 http://ftpmaster.internal/ubuntu plucky/main ppc64el libtasn1-6-dev ppc64el 4.20.0-2 [104 kB] 153s Get:428 http://ftpmaster.internal/ubuntu plucky/main ppc64el nettle-dev ppc64el 3.10-1 [1231 kB] 153s Get:429 http://ftpmaster.internal/ubuntu plucky/main ppc64el libgnutls28-dev ppc64el 3.8.9-2ubuntu1 [1223 kB] 153s Get:430 http://ftpmaster.internal/ubuntu plucky/main ppc64el librtmp-dev ppc64el 2.4+20151223.gitfa8646d.1-2build7 [76.1 kB] 153s Get:431 http://ftpmaster.internal/ubuntu plucky/main ppc64el libssl-dev ppc64el 3.4.0-1ubuntu2 [3141 kB] 153s Get:432 http://ftpmaster.internal/ubuntu plucky/main ppc64el libssh2-1-dev ppc64el 1.11.1-1 [316 kB] 153s Get:433 http://ftpmaster.internal/ubuntu plucky/main ppc64el libzstd-dev ppc64el 1.5.6+dfsg-2 [508 kB] 153s Get:434 http://ftpmaster.internal/ubuntu plucky/main ppc64el libcurl4-openssl-dev ppc64el 8.12.0+git20250209.89ed161+ds-1ubuntu1 [599 kB] 153s Get:435 http://ftpmaster.internal/ubuntu plucky/universe ppc64el hdf5-helpers ppc64el 1.14.5+repack-3 [17.1 kB] 153s Get:436 http://ftpmaster.internal/ubuntu plucky/universe ppc64el libhdf5-dev ppc64el 1.14.5+repack-3 [3909 kB] 153s Get:437 http://ftpmaster.internal/ubuntu plucky/main ppc64el xorg-sgml-doctools all 1:1.11-1.1 [10.9 kB] 153s Get:438 http://ftpmaster.internal/ubuntu plucky/main ppc64el x11proto-dev all 2024.1-1 [606 kB] 153s Get:439 http://ftpmaster.internal/ubuntu plucky/main ppc64el libxau-dev ppc64el 1:1.0.11-1 [10.6 kB] 153s Get:440 http://ftpmaster.internal/ubuntu plucky/main ppc64el libxdmcp-dev ppc64el 1:1.1.5-1 [27.7 kB] 153s Get:441 http://ftpmaster.internal/ubuntu plucky/main ppc64el xtrans-dev all 1.4.0-1 [68.9 kB] 153s Get:442 http://ftpmaster.internal/ubuntu plucky/main ppc64el libxcb1-dev ppc64el 1.17.0-2 [97.5 kB] 153s Get:443 http://ftpmaster.internal/ubuntu plucky/main ppc64el libx11-dev ppc64el 2:1.8.10-2 [842 kB] 153s Get:444 http://ftpmaster.internal/ubuntu plucky/main ppc64el libglx-dev ppc64el 1.7.0-1build1 [14.2 kB] 153s Get:445 http://ftpmaster.internal/ubuntu plucky/main ppc64el libgl-dev ppc64el 1.7.0-1build1 [102 kB] 153s Get:446 http://ftpmaster.internal/ubuntu plucky/main ppc64el libblas-dev ppc64el 3.12.1-2 [318 kB] 153s Get:447 http://ftpmaster.internal/ubuntu plucky/main ppc64el liblapack-dev ppc64el 3.12.1-2 [6076 kB] 154s Get:448 http://ftpmaster.internal/ubuntu plucky/main ppc64el libfftw3-long3 ppc64el 3.3.10-2fakesync1build1 [708 kB] 154s Get:449 http://ftpmaster.internal/ubuntu plucky/main ppc64el libfftw3-bin ppc64el 3.3.10-2fakesync1build1 [35.0 kB] 154s Get:450 http://ftpmaster.internal/ubuntu plucky/main ppc64el libfftw3-dev ppc64el 3.3.10-2fakesync1build1 [1300 kB] 154s Get:451 http://ftpmaster.internal/ubuntu plucky/main ppc64el libgfortran-14-dev ppc64el 14.2.0-17ubuntu1 [621 kB] 154s Get:452 http://ftpmaster.internal/ubuntu plucky/main ppc64el gfortran-14-powerpc64le-linux-gnu ppc64el 14.2.0-17ubuntu1 [11.3 MB] 154s Get:453 http://ftpmaster.internal/ubuntu plucky/main ppc64el gfortran-14 ppc64el 14.2.0-17ubuntu1 [13.6 kB] 154s Get:454 http://ftpmaster.internal/ubuntu plucky/main ppc64el gfortran-powerpc64le-linux-gnu ppc64el 4:14.2.0-1ubuntu1 [1024 B] 154s Get:455 http://ftpmaster.internal/ubuntu plucky/main ppc64el gfortran ppc64el 4:14.2.0-1ubuntu1 [1166 B] 154s Get:456 http://ftpmaster.internal/ubuntu plucky/main ppc64el libstdc++-14-dev ppc64el 14.2.0-17ubuntu1 [2677 kB] 155s Get:457 http://ftpmaster.internal/ubuntu plucky/main ppc64el g++-14-powerpc64le-linux-gnu ppc64el 14.2.0-17ubuntu1 [12.0 MB] 155s Get:458 http://ftpmaster.internal/ubuntu plucky/main ppc64el g++-14 ppc64el 14.2.0-17ubuntu1 [21.8 kB] 155s Get:459 http://ftpmaster.internal/ubuntu plucky/main ppc64el g++-powerpc64le-linux-gnu ppc64el 4:14.2.0-1ubuntu1 [966 B] 155s Get:460 http://ftpmaster.internal/ubuntu plucky/main ppc64el g++ ppc64el 4:14.2.0-1ubuntu1 [1088 B] 155s Get:461 http://ftpmaster.internal/ubuntu plucky/universe ppc64el octave-dev ppc64el 9.4.0-1 [463 kB] 155s Get:462 http://ftpmaster.internal/ubuntu plucky/universe ppc64el dh-octave all 1.8.0 [19.7 kB] 155s Get:463 http://ftpmaster.internal/ubuntu plucky/main ppc64el libfontenc1 ppc64el 1:1.1.8-1build1 [15.8 kB] 155s Get:464 http://ftpmaster.internal/ubuntu plucky/main ppc64el libxt6t64 ppc64el 1:1.2.1-1.2build1 [202 kB] 155s Get:465 http://ftpmaster.internal/ubuntu plucky/main ppc64el libxmu6 ppc64el 2:1.1.3-3build2 [56.8 kB] 155s Get:466 http://ftpmaster.internal/ubuntu plucky/main ppc64el libxaw7 ppc64el 2:1.0.16-1 [230 kB] 155s Get:467 http://ftpmaster.internal/ubuntu plucky/main ppc64el libxfont2 ppc64el 1:2.0.6-1build1 [116 kB] 155s Get:468 http://ftpmaster.internal/ubuntu plucky/main ppc64el libxkbfile1 ppc64el 1:1.1.0-1build4 [88.9 kB] 155s Get:469 http://ftpmaster.internal/ubuntu plucky/main ppc64el libxrandr2 ppc64el 2:1.5.4-1 [21.7 kB] 155s Get:470 http://ftpmaster.internal/ubuntu plucky/universe ppc64el octave-io ppc64el 2.6.4-3build2 [240 kB] 155s Get:471 http://ftpmaster.internal/ubuntu plucky/universe ppc64el octave-statistics-common all 1.7.2-1 [926 kB] 155s Get:472 http://ftpmaster.internal/ubuntu plucky/universe ppc64el octave-statistics ppc64el 1.7.2-1 [214 kB] 155s Get:473 http://ftpmaster.internal/ubuntu plucky/main ppc64el x11-xkb-utils ppc64el 7.7+9 [201 kB] 155s Get:474 http://ftpmaster.internal/ubuntu plucky/main ppc64el xserver-common all 2:21.1.14-2ubuntu1 [33.7 kB] 155s Get:475 http://ftpmaster.internal/ubuntu plucky/universe ppc64el xvfb ppc64el 2:21.1.14-2ubuntu1 [1095 kB] 156s Fetched 195 MB in 13s (15.1 MB/s) 156s Selecting previously unselected package libstemmer0d:ppc64el. 156s (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 ... 106313 files and directories currently installed.) 157s Preparing to unpack .../000-libstemmer0d_2.2.0-4build1_ppc64el.deb ... 157s Unpacking libstemmer0d:ppc64el (2.2.0-4build1) ... 157s Selecting previously unselected package libappstream5:ppc64el. 157s Preparing to unpack .../001-libappstream5_1.0.4-1_ppc64el.deb ... 157s Unpacking libappstream5:ppc64el (1.0.4-1) ... 157s Selecting previously unselected package appstream. 157s Preparing to unpack .../002-appstream_1.0.4-1_ppc64el.deb ... 157s Unpacking appstream (1.0.4-1) ... 157s Selecting previously unselected package m4. 157s Preparing to unpack .../003-m4_1.4.19-5_ppc64el.deb ... 157s Unpacking m4 (1.4.19-5) ... 157s Selecting previously unselected package autoconf. 157s Preparing to unpack .../004-autoconf_2.72-3_all.deb ... 157s Unpacking autoconf (2.72-3) ... 157s Selecting previously unselected package autotools-dev. 157s Preparing to unpack .../005-autotools-dev_20220109.1_all.deb ... 157s Unpacking autotools-dev (20220109.1) ... 157s Selecting previously unselected package automake. 157s Preparing to unpack .../006-automake_1%3a1.17-3_all.deb ... 157s Unpacking automake (1:1.17-3) ... 157s Selecting previously unselected package autopoint. 157s Preparing to unpack .../007-autopoint_0.23.1-1_all.deb ... 157s Unpacking autopoint (0.23.1-1) ... 157s Selecting previously unselected package libcapture-tiny-perl. 157s Preparing to unpack .../008-libcapture-tiny-perl_0.50-1_all.deb ... 157s Unpacking libcapture-tiny-perl (0.50-1) ... 157s Selecting previously unselected package libparams-util-perl. 157s Preparing to unpack .../009-libparams-util-perl_1.102-3build1_ppc64el.deb ... 157s Unpacking libparams-util-perl (1.102-3build1) ... 157s Selecting previously unselected package libsub-install-perl. 157s Preparing to unpack .../010-libsub-install-perl_0.929-1_all.deb ... 157s Unpacking libsub-install-perl (0.929-1) ... 157s Selecting previously unselected package libdata-optlist-perl. 157s Preparing to unpack .../011-libdata-optlist-perl_0.114-1_all.deb ... 157s Unpacking libdata-optlist-perl (0.114-1) ... 157s Selecting previously unselected package libb-hooks-op-check-perl:ppc64el. 157s Preparing to unpack .../012-libb-hooks-op-check-perl_0.22-3build2_ppc64el.deb ... 157s Unpacking libb-hooks-op-check-perl:ppc64el (0.22-3build2) ... 157s Selecting previously unselected package libdynaloader-functions-perl. 157s Preparing to unpack .../013-libdynaloader-functions-perl_0.004-1_all.deb ... 157s Unpacking libdynaloader-functions-perl (0.004-1) ... 157s Selecting previously unselected package libdevel-callchecker-perl:ppc64el. 157s Preparing to unpack .../014-libdevel-callchecker-perl_0.009-1build1_ppc64el.deb ... 157s Unpacking libdevel-callchecker-perl:ppc64el (0.009-1build1) ... 157s Selecting previously unselected package libparams-classify-perl:ppc64el. 157s Preparing to unpack .../015-libparams-classify-perl_0.015-2build6_ppc64el.deb ... 157s Unpacking libparams-classify-perl:ppc64el (0.015-2build6) ... 157s Selecting previously unselected package libmodule-runtime-perl. 157s Preparing to unpack .../016-libmodule-runtime-perl_0.016-2_all.deb ... 157s Unpacking libmodule-runtime-perl (0.016-2) ... 157s Selecting previously unselected package libtry-tiny-perl. 157s Preparing to unpack .../017-libtry-tiny-perl_0.32-1_all.deb ... 157s Unpacking libtry-tiny-perl (0.32-1) ... 157s Selecting previously unselected package libmodule-implementation-perl. 157s Preparing to unpack .../018-libmodule-implementation-perl_0.09-2_all.deb ... 157s Unpacking libmodule-implementation-perl (0.09-2) ... 157s Selecting previously unselected package libpackage-stash-perl. 157s Preparing to unpack .../019-libpackage-stash-perl_0.40-1_all.deb ... 157s Unpacking libpackage-stash-perl (0.40-1) ... 157s Selecting previously unselected package libclass-load-perl. 157s Preparing to unpack .../020-libclass-load-perl_0.25-2_all.deb ... 157s Unpacking libclass-load-perl (0.25-2) ... 157s Selecting previously unselected package libio-stringy-perl. 157s Preparing to unpack .../021-libio-stringy-perl_2.113-2_all.deb ... 157s Unpacking libio-stringy-perl (2.113-2) ... 157s Selecting previously unselected package libparams-validate-perl:ppc64el. 157s Preparing to unpack .../022-libparams-validate-perl_1.31-2build4_ppc64el.deb ... 157s Unpacking libparams-validate-perl:ppc64el (1.31-2build4) ... 157s Selecting previously unselected package libsub-exporter-perl. 157s Preparing to unpack .../023-libsub-exporter-perl_0.990-1_all.deb ... 157s Unpacking libsub-exporter-perl (0.990-1) ... 157s Selecting previously unselected package libgetopt-long-descriptive-perl. 157s Preparing to unpack .../024-libgetopt-long-descriptive-perl_0.116-2_all.deb ... 157s Unpacking libgetopt-long-descriptive-perl (0.116-2) ... 157s Selecting previously unselected package libio-tiecombine-perl. 157s Preparing to unpack .../025-libio-tiecombine-perl_1.005-3_all.deb ... 157s Unpacking libio-tiecombine-perl (1.005-3) ... 157s Selecting previously unselected package libmodule-pluggable-perl. 157s Preparing to unpack .../026-libmodule-pluggable-perl_5.2-5_all.deb ... 157s Unpacking libmodule-pluggable-perl (5.2-5) ... 157s Selecting previously unselected package libstring-rewriteprefix-perl. 157s Preparing to unpack .../027-libstring-rewriteprefix-perl_0.009-1_all.deb ... 157s Unpacking libstring-rewriteprefix-perl (0.009-1) ... 157s Selecting previously unselected package libapp-cmd-perl. 157s Preparing to unpack .../028-libapp-cmd-perl_0.337-2_all.deb ... 157s Unpacking libapp-cmd-perl (0.337-2) ... 157s Selecting previously unselected package libboolean-perl. 157s Preparing to unpack .../029-libboolean-perl_0.46-3_all.deb ... 157s Unpacking libboolean-perl (0.46-3) ... 157s Selecting previously unselected package libsub-uplevel-perl. 157s Preparing to unpack .../030-libsub-uplevel-perl_0.2800-3_all.deb ... 157s Unpacking libsub-uplevel-perl (0.2800-3) ... 157s Selecting previously unselected package libtest-exception-perl. 157s Preparing to unpack .../031-libtest-exception-perl_0.43-3_all.deb ... 157s Unpacking libtest-exception-perl (0.43-3) ... 157s Selecting previously unselected package libcarp-assert-more-perl. 157s Preparing to unpack .../032-libcarp-assert-more-perl_2.8.0-1_all.deb ... 157s Unpacking libcarp-assert-more-perl (2.8.0-1) ... 157s Selecting previously unselected package libfile-which-perl. 157s Preparing to unpack .../033-libfile-which-perl_1.27-2_all.deb ... 157s Unpacking libfile-which-perl (1.27-2) ... 157s Selecting previously unselected package libfile-homedir-perl. 157s Preparing to unpack .../034-libfile-homedir-perl_1.006-2_all.deb ... 157s Unpacking libfile-homedir-perl (1.006-2) ... 157s Selecting previously unselected package libclone-choose-perl. 157s Preparing to unpack .../035-libclone-choose-perl_0.010-2_all.deb ... 157s Unpacking libclone-choose-perl (0.010-2) ... 157s Selecting previously unselected package libhash-merge-perl. 157s Preparing to unpack .../036-libhash-merge-perl_0.302-1_all.deb ... 157s Unpacking libhash-merge-perl (0.302-1) ... 157s Selecting previously unselected package libjson-perl. 157s Preparing to unpack .../037-libjson-perl_4.10000-1_all.deb ... 157s Unpacking libjson-perl (4.10000-1) ... 157s Selecting previously unselected package libexporter-tiny-perl. 157s Preparing to unpack .../038-libexporter-tiny-perl_1.006002-1_all.deb ... 157s Unpacking libexporter-tiny-perl (1.006002-1) ... 157s Selecting previously unselected package liblist-moreutils-xs-perl. 157s Preparing to unpack .../039-liblist-moreutils-xs-perl_0.430-4build1_ppc64el.deb ... 157s Unpacking liblist-moreutils-xs-perl (0.430-4build1) ... 157s Selecting previously unselected package liblist-moreutils-perl. 157s Preparing to unpack .../040-liblist-moreutils-perl_0.430-2_all.deb ... 157s Unpacking liblist-moreutils-perl (0.430-2) ... 157s Selecting previously unselected package liblog-log4perl-perl. 157s Preparing to unpack .../041-liblog-log4perl-perl_1.57-1_all.deb ... 157s Unpacking liblog-log4perl-perl (1.57-1) ... 157s Selecting previously unselected package libmouse-perl:ppc64el. 157s Preparing to unpack .../042-libmouse-perl_2.5.11-1build1_ppc64el.deb ... 157s Unpacking libmouse-perl:ppc64el (2.5.11-1build1) ... 157s Selecting previously unselected package libmousex-nativetraits-perl. 157s Preparing to unpack .../043-libmousex-nativetraits-perl_1.09-3_all.deb ... 157s Unpacking libmousex-nativetraits-perl (1.09-3) ... 157s Selecting previously unselected package libmousex-strictconstructor-perl. 157s Preparing to unpack .../044-libmousex-strictconstructor-perl_0.02-3_all.deb ... 157s Unpacking libmousex-strictconstructor-perl (0.02-3) ... 157s Selecting previously unselected package libparse-recdescent-perl. 157s Preparing to unpack .../045-libparse-recdescent-perl_1.967015+dfsg-4_all.deb ... 157s Unpacking libparse-recdescent-perl (1.967015+dfsg-4) ... 157s Selecting previously unselected package libpath-tiny-perl. 157s Preparing to unpack .../046-libpath-tiny-perl_0.146-1_all.deb ... 157s Unpacking libpath-tiny-perl (0.146-1) ... 157s Selecting previously unselected package libpod-pom-perl. 157s Preparing to unpack .../047-libpod-pom-perl_2.01-4_all.deb ... 157s Unpacking libpod-pom-perl (2.01-4) ... 157s Selecting previously unselected package libregexp-common-perl. 157s Preparing to unpack .../048-libregexp-common-perl_2024080801-1_all.deb ... 157s Unpacking libregexp-common-perl (2024080801-1) ... 157s Selecting previously unselected package libyaml-tiny-perl. 157s Preparing to unpack .../049-libyaml-tiny-perl_1.76-1_all.deb ... 157s Unpacking libyaml-tiny-perl (1.76-1) ... 158s Selecting previously unselected package libconfig-model-perl. 158s Preparing to unpack .../050-libconfig-model-perl_2.155-1_all.deb ... 158s Unpacking libconfig-model-perl (2.155-1) ... 158s Selecting previously unselected package libyaml-pp-perl. 158s Preparing to unpack .../051-libyaml-pp-perl_0.38.1-2_all.deb ... 158s Unpacking libyaml-pp-perl (0.38.1-2) ... 158s Selecting previously unselected package cme. 158s Preparing to unpack .../052-cme_1.041-1_all.deb ... 158s Unpacking cme (1.041-1) ... 158s Selecting previously unselected package libisl23:ppc64el. 158s Preparing to unpack .../053-libisl23_0.27-1_ppc64el.deb ... 158s Unpacking libisl23:ppc64el (0.27-1) ... 158s Selecting previously unselected package libmpc3:ppc64el. 158s Preparing to unpack .../054-libmpc3_1.3.1-1build2_ppc64el.deb ... 158s Unpacking libmpc3:ppc64el (1.3.1-1build2) ... 158s Selecting previously unselected package cpp-14-powerpc64le-linux-gnu. 158s Preparing to unpack .../055-cpp-14-powerpc64le-linux-gnu_14.2.0-17ubuntu1_ppc64el.deb ... 158s Unpacking cpp-14-powerpc64le-linux-gnu (14.2.0-17ubuntu1) ... 158s Selecting previously unselected package cpp-14. 158s Preparing to unpack .../056-cpp-14_14.2.0-17ubuntu1_ppc64el.deb ... 158s Unpacking cpp-14 (14.2.0-17ubuntu1) ... 158s Selecting previously unselected package cpp-powerpc64le-linux-gnu. 158s Preparing to unpack .../057-cpp-powerpc64le-linux-gnu_4%3a14.2.0-1ubuntu1_ppc64el.deb ... 158s Unpacking cpp-powerpc64le-linux-gnu (4:14.2.0-1ubuntu1) ... 158s Selecting previously unselected package cpp. 158s Preparing to unpack .../058-cpp_4%3a14.2.0-1ubuntu1_ppc64el.deb ... 158s Unpacking cpp (4:14.2.0-1ubuntu1) ... 158s Selecting previously unselected package libdebhelper-perl. 158s Preparing to unpack .../059-libdebhelper-perl_13.24.1ubuntu2_all.deb ... 158s Unpacking libdebhelper-perl (13.24.1ubuntu2) ... 158s Selecting previously unselected package libcc1-0:ppc64el. 158s Preparing to unpack .../060-libcc1-0_14.2.0-17ubuntu1_ppc64el.deb ... 158s Unpacking libcc1-0:ppc64el (14.2.0-17ubuntu1) ... 158s Selecting previously unselected package libgomp1:ppc64el. 158s Preparing to unpack .../061-libgomp1_14.2.0-17ubuntu1_ppc64el.deb ... 158s Unpacking libgomp1:ppc64el (14.2.0-17ubuntu1) ... 158s Selecting previously unselected package libitm1:ppc64el. 158s Preparing to unpack .../062-libitm1_14.2.0-17ubuntu1_ppc64el.deb ... 158s Unpacking libitm1:ppc64el (14.2.0-17ubuntu1) ... 158s Selecting previously unselected package libasan8:ppc64el. 158s Preparing to unpack .../063-libasan8_14.2.0-17ubuntu1_ppc64el.deb ... 158s Unpacking libasan8:ppc64el (14.2.0-17ubuntu1) ... 158s Selecting previously unselected package liblsan0:ppc64el. 158s Preparing to unpack .../064-liblsan0_14.2.0-17ubuntu1_ppc64el.deb ... 158s Unpacking liblsan0:ppc64el (14.2.0-17ubuntu1) ... 158s Selecting previously unselected package libtsan2:ppc64el. 158s Preparing to unpack .../065-libtsan2_14.2.0-17ubuntu1_ppc64el.deb ... 158s Unpacking libtsan2:ppc64el (14.2.0-17ubuntu1) ... 158s Selecting previously unselected package libubsan1:ppc64el. 158s Preparing to unpack .../066-libubsan1_14.2.0-17ubuntu1_ppc64el.deb ... 158s Unpacking libubsan1:ppc64el (14.2.0-17ubuntu1) ... 158s Selecting previously unselected package libquadmath0:ppc64el. 158s Preparing to unpack .../067-libquadmath0_14.2.0-17ubuntu1_ppc64el.deb ... 158s Unpacking libquadmath0:ppc64el (14.2.0-17ubuntu1) ... 158s Selecting previously unselected package libgcc-14-dev:ppc64el. 158s Preparing to unpack .../068-libgcc-14-dev_14.2.0-17ubuntu1_ppc64el.deb ... 158s Unpacking libgcc-14-dev:ppc64el (14.2.0-17ubuntu1) ... 158s Selecting previously unselected package gcc-14-powerpc64le-linux-gnu. 158s Preparing to unpack .../069-gcc-14-powerpc64le-linux-gnu_14.2.0-17ubuntu1_ppc64el.deb ... 158s Unpacking gcc-14-powerpc64le-linux-gnu (14.2.0-17ubuntu1) ... 159s Selecting previously unselected package gcc-14. 159s Preparing to unpack .../070-gcc-14_14.2.0-17ubuntu1_ppc64el.deb ... 159s Unpacking gcc-14 (14.2.0-17ubuntu1) ... 159s Selecting previously unselected package gcc-powerpc64le-linux-gnu. 159s Preparing to unpack .../071-gcc-powerpc64le-linux-gnu_4%3a14.2.0-1ubuntu1_ppc64el.deb ... 159s Unpacking gcc-powerpc64le-linux-gnu (4:14.2.0-1ubuntu1) ... 159s Selecting previously unselected package gcc. 159s Preparing to unpack .../072-gcc_4%3a14.2.0-1ubuntu1_ppc64el.deb ... 159s Unpacking gcc (4:14.2.0-1ubuntu1) ... 159s Selecting previously unselected package libtool. 159s Preparing to unpack .../073-libtool_2.5.4-3build1_all.deb ... 159s Unpacking libtool (2.5.4-3build1) ... 159s Selecting previously unselected package dh-autoreconf. 159s Preparing to unpack .../074-dh-autoreconf_20_all.deb ... 159s Unpacking dh-autoreconf (20) ... 159s Selecting previously unselected package libarchive-zip-perl. 159s Preparing to unpack .../075-libarchive-zip-perl_1.68-1_all.deb ... 159s Unpacking libarchive-zip-perl (1.68-1) ... 159s Selecting previously unselected package libfile-stripnondeterminism-perl. 159s Preparing to unpack .../076-libfile-stripnondeterminism-perl_1.14.1-2_all.deb ... 159s Unpacking libfile-stripnondeterminism-perl (1.14.1-2) ... 159s Selecting previously unselected package dh-strip-nondeterminism. 159s Preparing to unpack .../077-dh-strip-nondeterminism_1.14.1-2_all.deb ... 159s Unpacking dh-strip-nondeterminism (1.14.1-2) ... 159s Selecting previously unselected package debugedit. 159s Preparing to unpack .../078-debugedit_1%3a5.1-2_ppc64el.deb ... 159s Unpacking debugedit (1:5.1-2) ... 159s Selecting previously unselected package dwz. 159s Preparing to unpack .../079-dwz_0.15-1build6_ppc64el.deb ... 159s Unpacking dwz (0.15-1build6) ... 159s Selecting previously unselected package gettext. 159s Preparing to unpack .../080-gettext_0.23.1-1_ppc64el.deb ... 159s Unpacking gettext (0.23.1-1) ... 159s Selecting previously unselected package intltool-debian. 159s Preparing to unpack .../081-intltool-debian_0.35.0+20060710.6_all.deb ... 159s Unpacking intltool-debian (0.35.0+20060710.6) ... 159s Selecting previously unselected package po-debconf. 159s Preparing to unpack .../082-po-debconf_1.0.21+nmu1_all.deb ... 159s Unpacking po-debconf (1.0.21+nmu1) ... 159s Selecting previously unselected package debhelper. 159s Preparing to unpack .../083-debhelper_13.24.1ubuntu2_all.deb ... 159s Unpacking debhelper (13.24.1ubuntu2) ... 159s Selecting previously unselected package aglfn. 159s Preparing to unpack .../084-aglfn_1.7+git20191031.4036a9c-2_all.deb ... 159s Unpacking aglfn (1.7+git20191031.4036a9c-2) ... 159s Selecting previously unselected package gnuplot-data. 159s Preparing to unpack .../085-gnuplot-data_6.0.0+dfsg1-1ubuntu3_all.deb ... 159s Unpacking gnuplot-data (6.0.0+dfsg1-1ubuntu3) ... 159s Selecting previously unselected package fonts-dejavu-mono. 159s Preparing to unpack .../086-fonts-dejavu-mono_2.37-8_all.deb ... 159s Unpacking fonts-dejavu-mono (2.37-8) ... 159s Selecting previously unselected package fonts-dejavu-core. 159s Preparing to unpack .../087-fonts-dejavu-core_2.37-8_all.deb ... 159s Unpacking fonts-dejavu-core (2.37-8) ... 159s Selecting previously unselected package fonts-freefont-otf. 159s Preparing to unpack .../088-fonts-freefont-otf_20211204+svn4273-2_all.deb ... 159s Unpacking fonts-freefont-otf (20211204+svn4273-2) ... 159s Selecting previously unselected package fontconfig-config. 159s Preparing to unpack .../089-fontconfig-config_2.15.0-1.1ubuntu2_ppc64el.deb ... 159s Unpacking fontconfig-config (2.15.0-1.1ubuntu2) ... 159s Selecting previously unselected package libfontconfig1:ppc64el. 159s Preparing to unpack .../090-libfontconfig1_2.15.0-1.1ubuntu2_ppc64el.deb ... 159s Unpacking libfontconfig1:ppc64el (2.15.0-1.1ubuntu2) ... 159s Selecting previously unselected package libpixman-1-0:ppc64el. 159s Preparing to unpack .../091-libpixman-1-0_0.44.0-3_ppc64el.deb ... 159s Unpacking libpixman-1-0:ppc64el (0.44.0-3) ... 159s Selecting previously unselected package libxcb-render0:ppc64el. 159s Preparing to unpack .../092-libxcb-render0_1.17.0-2_ppc64el.deb ... 159s Unpacking libxcb-render0:ppc64el (1.17.0-2) ... 159s Selecting previously unselected package libxcb-shm0:ppc64el. 159s Preparing to unpack .../093-libxcb-shm0_1.17.0-2_ppc64el.deb ... 159s Unpacking libxcb-shm0:ppc64el (1.17.0-2) ... 159s Selecting previously unselected package libxrender1:ppc64el. 159s Preparing to unpack .../094-libxrender1_1%3a0.9.10-1.1build1_ppc64el.deb ... 159s Unpacking libxrender1:ppc64el (1:0.9.10-1.1build1) ... 159s Selecting previously unselected package libcairo2:ppc64el. 159s Preparing to unpack .../095-libcairo2_1.18.2-2_ppc64el.deb ... 159s Unpacking libcairo2:ppc64el (1.18.2-2) ... 159s Selecting previously unselected package libsharpyuv0:ppc64el. 159s Preparing to unpack .../096-libsharpyuv0_1.5.0-0.1_ppc64el.deb ... 159s Unpacking libsharpyuv0:ppc64el (1.5.0-0.1) ... 159s Selecting previously unselected package libaom3:ppc64el. 160s Preparing to unpack .../097-libaom3_3.12.0-1_ppc64el.deb ... 160s Unpacking libaom3:ppc64el (3.12.0-1) ... 160s Selecting previously unselected package libheif-plugin-aomdec:ppc64el. 160s Preparing to unpack .../098-libheif-plugin-aomdec_1.19.5-1build1_ppc64el.deb ... 160s Unpacking libheif-plugin-aomdec:ppc64el (1.19.5-1build1) ... 160s Selecting previously unselected package libde265-0:ppc64el. 160s Preparing to unpack .../099-libde265-0_1.0.15-1build4_ppc64el.deb ... 160s Unpacking libde265-0:ppc64el (1.0.15-1build4) ... 160s Selecting previously unselected package libheif-plugin-libde265:ppc64el. 160s Preparing to unpack .../100-libheif-plugin-libde265_1.19.5-1build1_ppc64el.deb ... 160s Unpacking libheif-plugin-libde265:ppc64el (1.19.5-1build1) ... 160s Selecting previously unselected package libheif1:ppc64el. 160s Preparing to unpack .../101-libheif1_1.19.5-1build1_ppc64el.deb ... 160s Unpacking libheif1:ppc64el (1.19.5-1build1) ... 160s Selecting previously unselected package libimagequant0:ppc64el. 160s Preparing to unpack .../102-libimagequant0_2.18.0-1build1_ppc64el.deb ... 160s Unpacking libimagequant0:ppc64el (2.18.0-1build1) ... 160s Selecting previously unselected package libjpeg-turbo8:ppc64el. 160s Preparing to unpack .../103-libjpeg-turbo8_2.1.5-3ubuntu2_ppc64el.deb ... 160s Unpacking libjpeg-turbo8:ppc64el (2.1.5-3ubuntu2) ... 160s Selecting previously unselected package libjpeg8:ppc64el. 160s Preparing to unpack .../104-libjpeg8_8c-2ubuntu11_ppc64el.deb ... 160s Unpacking libjpeg8:ppc64el (8c-2ubuntu11) ... 160s Selecting previously unselected package libgraphite2-3:ppc64el. 160s Preparing to unpack .../105-libgraphite2-3_1.3.14-2ubuntu1_ppc64el.deb ... 160s Unpacking libgraphite2-3:ppc64el (1.3.14-2ubuntu1) ... 160s Selecting previously unselected package libharfbuzz0b:ppc64el. 160s Preparing to unpack .../106-libharfbuzz0b_10.2.0-1_ppc64el.deb ... 160s Unpacking libharfbuzz0b:ppc64el (10.2.0-1) ... 160s Selecting previously unselected package libraqm0:ppc64el. 160s Preparing to unpack .../107-libraqm0_0.10.2-1_ppc64el.deb ... 160s Unpacking libraqm0:ppc64el (0.10.2-1) ... 160s Selecting previously unselected package libdeflate0:ppc64el. 160s Preparing to unpack .../108-libdeflate0_1.23-1_ppc64el.deb ... 160s Unpacking libdeflate0:ppc64el (1.23-1) ... 160s Selecting previously unselected package libjbig0:ppc64el. 160s Preparing to unpack .../109-libjbig0_2.1-6.1ubuntu2_ppc64el.deb ... 160s Unpacking libjbig0:ppc64el (2.1-6.1ubuntu2) ... 160s Selecting previously unselected package liblerc4:ppc64el. 160s Preparing to unpack .../110-liblerc4_4.0.0+ds-5ubuntu1_ppc64el.deb ... 160s Unpacking liblerc4:ppc64el (4.0.0+ds-5ubuntu1) ... 160s Selecting previously unselected package libwebp7:ppc64el. 160s Preparing to unpack .../111-libwebp7_1.5.0-0.1_ppc64el.deb ... 160s Unpacking libwebp7:ppc64el (1.5.0-0.1) ... 160s Selecting previously unselected package libtiff6:ppc64el. 160s Preparing to unpack .../112-libtiff6_4.5.1+git230720-4ubuntu4_ppc64el.deb ... 160s Unpacking libtiff6:ppc64el (4.5.1+git230720-4ubuntu4) ... 160s Selecting previously unselected package libxpm4:ppc64el. 160s Preparing to unpack .../113-libxpm4_1%3a3.5.17-1build2_ppc64el.deb ... 160s Unpacking libxpm4:ppc64el (1:3.5.17-1build2) ... 160s Selecting previously unselected package libgd3:ppc64el. 160s Preparing to unpack .../114-libgd3_2.3.3-12ubuntu3_ppc64el.deb ... 160s Unpacking libgd3:ppc64el (2.3.3-12ubuntu3) ... 160s Selecting previously unselected package liblua5.4-0:ppc64el. 160s Preparing to unpack .../115-liblua5.4-0_5.4.7-1_ppc64el.deb ... 160s Unpacking liblua5.4-0:ppc64el (5.4.7-1) ... 160s Selecting previously unselected package fontconfig. 160s Preparing to unpack .../116-fontconfig_2.15.0-1.1ubuntu2_ppc64el.deb ... 160s Unpacking fontconfig (2.15.0-1.1ubuntu2) ... 160s Selecting previously unselected package libthai-data. 160s Preparing to unpack .../117-libthai-data_0.1.29-2build1_all.deb ... 160s Unpacking libthai-data (0.1.29-2build1) ... 160s Selecting previously unselected package libdatrie1:ppc64el. 160s Preparing to unpack .../118-libdatrie1_0.2.13-3build1_ppc64el.deb ... 160s Unpacking libdatrie1:ppc64el (0.2.13-3build1) ... 160s Selecting previously unselected package libthai0:ppc64el. 160s Preparing to unpack .../119-libthai0_0.1.29-2build1_ppc64el.deb ... 160s Unpacking libthai0:ppc64el (0.1.29-2build1) ... 160s Selecting previously unselected package libpango-1.0-0:ppc64el. 160s Preparing to unpack .../120-libpango-1.0-0_1.56.1-1_ppc64el.deb ... 160s Unpacking libpango-1.0-0:ppc64el (1.56.1-1) ... 160s Selecting previously unselected package libpangoft2-1.0-0:ppc64el. 160s Preparing to unpack .../121-libpangoft2-1.0-0_1.56.1-1_ppc64el.deb ... 160s Unpacking libpangoft2-1.0-0:ppc64el (1.56.1-1) ... 160s Selecting previously unselected package libpangocairo-1.0-0:ppc64el. 160s Preparing to unpack .../122-libpangocairo-1.0-0_1.56.1-1_ppc64el.deb ... 160s Unpacking libpangocairo-1.0-0:ppc64el (1.56.1-1) ... 160s Selecting previously unselected package libwebpmux3:ppc64el. 160s Preparing to unpack .../123-libwebpmux3_1.5.0-0.1_ppc64el.deb ... 160s Unpacking libwebpmux3:ppc64el (1.5.0-0.1) ... 160s Selecting previously unselected package gnuplot-nox. 160s Preparing to unpack .../124-gnuplot-nox_6.0.0+dfsg1-1ubuntu3_ppc64el.deb ... 160s Unpacking gnuplot-nox (6.0.0+dfsg1-1ubuntu3) ... 160s Selecting previously unselected package dh-octave-autopkgtest. 160s Preparing to unpack .../125-dh-octave-autopkgtest_1.8.0_all.deb ... 160s Unpacking dh-octave-autopkgtest (1.8.0) ... 160s Selecting previously unselected package libapt-pkg-perl. 160s Preparing to unpack .../126-libapt-pkg-perl_0.1.40build8_ppc64el.deb ... 160s Unpacking libapt-pkg-perl (0.1.40build8) ... 160s Selecting previously unselected package libarray-intspan-perl. 160s Preparing to unpack .../127-libarray-intspan-perl_2.004-2_all.deb ... 160s Unpacking libarray-intspan-perl (2.004-2) ... 160s Selecting previously unselected package libyaml-libyaml-perl. 160s Preparing to unpack .../128-libyaml-libyaml-perl_0.903.0+ds-1_ppc64el.deb ... 160s Unpacking libyaml-libyaml-perl (0.903.0+ds-1) ... 160s Selecting previously unselected package libconfig-model-backend-yaml-perl. 160s Preparing to unpack .../129-libconfig-model-backend-yaml-perl_2.134-2_all.deb ... 160s Unpacking libconfig-model-backend-yaml-perl (2.134-2) ... 160s Selecting previously unselected package libexporter-lite-perl. 160s Preparing to unpack .../130-libexporter-lite-perl_0.09-2_all.deb ... 160s Unpacking libexporter-lite-perl (0.09-2) ... 160s Selecting previously unselected package libencode-locale-perl. 160s Preparing to unpack .../131-libencode-locale-perl_1.05-3_all.deb ... 160s Unpacking libencode-locale-perl (1.05-3) ... 160s Selecting previously unselected package libtimedate-perl. 160s Preparing to unpack .../132-libtimedate-perl_2.3300-2_all.deb ... 160s Unpacking libtimedate-perl (2.3300-2) ... 160s Selecting previously unselected package libhttp-date-perl. 160s Preparing to unpack .../133-libhttp-date-perl_6.06-1_all.deb ... 160s Unpacking libhttp-date-perl (6.06-1) ... 160s Selecting previously unselected package libfile-listing-perl. 160s Preparing to unpack .../134-libfile-listing-perl_6.16-1_all.deb ... 160s Unpacking libfile-listing-perl (6.16-1) ... 160s Selecting previously unselected package libhtml-tagset-perl. 160s Preparing to unpack .../135-libhtml-tagset-perl_3.24-1_all.deb ... 160s Unpacking libhtml-tagset-perl (3.24-1) ... 160s Selecting previously unselected package liburi-perl. 160s Preparing to unpack .../136-liburi-perl_5.30-1_all.deb ... 160s Unpacking liburi-perl (5.30-1) ... 160s Selecting previously unselected package libhtml-parser-perl:ppc64el. 160s Preparing to unpack .../137-libhtml-parser-perl_3.83-1build1_ppc64el.deb ... 160s Unpacking libhtml-parser-perl:ppc64el (3.83-1build1) ... 161s Selecting previously unselected package libhtml-tree-perl. 161s Preparing to unpack .../138-libhtml-tree-perl_5.07-3_all.deb ... 161s Unpacking libhtml-tree-perl (5.07-3) ... 161s Selecting previously unselected package libclone-perl:ppc64el. 161s Preparing to unpack .../139-libclone-perl_0.47-1_ppc64el.deb ... 161s Unpacking libclone-perl:ppc64el (0.47-1) ... 161s Selecting previously unselected package libio-html-perl. 161s Preparing to unpack .../140-libio-html-perl_1.004-3_all.deb ... 161s Unpacking libio-html-perl (1.004-3) ... 161s Selecting previously unselected package liblwp-mediatypes-perl. 161s Preparing to unpack .../141-liblwp-mediatypes-perl_6.04-2_all.deb ... 161s Unpacking liblwp-mediatypes-perl (6.04-2) ... 161s Selecting previously unselected package libhttp-message-perl. 161s Preparing to unpack .../142-libhttp-message-perl_7.00-2ubuntu1_all.deb ... 161s Unpacking libhttp-message-perl (7.00-2ubuntu1) ... 161s Selecting previously unselected package libhttp-cookies-perl. 161s Preparing to unpack .../143-libhttp-cookies-perl_6.11-1_all.deb ... 161s Unpacking libhttp-cookies-perl (6.11-1) ... 161s Selecting previously unselected package libhttp-negotiate-perl. 161s Preparing to unpack .../144-libhttp-negotiate-perl_6.01-2_all.deb ... 161s Unpacking libhttp-negotiate-perl (6.01-2) ... 161s Selecting previously unselected package perl-openssl-defaults:ppc64el. 161s Preparing to unpack .../145-perl-openssl-defaults_7build3_ppc64el.deb ... 161s Unpacking perl-openssl-defaults:ppc64el (7build3) ... 161s Selecting previously unselected package libnet-ssleay-perl:ppc64el. 161s Preparing to unpack .../146-libnet-ssleay-perl_1.94-2_ppc64el.deb ... 161s Unpacking libnet-ssleay-perl:ppc64el (1.94-2) ... 161s Selecting previously unselected package libio-socket-ssl-perl. 161s Preparing to unpack .../147-libio-socket-ssl-perl_2.089-1_all.deb ... 161s Unpacking libio-socket-ssl-perl (2.089-1) ... 161s Selecting previously unselected package libnet-http-perl. 161s Preparing to unpack .../148-libnet-http-perl_6.23-1_all.deb ... 161s Unpacking libnet-http-perl (6.23-1) ... 161s Selecting previously unselected package liblwp-protocol-https-perl. 161s Preparing to unpack .../149-liblwp-protocol-https-perl_6.14-1_all.deb ... 161s Unpacking liblwp-protocol-https-perl (6.14-1) ... 161s Selecting previously unselected package libwww-robotrules-perl. 161s Preparing to unpack .../150-libwww-robotrules-perl_6.02-1_all.deb ... 161s Unpacking libwww-robotrules-perl (6.02-1) ... 161s Selecting previously unselected package libwww-perl. 161s Preparing to unpack .../151-libwww-perl_6.77-1_all.deb ... 161s Unpacking libwww-perl (6.77-1) ... 161s Selecting previously unselected package liberror-perl. 161s Preparing to unpack .../152-liberror-perl_0.17029-2_all.deb ... 161s Unpacking liberror-perl (0.17029-2) ... 161s Selecting previously unselected package libparse-debcontrol-perl. 161s Preparing to unpack .../153-libparse-debcontrol-perl_2.005-6_all.deb ... 161s Unpacking libparse-debcontrol-perl (2.005-6) ... 161s Selecting previously unselected package libsoftware-copyright-perl. 161s Preparing to unpack .../154-libsoftware-copyright-perl_0.012-2_all.deb ... 161s Unpacking libsoftware-copyright-perl (0.012-2) ... 161s Selecting previously unselected package libalgorithm-c3-perl. 161s Preparing to unpack .../155-libalgorithm-c3-perl_0.11-2_all.deb ... 161s Unpacking libalgorithm-c3-perl (0.11-2) ... 161s Selecting previously unselected package libclass-c3-perl. 161s Preparing to unpack .../156-libclass-c3-perl_0.35-2_all.deb ... 161s Unpacking libclass-c3-perl (0.35-2) ... 161s Selecting previously unselected package libmro-compat-perl. 161s Preparing to unpack .../157-libmro-compat-perl_0.15-2_all.deb ... 161s Unpacking libmro-compat-perl (0.15-2) ... 161s Selecting previously unselected package libdata-section-perl. 161s Preparing to unpack .../158-libdata-section-perl_0.200008-1_all.deb ... 161s Unpacking libdata-section-perl (0.200008-1) ... 161s Selecting previously unselected package libtext-template-perl. 161s Preparing to unpack .../159-libtext-template-perl_1.61-1_all.deb ... 161s Unpacking libtext-template-perl (1.61-1) ... 161s Selecting previously unselected package libsoftware-license-perl. 161s Preparing to unpack .../160-libsoftware-license-perl_0.104006-1_all.deb ... 161s Unpacking libsoftware-license-perl (0.104006-1) ... 161s Selecting previously unselected package libsoftware-licensemoreutils-perl. 161s Preparing to unpack .../161-libsoftware-licensemoreutils-perl_1.009-1_all.deb ... 161s Unpacking libsoftware-licensemoreutils-perl (1.009-1) ... 161s Selecting previously unselected package libsort-versions-perl. 161s Preparing to unpack .../162-libsort-versions-perl_1.62-3_all.deb ... 161s Unpacking libsort-versions-perl (1.62-3) ... 161s Selecting previously unselected package libtext-reform-perl. 161s Preparing to unpack .../163-libtext-reform-perl_1.20-5_all.deb ... 161s Unpacking libtext-reform-perl (1.20-5) ... 161s Selecting previously unselected package libtext-autoformat-perl. 161s Preparing to unpack .../164-libtext-autoformat-perl_1.750000-2_all.deb ... 161s Unpacking libtext-autoformat-perl (1.750000-2) ... 161s Selecting previously unselected package libtext-levenshtein-damerau-perl. 161s Preparing to unpack .../165-libtext-levenshtein-damerau-perl_0.41-3_all.deb ... 161s Unpacking libtext-levenshtein-damerau-perl (0.41-3) ... 161s Selecting previously unselected package libtoml-tiny-perl. 161s Preparing to unpack .../166-libtoml-tiny-perl_0.18-1_all.deb ... 161s Unpacking libtoml-tiny-perl (0.18-1) ... 161s Selecting previously unselected package libclass-inspector-perl. 161s Preparing to unpack .../167-libclass-inspector-perl_1.36-3_all.deb ... 161s Unpacking libclass-inspector-perl (1.36-3) ... 161s Selecting previously unselected package libfile-sharedir-perl. 161s Preparing to unpack .../168-libfile-sharedir-perl_1.118-3_all.deb ... 161s Unpacking libfile-sharedir-perl (1.118-3) ... 161s Selecting previously unselected package libindirect-perl. 161s Preparing to unpack .../169-libindirect-perl_0.39-2build5_ppc64el.deb ... 161s Unpacking libindirect-perl (0.39-2build5) ... 161s Selecting previously unselected package libxs-parse-keyword-perl. 161s Preparing to unpack .../170-libxs-parse-keyword-perl_0.48-2_ppc64el.deb ... 161s Unpacking libxs-parse-keyword-perl (0.48-2) ... 161s Selecting previously unselected package libxs-parse-sublike-perl:ppc64el. 161s Preparing to unpack .../171-libxs-parse-sublike-perl_0.36-1_ppc64el.deb ... 161s Unpacking libxs-parse-sublike-perl:ppc64el (0.36-1) ... 161s Selecting previously unselected package libobject-pad-perl. 161s Preparing to unpack .../172-libobject-pad-perl_0.819-1_ppc64el.deb ... 161s Unpacking libobject-pad-perl (0.819-1) ... 161s Selecting previously unselected package libsyntax-keyword-try-perl. 161s Preparing to unpack .../173-libsyntax-keyword-try-perl_0.30-1_ppc64el.deb ... 161s Unpacking libsyntax-keyword-try-perl (0.30-1) ... 161s Selecting previously unselected package libio-interactive-perl. 161s Preparing to unpack .../174-libio-interactive-perl_1.026-1_all.deb ... 161s Unpacking libio-interactive-perl (1.026-1) ... 161s Selecting previously unselected package liblog-any-perl. 161s Preparing to unpack .../175-liblog-any-perl_1.717-1_all.deb ... 161s Unpacking liblog-any-perl (1.717-1) ... 161s Selecting previously unselected package liblog-any-adapter-screen-perl. 161s Preparing to unpack .../176-liblog-any-adapter-screen-perl_0.141-1_all.deb ... 161s Unpacking liblog-any-adapter-screen-perl (0.141-1) ... 161s Selecting previously unselected package libsub-exporter-progressive-perl. 161s Preparing to unpack .../177-libsub-exporter-progressive-perl_0.001013-3_all.deb ... 161s Unpacking libsub-exporter-progressive-perl (0.001013-3) ... 161s Selecting previously unselected package libvariable-magic-perl. 161s Preparing to unpack .../178-libvariable-magic-perl_0.64-1build1_ppc64el.deb ... 161s Unpacking libvariable-magic-perl (0.64-1build1) ... 161s Selecting previously unselected package libb-hooks-endofscope-perl. 161s Preparing to unpack .../179-libb-hooks-endofscope-perl_0.28-1_all.deb ... 161s Unpacking libb-hooks-endofscope-perl (0.28-1) ... 161s Selecting previously unselected package libsub-identify-perl. 161s Preparing to unpack .../180-libsub-identify-perl_0.14-3build4_ppc64el.deb ... 161s Unpacking libsub-identify-perl (0.14-3build4) ... 161s Selecting previously unselected package libsub-name-perl:ppc64el. 161s Preparing to unpack .../181-libsub-name-perl_0.28-1_ppc64el.deb ... 161s Unpacking libsub-name-perl:ppc64el (0.28-1) ... 162s Selecting previously unselected package libnamespace-clean-perl. 162s Preparing to unpack .../182-libnamespace-clean-perl_0.27-2_all.deb ... 162s Unpacking libnamespace-clean-perl (0.27-2) ... 162s Selecting previously unselected package libnumber-compare-perl. 162s Preparing to unpack .../183-libnumber-compare-perl_0.03-3_all.deb ... 162s Unpacking libnumber-compare-perl (0.03-3) ... 162s Selecting previously unselected package libtext-glob-perl. 162s Preparing to unpack .../184-libtext-glob-perl_0.11-3_all.deb ... 162s Unpacking libtext-glob-perl (0.11-3) ... 162s Selecting previously unselected package libpath-iterator-rule-perl. 162s Preparing to unpack .../185-libpath-iterator-rule-perl_1.015-2_all.deb ... 162s Unpacking libpath-iterator-rule-perl (1.015-2) ... 162s Selecting previously unselected package libpod-parser-perl. 162s Preparing to unpack .../186-libpod-parser-perl_1.67-1_all.deb ... 162s Adding 'diversion of /usr/bin/podselect to /usr/bin/podselect.bundled by libpod-parser-perl' 162s Adding 'diversion of /usr/share/man/man1/podselect.1.gz to /usr/share/man/man1/podselect.bundled.1.gz by libpod-parser-perl' 162s Unpacking libpod-parser-perl (1.67-1) ... 162s Selecting previously unselected package libpod-constants-perl. 162s Preparing to unpack .../187-libpod-constants-perl_0.19-2_all.deb ... 162s Unpacking libpod-constants-perl (0.19-2) ... 162s Selecting previously unselected package libset-intspan-perl. 162s Preparing to unpack .../188-libset-intspan-perl_1.19-3_all.deb ... 162s Unpacking libset-intspan-perl (1.19-3) ... 162s Selecting previously unselected package libstring-copyright-perl. 162s Preparing to unpack .../189-libstring-copyright-perl_0.003014-1_all.deb ... 162s Unpacking libstring-copyright-perl (0.003014-1) ... 162s Selecting previously unselected package libstring-escape-perl. 162s Preparing to unpack .../190-libstring-escape-perl_2010.002-3_all.deb ... 162s Unpacking libstring-escape-perl (2010.002-3) ... 162s Selecting previously unselected package libregexp-pattern-license-perl. 162s Preparing to unpack .../191-libregexp-pattern-license-perl_3.11.2-1_all.deb ... 162s Unpacking libregexp-pattern-license-perl (3.11.2-1) ... 162s Selecting previously unselected package libregexp-pattern-perl. 162s Preparing to unpack .../192-libregexp-pattern-perl_0.2.14-2_all.deb ... 162s Unpacking libregexp-pattern-perl (0.2.14-2) ... 162s Selecting previously unselected package libstring-license-perl. 162s Preparing to unpack .../193-libstring-license-perl_0.0.11-1ubuntu1_all.deb ... 162s Unpacking libstring-license-perl (0.0.11-1ubuntu1) ... 162s Selecting previously unselected package licensecheck. 162s Preparing to unpack .../194-licensecheck_3.3.9-1ubuntu1_all.deb ... 162s Unpacking licensecheck (3.3.9-1ubuntu1) ... 162s Selecting previously unselected package diffstat. 162s Preparing to unpack .../195-diffstat_1.67-1_ppc64el.deb ... 162s Unpacking diffstat (1.67-1) ... 162s Selecting previously unselected package libberkeleydb-perl:ppc64el. 162s Preparing to unpack .../196-libberkeleydb-perl_0.66-1_ppc64el.deb ... 162s Unpacking libberkeleydb-perl:ppc64el (0.66-1) ... 162s Selecting previously unselected package libclass-xsaccessor-perl. 162s Preparing to unpack .../197-libclass-xsaccessor-perl_1.19-4build5_ppc64el.deb ... 162s Unpacking libclass-xsaccessor-perl (1.19-4build5) ... 162s Selecting previously unselected package libconfig-tiny-perl. 162s Preparing to unpack .../198-libconfig-tiny-perl_2.30-1_all.deb ... 162s Unpacking libconfig-tiny-perl (2.30-1) ... 162s Selecting previously unselected package libconst-fast-perl. 162s Preparing to unpack .../199-libconst-fast-perl_0.014-2_all.deb ... 162s Unpacking libconst-fast-perl (0.014-2) ... 162s Selecting previously unselected package libcpanel-json-xs-perl:ppc64el. 162s Preparing to unpack .../200-libcpanel-json-xs-perl_4.39-1_ppc64el.deb ... 162s Unpacking libcpanel-json-xs-perl:ppc64el (4.39-1) ... 162s Selecting previously unselected package libaliased-perl. 162s Preparing to unpack .../201-libaliased-perl_0.34-3_all.deb ... 162s Unpacking libaliased-perl (0.34-3) ... 162s Selecting previously unselected package libclass-data-inheritable-perl. 162s Preparing to unpack .../202-libclass-data-inheritable-perl_0.10-1_all.deb ... 162s Unpacking libclass-data-inheritable-perl (0.10-1) ... 162s Selecting previously unselected package libdevel-stacktrace-perl. 162s Preparing to unpack .../203-libdevel-stacktrace-perl_2.0500-1_all.deb ... 162s Unpacking libdevel-stacktrace-perl (2.0500-1) ... 162s Selecting previously unselected package libexception-class-perl. 162s Preparing to unpack .../204-libexception-class-perl_1.45-1_all.deb ... 162s Unpacking libexception-class-perl (1.45-1) ... 162s Selecting previously unselected package libiterator-perl. 162s Preparing to unpack .../205-libiterator-perl_0.03+ds1-2_all.deb ... 162s Unpacking libiterator-perl (0.03+ds1-2) ... 162s Selecting previously unselected package libiterator-util-perl. 162s Preparing to unpack .../206-libiterator-util-perl_0.02+ds1-2_all.deb ... 162s Unpacking libiterator-util-perl (0.02+ds1-2) ... 162s Selecting previously unselected package libdata-dpath-perl. 162s Preparing to unpack .../207-libdata-dpath-perl_0.60-1_all.deb ... 162s Unpacking libdata-dpath-perl (0.60-1) ... 162s Selecting previously unselected package libnet-domain-tld-perl. 162s Preparing to unpack .../208-libnet-domain-tld-perl_1.75-4_all.deb ... 162s Unpacking libnet-domain-tld-perl (1.75-4) ... 162s Selecting previously unselected package libdata-validate-domain-perl. 162s Preparing to unpack .../209-libdata-validate-domain-perl_0.15-1_all.deb ... 162s Unpacking libdata-validate-domain-perl (0.15-1) ... 162s Selecting previously unselected package libnet-ipv6addr-perl. 162s Preparing to unpack .../210-libnet-ipv6addr-perl_1.02-1_all.deb ... 162s Unpacking libnet-ipv6addr-perl (1.02-1) ... 162s Selecting previously unselected package libnet-netmask-perl. 162s Preparing to unpack .../211-libnet-netmask-perl_2.0002-2_all.deb ... 162s Unpacking libnet-netmask-perl (2.0002-2) ... 162s Selecting previously unselected package libnetaddr-ip-perl. 162s Preparing to unpack .../212-libnetaddr-ip-perl_4.079+dfsg-2build5_ppc64el.deb ... 162s Unpacking libnetaddr-ip-perl (4.079+dfsg-2build5) ... 162s Selecting previously unselected package libdata-validate-ip-perl. 162s Preparing to unpack .../213-libdata-validate-ip-perl_0.31-1_all.deb ... 162s Unpacking libdata-validate-ip-perl (0.31-1) ... 162s Selecting previously unselected package libdata-validate-uri-perl. 162s Preparing to unpack .../214-libdata-validate-uri-perl_0.07-3_all.deb ... 162s Unpacking libdata-validate-uri-perl (0.07-3) ... 162s Selecting previously unselected package libdevel-size-perl. 162s Preparing to unpack .../215-libdevel-size-perl_0.84-1build1_ppc64el.deb ... 162s Unpacking libdevel-size-perl (0.84-1build1) ... 162s Selecting previously unselected package libemail-address-xs-perl. 162s Preparing to unpack .../216-libemail-address-xs-perl_1.05-1build5_ppc64el.deb ... 162s Unpacking libemail-address-xs-perl (1.05-1build5) ... 162s Selecting previously unselected package libipc-system-simple-perl. 162s Preparing to unpack .../217-libipc-system-simple-perl_1.30-2_all.deb ... 162s Unpacking libipc-system-simple-perl (1.30-2) ... 162s Selecting previously unselected package libfile-basedir-perl. 162s Preparing to unpack .../218-libfile-basedir-perl_0.09-2_all.deb ... 162s Unpacking libfile-basedir-perl (0.09-2) ... 162s Selecting previously unselected package libfile-find-rule-perl. 162s Preparing to unpack .../219-libfile-find-rule-perl_0.34-3_all.deb ... 162s Unpacking libfile-find-rule-perl (0.34-3) ... 162s Selecting previously unselected package libio-string-perl. 162s Preparing to unpack .../220-libio-string-perl_1.08-4_all.deb ... 162s Unpacking libio-string-perl (1.08-4) ... 162s Selecting previously unselected package libfont-ttf-perl. 162s Preparing to unpack .../221-libfont-ttf-perl_1.06-2_all.deb ... 162s Unpacking libfont-ttf-perl (1.06-2) ... 162s Selecting previously unselected package libhtml-html5-entities-perl. 162s Preparing to unpack .../222-libhtml-html5-entities-perl_0.004-3_all.deb ... 162s Unpacking libhtml-html5-entities-perl (0.004-3) ... 162s Selecting previously unselected package libhtml-tokeparser-simple-perl. 162s Preparing to unpack .../223-libhtml-tokeparser-simple-perl_3.16-4_all.deb ... 162s Unpacking libhtml-tokeparser-simple-perl (3.16-4) ... 162s Selecting previously unselected package libipc-run3-perl. 162s Preparing to unpack .../224-libipc-run3-perl_0.049-1_all.deb ... 162s Unpacking libipc-run3-perl (0.049-1) ... 162s Selecting previously unselected package libjson-maybexs-perl. 162s Preparing to unpack .../225-libjson-maybexs-perl_1.004008-1_all.deb ... 162s Unpacking libjson-maybexs-perl (1.004008-1) ... 163s Selecting previously unselected package liblist-compare-perl. 163s Preparing to unpack .../226-liblist-compare-perl_0.55-2_all.deb ... 163s Unpacking liblist-compare-perl (0.55-2) ... 163s Selecting previously unselected package liblist-someutils-perl. 163s Preparing to unpack .../227-liblist-someutils-perl_0.59-1_all.deb ... 163s Unpacking liblist-someutils-perl (0.59-1) ... 163s Selecting previously unselected package liblist-utilsby-perl. 163s Preparing to unpack .../228-liblist-utilsby-perl_0.12-2_all.deb ... 163s Unpacking liblist-utilsby-perl (0.12-2) ... 163s Selecting previously unselected package libmldbm-perl. 163s Preparing to unpack .../229-libmldbm-perl_2.05-4_all.deb ... 163s Unpacking libmldbm-perl (2.05-4) ... 163s Selecting previously unselected package libclass-method-modifiers-perl. 163s Preparing to unpack .../230-libclass-method-modifiers-perl_2.15-1_all.deb ... 163s Unpacking libclass-method-modifiers-perl (2.15-1) ... 163s Selecting previously unselected package libimport-into-perl. 163s Preparing to unpack .../231-libimport-into-perl_1.002005-2_all.deb ... 163s Unpacking libimport-into-perl (1.002005-2) ... 163s Selecting previously unselected package librole-tiny-perl. 163s Preparing to unpack .../232-librole-tiny-perl_2.002004-1_all.deb ... 163s Unpacking librole-tiny-perl (2.002004-1) ... 163s Selecting previously unselected package libsub-quote-perl. 163s Preparing to unpack .../233-libsub-quote-perl_2.006008-1ubuntu1_all.deb ... 163s Unpacking libsub-quote-perl (2.006008-1ubuntu1) ... 163s Selecting previously unselected package libmoo-perl. 163s Preparing to unpack .../234-libmoo-perl_2.005005-1_all.deb ... 163s Unpacking libmoo-perl (2.005005-1) ... 163s Selecting previously unselected package libstrictures-perl. 163s Preparing to unpack .../235-libstrictures-perl_2.000006-1_all.deb ... 163s Unpacking libstrictures-perl (2.000006-1) ... 163s Selecting previously unselected package libmoox-aliases-perl. 163s Preparing to unpack .../236-libmoox-aliases-perl_0.001006-2_all.deb ... 163s Unpacking libmoox-aliases-perl (0.001006-2) ... 163s Selecting previously unselected package libperlio-gzip-perl. 163s Preparing to unpack .../237-libperlio-gzip-perl_0.20-1build5_ppc64el.deb ... 163s Unpacking libperlio-gzip-perl (0.20-1build5) ... 163s Selecting previously unselected package libperlio-utf8-strict-perl. 163s Preparing to unpack .../238-libperlio-utf8-strict-perl_0.010-1build4_ppc64el.deb ... 163s Unpacking libperlio-utf8-strict-perl (0.010-1build4) ... 163s Selecting previously unselected package libproc-processtable-perl:ppc64el. 163s Preparing to unpack .../239-libproc-processtable-perl_0.636-1build4_ppc64el.deb ... 163s Unpacking libproc-processtable-perl:ppc64el (0.636-1build4) ... 163s Selecting previously unselected package libregexp-wildcards-perl. 163s Preparing to unpack .../240-libregexp-wildcards-perl_1.05-3_all.deb ... 163s Unpacking libregexp-wildcards-perl (1.05-3) ... 163s Selecting previously unselected package libsereal-decoder-perl. 163s Preparing to unpack .../241-libsereal-decoder-perl_5.004+ds-1build4_ppc64el.deb ... 163s Unpacking libsereal-decoder-perl (5.004+ds-1build4) ... 163s Selecting previously unselected package libsereal-encoder-perl. 163s Preparing to unpack .../242-libsereal-encoder-perl_5.004+ds-1build4_ppc64el.deb ... 163s Unpacking libsereal-encoder-perl (5.004+ds-1build4) ... 163s Selecting previously unselected package libterm-readkey-perl. 163s Preparing to unpack .../243-libterm-readkey-perl_2.38-2build5_ppc64el.deb ... 163s Unpacking libterm-readkey-perl (2.38-2build5) ... 163s Selecting previously unselected package libtext-levenshteinxs-perl. 163s Preparing to unpack .../244-libtext-levenshteinxs-perl_0.03-5build5_ppc64el.deb ... 163s Unpacking libtext-levenshteinxs-perl (0.03-5build5) ... 163s Selecting previously unselected package libmarkdown2:ppc64el. 163s Preparing to unpack .../245-libmarkdown2_2.2.7-2ubuntu1_ppc64el.deb ... 163s Unpacking libmarkdown2:ppc64el (2.2.7-2ubuntu1) ... 163s Selecting previously unselected package libtext-markdown-discount-perl. 163s Preparing to unpack .../246-libtext-markdown-discount-perl_0.18-1_ppc64el.deb ... 163s Unpacking libtext-markdown-discount-perl (0.18-1) ... 163s Selecting previously unselected package libdata-messagepack-perl. 163s Preparing to unpack .../247-libdata-messagepack-perl_1.02-1build5_ppc64el.deb ... 163s Unpacking libdata-messagepack-perl (1.02-1build5) ... 163s Selecting previously unselected package libtext-xslate-perl:ppc64el. 163s Preparing to unpack .../248-libtext-xslate-perl_3.5.9-2build1_ppc64el.deb ... 163s Unpacking libtext-xslate-perl:ppc64el (3.5.9-2build1) ... 163s Selecting previously unselected package libtime-duration-perl. 163s Preparing to unpack .../249-libtime-duration-perl_1.21-2_all.deb ... 163s Unpacking libtime-duration-perl (1.21-2) ... 163s Selecting previously unselected package libtime-moment-perl. 163s Preparing to unpack .../250-libtime-moment-perl_0.44-2build5_ppc64el.deb ... 163s Unpacking libtime-moment-perl (0.44-2build5) ... 163s Selecting previously unselected package libunicode-utf8-perl. 163s Preparing to unpack .../251-libunicode-utf8-perl_0.62-2build4_ppc64el.deb ... 163s Unpacking libunicode-utf8-perl (0.62-2build4) ... 163s Selecting previously unselected package libcgi-pm-perl. 163s Preparing to unpack .../252-libcgi-pm-perl_4.67-1_all.deb ... 163s Unpacking libcgi-pm-perl (4.67-1) ... 163s Selecting previously unselected package libhtml-form-perl. 163s Preparing to unpack .../253-libhtml-form-perl_6.12-1_all.deb ... 163s Unpacking libhtml-form-perl (6.12-1) ... 163s Selecting previously unselected package libwww-mechanize-perl. 163s Preparing to unpack .../254-libwww-mechanize-perl_2.18-1ubuntu1_all.deb ... 163s Unpacking libwww-mechanize-perl (2.18-1ubuntu1) ... 163s Selecting previously unselected package libxml-namespacesupport-perl. 163s Preparing to unpack .../255-libxml-namespacesupport-perl_1.12-2_all.deb ... 163s Unpacking libxml-namespacesupport-perl (1.12-2) ... 163s Selecting previously unselected package libxml-sax-base-perl. 163s Preparing to unpack .../256-libxml-sax-base-perl_1.09-3_all.deb ... 163s Unpacking libxml-sax-base-perl (1.09-3) ... 163s Selecting previously unselected package libxml-sax-perl. 163s Preparing to unpack .../257-libxml-sax-perl_1.02+dfsg-4_all.deb ... 163s Unpacking libxml-sax-perl (1.02+dfsg-4) ... 163s Selecting previously unselected package libxml-libxml-perl. 163s Preparing to unpack .../258-libxml-libxml-perl_2.0207+dfsg+really+2.0134-5build1_ppc64el.deb ... 163s Unpacking libxml-libxml-perl (2.0207+dfsg+really+2.0134-5build1) ... 163s Selecting previously unselected package lzip. 163s Preparing to unpack .../259-lzip_1.25-1_ppc64el.deb ... 163s Unpacking lzip (1.25-1) ... 163s Selecting previously unselected package lzop. 163s Preparing to unpack .../260-lzop_1.04-2build3_ppc64el.deb ... 163s Unpacking lzop (1.04-2build3) ... 163s Selecting previously unselected package patchutils. 163s Preparing to unpack .../261-patchutils_0.4.2-1build3_ppc64el.deb ... 163s Unpacking patchutils (0.4.2-1build3) ... 163s Selecting previously unselected package t1utils. 163s Preparing to unpack .../262-t1utils_1.41-4build3_ppc64el.deb ... 163s Unpacking t1utils (1.41-4build3) ... 163s Selecting previously unselected package unzip. 163s Preparing to unpack .../263-unzip_6.0-28ubuntu6_ppc64el.deb ... 163s Unpacking unzip (6.0-28ubuntu6) ... 163s Selecting previously unselected package lintian. 163s Preparing to unpack .../264-lintian_2.121.1ubuntu1_all.deb ... 163s Unpacking lintian (2.121.1ubuntu1) ... 164s Selecting previously unselected package libconfig-model-dpkg-perl. 164s Preparing to unpack .../265-libconfig-model-dpkg-perl_3.010_all.deb ... 164s Unpacking libconfig-model-dpkg-perl (3.010) ... 164s Selecting previously unselected package libconvert-binhex-perl. 164s Preparing to unpack .../266-libconvert-binhex-perl_1.125-3_all.deb ... 164s Unpacking libconvert-binhex-perl (1.125-3) ... 164s Selecting previously unselected package libnet-smtp-ssl-perl. 164s Preparing to unpack .../267-libnet-smtp-ssl-perl_1.04-2_all.deb ... 164s Unpacking libnet-smtp-ssl-perl (1.04-2) ... 164s Selecting previously unselected package libmailtools-perl. 164s Preparing to unpack .../268-libmailtools-perl_2.22-1_all.deb ... 164s Unpacking libmailtools-perl (2.22-1) ... 164s Selecting previously unselected package libmime-tools-perl. 164s Preparing to unpack .../269-libmime-tools-perl_5.515-1_all.deb ... 164s Unpacking libmime-tools-perl (5.515-1) ... 164s Selecting previously unselected package libsuitesparseconfig7:ppc64el. 164s Preparing to unpack .../270-libsuitesparseconfig7_1%3a7.8.3+dfsg-3_ppc64el.deb ... 164s Unpacking libsuitesparseconfig7:ppc64el (1:7.8.3+dfsg-3) ... 164s Selecting previously unselected package libamd3:ppc64el. 164s Preparing to unpack .../271-libamd3_1%3a7.8.3+dfsg-3_ppc64el.deb ... 164s Unpacking libamd3:ppc64el (1:7.8.3+dfsg-3) ... 164s Selecting previously unselected package libblas3:ppc64el. 164s Preparing to unpack .../272-libblas3_3.12.1-2_ppc64el.deb ... 164s Unpacking libblas3:ppc64el (3.12.1-2) ... 164s Selecting previously unselected package libgfortran5:ppc64el. 164s Preparing to unpack .../273-libgfortran5_14.2.0-17ubuntu1_ppc64el.deb ... 164s Unpacking libgfortran5:ppc64el (14.2.0-17ubuntu1) ... 164s Selecting previously unselected package liblapack3:ppc64el. 164s Preparing to unpack .../274-liblapack3_3.12.1-2_ppc64el.deb ... 164s Unpacking liblapack3:ppc64el (3.12.1-2) ... 164s Selecting previously unselected package libarpack2t64:ppc64el. 164s Preparing to unpack .../275-libarpack2t64_3.9.1-4_ppc64el.deb ... 164s Unpacking libarpack2t64:ppc64el (3.9.1-4) ... 164s Selecting previously unselected package libccolamd3:ppc64el. 164s Preparing to unpack .../276-libccolamd3_1%3a7.8.3+dfsg-3_ppc64el.deb ... 164s Unpacking libccolamd3:ppc64el (1:7.8.3+dfsg-3) ... 164s Selecting previously unselected package libcamd3:ppc64el. 164s Preparing to unpack .../277-libcamd3_1%3a7.8.3+dfsg-3_ppc64el.deb ... 164s Unpacking libcamd3:ppc64el (1:7.8.3+dfsg-3) ... 164s Selecting previously unselected package libcolamd3:ppc64el. 164s Preparing to unpack .../278-libcolamd3_1%3a7.8.3+dfsg-3_ppc64el.deb ... 164s Unpacking libcolamd3:ppc64el (1:7.8.3+dfsg-3) ... 164s Selecting previously unselected package libcholmod5:ppc64el. 164s Preparing to unpack .../279-libcholmod5_1%3a7.8.3+dfsg-3_ppc64el.deb ... 164s Unpacking libcholmod5:ppc64el (1:7.8.3+dfsg-3) ... 164s Selecting previously unselected package libcxsparse4:ppc64el. 164s Preparing to unpack .../280-libcxsparse4_1%3a7.8.3+dfsg-3_ppc64el.deb ... 164s Unpacking libcxsparse4:ppc64el (1:7.8.3+dfsg-3) ... 164s Selecting previously unselected package libfftw3-double3:ppc64el. 164s Preparing to unpack .../281-libfftw3-double3_3.3.10-2fakesync1build1_ppc64el.deb ... 164s Unpacking libfftw3-double3:ppc64el (3.3.10-2fakesync1build1) ... 164s Selecting previously unselected package libfftw3-single3:ppc64el. 164s Preparing to unpack .../282-libfftw3-single3_3.3.10-2fakesync1build1_ppc64el.deb ... 164s Unpacking libfftw3-single3:ppc64el (3.3.10-2fakesync1build1) ... 164s Selecting previously unselected package libxfixes3:ppc64el. 164s Preparing to unpack .../283-libxfixes3_1%3a6.0.0-2build1_ppc64el.deb ... 164s Unpacking libxfixes3:ppc64el (1:6.0.0-2build1) ... 164s Selecting previously unselected package libxcursor1:ppc64el. 164s Preparing to unpack .../284-libxcursor1_1%3a1.2.3-1_ppc64el.deb ... 164s Unpacking libxcursor1:ppc64el (1:1.2.3-1) ... 164s Selecting previously unselected package libxft2:ppc64el. 164s Preparing to unpack .../285-libxft2_2.3.6-1build1_ppc64el.deb ... 164s Unpacking libxft2:ppc64el (2.3.6-1build1) ... 164s Selecting previously unselected package libxinerama1:ppc64el. 164s Preparing to unpack .../286-libxinerama1_2%3a1.1.4-3build1_ppc64el.deb ... 164s Unpacking libxinerama1:ppc64el (2:1.1.4-3build1) ... 164s Selecting previously unselected package libfltk1.3t64:ppc64el. 164s Preparing to unpack .../287-libfltk1.3t64_1.3.8-6.1build2_ppc64el.deb ... 164s Unpacking libfltk1.3t64:ppc64el (1.3.8-6.1build2) ... 164s Selecting previously unselected package libglvnd0:ppc64el. 164s Preparing to unpack .../288-libglvnd0_1.7.0-1build1_ppc64el.deb ... 164s Unpacking libglvnd0:ppc64el (1.7.0-1build1) ... 164s Selecting previously unselected package libglapi-mesa:ppc64el. 164s Preparing to unpack .../289-libglapi-mesa_24.3.4-3ubuntu1_ppc64el.deb ... 164s Unpacking libglapi-mesa:ppc64el (24.3.4-3ubuntu1) ... 164s Selecting previously unselected package libx11-xcb1:ppc64el. 164s Preparing to unpack .../290-libx11-xcb1_2%3a1.8.10-2_ppc64el.deb ... 164s Unpacking libx11-xcb1:ppc64el (2:1.8.10-2) ... 164s Selecting previously unselected package libxcb-dri3-0:ppc64el. 164s Preparing to unpack .../291-libxcb-dri3-0_1.17.0-2_ppc64el.deb ... 164s Unpacking libxcb-dri3-0:ppc64el (1.17.0-2) ... 164s Selecting previously unselected package libxcb-glx0:ppc64el. 164s Preparing to unpack .../292-libxcb-glx0_1.17.0-2_ppc64el.deb ... 164s Unpacking libxcb-glx0:ppc64el (1.17.0-2) ... 165s Selecting previously unselected package libxcb-present0:ppc64el. 165s Preparing to unpack .../293-libxcb-present0_1.17.0-2_ppc64el.deb ... 165s Unpacking libxcb-present0:ppc64el (1.17.0-2) ... 165s Selecting previously unselected package libxcb-xfixes0:ppc64el. 165s Preparing to unpack .../294-libxcb-xfixes0_1.17.0-2_ppc64el.deb ... 165s Unpacking libxcb-xfixes0:ppc64el (1.17.0-2) ... 165s Selecting previously unselected package libxxf86vm1:ppc64el. 165s Preparing to unpack .../295-libxxf86vm1_1%3a1.1.4-1build4_ppc64el.deb ... 165s Unpacking libxxf86vm1:ppc64el (1:1.1.4-1build4) ... 165s Selecting previously unselected package libdrm-radeon1:ppc64el. 165s Preparing to unpack .../296-libdrm-radeon1_2.4.123-1_ppc64el.deb ... 165s Unpacking libdrm-radeon1:ppc64el (2.4.123-1) ... 165s Selecting previously unselected package libxcb-randr0:ppc64el. 165s Preparing to unpack .../297-libxcb-randr0_1.17.0-2_ppc64el.deb ... 165s Unpacking libxcb-randr0:ppc64el (1.17.0-2) ... 165s Selecting previously unselected package libxcb-sync1:ppc64el. 165s Preparing to unpack .../298-libxcb-sync1_1.17.0-2_ppc64el.deb ... 165s Unpacking libxcb-sync1:ppc64el (1.17.0-2) ... 165s Selecting previously unselected package libxshmfence1:ppc64el. 165s Preparing to unpack .../299-libxshmfence1_1.3-1build5_ppc64el.deb ... 165s Unpacking libxshmfence1:ppc64el (1.3-1build5) ... 165s Selecting previously unselected package mesa-libgallium:ppc64el. 165s Preparing to unpack .../300-mesa-libgallium_24.3.4-3ubuntu1_ppc64el.deb ... 165s Unpacking mesa-libgallium:ppc64el (24.3.4-3ubuntu1) ... 165s Selecting previously unselected package libwayland-server0:ppc64el. 165s Preparing to unpack .../301-libwayland-server0_1.23.1-1_ppc64el.deb ... 165s Unpacking libwayland-server0:ppc64el (1.23.1-1) ... 165s Selecting previously unselected package libgbm1:ppc64el. 165s Preparing to unpack .../302-libgbm1_24.3.4-3ubuntu1_ppc64el.deb ... 165s Unpacking libgbm1:ppc64el (24.3.4-3ubuntu1) ... 165s Selecting previously unselected package libvulkan1:ppc64el. 165s Preparing to unpack .../303-libvulkan1_1.4.304.0-1_ppc64el.deb ... 165s Unpacking libvulkan1:ppc64el (1.4.304.0-1) ... 165s Selecting previously unselected package libgl1-mesa-dri:ppc64el. 165s Preparing to unpack .../304-libgl1-mesa-dri_24.3.4-3ubuntu1_ppc64el.deb ... 165s Unpacking libgl1-mesa-dri:ppc64el (24.3.4-3ubuntu1) ... 165s Selecting previously unselected package libglx-mesa0:ppc64el. 165s Preparing to unpack .../305-libglx-mesa0_24.3.4-3ubuntu1_ppc64el.deb ... 165s Unpacking libglx-mesa0:ppc64el (24.3.4-3ubuntu1) ... 165s Selecting previously unselected package libglx0:ppc64el. 165s Preparing to unpack .../306-libglx0_1.7.0-1build1_ppc64el.deb ... 165s Unpacking libglx0:ppc64el (1.7.0-1build1) ... 165s Selecting previously unselected package libgl1:ppc64el. 165s Preparing to unpack .../307-libgl1_1.7.0-1build1_ppc64el.deb ... 165s Unpacking libgl1:ppc64el (1.7.0-1build1) ... 165s Selecting previously unselected package libfltk-gl1.3t64:ppc64el. 165s Preparing to unpack .../308-libfltk-gl1.3t64_1.3.8-6.1build2_ppc64el.deb ... 165s Unpacking libfltk-gl1.3t64:ppc64el (1.3.8-6.1build2) ... 165s Selecting previously unselected package libgl2ps1.4. 165s Preparing to unpack .../309-libgl2ps1.4_1.4.2+dfsg1-2build1_ppc64el.deb ... 165s Unpacking libgl2ps1.4 (1.4.2+dfsg1-2build1) ... 165s Selecting previously unselected package libltdl7:ppc64el. 165s Preparing to unpack .../310-libltdl7_2.5.4-3build1_ppc64el.deb ... 165s Unpacking libltdl7:ppc64el (2.5.4-3build1) ... 165s Selecting previously unselected package libglpk40:ppc64el. 165s Preparing to unpack .../311-libglpk40_5.0-1build2_ppc64el.deb ... 165s Unpacking libglpk40:ppc64el (5.0-1build2) ... 165s Selecting previously unselected package libopengl0:ppc64el. 165s Preparing to unpack .../312-libopengl0_1.7.0-1build1_ppc64el.deb ... 165s Unpacking libopengl0:ppc64el (1.7.0-1build1) ... 165s Selecting previously unselected package libglu1-mesa:ppc64el. 165s Preparing to unpack .../313-libglu1-mesa_9.0.2-1.1build1_ppc64el.deb ... 165s Unpacking libglu1-mesa:ppc64el (9.0.2-1.1build1) ... 165s Selecting previously unselected package libhwy1t64:ppc64el. 165s Preparing to unpack .../314-libhwy1t64_1.2.0-3ubuntu3_ppc64el.deb ... 165s Unpacking libhwy1t64:ppc64el (1.2.0-3ubuntu3) ... 165s Selecting previously unselected package liblcms2-2:ppc64el. 165s Preparing to unpack .../315-liblcms2-2_2.16-2_ppc64el.deb ... 165s Unpacking liblcms2-2:ppc64el (2.16-2) ... 165s Selecting previously unselected package libjxl0.11:ppc64el. 165s Preparing to unpack .../316-libjxl0.11_0.11.1-1_ppc64el.deb ... 165s Unpacking libjxl0.11:ppc64el (0.11.1-1) ... 165s Selecting previously unselected package libwmflite-0.2-7:ppc64el. 165s Preparing to unpack .../317-libwmflite-0.2-7_0.2.13-1.1build3_ppc64el.deb ... 165s Unpacking libwmflite-0.2-7:ppc64el (0.2.13-1.1build3) ... 165s Selecting previously unselected package libgraphicsmagick-q16-3t64. 165s Preparing to unpack .../318-libgraphicsmagick-q16-3t64_1.4+really1.3.45-1build2_ppc64el.deb ... 165s Unpacking libgraphicsmagick-q16-3t64 (1.4+really1.3.45-1build2) ... 165s Selecting previously unselected package libgraphicsmagick++-q16-12t64. 165s Preparing to unpack .../319-libgraphicsmagick++-q16-12t64_1.4+really1.3.45-1build2_ppc64el.deb ... 165s Unpacking libgraphicsmagick++-q16-12t64 (1.4+really1.3.45-1build2) ... 165s Selecting previously unselected package libaec0:ppc64el. 165s Preparing to unpack .../320-libaec0_1.1.3-1_ppc64el.deb ... 165s Unpacking libaec0:ppc64el (1.1.3-1) ... 165s Selecting previously unselected package libsz2:ppc64el. 165s Preparing to unpack .../321-libsz2_1.1.3-1_ppc64el.deb ... 165s Unpacking libsz2:ppc64el (1.1.3-1) ... 165s Selecting previously unselected package libhdf5-310:ppc64el. 165s Preparing to unpack .../322-libhdf5-310_1.14.5+repack-3_ppc64el.deb ... 165s Unpacking libhdf5-310:ppc64el (1.14.5+repack-3) ... 165s Selecting previously unselected package libasound2-data. 165s Preparing to unpack .../323-libasound2-data_1.2.13-1build1_all.deb ... 165s Unpacking libasound2-data (1.2.13-1build1) ... 165s Selecting previously unselected package libasound2t64:ppc64el. 165s Preparing to unpack .../324-libasound2t64_1.2.13-1build1_ppc64el.deb ... 165s Unpacking libasound2t64:ppc64el (1.2.13-1build1) ... 165s Selecting previously unselected package libopus0:ppc64el. 166s Preparing to unpack .../325-libopus0_1.5.2-2_ppc64el.deb ... 166s Unpacking libopus0:ppc64el (1.5.2-2) ... 166s Selecting previously unselected package libsamplerate0:ppc64el. 166s Preparing to unpack .../326-libsamplerate0_0.2.2-4build1_ppc64el.deb ... 166s Unpacking libsamplerate0:ppc64el (0.2.2-4build1) ... 166s Selecting previously unselected package libjack-jackd2-0:ppc64el. 166s Preparing to unpack .../327-libjack-jackd2-0_1.9.22~dfsg-4_ppc64el.deb ... 166s Unpacking libjack-jackd2-0:ppc64el (1.9.22~dfsg-4) ... 166s Selecting previously unselected package libportaudio2:ppc64el. 166s Preparing to unpack .../328-libportaudio2_19.6.0-1.2build3_ppc64el.deb ... 166s Unpacking libportaudio2:ppc64el (19.6.0-1.2build3) ... 166s Selecting previously unselected package libqhull-r8.0:ppc64el. 166s Preparing to unpack .../329-libqhull-r8.0_2020.2-6build1_ppc64el.deb ... 166s Unpacking libqhull-r8.0:ppc64el (2020.2-6build1) ... 166s Selecting previously unselected package libqrupdate1:ppc64el. 166s Preparing to unpack .../330-libqrupdate1_1.1.5-1_ppc64el.deb ... 166s Unpacking libqrupdate1:ppc64el (1.1.5-1) ... 166s Selecting previously unselected package libqscintilla2-qt6-l10n. 166s Preparing to unpack .../331-libqscintilla2-qt6-l10n_2.14.1+dfsg-1build4_all.deb ... 166s Unpacking libqscintilla2-qt6-l10n (2.14.1+dfsg-1build4) ... 166s Selecting previously unselected package libb2-1:ppc64el. 166s Preparing to unpack .../332-libb2-1_0.98.1-1.1build1_ppc64el.deb ... 166s Unpacking libb2-1:ppc64el (0.98.1-1.1build1) ... 166s Selecting previously unselected package libdouble-conversion3:ppc64el. 166s Preparing to unpack .../333-libdouble-conversion3_3.3.0-1build1_ppc64el.deb ... 166s Unpacking libdouble-conversion3:ppc64el (3.3.0-1build1) ... 166s Selecting previously unselected package libpcre2-16-0:ppc64el. 166s Preparing to unpack .../334-libpcre2-16-0_10.42-4ubuntu3_ppc64el.deb ... 166s Unpacking libpcre2-16-0:ppc64el (10.42-4ubuntu3) ... 166s Selecting previously unselected package libqt6core6t64:ppc64el. 166s Preparing to unpack .../335-libqt6core6t64_6.8.1+dfsg-0ubuntu4_ppc64el.deb ... 166s Unpacking libqt6core6t64:ppc64el (6.8.1+dfsg-0ubuntu4) ... 166s Selecting previously unselected package libwayland-client0:ppc64el. 166s Preparing to unpack .../336-libwayland-client0_1.23.1-1_ppc64el.deb ... 166s Unpacking libwayland-client0:ppc64el (1.23.1-1) ... 166s Selecting previously unselected package libegl-mesa0:ppc64el. 166s Preparing to unpack .../337-libegl-mesa0_24.3.4-3ubuntu1_ppc64el.deb ... 166s Unpacking libegl-mesa0:ppc64el (24.3.4-3ubuntu1) ... 166s Selecting previously unselected package libegl1:ppc64el. 166s Preparing to unpack .../338-libegl1_1.7.0-1build1_ppc64el.deb ... 166s Unpacking libegl1:ppc64el (1.7.0-1build1) ... 166s Selecting previously unselected package x11-common. 166s Preparing to unpack .../339-x11-common_1%3a7.7+23ubuntu3_all.deb ... 166s Unpacking x11-common (1:7.7+23ubuntu3) ... 166s Selecting previously unselected package libice6:ppc64el. 166s Preparing to unpack .../340-libice6_2%3a1.1.1-1_ppc64el.deb ... 166s Unpacking libice6:ppc64el (2:1.1.1-1) ... 166s Selecting previously unselected package libmtdev1t64:ppc64el. 166s Preparing to unpack .../341-libmtdev1t64_1.1.7-1_ppc64el.deb ... 166s Unpacking libmtdev1t64:ppc64el (1.1.7-1) ... 166s Selecting previously unselected package libwacom-common. 166s Preparing to unpack .../342-libwacom-common_2.14.0-1_all.deb ... 166s Unpacking libwacom-common (2.14.0-1) ... 166s Selecting previously unselected package libwacom9:ppc64el. 166s Preparing to unpack .../343-libwacom9_2.14.0-1_ppc64el.deb ... 166s Unpacking libwacom9:ppc64el (2.14.0-1) ... 166s Selecting previously unselected package libinput-bin. 166s Preparing to unpack .../344-libinput-bin_1.27.1-1_ppc64el.deb ... 166s Unpacking libinput-bin (1.27.1-1) ... 166s Selecting previously unselected package libinput10:ppc64el. 166s Preparing to unpack .../345-libinput10_1.27.1-1_ppc64el.deb ... 166s Unpacking libinput10:ppc64el (1.27.1-1) ... 166s Selecting previously unselected package libmd4c0:ppc64el. 166s Preparing to unpack .../346-libmd4c0_0.5.2-2_ppc64el.deb ... 166s Unpacking libmd4c0:ppc64el (0.5.2-2) ... 166s Selecting previously unselected package libqt6dbus6:ppc64el. 166s Preparing to unpack .../347-libqt6dbus6_6.8.1+dfsg-0ubuntu4_ppc64el.deb ... 166s Unpacking libqt6dbus6:ppc64el (6.8.1+dfsg-0ubuntu4) ... 166s Selecting previously unselected package libsm6:ppc64el. 166s Preparing to unpack .../348-libsm6_2%3a1.2.4-1_ppc64el.deb ... 166s Unpacking libsm6:ppc64el (2:1.2.4-1) ... 166s Selecting previously unselected package libts0t64:ppc64el. 166s Preparing to unpack .../349-libts0t64_1.22-1.1build1_ppc64el.deb ... 166s Unpacking libts0t64:ppc64el (1.22-1.1build1) ... 166s Selecting previously unselected package libxcb-util1:ppc64el. 166s Preparing to unpack .../350-libxcb-util1_0.4.1-1_ppc64el.deb ... 166s Unpacking libxcb-util1:ppc64el (0.4.1-1) ... 166s Selecting previously unselected package libxcb-image0:ppc64el. 166s Preparing to unpack .../351-libxcb-image0_0.4.0-2build1_ppc64el.deb ... 166s Unpacking libxcb-image0:ppc64el (0.4.0-2build1) ... 166s Selecting previously unselected package libxcb-render-util0:ppc64el. 166s Preparing to unpack .../352-libxcb-render-util0_0.3.10-1_ppc64el.deb ... 166s Unpacking libxcb-render-util0:ppc64el (0.3.10-1) ... 166s Selecting previously unselected package libxcb-cursor0:ppc64el. 166s Preparing to unpack .../353-libxcb-cursor0_0.1.5-1_ppc64el.deb ... 166s Unpacking libxcb-cursor0:ppc64el (0.1.5-1) ... 166s Selecting previously unselected package libxcb-icccm4:ppc64el. 166s Preparing to unpack .../354-libxcb-icccm4_0.4.2-1_ppc64el.deb ... 166s Unpacking libxcb-icccm4:ppc64el (0.4.2-1) ... 166s Selecting previously unselected package libxcb-keysyms1:ppc64el. 166s Preparing to unpack .../355-libxcb-keysyms1_0.4.1-1_ppc64el.deb ... 166s Unpacking libxcb-keysyms1:ppc64el (0.4.1-1) ... 166s Selecting previously unselected package libxcb-shape0:ppc64el. 166s Preparing to unpack .../356-libxcb-shape0_1.17.0-2_ppc64el.deb ... 166s Unpacking libxcb-shape0:ppc64el (1.17.0-2) ... 166s Selecting previously unselected package libxcb-xinput0:ppc64el. 166s Preparing to unpack .../357-libxcb-xinput0_1.17.0-2_ppc64el.deb ... 166s Unpacking libxcb-xinput0:ppc64el (1.17.0-2) ... 166s Selecting previously unselected package libxcb-xkb1:ppc64el. 166s Preparing to unpack .../358-libxcb-xkb1_1.17.0-2_ppc64el.deb ... 166s Unpacking libxcb-xkb1:ppc64el (1.17.0-2) ... 166s Selecting previously unselected package libxkbcommon-x11-0:ppc64el. 166s Preparing to unpack .../359-libxkbcommon-x11-0_1.7.0-2_ppc64el.deb ... 166s Unpacking libxkbcommon-x11-0:ppc64el (1.7.0-2) ... 166s Selecting previously unselected package libqt6gui6:ppc64el. 167s Preparing to unpack .../360-libqt6gui6_6.8.1+dfsg-0ubuntu4_ppc64el.deb ... 167s Unpacking libqt6gui6:ppc64el (6.8.1+dfsg-0ubuntu4) ... 167s Selecting previously unselected package libavahi-common-data:ppc64el. 167s Preparing to unpack .../361-libavahi-common-data_0.8-14ubuntu1_ppc64el.deb ... 167s Unpacking libavahi-common-data:ppc64el (0.8-14ubuntu1) ... 167s Selecting previously unselected package libavahi-common3:ppc64el. 167s Preparing to unpack .../362-libavahi-common3_0.8-14ubuntu1_ppc64el.deb ... 167s Unpacking libavahi-common3:ppc64el (0.8-14ubuntu1) ... 167s Selecting previously unselected package libavahi-client3:ppc64el. 167s Preparing to unpack .../363-libavahi-client3_0.8-14ubuntu1_ppc64el.deb ... 167s Unpacking libavahi-client3:ppc64el (0.8-14ubuntu1) ... 167s Selecting previously unselected package libcups2t64:ppc64el. 167s Preparing to unpack .../364-libcups2t64_2.4.11-0ubuntu2_ppc64el.deb ... 167s Unpacking libcups2t64:ppc64el (2.4.11-0ubuntu2) ... 167s Selecting previously unselected package libqt6widgets6:ppc64el. 167s Preparing to unpack .../365-libqt6widgets6_6.8.1+dfsg-0ubuntu4_ppc64el.deb ... 167s Unpacking libqt6widgets6:ppc64el (6.8.1+dfsg-0ubuntu4) ... 167s Selecting previously unselected package libqt6printsupport6:ppc64el. 167s Preparing to unpack .../366-libqt6printsupport6_6.8.1+dfsg-0ubuntu4_ppc64el.deb ... 167s Unpacking libqt6printsupport6:ppc64el (6.8.1+dfsg-0ubuntu4) ... 167s Selecting previously unselected package libqscintilla2-qt6-15:ppc64el. 167s Preparing to unpack .../367-libqscintilla2-qt6-15_2.14.1+dfsg-1build4_ppc64el.deb ... 167s Unpacking libqscintilla2-qt6-15:ppc64el (2.14.1+dfsg-1build4) ... 167s Selecting previously unselected package libqt6core5compat6:ppc64el. 167s Preparing to unpack .../368-libqt6core5compat6_6.8.1-0ubuntu2_ppc64el.deb ... 167s Unpacking libqt6core5compat6:ppc64el (6.8.1-0ubuntu2) ... 167s Selecting previously unselected package libqt6sql6:ppc64el. 167s Preparing to unpack .../369-libqt6sql6_6.8.1+dfsg-0ubuntu4_ppc64el.deb ... 167s Unpacking libqt6sql6:ppc64el (6.8.1+dfsg-0ubuntu4) ... 167s Selecting previously unselected package libqt6help6:ppc64el. 167s Preparing to unpack .../370-libqt6help6_6.8.1-0ubuntu1_ppc64el.deb ... 167s Unpacking libqt6help6:ppc64el (6.8.1-0ubuntu1) ... 167s Selecting previously unselected package libduktape207:ppc64el. 167s Preparing to unpack .../371-libduktape207_2.7.0+tests-0ubuntu3_ppc64el.deb ... 167s Unpacking libduktape207:ppc64el (2.7.0+tests-0ubuntu3) ... 167s Selecting previously unselected package libproxy1v5:ppc64el. 167s Preparing to unpack .../372-libproxy1v5_0.5.9-1_ppc64el.deb ... 167s Unpacking libproxy1v5:ppc64el (0.5.9-1) ... 167s Selecting previously unselected package libqt6network6:ppc64el. 167s Preparing to unpack .../373-libqt6network6_6.8.1+dfsg-0ubuntu4_ppc64el.deb ... 167s Unpacking libqt6network6:ppc64el (6.8.1+dfsg-0ubuntu4) ... 167s Selecting previously unselected package libqt6opengl6:ppc64el. 167s Preparing to unpack .../374-libqt6opengl6_6.8.1+dfsg-0ubuntu4_ppc64el.deb ... 167s Unpacking libqt6opengl6:ppc64el (6.8.1+dfsg-0ubuntu4) ... 167s Selecting previously unselected package libqt6openglwidgets6:ppc64el. 167s Preparing to unpack .../375-libqt6openglwidgets6_6.8.1+dfsg-0ubuntu4_ppc64el.deb ... 167s Unpacking libqt6openglwidgets6:ppc64el (6.8.1+dfsg-0ubuntu4) ... 167s Selecting previously unselected package libqt6xml6:ppc64el. 167s Preparing to unpack .../376-libqt6xml6_6.8.1+dfsg-0ubuntu4_ppc64el.deb ... 167s Unpacking libqt6xml6:ppc64el (6.8.1+dfsg-0ubuntu4) ... 167s Selecting previously unselected package libogg0:ppc64el. 167s Preparing to unpack .../377-libogg0_1.3.5-3build1_ppc64el.deb ... 167s Unpacking libogg0:ppc64el (1.3.5-3build1) ... 167s Selecting previously unselected package libflac12t64:ppc64el. 167s Preparing to unpack .../378-libflac12t64_1.4.3+ds-4_ppc64el.deb ... 167s Unpacking libflac12t64:ppc64el (1.4.3+ds-4) ... 167s Selecting previously unselected package libmp3lame0:ppc64el. 167s Preparing to unpack .../379-libmp3lame0_3.100-6build1_ppc64el.deb ... 167s Unpacking libmp3lame0:ppc64el (3.100-6build1) ... 167s Selecting previously unselected package libmpg123-0t64:ppc64el. 167s Preparing to unpack .../380-libmpg123-0t64_1.32.10-1_ppc64el.deb ... 167s Unpacking libmpg123-0t64:ppc64el (1.32.10-1) ... 167s Selecting previously unselected package libvorbis0a:ppc64el. 167s Preparing to unpack .../381-libvorbis0a_1.3.7-2_ppc64el.deb ... 167s Unpacking libvorbis0a:ppc64el (1.3.7-2) ... 167s Selecting previously unselected package libvorbisenc2:ppc64el. 167s Preparing to unpack .../382-libvorbisenc2_1.3.7-2_ppc64el.deb ... 167s Unpacking libvorbisenc2:ppc64el (1.3.7-2) ... 167s Selecting previously unselected package libsndfile1:ppc64el. 167s Preparing to unpack .../383-libsndfile1_1.2.2-2_ppc64el.deb ... 167s Unpacking libsndfile1:ppc64el (1.2.2-2) ... 167s Selecting previously unselected package libspqr4:ppc64el. 167s Preparing to unpack .../384-libspqr4_1%3a7.8.3+dfsg-3_ppc64el.deb ... 167s Unpacking libspqr4:ppc64el (1:7.8.3+dfsg-3) ... 167s Selecting previously unselected package libumfpack6:ppc64el. 167s Preparing to unpack .../385-libumfpack6_1%3a7.8.3+dfsg-3_ppc64el.deb ... 167s Unpacking libumfpack6:ppc64el (1:7.8.3+dfsg-3) ... 167s Selecting previously unselected package libtext-unidecode-perl. 167s Preparing to unpack .../386-libtext-unidecode-perl_1.30-3_all.deb ... 167s Unpacking libtext-unidecode-perl (1.30-3) ... 167s Selecting previously unselected package texinfo-lib. 167s Preparing to unpack .../387-texinfo-lib_7.1.1-1_ppc64el.deb ... 167s Unpacking texinfo-lib (7.1.1-1) ... 167s Selecting previously unselected package tex-common. 167s Preparing to unpack .../388-tex-common_6.18_all.deb ... 167s Unpacking tex-common (6.18) ... 167s Selecting previously unselected package texinfo. 167s Preparing to unpack .../389-texinfo_7.1.1-1_all.deb ... 167s Unpacking texinfo (7.1.1-1) ... 167s Selecting previously unselected package octave-common. 167s Preparing to unpack .../390-octave-common_9.4.0-1_all.deb ... 167s Unpacking octave-common (9.4.0-1) ... 168s Selecting previously unselected package octave. 168s Preparing to unpack .../391-octave_9.4.0-1_ppc64el.deb ... 168s Unpacking octave (9.4.0-1) ... 168s Selecting previously unselected package libncurses-dev:ppc64el. 168s Preparing to unpack .../392-libncurses-dev_6.5+20250125-2_ppc64el.deb ... 168s Unpacking libncurses-dev:ppc64el (6.5+20250125-2) ... 168s Selecting previously unselected package libreadline-dev:ppc64el. 168s Preparing to unpack .../393-libreadline-dev_8.2-6_ppc64el.deb ... 168s Unpacking libreadline-dev:ppc64el (8.2-6) ... 168s Selecting previously unselected package libhdf5-fortran-310:ppc64el. 168s Preparing to unpack .../394-libhdf5-fortran-310_1.14.5+repack-3_ppc64el.deb ... 168s Unpacking libhdf5-fortran-310:ppc64el (1.14.5+repack-3) ... 168s Selecting previously unselected package libhdf5-hl-310:ppc64el. 168s Preparing to unpack .../395-libhdf5-hl-310_1.14.5+repack-3_ppc64el.deb ... 168s Unpacking libhdf5-hl-310:ppc64el (1.14.5+repack-3) ... 168s Selecting previously unselected package libhdf5-hl-fortran-310:ppc64el. 168s Preparing to unpack .../396-libhdf5-hl-fortran-310_1.14.5+repack-3_ppc64el.deb ... 168s Unpacking libhdf5-hl-fortran-310:ppc64el (1.14.5+repack-3) ... 168s Selecting previously unselected package libhdf5-cpp-310:ppc64el. 168s Preparing to unpack .../397-libhdf5-cpp-310_1.14.5+repack-3_ppc64el.deb ... 168s Unpacking libhdf5-cpp-310:ppc64el (1.14.5+repack-3) ... 168s Selecting previously unselected package libhdf5-hl-cpp-310:ppc64el. 168s Preparing to unpack .../398-libhdf5-hl-cpp-310_1.14.5+repack-3_ppc64el.deb ... 168s Unpacking libhdf5-hl-cpp-310:ppc64el (1.14.5+repack-3) ... 168s Selecting previously unselected package zlib1g-dev:ppc64el. 168s Preparing to unpack .../399-zlib1g-dev_1%3a1.3.dfsg+really1.3.1-1ubuntu1_ppc64el.deb ... 168s Unpacking zlib1g-dev:ppc64el (1:1.3.dfsg+really1.3.1-1ubuntu1) ... 168s Selecting previously unselected package libjpeg-turbo8-dev:ppc64el. 168s Preparing to unpack .../400-libjpeg-turbo8-dev_2.1.5-3ubuntu2_ppc64el.deb ... 168s Unpacking libjpeg-turbo8-dev:ppc64el (2.1.5-3ubuntu2) ... 168s Selecting previously unselected package libjpeg8-dev:ppc64el. 168s Preparing to unpack .../401-libjpeg8-dev_8c-2ubuntu11_ppc64el.deb ... 168s Unpacking libjpeg8-dev:ppc64el (8c-2ubuntu11) ... 168s Selecting previously unselected package libjpeg-dev:ppc64el. 168s Preparing to unpack .../402-libjpeg-dev_8c-2ubuntu11_ppc64el.deb ... 168s Unpacking libjpeg-dev:ppc64el (8c-2ubuntu11) ... 168s Selecting previously unselected package libaec-dev:ppc64el. 168s Preparing to unpack .../403-libaec-dev_1.1.3-1_ppc64el.deb ... 168s Unpacking libaec-dev:ppc64el (1.1.3-1) ... 168s Selecting previously unselected package libbrotli-dev:ppc64el. 168s Preparing to unpack .../404-libbrotli-dev_1.1.0-2build3_ppc64el.deb ... 168s Unpacking libbrotli-dev:ppc64el (1.1.0-2build3) ... 168s Selecting previously unselected package libidn2-dev:ppc64el. 168s Preparing to unpack .../405-libidn2-dev_2.3.7-2build2_ppc64el.deb ... 168s Unpacking libidn2-dev:ppc64el (2.3.7-2build2) ... 168s Selecting previously unselected package comerr-dev:ppc64el. 168s Preparing to unpack .../406-comerr-dev_2.1-1.47.2-1ubuntu1_ppc64el.deb ... 168s Unpacking comerr-dev:ppc64el (2.1-1.47.2-1ubuntu1) ... 168s Selecting previously unselected package libgssrpc4t64:ppc64el. 168s Preparing to unpack .../407-libgssrpc4t64_1.21.3-4ubuntu1_ppc64el.deb ... 168s Unpacking libgssrpc4t64:ppc64el (1.21.3-4ubuntu1) ... 168s Selecting previously unselected package libkadm5clnt-mit12:ppc64el. 168s Preparing to unpack .../408-libkadm5clnt-mit12_1.21.3-4ubuntu1_ppc64el.deb ... 168s Unpacking libkadm5clnt-mit12:ppc64el (1.21.3-4ubuntu1) ... 169s Selecting previously unselected package libkdb5-10t64:ppc64el. 169s Preparing to unpack .../409-libkdb5-10t64_1.21.3-4ubuntu1_ppc64el.deb ... 169s Unpacking libkdb5-10t64:ppc64el (1.21.3-4ubuntu1) ... 169s Selecting previously unselected package libkadm5srv-mit12:ppc64el. 169s Preparing to unpack .../410-libkadm5srv-mit12_1.21.3-4ubuntu1_ppc64el.deb ... 169s Unpacking libkadm5srv-mit12:ppc64el (1.21.3-4ubuntu1) ... 169s Selecting previously unselected package krb5-multidev:ppc64el. 169s Preparing to unpack .../411-krb5-multidev_1.21.3-4ubuntu1_ppc64el.deb ... 169s Unpacking krb5-multidev:ppc64el (1.21.3-4ubuntu1) ... 169s Selecting previously unselected package libkrb5-dev:ppc64el. 169s Preparing to unpack .../412-libkrb5-dev_1.21.3-4ubuntu1_ppc64el.deb ... 169s Unpacking libkrb5-dev:ppc64el (1.21.3-4ubuntu1) ... 169s Selecting previously unselected package libldap-dev:ppc64el. 169s Preparing to unpack .../413-libldap-dev_2.6.9+dfsg-1~exp2ubuntu1_ppc64el.deb ... 169s Unpacking libldap-dev:ppc64el (2.6.9+dfsg-1~exp2ubuntu1) ... 169s Selecting previously unselected package libpkgconf3:ppc64el. 169s Preparing to unpack .../414-libpkgconf3_1.8.1-4_ppc64el.deb ... 169s Unpacking libpkgconf3:ppc64el (1.8.1-4) ... 169s Selecting previously unselected package pkgconf-bin. 169s Preparing to unpack .../415-pkgconf-bin_1.8.1-4_ppc64el.deb ... 169s Unpacking pkgconf-bin (1.8.1-4) ... 169s Selecting previously unselected package pkgconf:ppc64el. 169s Preparing to unpack .../416-pkgconf_1.8.1-4_ppc64el.deb ... 169s Unpacking pkgconf:ppc64el (1.8.1-4) ... 169s Selecting previously unselected package libnghttp2-dev:ppc64el. 169s Preparing to unpack .../417-libnghttp2-dev_1.64.0-1_ppc64el.deb ... 169s Unpacking libnghttp2-dev:ppc64el (1.64.0-1) ... 169s Selecting previously unselected package libpsl-dev:ppc64el. 169s Preparing to unpack .../418-libpsl-dev_0.21.2-1.1build1_ppc64el.deb ... 169s Unpacking libpsl-dev:ppc64el (0.21.2-1.1build1) ... 169s Selecting previously unselected package libgmpxx4ldbl:ppc64el. 169s Preparing to unpack .../419-libgmpxx4ldbl_2%3a6.3.0+dfsg-2ubuntu7_ppc64el.deb ... 169s Unpacking libgmpxx4ldbl:ppc64el (2:6.3.0+dfsg-2ubuntu7) ... 169s Selecting previously unselected package libgmp-dev:ppc64el. 169s Preparing to unpack .../420-libgmp-dev_2%3a6.3.0+dfsg-2ubuntu7_ppc64el.deb ... 169s Unpacking libgmp-dev:ppc64el (2:6.3.0+dfsg-2ubuntu7) ... 169s Selecting previously unselected package libevent-2.1-7t64:ppc64el. 169s Preparing to unpack .../421-libevent-2.1-7t64_2.1.12-stable-10_ppc64el.deb ... 169s Unpacking libevent-2.1-7t64:ppc64el (2.1.12-stable-10) ... 169s Selecting previously unselected package libunbound8:ppc64el. 169s Preparing to unpack .../422-libunbound8_1.22.0-1ubuntu1_ppc64el.deb ... 169s Unpacking libunbound8:ppc64el (1.22.0-1ubuntu1) ... 169s Selecting previously unselected package libgnutls-dane0t64:ppc64el. 169s Preparing to unpack .../423-libgnutls-dane0t64_3.8.9-2ubuntu1_ppc64el.deb ... 169s Unpacking libgnutls-dane0t64:ppc64el (3.8.9-2ubuntu1) ... 169s Selecting previously unselected package libgnutls-openssl27t64:ppc64el. 169s Preparing to unpack .../424-libgnutls-openssl27t64_3.8.9-2ubuntu1_ppc64el.deb ... 169s Unpacking libgnutls-openssl27t64:ppc64el (3.8.9-2ubuntu1) ... 169s Selecting previously unselected package libp11-kit-dev:ppc64el. 169s Preparing to unpack .../425-libp11-kit-dev_0.25.5-2ubuntu2_ppc64el.deb ... 169s Unpacking libp11-kit-dev:ppc64el (0.25.5-2ubuntu2) ... 169s Selecting previously unselected package libtasn1-6-dev:ppc64el. 169s Preparing to unpack .../426-libtasn1-6-dev_4.20.0-2_ppc64el.deb ... 169s Unpacking libtasn1-6-dev:ppc64el (4.20.0-2) ... 169s Selecting previously unselected package nettle-dev:ppc64el. 169s Preparing to unpack .../427-nettle-dev_3.10-1_ppc64el.deb ... 169s Unpacking nettle-dev:ppc64el (3.10-1) ... 169s Selecting previously unselected package libgnutls28-dev:ppc64el. 169s Preparing to unpack .../428-libgnutls28-dev_3.8.9-2ubuntu1_ppc64el.deb ... 169s Unpacking libgnutls28-dev:ppc64el (3.8.9-2ubuntu1) ... 169s Selecting previously unselected package librtmp-dev:ppc64el. 169s Preparing to unpack .../429-librtmp-dev_2.4+20151223.gitfa8646d.1-2build7_ppc64el.deb ... 169s Unpacking librtmp-dev:ppc64el (2.4+20151223.gitfa8646d.1-2build7) ... 169s Selecting previously unselected package libssl-dev:ppc64el. 169s Preparing to unpack .../430-libssl-dev_3.4.0-1ubuntu2_ppc64el.deb ... 169s Unpacking libssl-dev:ppc64el (3.4.0-1ubuntu2) ... 169s Selecting previously unselected package libssh2-1-dev:ppc64el. 169s Preparing to unpack .../431-libssh2-1-dev_1.11.1-1_ppc64el.deb ... 169s Unpacking libssh2-1-dev:ppc64el (1.11.1-1) ... 169s Selecting previously unselected package libzstd-dev:ppc64el. 169s Preparing to unpack .../432-libzstd-dev_1.5.6+dfsg-2_ppc64el.deb ... 169s Unpacking libzstd-dev:ppc64el (1.5.6+dfsg-2) ... 169s Selecting previously unselected package libcurl4-openssl-dev:ppc64el. 169s Preparing to unpack .../433-libcurl4-openssl-dev_8.12.0+git20250209.89ed161+ds-1ubuntu1_ppc64el.deb ... 169s Unpacking libcurl4-openssl-dev:ppc64el (8.12.0+git20250209.89ed161+ds-1ubuntu1) ... 169s Selecting previously unselected package hdf5-helpers. 169s Preparing to unpack .../434-hdf5-helpers_1.14.5+repack-3_ppc64el.deb ... 169s Unpacking hdf5-helpers (1.14.5+repack-3) ... 169s Selecting previously unselected package libhdf5-dev. 169s Preparing to unpack .../435-libhdf5-dev_1.14.5+repack-3_ppc64el.deb ... 169s Unpacking libhdf5-dev (1.14.5+repack-3) ... 170s Selecting previously unselected package xorg-sgml-doctools. 170s Preparing to unpack .../436-xorg-sgml-doctools_1%3a1.11-1.1_all.deb ... 170s Unpacking xorg-sgml-doctools (1:1.11-1.1) ... 170s Selecting previously unselected package x11proto-dev. 170s Preparing to unpack .../437-x11proto-dev_2024.1-1_all.deb ... 170s Unpacking x11proto-dev (2024.1-1) ... 170s Selecting previously unselected package libxau-dev:ppc64el. 170s Preparing to unpack .../438-libxau-dev_1%3a1.0.11-1_ppc64el.deb ... 170s Unpacking libxau-dev:ppc64el (1:1.0.11-1) ... 170s Selecting previously unselected package libxdmcp-dev:ppc64el. 170s Preparing to unpack .../439-libxdmcp-dev_1%3a1.1.5-1_ppc64el.deb ... 170s Unpacking libxdmcp-dev:ppc64el (1:1.1.5-1) ... 170s Selecting previously unselected package xtrans-dev. 170s Preparing to unpack .../440-xtrans-dev_1.4.0-1_all.deb ... 170s Unpacking xtrans-dev (1.4.0-1) ... 170s Selecting previously unselected package libxcb1-dev:ppc64el. 170s Preparing to unpack .../441-libxcb1-dev_1.17.0-2_ppc64el.deb ... 170s Unpacking libxcb1-dev:ppc64el (1.17.0-2) ... 170s Selecting previously unselected package libx11-dev:ppc64el. 170s Preparing to unpack .../442-libx11-dev_2%3a1.8.10-2_ppc64el.deb ... 170s Unpacking libx11-dev:ppc64el (2:1.8.10-2) ... 170s Selecting previously unselected package libglx-dev:ppc64el. 170s Preparing to unpack .../443-libglx-dev_1.7.0-1build1_ppc64el.deb ... 170s Unpacking libglx-dev:ppc64el (1.7.0-1build1) ... 170s Selecting previously unselected package libgl-dev:ppc64el. 170s Preparing to unpack .../444-libgl-dev_1.7.0-1build1_ppc64el.deb ... 170s Unpacking libgl-dev:ppc64el (1.7.0-1build1) ... 170s Selecting previously unselected package libblas-dev:ppc64el. 170s Preparing to unpack .../445-libblas-dev_3.12.1-2_ppc64el.deb ... 170s Unpacking libblas-dev:ppc64el (3.12.1-2) ... 170s Selecting previously unselected package liblapack-dev:ppc64el. 170s Preparing to unpack .../446-liblapack-dev_3.12.1-2_ppc64el.deb ... 170s Unpacking liblapack-dev:ppc64el (3.12.1-2) ... 170s Selecting previously unselected package libfftw3-long3:ppc64el. 170s Preparing to unpack .../447-libfftw3-long3_3.3.10-2fakesync1build1_ppc64el.deb ... 170s Unpacking libfftw3-long3:ppc64el (3.3.10-2fakesync1build1) ... 170s Selecting previously unselected package libfftw3-bin. 170s Preparing to unpack .../448-libfftw3-bin_3.3.10-2fakesync1build1_ppc64el.deb ... 170s Unpacking libfftw3-bin (3.3.10-2fakesync1build1) ... 170s Selecting previously unselected package libfftw3-dev:ppc64el. 170s Preparing to unpack .../449-libfftw3-dev_3.3.10-2fakesync1build1_ppc64el.deb ... 170s Unpacking libfftw3-dev:ppc64el (3.3.10-2fakesync1build1) ... 170s Selecting previously unselected package libgfortran-14-dev:ppc64el. 170s Preparing to unpack .../450-libgfortran-14-dev_14.2.0-17ubuntu1_ppc64el.deb ... 170s Unpacking libgfortran-14-dev:ppc64el (14.2.0-17ubuntu1) ... 170s Selecting previously unselected package gfortran-14-powerpc64le-linux-gnu. 170s Preparing to unpack .../451-gfortran-14-powerpc64le-linux-gnu_14.2.0-17ubuntu1_ppc64el.deb ... 170s Unpacking gfortran-14-powerpc64le-linux-gnu (14.2.0-17ubuntu1) ... 170s Selecting previously unselected package gfortran-14. 170s Preparing to unpack .../452-gfortran-14_14.2.0-17ubuntu1_ppc64el.deb ... 170s Unpacking gfortran-14 (14.2.0-17ubuntu1) ... 170s Selecting previously unselected package gfortran-powerpc64le-linux-gnu. 170s Preparing to unpack .../453-gfortran-powerpc64le-linux-gnu_4%3a14.2.0-1ubuntu1_ppc64el.deb ... 170s Unpacking gfortran-powerpc64le-linux-gnu (4:14.2.0-1ubuntu1) ... 170s Selecting previously unselected package gfortran. 170s Preparing to unpack .../454-gfortran_4%3a14.2.0-1ubuntu1_ppc64el.deb ... 170s Unpacking gfortran (4:14.2.0-1ubuntu1) ... 170s Selecting previously unselected package libstdc++-14-dev:ppc64el. 170s Preparing to unpack .../455-libstdc++-14-dev_14.2.0-17ubuntu1_ppc64el.deb ... 170s Unpacking libstdc++-14-dev:ppc64el (14.2.0-17ubuntu1) ... 171s Selecting previously unselected package g++-14-powerpc64le-linux-gnu. 171s Preparing to unpack .../456-g++-14-powerpc64le-linux-gnu_14.2.0-17ubuntu1_ppc64el.deb ... 171s Unpacking g++-14-powerpc64le-linux-gnu (14.2.0-17ubuntu1) ... 171s Selecting previously unselected package g++-14. 171s Preparing to unpack .../457-g++-14_14.2.0-17ubuntu1_ppc64el.deb ... 171s Unpacking g++-14 (14.2.0-17ubuntu1) ... 171s Selecting previously unselected package g++-powerpc64le-linux-gnu. 171s Preparing to unpack .../458-g++-powerpc64le-linux-gnu_4%3a14.2.0-1ubuntu1_ppc64el.deb ... 171s Unpacking g++-powerpc64le-linux-gnu (4:14.2.0-1ubuntu1) ... 171s Selecting previously unselected package g++. 171s Preparing to unpack .../459-g++_4%3a14.2.0-1ubuntu1_ppc64el.deb ... 171s Unpacking g++ (4:14.2.0-1ubuntu1) ... 171s Selecting previously unselected package octave-dev. 171s Preparing to unpack .../460-octave-dev_9.4.0-1_ppc64el.deb ... 171s Unpacking octave-dev (9.4.0-1) ... 171s Selecting previously unselected package dh-octave. 171s Preparing to unpack .../461-dh-octave_1.8.0_all.deb ... 171s Unpacking dh-octave (1.8.0) ... 171s Selecting previously unselected package libfontenc1:ppc64el. 171s Preparing to unpack .../462-libfontenc1_1%3a1.1.8-1build1_ppc64el.deb ... 171s Unpacking libfontenc1:ppc64el (1:1.1.8-1build1) ... 171s Selecting previously unselected package libxt6t64:ppc64el. 171s Preparing to unpack .../463-libxt6t64_1%3a1.2.1-1.2build1_ppc64el.deb ... 171s Unpacking libxt6t64:ppc64el (1:1.2.1-1.2build1) ... 171s Selecting previously unselected package libxmu6:ppc64el. 171s Preparing to unpack .../464-libxmu6_2%3a1.1.3-3build2_ppc64el.deb ... 171s Unpacking libxmu6:ppc64el (2:1.1.3-3build2) ... 171s Selecting previously unselected package libxaw7:ppc64el. 171s Preparing to unpack .../465-libxaw7_2%3a1.0.16-1_ppc64el.deb ... 171s Unpacking libxaw7:ppc64el (2:1.0.16-1) ... 171s Selecting previously unselected package libxfont2:ppc64el. 171s Preparing to unpack .../466-libxfont2_1%3a2.0.6-1build1_ppc64el.deb ... 171s Unpacking libxfont2:ppc64el (1:2.0.6-1build1) ... 171s Selecting previously unselected package libxkbfile1:ppc64el. 171s Preparing to unpack .../467-libxkbfile1_1%3a1.1.0-1build4_ppc64el.deb ... 171s Unpacking libxkbfile1:ppc64el (1:1.1.0-1build4) ... 171s Selecting previously unselected package libxrandr2:ppc64el. 171s Preparing to unpack .../468-libxrandr2_2%3a1.5.4-1_ppc64el.deb ... 171s Unpacking libxrandr2:ppc64el (2:1.5.4-1) ... 171s Selecting previously unselected package octave-io. 171s Preparing to unpack .../469-octave-io_2.6.4-3build2_ppc64el.deb ... 171s Unpacking octave-io (2.6.4-3build2) ... 171s Selecting previously unselected package octave-statistics-common. 171s Preparing to unpack .../470-octave-statistics-common_1.7.2-1_all.deb ... 171s Unpacking octave-statistics-common (1.7.2-1) ... 171s Selecting previously unselected package octave-statistics. 171s Preparing to unpack .../471-octave-statistics_1.7.2-1_ppc64el.deb ... 171s Unpacking octave-statistics (1.7.2-1) ... 171s Selecting previously unselected package x11-xkb-utils. 171s Preparing to unpack .../472-x11-xkb-utils_7.7+9_ppc64el.deb ... 171s Unpacking x11-xkb-utils (7.7+9) ... 171s Selecting previously unselected package xserver-common. 171s Preparing to unpack .../473-xserver-common_2%3a21.1.14-2ubuntu1_all.deb ... 171s Unpacking xserver-common (2:21.1.14-2ubuntu1) ... 171s Selecting previously unselected package xvfb. 171s Preparing to unpack .../474-xvfb_2%3a21.1.14-2ubuntu1_ppc64el.deb ... 171s Unpacking xvfb (2:21.1.14-2ubuntu1) ... 171s Setting up libapt-pkg-perl (0.1.40build8) ... 171s Setting up libhwy1t64:ppc64el (1.2.0-3ubuntu3) ... 171s Setting up libmodule-pluggable-perl (5.2-5) ... 171s Setting up libgraphite2-3:ppc64el (1.3.14-2ubuntu1) ... 171s Setting up libstring-escape-perl (2010.002-3) ... 171s Setting up libgnutls-openssl27t64:ppc64el (3.8.9-2ubuntu1) ... 171s Setting up libxcb-dri3-0:ppc64el (1.17.0-2) ... 171s Setting up liblcms2-2:ppc64el (2.16-2) ... 171s Setting up libberkeleydb-perl:ppc64el (0.66-1) ... 171s Setting up libpixman-1-0:ppc64el (0.44.0-3) ... 171s Setting up libsharpyuv0:ppc64el (1.5.0-0.1) ... 171s Setting up libwayland-server0:ppc64el (1.23.1-1) ... 171s Setting up libaom3:ppc64el (3.12.0-1) ... 171s Setting up libx11-xcb1:ppc64el (2:1.8.10-2) ... 171s Setting up libfile-which-perl (1.27-2) ... 171s Setting up libdouble-conversion3:ppc64el (3.3.0-1build1) ... 171s Setting up libncurses-dev:ppc64el (6.5+20250125-2) ... 171s Setting up libunicode-utf8-perl (0.62-2build4) ... 171s Setting up libset-intspan-perl (1.19-3) ... 171s Setting up libxcb-xfixes0:ppc64el (1.17.0-2) ... 171s Setting up libogg0:ppc64el (1.3.5-3build1) ... 171s Setting up libmouse-perl:ppc64el (2.5.11-1build1) ... 171s Setting up libzstd-dev:ppc64el (1.5.6+dfsg-2) ... 171s Setting up liblerc4:ppc64el (4.0.0+ds-5ubuntu1) ... 171s Setting up libpod-pom-perl (2.01-4) ... 171s Setting up libxpm4:ppc64el (1:3.5.17-1build2) ... 171s Setting up hdf5-helpers (1.14.5+repack-3) ... 172s Setting up libwmflite-0.2-7:ppc64el (0.2.13-1.1build3) ... 172s Setting up libregexp-pattern-perl (0.2.14-2) ... 172s Setting up libdata-messagepack-perl (1.02-1build5) ... 172s Setting up libclass-inspector-perl (1.36-3) ... 172s Setting up libxcb-xinput0:ppc64el (1.17.0-2) ... 172s Setting up libxrender1:ppc64el (1:0.9.10-1.1build1) ... 172s Setting up libdynaloader-functions-perl (0.004-1) ... 172s Setting up libdatrie1:ppc64el (0.2.13-3build1) ... 172s Setting up libtext-glob-perl (0.11-3) ... 172s Setting up libclass-method-modifiers-perl (2.15-1) ... 172s Setting up liblist-compare-perl (0.55-2) ... 172s Setting up libxcb-render0:ppc64el (1.17.0-2) ... 172s Setting up libclone-perl:ppc64el (0.47-1) ... 172s Setting up libarchive-zip-perl (1.68-1) ... 172s Setting up libsub-identify-perl (0.14-3build4) ... 172s Setting up libdrm-radeon1:ppc64el (2.4.123-1) ... 172s Setting up libcpanel-json-xs-perl:ppc64el (4.39-1) ... 172s Setting up libglvnd0:ppc64el (1.7.0-1build1) ... 172s Setting up libio-stringy-perl (2.113-2) ... 172s Setting up libhtml-tagset-perl (3.24-1) ... 172s Setting up libts0t64:ppc64el (1.22-1.1build1) ... 172s Setting up liblog-any-perl (1.717-1) ... 172s Setting up libyaml-pp-perl (0.38.1-2) ... 172s Setting up libxcb-glx0:ppc64el (1.17.0-2) ... 172s Setting up libdevel-size-perl (0.84-1build1) ... 172s Setting up unzip (6.0-28ubuntu6) ... 172s Setting up libdebhelper-perl (13.24.1ubuntu2) ... 172s Setting up libregexp-pattern-license-perl (3.11.2-1) ... 172s Setting up libconvert-binhex-perl (1.125-3) ... 172s Setting up liblwp-mediatypes-perl (6.04-2) ... 172s Setting up libyaml-libyaml-perl (0.903.0+ds-1) ... 172s Setting up fonts-freefont-otf (20211204+svn4273-2) ... 172s Setting up libio-interactive-perl (1.026-1) ... 172s Setting up libxcb-keysyms1:ppc64el (0.4.1-1) ... 172s Setting up libxcb-shape0:ppc64el (1.17.0-2) ... 172s Setting up x11-common (1:7.7+23ubuntu3) ... 172s Setting up libtry-tiny-perl (0.32-1) ... 172s Setting up libdeflate0:ppc64el (1.23-1) ... 172s Setting up perl-openssl-defaults:ppc64el (7build3) ... 172s Setting up libmldbm-perl (2.05-4) ... 172s Setting up libxml-namespacesupport-perl (1.12-2) ... 172s Setting up m4 (1.4.19-5) ... 172s Setting up libevent-2.1-7t64:ppc64el (2.1.12-stable-10) ... 172s Setting up libclone-choose-perl (0.010-2) ... 172s Setting up libqhull-r8.0:ppc64el (2020.2-6build1) ... 172s Setting up libxcb-render-util0:ppc64el (0.3.10-1) ... 172s Setting up libtime-moment-perl (0.44-2build5) ... 172s Setting up libencode-locale-perl (1.05-3) ... 172s Setting up libxcb-shm0:ppc64el (1.17.0-2) ... 172s Setting up libxcb-icccm4:ppc64el (0.4.2-1) ... 172s Setting up texinfo-lib (7.1.1-1) ... 172s Setting up libreadline-dev:ppc64el (8.2-6) ... 172s Setting up libmpg123-0t64:ppc64el (1.32.10-1) ... 172s Setting up libgomp1:ppc64el (14.2.0-17ubuntu1) ... 172s Setting up libconfig-tiny-perl (2.30-1) ... 172s Setting up libsereal-encoder-perl (5.004+ds-1build4) ... 172s Setting up liblist-utilsby-perl (0.12-2) ... 172s Setting up libyaml-tiny-perl (1.76-1) ... 172s Setting up libjbig0:ppc64el (2.1-6.1ubuntu2) ... 172s Setting up octave-common (9.4.0-1) ... 172s Setting up libregexp-common-perl (2024080801-1) ... 172s Setting up libpcre2-16-0:ppc64el (10.42-4ubuntu3) ... 172s Setting up libaec0:ppc64el (1.1.3-1) ... 172s Setting up libnet-netmask-perl (2.0002-2) ... 172s Setting up libopengl0:ppc64el (1.7.0-1build1) ... 172s Setting up libsub-install-perl (0.929-1) ... 172s Setting up libxcb-util1:ppc64el (0.4.1-1) ... 172s Setting up libpsl-dev:ppc64el (0.21.2-1.1build1) ... 172s Setting up libxxf86vm1:ppc64el (1:1.1.4-1build4) ... 172s Setting up libindirect-perl (0.39-2build5) ... 172s Setting up libxcb-xkb1:ppc64el (1.17.0-2) ... 172s Setting up libxcb-image0:ppc64el (0.4.0-2build1) ... 172s Setting up libnumber-compare-perl (0.03-3) ... 172s Setting up libxcb-present0:ppc64el (1.17.0-2) ... 172s Setting up liberror-perl (0.17029-2) ... 172s Setting up libasound2-data (1.2.13-1build1) ... 172s Setting up patchutils (0.4.2-1build3) ... 172s Setting up tex-common (6.18) ... 172s update-language: texlive-base not installed and configured, doing nothing! 172s Setting up libjson-maybexs-perl (1.004008-1) ... 172s Setting up libxml-sax-base-perl (1.09-3) ... 172s Setting up libio-string-perl (1.08-4) ... 172s Setting up libboolean-perl (0.46-3) ... 172s Setting up libnetaddr-ip-perl (4.079+dfsg-2build5) ... 172s Setting up xtrans-dev (1.4.0-1) ... 172s Setting up libfontenc1:ppc64el (1:1.1.8-1build1) ... 172s Setting up autotools-dev (20220109.1) ... 172s Setting up libblas3:ppc64el (3.12.1-2) ... 172s update-alternatives: using /usr/lib/powerpc64le-linux-gnu/blas/libblas.so.3 to provide /usr/lib/powerpc64le-linux-gnu/libblas.so.3 (libblas.so.3-powerpc64le-linux-gnu) in auto mode 172s Setting up libclass-data-inheritable-perl (0.10-1) ... 172s Setting up libunbound8:ppc64el (1.22.0-1ubuntu1) ... 172s Setting up libpkgconf3:ppc64el (1.8.1-4) ... 172s Setting up libgmpxx4ldbl:ppc64el (2:6.3.0+dfsg-2ubuntu7) ... 172s Setting up libalgorithm-c3-perl (0.11-2) ... 172s Setting up libasound2t64:ppc64el (1.2.13-1build1) ... 172s Setting up liblog-log4perl-perl (1.57-1) ... 172s Setting up libtext-reform-perl (1.20-5) ... 172s Setting up libgnutls-dane0t64:ppc64el (3.8.9-2ubuntu1) ... 172s Setting up libfile-find-rule-perl (0.34-3) ... 172s Setting up libxfixes3:ppc64el (1:6.0.0-2build1) ... 172s Setting up libxcb-sync1:ppc64el (1.17.0-2) ... 172s Setting up libipc-system-simple-perl (1.30-2) ... 172s Setting up libio-tiecombine-perl (1.005-3) ... 172s Setting up libnet-domain-tld-perl (1.75-4) ... 172s Setting up libgssrpc4t64:ppc64el (1.21.3-4ubuntu1) ... 172s Setting up libperlio-utf8-strict-perl (0.010-1build4) ... 172s Setting up libldap-dev:ppc64el (2.6.9+dfsg-1~exp2ubuntu1) ... 172s Setting up aglfn (1.7+git20191031.4036a9c-2) ... 172s Setting up libxcb-cursor0:ppc64el (0.1.5-1) ... 172s Setting up lzip (1.25-1) ... 172s update-alternatives: using /usr/bin/lzip.lzip to provide /usr/bin/lzip (lzip) in auto mode 172s update-alternatives: using /usr/bin/lzip.lzip to provide /usr/bin/lzip-compressor (lzip-compressor) in auto mode 172s update-alternatives: using /usr/bin/lzip.lzip to provide /usr/bin/lzip-decompressor (lzip-decompressor) in auto mode 172s Setting up libavahi-common-data:ppc64el (0.8-14ubuntu1) ... 172s Setting up libopus0:ppc64el (1.5.2-2) ... 172s Setting up t1utils (1.41-4build3) ... 172s Setting up libquadmath0:ppc64el (14.2.0-17ubuntu1) ... 172s Setting up libxinerama1:ppc64el (2:1.1.4-3build1) ... 172s Setting up diffstat (1.67-1) ... 172s Setting up libimagequant0:ppc64el (2.18.0-1build1) ... 172s Setting up comerr-dev:ppc64el (2.1-1.47.2-1ubuntu1) ... 172s Setting up libxkbcommon-x11-0:ppc64el (1.7.0-2) ... 172s Setting up fonts-dejavu-mono (2.37-8) ... 172s Setting up libssl-dev:ppc64el (3.4.0-1ubuntu2) ... 172s Setting up libmpc3:ppc64el (1.3.1-1build2) ... 172s Setting up libvorbis0a:ppc64el (1.3.7-2) ... 172s Setting up libvariable-magic-perl (0.64-1build1) ... 172s Setting up libio-html-perl (1.004-3) ... 172s Setting up libxrandr2:ppc64el (2:1.5.4-1) ... 172s Setting up libtext-template-perl (1.61-1) ... 172s Setting up libpod-parser-perl (1.67-1) ... 172s Setting up autopoint (0.23.1-1) ... 172s Setting up libb-hooks-op-check-perl:ppc64el (0.22-3build2) ... 172s Setting up fonts-dejavu-core (2.37-8) ... 172s Setting up liblist-moreutils-xs-perl (0.430-4build1) ... 172s Setting up pkgconf-bin (1.8.1-4) ... 172s Setting up libjpeg-turbo8:ppc64el (2.1.5-3ubuntu2) ... 172s Setting up libqscintilla2-qt6-l10n (2.14.1+dfsg-1build4) ... 172s Setting up libltdl7:ppc64el (2.5.4-3build1) ... 172s Setting up libidn2-dev:ppc64el (2.3.7-2build2) ... 172s Setting up libfftw3-double3:ppc64el (3.3.10-2fakesync1build1) ... 172s Setting up libglapi-mesa:ppc64el (24.3.4-3ubuntu1) ... 172s Setting up libparams-util-perl (1.102-3build1) ... 172s Setting up libgfortran5:ppc64el (14.2.0-17ubuntu1) ... 172s Setting up libvulkan1:ppc64el (1.4.304.0-1) ... 172s Setting up libtime-duration-perl (1.21-2) ... 172s Setting up autoconf (2.72-3) ... 172s Setting up libtext-xslate-perl:ppc64el (3.5.9-2build1) ... 172s Setting up libsub-exporter-progressive-perl (0.001013-3) ... 172s Setting up libwebp7:ppc64el (1.5.0-0.1) ... 172s Setting up libarray-intspan-perl (2.004-2) ... 172s Setting up libcapture-tiny-perl (0.50-1) ... 172s Setting up libtimedate-perl (2.3300-2) ... 172s Setting up libexporter-lite-perl (0.09-2) ... 172s Setting up libubsan1:ppc64el (14.2.0-17ubuntu1) ... 172s Setting up libsub-name-perl:ppc64el (0.28-1) ... 172s Setting up zlib1g-dev:ppc64el (1:1.3.dfsg+really1.3.1-1ubuntu1) ... 172s Setting up dwz (0.15-1build6) ... 172s Setting up libdata-validate-domain-perl (0.15-1) ... 172s Setting up libproc-processtable-perl:ppc64el (0.636-1build4) ... 172s Setting up libparse-recdescent-perl (1.967015+dfsg-4) ... 172s Setting up libmtdev1t64:ppc64el (1.1.7-1) ... 172s Setting up libduktape207:ppc64el (2.7.0+tests-0ubuntu3) ... 172s Setting up libxshmfence1:ppc64el (1.3-1build5) ... 172s Setting up libxcb-randr0:ppc64el (1.17.0-2) ... 172s Setting up libpath-tiny-perl (0.146-1) ... 172s Setting up libasan8:ppc64el (14.2.0-17ubuntu1) ... 172s Setting up lzop (1.04-2build3) ... 172s Setting up libjson-perl (4.10000-1) ... 172s Setting up liblog-any-adapter-screen-perl (0.141-1) ... 172s Setting up librole-tiny-perl (2.002004-1) ... 172s Setting up debugedit (1:5.1-2) ... 172s Setting up libipc-run3-perl (0.049-1) ... 172s Setting up libmd4c0:ppc64el (0.5.2-2) ... 172s Setting up libregexp-wildcards-perl (1.05-3) ... 172s Setting up libmousex-strictconstructor-perl (0.02-3) ... 172s Setting up libfile-sharedir-perl (1.118-3) ... 172s Setting up libsub-uplevel-perl (0.2800-3) ... 172s Setting up libsuitesparseconfig7:ppc64el (1:7.8.3+dfsg-3) ... 172s Setting up liblua5.4-0:ppc64el (5.4.7-1) ... 172s Setting up libaliased-perl (0.34-3) ... 172s Setting up libharfbuzz0b:ppc64el (10.2.0-1) ... 172s Setting up libthai-data (0.1.29-2build1) ... 172s Setting up xorg-sgml-doctools (1:1.11-1.1) ... 172s Setting up libstrictures-perl (2.000006-1) ... 172s Setting up libsub-quote-perl (2.006008-1ubuntu1) ... 172s Setting up libdevel-stacktrace-perl (2.0500-1) ... 172s Setting up libclass-xsaccessor-perl (1.19-4build5) ... 172s Setting up libtext-autoformat-perl (1.750000-2) ... 172s Setting up libglu1-mesa:ppc64el (9.0.2-1.1build1) ... 172s Setting up libflac12t64:ppc64el (1.4.3+ds-4) ... 172s Setting up libtoml-tiny-perl (0.18-1) ... 172s Setting up libstemmer0d:ppc64el (2.2.0-4build1) ... 172s Setting up libxkbfile1:ppc64el (1:1.1.0-1build4) ... 172s Setting up libsort-versions-perl (1.62-3) ... 172s Setting up libtsan2:ppc64el (14.2.0-17ubuntu1) ... 172s Setting up libexporter-tiny-perl (1.006002-1) ... 172s Setting up libterm-readkey-perl (2.38-2build5) ... 172s Setting up libisl23:ppc64el (0.27-1) ... 172s Setting up libtext-unidecode-perl (1.30-3) ... 172s Setting up libde265-0:ppc64el (1.0.15-1build4) ... 172s Setting up libfont-ttf-perl (1.06-2) ... 172s Setting up libfile-homedir-perl (1.006-2) ... 172s Setting up libsamplerate0:ppc64el (0.2.2-4build1) ... 172s Setting up libtasn1-6-dev:ppc64el (4.20.0-2) ... 172s Setting up libwebpmux3:ppc64el (1.5.0-0.1) ... 172s Setting up libtext-levenshteinxs-perl (0.03-5build5) ... 172s Setting up libperlio-gzip-perl (0.20-1build5) ... 172s Setting up libjxl0.11:ppc64el (0.11.1-1) ... 172s Setting up libxfont2:ppc64el (1:2.0.6-1build1) ... 172s Setting up libhtml-html5-entities-perl (0.004-3) ... 172s Setting up libtext-levenshtein-damerau-perl (0.41-3) ... 172s Setting up libsereal-decoder-perl (5.004+ds-1build4) ... 172s Setting up libmarkdown2:ppc64el (2.2.7-2ubuntu1) ... 172s Setting up libcc1-0:ppc64el (14.2.0-17ubuntu1) ... 172s Setting up liburi-perl (5.30-1) ... 172s Setting up libnet-ipv6addr-perl (1.02-1) ... 172s Setting up libbrotli-dev:ppc64el (1.1.0-2build3) ... 172s Setting up liblsan0:ppc64el (14.2.0-17ubuntu1) ... 172s Setting up libp11-kit-dev:ppc64el (0.25.5-2ubuntu2) ... 172s Setting up libmp3lame0:ppc64el (3.100-6build1) ... 172s Setting up libblas-dev:ppc64el (3.12.1-2) ... 172s update-alternatives: using /usr/lib/powerpc64le-linux-gnu/blas/libblas.so to provide /usr/lib/powerpc64le-linux-gnu/libblas.so (libblas.so-powerpc64le-linux-gnu) in auto mode 172s Setting up libsz2:ppc64el (1.1.3-1) ... 172s Setting up libitm1:ppc64el (14.2.0-17ubuntu1) ... 172s Setting up libvorbisenc2:ppc64el (1.3.7-2) ... 172s Setting up libkadm5clnt-mit12:ppc64el (1.21.3-4ubuntu1) ... 172s Setting up libdata-validate-ip-perl (0.31-1) ... 172s Setting up libwacom-common (2.14.0-1) ... 172s Setting up libmousex-nativetraits-perl (1.09-3) ... 172s Setting up libemail-address-xs-perl (1.05-1build5) ... 172s Setting up libwayland-client0:ppc64el (1.23.1-1) ... 172s Setting up libnet-ssleay-perl:ppc64el (1.94-2) ... 172s Setting up libjpeg8:ppc64el (8c-2ubuntu11) ... 172s Setting up automake (1:1.17-3) ... 172s update-alternatives: using /usr/bin/automake-1.17 to provide /usr/bin/automake (automake) in auto mode 172s Setting up libb2-1:ppc64el (0.98.1-1.1build1) ... 172s Setting up x11proto-dev (2024.1-1) ... 172s Setting up libfile-stripnondeterminism-perl (1.14.1-2) ... 172s Setting up gnuplot-data (6.0.0+dfsg1-1ubuntu3) ... 172s Setting up libice6:ppc64el (2:1.1.1-1) ... 172s Setting up libqt6core6t64:ppc64el (6.8.1+dfsg-0ubuntu4) ... 172s Setting up libhttp-date-perl (6.06-1) ... 172s Setting up mesa-libgallium:ppc64el (24.3.4-3ubuntu1) ... 172s Setting up libjpeg-turbo8-dev:ppc64el (2.1.5-3ubuntu2) ... 172s Setting up liblapack3:ppc64el (3.12.1-2) ... 172s update-alternatives: using /usr/lib/powerpc64le-linux-gnu/lapack/liblapack.so.3 to provide /usr/lib/powerpc64le-linux-gnu/liblapack.so.3 (liblapack.so.3-powerpc64le-linux-gnu) in auto mode 172s Setting up libproxy1v5:ppc64el (0.5.9-1) ... 172s Setting up libfile-basedir-perl (0.09-2) ... 172s Setting up gettext (0.23.1-1) ... 172s Setting up libarpack2t64:ppc64el (3.9.1-4) ... 172s Setting up libfftw3-single3:ppc64el (3.3.10-2fakesync1build1) ... 172s Setting up libgmp-dev:ppc64el (2:6.3.0+dfsg-2ubuntu7) ... 172s Setting up libamd3:ppc64el (1:7.8.3+dfsg-3) ... 172s Setting up libfile-listing-perl (6.16-1) ... 172s Setting up libxau-dev:ppc64el (1:1.0.11-1) ... 172s Setting up nettle-dev:ppc64el (3.10-1) ... 172s Setting up libkdb5-10t64:ppc64el (1.21.3-4ubuntu1) ... 172s Setting up libgbm1:ppc64el (24.3.4-3ubuntu1) ... 172s Setting up libcolamd3:ppc64el (1:7.8.3+dfsg-3) ... 172s Setting up libwacom9:ppc64el (2.14.0-1) ... 172s Setting up fontconfig-config (2.15.0-1.1ubuntu2) ... 173s Setting up liblist-moreutils-perl (0.430-2) ... 173s Setting up libxcursor1:ppc64el (1:1.2.3-1) ... 173s Setting up libpod-constants-perl (0.19-2) ... 173s Setting up libgl1-mesa-dri:ppc64el (24.3.4-3ubuntu1) ... 173s Setting up libhash-merge-perl (0.302-1) ... 173s Setting up libsoftware-copyright-perl (0.012-2) ... 173s Setting up libaec-dev:ppc64el (1.1.3-1) ... 173s Setting up libavahi-common3:ppc64el (0.8-14ubuntu1) ... 173s Setting up libcxsparse4:ppc64el (1:7.8.3+dfsg-3) ... 173s Setting up libfftw3-long3:ppc64el (3.3.10-2fakesync1build1) ... 173s Setting up libnet-http-perl (6.23-1) ... 173s Setting up libpath-iterator-rule-perl (1.015-2) ... 173s Setting up libtext-markdown-discount-perl (0.18-1) ... 173s Setting up libappstream5:ppc64el (1.0.4-1) ... 173s Setting up libexception-class-perl (1.45-1) ... 173s Setting up libclass-c3-perl (0.35-2) ... 173s Setting up libqrupdate1:ppc64el (1.1.5-1) ... 173s Setting up libdevel-callchecker-perl:ppc64el (0.009-1build1) ... 173s Setting up libxml-sax-perl (1.02+dfsg-4) ... 173s update-perl-sax-parsers: Registering Perl SAX parser XML::SAX::PurePerl with priority 10... 173s update-perl-sax-parsers: Updating overall Perl SAX parser modules info file... 173s Creating config file /etc/perl/XML/SAX/ParserDetails.ini with new version 173s Setting up libcamd3:ppc64el (1:7.8.3+dfsg-3) ... 173s Setting up pkgconf:ppc64el (1.8.1-4) ... 173s Setting up libinput-bin (1.27.1-1) ... 173s Setting up libxs-parse-sublike-perl:ppc64el (0.36-1) ... 173s Setting up intltool-debian (0.35.0+20060710.6) ... 173s Setting up libthai0:ppc64el (0.1.29-2build1) ... 173s Setting up libxdmcp-dev:ppc64el (1:1.1.5-1) ... 173s Setting up libegl-mesa0:ppc64el (24.3.4-3ubuntu1) ... 173s Setting up libdata-validate-uri-perl (0.07-3) ... 173s Setting up libxs-parse-keyword-perl (0.48-2) ... 173s Setting up libtest-exception-perl (0.43-3) ... 173s Setting up appstream (1.0.4-1) ... 173s ✔ Metadata cache was updated successfully. 173s Setting up libqt6xml6:ppc64el (6.8.1+dfsg-0ubuntu4) ... 173s Setting up libglpk40:ppc64el (5.0-1build2) ... 173s Setting up libqt6sql6:ppc64el (6.8.1+dfsg-0ubuntu4) ... 173s Setting up libstring-copyright-perl (0.003014-1) ... 173s Setting up libraqm0:ppc64el (0.10.2-1) ... 173s Setting up liblapack-dev:ppc64el (3.12.1-2) ... 173s update-alternatives: using /usr/lib/powerpc64le-linux-gnu/lapack/liblapack.so to provide /usr/lib/powerpc64le-linux-gnu/liblapack.so (liblapack.so-powerpc64le-linux-gnu) in auto mode 173s Setting up libdata-optlist-perl (0.114-1) ... 173s Setting up cpp-14-powerpc64le-linux-gnu (14.2.0-17ubuntu1) ... 173s Setting up libssh2-1-dev:ppc64el (1.11.1-1) ... 173s Setting up cpp-14 (14.2.0-17ubuntu1) ... 173s Setting up libccolamd3:ppc64el (1:7.8.3+dfsg-3) ... 173s Setting up libxml-libxml-perl (2.0207+dfsg+really+2.0134-5build1) ... 173s update-perl-sax-parsers: Registering Perl SAX parser XML::LibXML::SAX::Parser with priority 50... 173s update-perl-sax-parsers: Registering Perl SAX parser XML::LibXML::SAX with priority 50... 173s update-perl-sax-parsers: Updating overall Perl SAX parser modules info file... 173s Replacing config file /etc/perl/XML/SAX/ParserDetails.ini with new version 173s Setting up dh-strip-nondeterminism (1.14.1-2) ... 173s Setting up libwww-robotrules-perl (6.02-1) ... 173s Setting up libsyntax-keyword-try-perl (0.30-1) ... 173s Setting up libjack-jackd2-0:ppc64el (1.9.22~dfsg-4) ... 173s Setting up libhdf5-310:ppc64el (1.14.5+repack-3) ... 173s Setting up libtiff6:ppc64el (4.5.1+git230720-4ubuntu4) ... 173s Setting up libhtml-parser-perl:ppc64el (3.83-1build1) ... 173s Setting up libkadm5srv-mit12:ppc64el (1.21.3-4ubuntu1) ... 173s Setting up libegl1:ppc64el (1.7.0-1build1) ... 173s Setting up libqt6core5compat6:ppc64el (6.8.1-0ubuntu2) ... 173s Setting up libfontconfig1:ppc64el (2.15.0-1.1ubuntu2) ... 173s Setting up libsndfile1:ppc64el (1.2.2-2) ... 173s Setting up libmro-compat-perl (0.15-2) ... 173s Setting up libgcc-14-dev:ppc64el (14.2.0-17ubuntu1) ... 173s Setting up libjpeg8-dev:ppc64el (8c-2ubuntu11) ... 173s Setting up libhdf5-fortran-310:ppc64el (1.14.5+repack-3) ... 173s Setting up libstdc++-14-dev:ppc64el (14.2.0-17ubuntu1) ... 173s Setting up libsm6:ppc64el (2:1.2.4-1) ... 173s Setting up libavahi-client3:ppc64el (0.8-14ubuntu1) ... 173s Setting up libio-socket-ssl-perl (2.089-1) ... 173s Setting up cpp-powerpc64le-linux-gnu (4:14.2.0-1ubuntu1) ... 173s Setting up gcc-14-powerpc64le-linux-gnu (14.2.0-17ubuntu1) ... 173s Setting up libsub-exporter-perl (0.990-1) ... 173s Setting up libqt6dbus6:ppc64el (6.8.1+dfsg-0ubuntu4) ... 173s Setting up libhttp-message-perl (7.00-2ubuntu1) ... 173s Setting up libhtml-form-perl (6.12-1) ... 173s Setting up krb5-multidev:ppc64el (1.21.3-4ubuntu1) ... 173s Setting up libhdf5-cpp-310:ppc64el (1.14.5+repack-3) ... 173s Setting up libgfortran-14-dev:ppc64el (14.2.0-17ubuntu1) ... 173s Setting up libiterator-perl (0.03+ds1-2) ... 173s Setting up libgnutls28-dev:ppc64el (3.8.9-2ubuntu1) ... 173s Setting up libinput10:ppc64el (1.27.1-1) ... 173s Setting up libnghttp2-dev:ppc64el (1.64.0-1) ... 173s Setting up libhdf5-hl-310:ppc64el (1.14.5+repack-3) ... 173s Setting up libportaudio2:ppc64el (19.6.0-1.2build3) ... 173s Setting up libhttp-negotiate-perl (6.01-2) ... 173s Setting up fontconfig (2.15.0-1.1ubuntu2) ... 176s Regenerating fonts cache... done. 176s Setting up libcarp-assert-more-perl (2.8.0-1) ... 176s Setting up libcholmod5:ppc64el (1:7.8.3+dfsg-3) ... 176s Setting up libxft2:ppc64el (2.3.6-1build1) ... 176s Setting up libglx-mesa0:ppc64el (24.3.4-3ubuntu1) ... 176s Setting up libxcb1-dev:ppc64el (1.17.0-2) ... 176s Setting up g++-14-powerpc64le-linux-gnu (14.2.0-17ubuntu1) ... 176s Setting up libiterator-util-perl (0.02+ds1-2) ... 176s Setting up libglx0:ppc64el (1.7.0-1build1) ... 176s Setting up libhttp-cookies-perl (6.11-1) ... 176s Setting up libspqr4:ppc64el (1:7.8.3+dfsg-3) ... 176s Setting up libfftw3-bin (3.3.10-2fakesync1build1) ... 176s Setting up po-debconf (1.0.21+nmu1) ... 176s Setting up libhtml-tree-perl (5.07-3) ... 176s Setting up libparams-classify-perl:ppc64el (0.015-2build6) ... 176s Setting up libpango-1.0-0:ppc64el (1.56.1-1) ... 176s Setting up libcgi-pm-perl (4.67-1) ... 176s Setting up libjpeg-dev:ppc64el (8c-2ubuntu11) ... 176s Setting up libx11-dev:ppc64el (2:1.8.10-2) ... 176s Setting up libcairo2:ppc64el (1.18.2-2) ... 176s Setting up gcc-14 (14.2.0-17ubuntu1) ... 176s Setting up libobject-pad-perl (0.819-1) ... 176s Setting up libkrb5-dev:ppc64el (1.21.3-4ubuntu1) ... 176s Setting up libgl1:ppc64el (1.7.0-1build1) ... 176s Setting up libqt6gui6:ppc64el (6.8.1+dfsg-0ubuntu4) ... 176s Setting up libnet-smtp-ssl-perl (1.04-2) ... 176s Setting up gcc-powerpc64le-linux-gnu (4:14.2.0-1ubuntu1) ... 176s Setting up libmodule-runtime-perl (0.016-2) ... 176s Setting up libmailtools-perl (2.22-1) ... 176s Setting up libconfig-model-perl (2.155-1) ... 176s Setting up libxt6t64:ppc64el (1:1.2.1-1.2build1) ... 176s Setting up librtmp-dev:ppc64el (2.4+20151223.gitfa8646d.1-2build7) ... 176s Setting up texinfo (7.1.1-1) ... 176s Setting up libumfpack6:ppc64el (1:7.8.3+dfsg-3) ... 176s Setting up libconst-fast-perl (0.014-2) ... 176s Setting up libqt6network6:ppc64el (6.8.1+dfsg-0ubuntu4) ... 176s Setting up cpp (4:14.2.0-1ubuntu1) ... 176s Setting up libdata-section-perl (0.200008-1) ... 176s Setting up libglx-dev:ppc64el (1.7.0-1build1) ... 176s Setting up g++-14 (14.2.0-17ubuntu1) ... 176s Setting up gfortran-14-powerpc64le-linux-gnu (14.2.0-17ubuntu1) ... 176s Setting up libpangoft2-1.0-0:ppc64el (1.56.1-1) ... 176s Setting up libdata-dpath-perl (0.60-1) ... 176s Setting up gfortran-14 (14.2.0-17ubuntu1) ... 176s Setting up libfltk1.3t64:ppc64el (1.3.8-6.1build2) ... 176s Setting up libfftw3-dev:ppc64el (3.3.10-2fakesync1build1) ... 176s Setting up libcups2t64:ppc64el (2.4.11-0ubuntu2) ... 176s Setting up libgl-dev:ppc64el (1.7.0-1build1) ... 176s Setting up libstring-rewriteprefix-perl (0.009-1) ... 176s Setting up libpangocairo-1.0-0:ppc64el (1.56.1-1) ... 176s Setting up g++-powerpc64le-linux-gnu (4:14.2.0-1ubuntu1) ... 176s Setting up libhdf5-hl-cpp-310:ppc64el (1.14.5+repack-3) ... 176s Setting up libconfig-model-backend-yaml-perl (2.134-2) ... 176s Setting up libhdf5-hl-fortran-310:ppc64el (1.14.5+repack-3) ... 176s Setting up libxmu6:ppc64el (2:1.1.3-3build2) ... 176s Setting up libtool (2.5.4-3build1) ... 176s Setting up libmodule-implementation-perl (0.09-2) ... 176s Setting up libpackage-stash-perl (0.40-1) ... 176s Setting up libimport-into-perl (1.002005-2) ... 176s Setting up libmoo-perl (2.005005-1) ... 176s Setting up libqt6opengl6:ppc64el (6.8.1+dfsg-0ubuntu4) ... 176s Setting up liblist-someutils-perl (0.59-1) ... 176s Setting up libxaw7:ppc64el (2:1.0.16-1) ... 176s Setting up libmime-tools-perl (5.515-1) ... 176s Setting up libsoftware-license-perl (0.104006-1) ... 176s Setting up libclass-load-perl (0.25-2) ... 176s Setting up gcc (4:14.2.0-1ubuntu1) ... 176s Setting up libgl2ps1.4 (1.4.2+dfsg1-2build1) ... 176s Setting up libqt6widgets6:ppc64el (6.8.1+dfsg-0ubuntu4) ... 176s Setting up dh-autoreconf (20) ... 176s Setting up libfltk-gl1.3t64:ppc64el (1.3.8-6.1build2) ... 176s Setting up gfortran-powerpc64le-linux-gnu (4:14.2.0-1ubuntu1) ... 176s Setting up libcurl4-openssl-dev:ppc64el (8.12.0+git20250209.89ed161+ds-1ubuntu1) ... 176s Setting up libhdf5-dev (1.14.5+repack-3) ... 176s update-alternatives: using /usr/lib/powerpc64le-linux-gnu/pkgconfig/hdf5-serial.pc to provide /usr/lib/powerpc64le-linux-gnu/pkgconfig/hdf5.pc (hdf5.pc) in auto mode 176s Setting up g++ (4:14.2.0-1ubuntu1) ... 176s update-alternatives: using /usr/bin/g++ to provide /usr/bin/c++ (c++) in auto mode 176s Setting up libmoox-aliases-perl (0.001006-2) ... 176s Setting up libparams-validate-perl:ppc64el (1.31-2build4) ... 176s Setting up libqt6openglwidgets6:ppc64el (6.8.1+dfsg-0ubuntu4) ... 176s Setting up libb-hooks-endofscope-perl (0.28-1) ... 176s Setting up libqt6printsupport6:ppc64el (6.8.1+dfsg-0ubuntu4) ... 176s Setting up libsoftware-licensemoreutils-perl (1.009-1) ... 176s Setting up x11-xkb-utils (7.7+9) ... 176s Setting up libqt6help6:ppc64el (6.8.1-0ubuntu1) ... 176s Setting up libqscintilla2-qt6-15:ppc64el (2.14.1+dfsg-1build4) ... 176s Setting up debhelper (13.24.1ubuntu2) ... 176s Setting up gfortran (4:14.2.0-1ubuntu1) ... 176s update-alternatives: using /usr/bin/gfortran to provide /usr/bin/f95 (f95) in auto mode 176s 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 176s update-alternatives: using /usr/bin/gfortran to provide /usr/bin/f77 (f77) in auto mode 176s 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 176s Setting up libnamespace-clean-perl (0.27-2) ... 176s Setting up libstring-license-perl (0.0.11-1ubuntu1) ... 176s Setting up libgetopt-long-descriptive-perl (0.116-2) ... 176s Setting up xserver-common (2:21.1.14-2ubuntu1) ... 176s Setting up licensecheck (3.3.9-1ubuntu1) ... 176s Setting up libapp-cmd-perl (0.337-2) ... 176s Setting up xvfb (2:21.1.14-2ubuntu1) ... 176s Setting up cme (1.041-1) ... 176s Setting up libheif-plugin-aomdec:ppc64el (1.19.5-1build1) ... 176s Setting up libwww-perl (6.77-1) ... 176s Setting up libheif1:ppc64el (1.19.5-1build1) ... 176s Setting up libparse-debcontrol-perl (2.005-6) ... 176s Setting up libhtml-tokeparser-simple-perl (3.16-4) ... 176s Setting up libwww-mechanize-perl (2.18-1ubuntu1) ... 176s Setting up libgd3:ppc64el (2.3.3-12ubuntu3) ... 176s Setting up gnuplot-nox (6.0.0+dfsg1-1ubuntu3) ... 176s update-alternatives: using /usr/bin/gnuplot-nox to provide /usr/bin/gnuplot (gnuplot) in auto mode 176s Setting up liblwp-protocol-https-perl (6.14-1) ... 176s Setting up libheif-plugin-libde265:ppc64el (1.19.5-1build1) ... 176s Setting up libgraphicsmagick-q16-3t64 (1.4+really1.3.45-1build2) ... 176s Setting up lintian (2.121.1ubuntu1) ... 176s Setting up libgraphicsmagick++-q16-12t64 (1.4+really1.3.45-1build2) ... 176s Setting up libconfig-model-dpkg-perl (3.010) ... 176s Setting up dh-octave-autopkgtest (1.8.0) ... 176s Setting up octave (9.4.0-1) ... 176s Setting up octave-dev (9.4.0-1) ... 176s Setting up octave-io (2.6.4-3build2) ... 176s Setting up octave-statistics-common (1.7.2-1) ... 176s Setting up octave-statistics (1.7.2-1) ... 176s Setting up dh-octave (1.8.0) ... 176s Processing triggers for libc-bin (2.41-1ubuntu1) ... 176s Processing triggers for man-db (2.13.0-1) ... 177s Processing triggers for udev (257.2-3ubuntu1) ... 178s Processing triggers for install-info (7.1.1-1) ... 179s autopkgtest [05:22:55]: test command1: DH_OCTAVE_TEST_ENV="xvfb-run -a" /usr/bin/dh_octave_check --use-installed-package 179s autopkgtest [05:22:55]: test command1: [----------------------- 179s Checking package... 180s Run the unit tests... 181s Checking m files ... 181s [inst/regression_ftest.m] 181s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/regression_ftest.m 181s ***** error regression_ftest (); 181s ***** error ... 181s regression_ftest ([1 2 3]', [2 3 4; 3 4 5]'); 181s ***** error ... 181s regression_ftest ([1 2 NaN]', [2 3 4; 3 4 5]', [1 0.5]); 181s ***** error ... 181s regression_ftest ([1 2 Inf]', [2 3 4; 3 4 5]', [1 0.5]); 181s ***** error ... 181s regression_ftest ([1 2 3+i]', [2 3 4; 3 4 5]', [1 0.5]); 181s ***** error ... 181s regression_ftest ([1 2 3]', [2 3 NaN; 3 4 5]', [1 0.5]); 181s ***** error ... 181s regression_ftest ([1 2 3]', [2 3 Inf; 3 4 5]', [1 0.5]); 181s ***** error ... 181s regression_ftest ([1 2 3]', [2 3 4; 3 4 3+i]', [1 0.5]); 181s ***** error ... 181s regression_ftest ([1 2 3]', [2 3 4; 3 4 5]', [1 0.5], [], "alpha", 0); 181s ***** error ... 181s regression_ftest ([1 2 3]', [2 3 4; 3 4 5]', [1 0.5], [], "alpha", 1.2); 181s ***** error ... 181s regression_ftest ([1 2 3]', [2 3 4; 3 4 5]', [1 0.5], [], "alpha", [.02 .1]); 181s ***** error ... 181s regression_ftest ([1 2 3]', [2 3 4; 3 4 5]', [1 0.5], [], "alpha", "a"); 181s ***** error ... 181s regression_ftest ([1 2 3]', [2 3 4; 3 4 5]', [1 0.5], [], "some", 0.05); 181s ***** error ... 181s regression_ftest ([1 2 3]', [2 3; 3 4]', [1 0.5]); 181s ***** error ... 181s regression_ftest ([1 2; 3 4]', [2 3; 3 4]', [1 0.5]); 181s ***** error ... 181s regression_ftest ([1 2 3]', [2 3 4; 3 4 5]', [1 0.5], ones (2)); 181s ***** error ... 181s regression_ftest ([1 2 3]', [2 3 4; 3 4 5]', [1 0.5], "alpha"); 181s ***** error ... 181s regression_ftest ([1 2 3]', [2 3 4; 3 4 5]', [1 0.5], [1 2]); 181s 18 tests, 18 passed, 0 known failure, 0 skipped 181s [inst/regression_ttest.m] 181s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/regression_ttest.m 181s ***** error regression_ttest (); 181s ***** error regression_ttest (1); 182s ***** error ... 182s regression_ttest ([1 2 NaN]', [2 3 4]'); 182s ***** error ... 182s regression_ttest ([1 2 Inf]', [2 3 4]'); 182s ***** error ... 182s regression_ttest ([1 2 3+i]', [2 3 4]'); 182s ***** error ... 182s regression_ttest ([1 2 3]', [2 3 NaN]'); 182s ***** error ... 182s regression_ttest ([1 2 3]', [2 3 Inf]'); 182s ***** error ... 182s regression_ttest ([1 2 3]', [3 4 3+i]'); 182s ***** error ... 182s regression_ttest ([1 2 3]', [3 4 4 5]'); 182s ***** error ... 182s regression_ttest ([1 2 3]', [2 3 4]', "alpha", 0); 182s ***** error ... 182s regression_ttest ([1 2 3]', [2 3 4]', "alpha", 1.2); 182s ***** error ... 182s regression_ttest ([1 2 3]', [2 3 4]', "alpha", [.02 .1]); 182s ***** error ... 182s regression_ttest ([1 2 3]', [2 3 4]', "alpha", "a"); 182s ***** error ... 182s regression_ttest ([1 2 3]', [2 3 4]', "some", 0.05); 182s ***** error ... 182s regression_ttest ([1 2 3]', [2 3 4]', "tail", "val"); 182s ***** error ... 182s regression_ttest ([1 2 3]', [2 3 4]', "alpha", 0.01, "tail", "val"); 182s 16 tests, 16 passed, 0 known failure, 0 skipped 182s [inst/ztest.m] 182s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/ztest.m 182s ***** error ztest (); 182s ***** error ... 182s ztest ([1, 2, 3, 4], 2, -0.5); 182s ***** error ... 182s ztest ([1, 2, 3, 4], 1, 2, "alpha", 0); 182s ***** error ... 182s ztest ([1, 2, 3, 4], 1, 2, "alpha", 1.2); 182s ***** error ... 182s ztest ([1, 2, 3, 4], 1, 2, "alpha", "val"); 182s ***** error ... 182s ztest ([1, 2, 3, 4], 1, 2, "tail", "val"); 182s ***** error ... 182s ztest ([1, 2, 3, 4], 1, 2, "alpha", 0.01, "tail", "val"); 182s ***** error ... 182s ztest ([1, 2, 3, 4], 1, 2, "dim", 3); 182s ***** error ... 182s ztest ([1, 2, 3, 4], 1, 2, "alpha", 0.01, "tail", "both", "dim", 3); 182s ***** error ... 182s ztest ([1, 2, 3, 4], 1, 2, "alpha", 0.01, "tail", "both", "badoption", 3); 182s ***** test 182s load carsmall 182s [h, pval, ci] = ztest (MPG, mean (MPG, "omitnan"), std (MPG, "omitnan")); 182s assert (h, 0); 182s assert (pval, 1, 1e-14); 182s assert (ci, [22.094; 25.343], 1e-3); 182s ***** test 182s load carsmall 182s [h, pval, ci] = ztest (MPG, 26, 8); 182s assert (h, 1); 182s assert (pval, 0.00568359158544743, 1e-14); 182s assert (ci, [22.101; 25.335], 1e-3); 182s ***** test 182s load carsmall 182s [h, pval, ci] = ztest (MPG, 26, 4); 182s assert (h, 1); 182s assert (pval, 3.184168011941316e-08, 1e-14); 182s assert (ci, [22.909; 24.527], 1e-3); 182s 13 tests, 13 passed, 0 known failure, 0 skipped 182s [inst/histfit.m] 182s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/histfit.m 182s ***** demo 182s histfit (randn (100, 1)) 182s ***** demo 182s histfit (poissrnd (2, 1000, 1), 10, "Poisson") 182s ***** demo 182s histfit (betarnd (3, 10, 1000, 1), 10, "beta") 182s ***** test 182s hf = figure ("visible", "off"); 182s unwind_protect 182s x = [2, 4, 3, 2, 4, 3, 2, 5, 6, 4, 7, 5, 9, 8, 10, 4, 11]; 182s histfit (x); 182s unwind_protect_cleanup 182s close (hf); 182s end_unwind_protect 182s warning: using the gnuplot graphics toolkit is discouraged 182s 182s The gnuplot graphics toolkit is not actively maintained and has a number 182s of limitations that are unlikely to be fixed. Communication with gnuplot 182s uses a one-directional pipe and limited information is passed back to the 182s Octave interpreter so most changes made interactively in the plot window 182s will not be reflected in the graphics properties managed by Octave. For 182s example, if the plot window is closed with a mouse click, Octave will not 182s be notified and will not update its internal list of open figure windows. 182s The qt toolkit is recommended instead. 182s ***** test 182s hf = figure ("visible", "off"); 182s unwind_protect 182s x = [2, 4, 3, 2, NaN, 3, 2, 5, 6, 4, 7, 5, 9, 8, 10, 4, 11]; 182s histfit (x); 182s unwind_protect_cleanup 182s close (hf); 182s end_unwind_protect 182s ***** test 182s hf = figure ("visible", "off"); 182s unwind_protect 182s x = [2, 4, 3, 2, NaN, 3, 2, 5, 6, 4, 7, 5, 9, 8, 10, 4, 11]; 182s histfit (x, 3); 182s unwind_protect_cleanup 182s close (hf); 182s end_unwind_protect 182s ***** test 182s hf = figure ("visible", "off"); 182s unwind_protect 182s histfit (randn (100, 1)); 182s unwind_protect_cleanup 182s close (hf); 182s end_unwind_protect 183s ***** test 183s hf = figure ("visible", "off"); 183s unwind_protect 183s histfit (poissrnd (2, 1000, 1), 10, "Poisson"); 183s unwind_protect_cleanup 183s close (hf); 183s end_unwind_protect 183s ***** test 183s hf = figure ("visible", "off"); 183s unwind_protect 183s histfit (betarnd (3, 10, 1000, 1), 10, "beta"); 183s unwind_protect_cleanup 183s close (hf); 183s end_unwind_protect 183s ***** test 183s hf = figure ("visible", "off"); 183s unwind_protect 183s ax = gca (); 183s histfit (ax, randn (100, 1)); 183s unwind_protect_cleanup 183s close (hf); 183s end_unwind_protect 183s ***** test 183s hf = figure ("visible", "off"); 183s unwind_protect 183s ax = gca (); 183s histfit (ax, poissrnd (2, 1000, 1), 10, "Poisson"); 183s unwind_protect_cleanup 183s close (hf); 183s end_unwind_protect 184s ***** test 184s hf = figure ("visible", "off"); 184s unwind_protect 184s ax = gca (); 184s histfit (ax, betarnd (3, 10, 1000, 1), 10, "beta"); 184s unwind_protect_cleanup 184s close (hf); 184s end_unwind_protect 184s ***** test 184s hf = figure ("visible", "off"); 184s unwind_protect 184s ax = axes ("parent", hf); 184s fail ("histfit (ax)", "histfit: too few input arguments."); 184s unwind_protect_cleanup 184s close (hf); 184s end_unwind_protect 184s ***** error ... 184s histfit ('wer') 184s ***** error histfit ([NaN, NaN, NaN]); 184s ***** error ... 184s histfit (randn (100, 1), 5.6) 184s ***** error ... 184s histfit (randn (100, 1), 8, 5) 184s ***** error ... 184s histfit (randn (100, 1), 8, {'normal'}) 184s ***** error ... 184s histfit (randn (100, 1), 8, 'Kernel') 184s ***** error ... 184s histfit (randn (100, 1), 8, 'ASDASDASD') 184s 17 tests, 17 passed, 0 known failure, 0 skipped 184s [inst/bartlett_test.m] 184s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/bartlett_test.m 184s ***** error bartlett_test () 184s ***** error ... 184s bartlett_test (1, 2, 3, 4); 184s ***** error bartlett_test (randn (50, 2), 0); 184s ***** error ... 184s bartlett_test (randn (50, 2), [1, 2, 3]); 184s ***** error ... 184s bartlett_test (randn (50, 1), ones (55, 1)); 184s ***** error ... 184s bartlett_test (randn (50, 1), ones (50, 2)); 184s ***** error ... 184s bartlett_test (randn (50, 2), [], 1.2); 184s ***** error ... 184s bartlett_test (randn (50, 2), [], "alpha"); 184s ***** error ... 184s bartlett_test (randn (50, 1), [ones(25, 1); 2*ones(25, 1)], 1.2); 184s ***** error ... 184s bartlett_test (randn (50, 1), [ones(25, 1); 2*ones(25, 1)], "err"); 184s ***** warning ... 184s bartlett_test (randn (50, 1), [ones(24, 1); 2*ones(25, 1); 3]); 184s ***** test 184s load examgrades 184s [h, pval, chisq, df] = bartlett_test (grades); 184s assert (h, 1); 184s assert (pval, 7.908647337018238e-08, 1e-14); 184s assert (chisq, 38.73324, 1e-5); 184s assert (df, 4); 184s ***** test 184s load examgrades 184s [h, pval, chisq, df] = bartlett_test (grades(:,[2:4])); 184s assert (h, 1); 184s assert (pval, 0.01172, 1e-5); 184s assert (chisq, 8.89274, 1e-5); 184s assert (df, 2); 184s ***** test 184s load examgrades 184s [h, pval, chisq, df] = bartlett_test (grades(:,[1,4])); 184s assert (h, 0); 184s assert (pval, 0.88118, 1e-5); 184s assert (chisq, 0.02234, 1e-5); 184s assert (df, 1); 184s ***** test 184s load examgrades 184s grades = [grades; nan(10, 5)]; 184s [h, pval, chisq, df] = bartlett_test (grades(:,[1,4])); 184s assert (h, 0); 184s assert (pval, 0.88118, 1e-5); 184s assert (chisq, 0.02234, 1e-5); 184s assert (df, 1); 184s ***** test 184s load examgrades 184s [h, pval, chisq, df] = bartlett_test (grades(:,[2,5]), 0.01); 184s assert (h, 0); 184s assert (pval, 0.01791, 1e-5); 184s assert (chisq, 5.60486, 1e-5); 184s assert (df, 1); 184s 16 tests, 16 passed, 0 known failure, 0 skipped 184s [inst/gscatter.m] 184s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/gscatter.m 184s ***** demo 184s load fisheriris; 184s X = meas(:,3:4); 184s cidcs = kmeans (X, 3, "Replicates", 5); 184s gscatter (X(:,1), X(:,2), cidcs, [.75 .75 0; 0 .75 .75; .75 0 .75], "os^"); 184s title ("Fisher's iris data"); 184s ***** shared visibility_setting 184s visibility_setting = get (0, "DefaultFigureVisible"); 184s ***** test 184s hf = figure ("visible", "off"); 184s unwind_protect 184s load fisheriris; 184s X = meas(:,3:4); 184s cidcs = kmeans (X, 3, "Replicates", 5); 184s gscatter (X(:,1), X(:,2), cidcs, [.75 .75 0; 0 .75 .75; .75 0 .75], "os^"); 184s title ("Fisher's iris data"); 184s unwind_protect_cleanup 184s close (hf); 184s end_unwind_protect 184s warning: legend: 'best' not yet implemented for location specifier, using 'northeast' instead 184s ***** error gscatter (); 184s ***** error gscatter ([1]); 185s ***** error gscatter ([1], [2]); 185s ***** error gscatter ('abc', [1 2 3], [1]); 185s ***** error gscatter ([1 2 3], [1 2], [1]); 185s ***** error gscatter ([1 2 3], 'abc', [1]); 185s ***** error gscatter ([1 2], [1 2], [1]); 185s ***** error gscatter ([1 2], [1 2], [1 2], 'rb', 'so', 12, 'xxx'); 185s 9 tests, 9 passed, 0 known failure, 0 skipped 185s [inst/ranksum.m] 185s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/ranksum.m 185s ***** test 185s mileage = [33.3, 34.5, 37.4; 33.4, 34.8, 36.8; ... 185s 32.9, 33.8, 37.6; 32.6, 33.4, 36.6; ... 185s 32.5, 33.7, 37.0; 33.0, 33.9, 36.7]; 185s [p,h,stats] = ranksum(mileage(:,1),mileage(:,2)); 185s assert (p, 0.004329004329004329, 1e-14); 185s assert (h, true); 185s assert (stats.ranksum, 21.5); 185s ***** test 185s year1 = [51 52 62 62 52 52 51 53 59 63 59 56 63 74 68 86 82 70 69 75 73 ... 185s 49 47 50 60 59 60 62 61 71]'; 185s year2 = [54 53 64 66 57 53 54 54 62 66 59 59 67 76 75 86 82 67 74 80 75 ... 185s 54 50 53 62 62 62 72 60 67]'; 185s [p,h,stats] = ranksum(year1, year2, "alpha", 0.01, "tail", "left"); 185s assert (p, 0.1270832752950605, 1e-14); 185s assert (h, false); 185s assert (stats.ranksum, 837.5); 185s assert (stats.zval, -1.140287483634606, 1e-14); 185s [p,h,stats] = ranksum(year1, year2, "alpha", 0.01, "tail", "left", ... 185s "method", "exact"); 185s assert (p, 0.127343916432862, 1e-14); 185s assert (h, false); 185s assert (stats.ranksum, 837.5); 205s 2 tests, 2 passed, 0 known failure, 0 skipped 205s [inst/crosstab.m] 205s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/crosstab.m 205s ***** error crosstab () 205s ***** error crosstab (1) 205s ***** error crosstab (ones (2), [1 1]) 205s ***** error crosstab ([1 1], ones (2)) 205s ***** error crosstab ([1], [1 2]) 205s ***** error crosstab ([1 2], [1]) 205s ***** test 205s load carbig 205s [table, chisq, p, labels] = crosstab (cyl4, when, org); 205s assert (table(2,3,1), 38); 205s assert (labels{3,3}, "Japan"); 205s ***** test 205s load carbig 205s [table, chisq, p, labels] = crosstab (cyl4, when, org); 205s assert (table(2,3,2), 17); 205s assert (labels{1,3}, "USA"); 205s 8 tests, 8 passed, 0 known failure, 0 skipped 205s [inst/vartestn.m] 205s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/vartestn.m 205s ***** demo 205s ## Test the null hypothesis that the variances are equal across the five 205s ## columns of data in the students’ exam grades matrix, grades. 205s 205s load examgrades 205s vartestn (grades) 205s ***** demo 205s ## Test the null hypothesis that the variances in miles per gallon (MPG) are 205s ## equal across different model years. 205s 205s load carsmall 205s vartestn (MPG, Model_Year) 205s ***** demo 205s ## Use Levene’s test to test the null hypothesis that the variances in miles 205s ## per gallon (MPG) are equal across different model years. 205s 205s load carsmall 205s p = vartestn (MPG, Model_Year, "TestType", "LeveneAbsolute") 205s ***** demo 205s ## Test the null hypothesis that the variances are equal across the five 205s ## columns of data in the students’ exam grades matrix, grades, using the 205s ## Brown-Forsythe test. Suppress the display of the summary table of 205s ## statistics and the box plot. 205s 205s load examgrades 205s [p, stats] = vartestn (grades, "TestType", "BrownForsythe", "Display", "off") 205s ***** error vartestn (); 205s ***** error vartestn (1); 205s ***** error ... 205s vartestn ([1, 2, 3, 4, 5, 6, 7]); 205s ***** error ... 205s vartestn ([1, 2, 3, 4, 5, 6, 7], []); 205s ***** error ... 205s vartestn ([1, 2, 3, 4, 5, 6, 7], "TestType", "LeveneAbsolute"); 205s ***** error ... 205s vartestn ([1, 2, 3, 4, 5, 6, 7], [], "TestType", "LeveneAbsolute"); 205s ***** error ... 205s vartestn ([1, 2, 3, 4, 5, 6, 7], [1, 1, 1, 2, 2, 2, 2], "Display", "some"); 205s ***** error ... 205s vartestn (ones (50,3), "Display", "some"); 205s ***** error ... 206s vartestn (ones (50,3), "Display", "off", "testtype", "some"); 206s ***** error ... 206s vartestn (ones (50,3), [], "som"); 206s ***** error ... 206s vartestn (ones (50,3), [], "some", "some"); 206s ***** error ... 206s vartestn (ones (50,3), [1, 2], "Display", "off"); 206s ***** test 206s load examgrades 206s [p, stat] = vartestn (grades, "Display", "off"); 206s assert (p, 7.908647337018238e-08, 1e-14); 206s assert (stat.chisqstat, 38.7332, 1e-4); 206s assert (stat.df, 4); 206s ***** test 206s load examgrades 206s [p, stat] = vartestn (grades, "Display", "off", "TestType", "LeveneAbsolute"); 206s assert (p, 9.523239714592791e-07, 1e-14); 206s assert (stat.fstat, 8.5953, 1e-4); 206s assert (stat.df, [4, 595]); 206s ***** test 206s load examgrades 206s [p, stat] = vartestn (grades, "Display", "off", "TestType", "LeveneQuadratic"); 206s assert (p, 7.219514351897161e-07, 1e-14); 206s assert (stat.fstat, 8.7503, 1e-4); 206s assert (stat.df, [4, 595]); 206s ***** test 206s load examgrades 206s [p, stat] = vartestn (grades, "Display", "off", "TestType", "BrownForsythe"); 206s assert (p, 1.312093241723211e-06, 1e-14); 206s assert (stat.fstat, 8.4160, 1e-4); 206s assert (stat.df, [4, 595]); 206s ***** test 206s load examgrades 206s [p, stat] = vartestn (grades, "Display", "off", "TestType", "OBrien"); 206s assert (p, 8.235660885480556e-07, 1e-14); 206s assert (stat.fstat, 8.6766, 1e-4); 206s assert (stat.df, [4, 595]); 206s 17 tests, 17 passed, 0 known failure, 0 skipped 206s [inst/combnk.m] 206s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/combnk.m 206s ***** demo 206s c = combnk (1:5, 2); 206s disp ("All pairs of integers between 1 and 5:"); 206s disp (c); 206s ***** test 206s c = combnk (1:3, 2); 206s assert (c, [1, 2; 1, 3; 2, 3]); 206s ***** test 206s c = combnk (1:3, 6); 206s assert (isempty (c)); 206s ***** test 206s c = combnk ({1, 2, 3}, 2); 206s assert (c, {1, 2; 1, 3; 2, 3}); 206s ***** test 206s c = combnk ("hello", 2); 206s assert (c, ["lo"; "lo"; "ll"; "eo"; "el"; "el"; "ho"; "hl"; "hl"; "he"]); 206s 4 tests, 4 passed, 0 known failure, 0 skipped 206s [inst/standardizeMissing.m] 206s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/standardizeMissing.m 206s ***** assert (standardizeMissing (1, 1), NaN) 206s ***** assert (standardizeMissing (1, 0), 1) 206s ***** assert (standardizeMissing (eye(2), 1), [NaN 0;0 NaN]) 206s ***** assert (standardizeMissing ([1:3;4:6], [2 3; 4 5]), [1, NaN, NaN; NaN, NaN, 6]) 206s ***** assert (standardizeMissing (cat (3,1,2,3,4), 3), cat (3,1,2,NaN,4)) 206s ***** assert (standardizeMissing ('foo', 'a'), 'foo') 206s ***** assert (standardizeMissing ('foo', 'f'), ' oo') 206s ***** assert (standardizeMissing ('foo', 'o'), 'f ') 206s ***** assert (standardizeMissing ('foo', 'oo'), 'f ') 206s ***** assert (standardizeMissing ({'foo'}, 'f'), {'foo'}) 206s ***** assert (standardizeMissing ({'foo'}, {'f'}), {'foo'}) 206s ***** assert (standardizeMissing ({'foo'}, 'test'), {'foo'}) 206s ***** assert (standardizeMissing ({'foo'}, {'test'}), {'foo'}) 206s ***** assert (standardizeMissing ({'foo'}, 'foo'), {''}) 206s ***** assert (standardizeMissing ({'foo'}, {'foo'}), {''}) 206s ***** assert (standardizeMissing (['foo';'bar'], 'oar'), ['f ';'b ']) 206s ***** assert (standardizeMissing (['foo';'bar'], ['o';'a';'r']), ['f ';'b ']) 206s ***** assert (standardizeMissing (['foo';'bar'], ['o ';'ar']), ['f ';'b ']) 206s ***** assert (standardizeMissing ({'foo','bar'}, 'foo'), {'','bar'}) 206s ***** assert (standardizeMissing ({'foo','bar'}, 'f'), {'foo','bar'}) 206s ***** assert (standardizeMissing ({'foo','bar'}, {'foo', 'a'}), {'','bar'}) 206s ***** assert (standardizeMissing ({'foo'}, {'f', 'oo'}), {'foo'}) 206s ***** assert (standardizeMissing ({'foo','bar'}, {'foo'}), {'','bar'}) 206s ***** assert (standardizeMissing ({'foo','bar'}, {'foo', 'a'}), {'','bar'}) 206s ***** assert (standardizeMissing (double (1), single (1)), double (NaN)) 206s ***** assert (standardizeMissing (single (1), single (1)), single (NaN)) 206s ***** assert (standardizeMissing (single (1), double (1)), single (NaN)) 206s ***** assert (standardizeMissing (single (1), true), single (NaN)) 206s ***** assert (standardizeMissing (double (1), int32(1)), double (NaN)) 206s ***** assert (standardizeMissing (true, true), true) 206s ***** assert (standardizeMissing (true, 1), true) 206s ***** assert (standardizeMissing (int32 (1), int32 (1)), int32 (1)) 206s ***** assert (standardizeMissing (int32 (1), 1), int32 (1)) 206s ***** assert (standardizeMissing (uint32 (1), uint32 (1)), uint32 (1)) 206s ***** assert (standardizeMissing (uint32 (1), 1), uint32 (1)) 206s ***** error standardizeMissing (); 206s ***** error standardizeMissing (1); 206s ***** error standardizeMissing (1,2,3); 206s ***** error standardizeMissing ({'abc', 1}, 1); 206s ***** error standardizeMissing (struct ('a','b'), 1); 206s ***** error <'indicator' and 'A' must have > standardizeMissing ([1 2 3], {1}); 206s ***** error <'indicator' and 'A' must have > standardizeMissing ([1 2 3], 'a'); 206s ***** error <'indicator' and 'A' must have > standardizeMissing ([1 2 3], struct ('a', 1)); 206s ***** error <'indicator' and 'A' must have > standardizeMissing ('foo', 1); 206s ***** error <'indicator' and 'A' must have > standardizeMissing ('foo', {1}); 206s ***** error <'indicator' and 'A' must have > standardizeMissing ('foo', {'f'}); 206s ***** error <'indicator' and 'A' must have > standardizeMissing ('foo', struct ('a', 1)); 206s ***** error <'indicator' and 'A' must have > standardizeMissing ({'foo'}, 1); 206s ***** error <'indicator' and 'A' must have > standardizeMissing ({'foo'}, 1); 206s 49 tests, 49 passed, 0 known failure, 0 skipped 206s [inst/trimmean.m] 206s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/trimmean.m 206s ***** test 206s x = reshape (1:40, [5, 4, 2]); 206s x([3, 37]) = -100; 206s assert (trimmean (x, 10, "all"), 19.4722, 1e-4); 206s ***** test 206s x = reshape (1:40, [5, 4, 2]); 206s x([3, 37]) = -100; 206s out = trimmean (x, 10, [1, 2]); 206s assert (out(1,1,1), 10.3889, 1e-4); 206s assert (out(1,1,2), 29.6111, 1e-4); 206s ***** test 206s x = reshape (1:40, [5, 4, 2]); 206s x([3, 37]) = -100; 206s x([4, 38]) = NaN; 206s assert (trimmean (x, 10, "all"), 19.3824, 1e-4); 206s ***** test 206s x = reshape (1:40, [5, 4, 2]); 206s x([3, 37]) = -100; 206s out = trimmean (x, 10, 1); 206s assert (out(:,:,1), [-17.6, 8, 13, 18]); 206s assert (out(:,:,2), [23, 28, 33, 10.6]); 206s ***** test 206s x = reshape (1:40, [5, 4, 2]); 206s x([3, 37]) = -100; 206s x([4, 38]) = NaN; 206s out = trimmean (x, 10, 1); 206s assert (out(:,:,1), [-23, 8, 13, 18]); 206s assert (out(:,:,2), [23, 28, 33, 3.75]); 206s ***** test 206s x = reshape (1:40, [5, 4, 2]); 206s x([3, 37]) = -100; 206s out = trimmean (x, 10, 2); 206s assert (out(:,:,1), [8.5; 9.5; -15.25; 11.5; 12.5]); 206s assert (out(:,:,2), [28.5; -4.75; 30.5; 31.5; 32.5]); 206s ***** test 206s x = reshape (1:40, [5, 4, 2]); 206s x([3, 37]) = -100; 206s x([4, 38]) = NaN; 206s out = trimmean (x, 10, 2); 206s assert (out(:,:,1), [8.5; 9.5; -15.25; 14; 12.5]); 206s assert (out(:,:,2), [28.5; -4.75; 28; 31.5; 32.5]); 206s ***** test 206s x = reshape (1:40, [5, 4, 2]); 206s x([3, 37]) = -100; 206s out = trimmean (x, 10, [1, 2, 3]); 206s assert (out, trimmean (x, 10, "all")); 206s ***** test 206s x = reshape (1:40, [5, 4, 2]); 206s x([3, 37]) = -100; 206s x([4, 38]) = NaN; 206s out = trimmean (x, 10, [1, 2]); 206s assert (out(1,1,1), 10.7647, 1e-4); 206s assert (out(1,1,2), 29.1176, 1e-4); 206s ***** test 206s x = reshape (1:40, [5, 4, 2]); 206s x([3, 37]) = -100; 206s x([4, 38]) = NaN; 206s out = trimmean (x, 10, [1, 3]); 206s assert (out, [2.5556, 18, 23, 11.6667], 1e-4); 206s ***** test 206s x = reshape (1:40, [5, 4, 2]); 206s x([3, 37]) = -100; 206s x([4, 38]) = NaN; 206s out = trimmean (x, 10, [2, 3]); 206s assert (out, [18.5; 2.3750; 3.2857; 24; 22.5], 1e-4); 206s ***** test 206s x = reshape (1:40, [5, 4, 2]); 206s x([3, 37]) = -100; 206s x([4, 38]) = NaN; 206s out = trimmean (x, 10, [1, 2, 3]); 206s assert (out, trimmean (x, 10, "all")); 206s ***** test 206s x = reshape (1:40, [5, 4, 2]); 206s x([3, 37]) = -100; 206s x([4, 38]) = NaN; 206s out = trimmean (x, 10, [2, 3, 5]); 206s assert (out, [18.5; 2.3750; 3.2857; 24; 22.5], 1e-4); 206s ***** assert (trimmean (reshape (1:40, [5, 4, 2]), 10, 4), reshape(1:40, [5, 4, 2])) 206s ***** assert (trimmean ([], 10), NaN) 206s ***** assert (trimmean ([1;2;3;4;5], 10, 2), [1;2;3;4;5]) 206s ***** error trimmean (1) 207s ***** error trimmean (1,2,3,4,5) 207s ***** error trimmean ([1 2 3 4], -10) 207s ***** error trimmean ([1 2 3 4], 100) 207s ***** error trimmean ([1 2 3 4], 10, "flag") 207s ***** error trimmean ([1 2 3 4], 10, "flag", 1) 207s ***** error ... 207s trimmean ([1 2 3 4], 10, -1) 207s ***** error ... 207s trimmean ([1 2 3 4], 10, "floor", -1) 207s ***** error ... 207s trimmean (reshape (1:40, [5, 4, 2]), 10, [-1, 2]) 207s ***** error ... 207s trimmean (reshape (1:40, [5, 4, 2]), 10, [1, 2, 2]) 207s 26 tests, 26 passed, 0 known failure, 0 skipped 207s [inst/vartest2.m] 207s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/vartest2.m 207s ***** error vartest2 (); 207s ***** error vartest2 (ones (20,1)); 207s ***** error ... 207s vartest2 (rand (20,1), 5); 207s ***** error ... 207s vartest2 (rand (20,1), rand (25,1)*2, "alpha", 0); 207s ***** error ... 207s vartest2 (rand (20,1), rand (25,1)*2, "alpha", 1.2); 207s ***** error ... 207s vartest2 (rand (20,1), rand (25,1)*2, "alpha", "some"); 207s ***** error ... 207s vartest2 (rand (20,1), rand (25,1)*2, "alpha", [0.05, 0.001]); 207s ***** error ... 207s vartest2 (rand (20,1), rand (25,1)*2, "tail", [0.05, 0.001]); 207s ***** error ... 207s vartest2 (rand (20,1), rand (25,1)*2, "tail", "some"); 207s ***** error ... 207s vartest2 (rand (20,1), rand (25,1)*2, "dim", 3); 207s ***** error ... 207s vartest2 (rand (20,1), rand (25,1)*2, "alpha", 0.001, "dim", 3); 207s ***** error ... 207s vartest2 (rand (20,1), rand (25,1)*2, "some", 3); 207s ***** error ... 207s vartest2 (rand (20,1), rand (25,1)*2, "some"); 207s ***** test 207s load carsmall 207s [h, pval, ci, stat] = vartest2 (MPG(Model_Year==82), MPG(Model_Year==76)); 207s assert (h, 0); 207s assert (pval, 0.6288022362718455, 1e-13); 207s assert (ci, [0.4139; 1.7193], 1e-4); 207s assert (stat.fstat, 0.8384, 1e-4); 207s assert (stat.df1, 30); 207s assert (stat.df2, 33); 207s 14 tests, 14 passed, 0 known failure, 0 skipped 207s [inst/mhsample.m] 207s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/mhsample.m 207s ***** demo 207s ## Define function to sample 207s d = 2; 207s mu = [-1; 2]; 207s rand ("seed", 5) # for reproducibility 207s Sigma = rand (d); 207s Sigma = (Sigma + Sigma'); 207s Sigma += eye (d) * abs (eigs (Sigma, 1, "sa")) * 1.1; 207s pdf = @(x)(2*pi)^(-d/2)*det(Sigma)^-.5*exp(-.5*sum((x.'-mu).*(Sigma\(x.'-mu)),1)); 207s ## Inputs 207s start = ones (1, 2); 207s nsamples = 500; 207s sym = true; 207s K = 500; 207s m = 10; 207s rand ("seed", 8) # for reproducibility 207s proprnd = @(x) (rand (size (x)) - .5) * 3 + x; 207s [smpl, accept] = mhsample (start, nsamples, "pdf", pdf, "proprnd", proprnd, ... 207s "symmetric", sym, "burnin", K, "thin", m); 207s figure; 207s hold on; 207s plot (smpl(:, 1), smpl(:, 2), 'x'); 207s [x, y] = meshgrid (linspace (-6, 4), linspace(-3, 7)); 207s z = reshape (pdf ([x(:), y(:)]), size(x)); 207s mesh (x, y, z, "facecolor", "None"); 207s ## Using sample points to find the volume of half a sphere with radius of .5 207s f = @(x) ((.25-(x(:,1)+1).^2-(x(:,2)-2).^2).^.5.*(((x(:,1)+1).^2+(x(:,2)-2).^2)<.25)).'; 207s int = mean (f (smpl) ./ pdf (smpl)); 207s errest = std (f (smpl) ./ pdf (smpl)) / nsamples ^ .5; 207s trueerr = abs (2 / 3 * pi * .25 ^ (3 / 2) - int); 207s printf ("Monte Carlo integral estimate int f(x) dx = %f\n", int); 207s printf ("Monte Carlo integral error estimate %f\n", errest); 207s printf ("The actual error %f\n", trueerr); 207s mesh (x, y, reshape (f([x(:), y(:)]), size(x)), "facecolor", "None"); 207s ***** demo 207s ## Integrate truncated normal distribution to find normilization constant 207s pdf = @(x) exp (-.5*x.^2)/(pi^.5*2^.5); 207s nsamples = 1e3; 207s rand ("seed", 5) # for reproducibility 207s proprnd = @(x) (rand (size (x)) - .5) * 3 + x; 207s [smpl, accept] = mhsample (1, nsamples, "pdf", pdf, "proprnd", proprnd, ... 207s "symmetric", true, "thin", 4); 207s f = @(x) exp(-.5 * x .^ 2) .* (x >= -2 & x <= 2); 207s x = linspace (-3, 3, 1000); 207s area(x, f(x)); 207s xlabel ('x'); 207s ylabel ('f(x)'); 207s int = mean (f (smpl) ./ pdf (smpl)); 207s errest = std (f (smpl) ./ pdf (smpl)) / nsamples^ .5; 207s trueerr = abs (erf (2 ^ .5) * 2 ^ .5 * pi ^ .5 - int); 207s printf ("Monte Carlo integral estimate int f(x) dx = %f\n", int); 207s printf ("Monte Carlo integral error estimate %f\n", errest); 207s printf ("The actual error %f\n", trueerr); 207s ***** test 207s nchain = 1e4; 207s start = rand (nchain, 1); 207s nsamples = 1e3; 207s pdf = @(x) exp (-.5*(x-1).^2)/(2*pi)^.5; 207s proppdf = @(x, y) 1/3; 207s proprnd = @(x) 3 * (rand (size (x)) - .5) + x; 207s [smpl, accept] = mhsample (start, nsamples, "pdf", pdf, "proppdf", proppdf, ... 207s "proprnd", proprnd, "thin", 2, "nchain", nchain, ... 207s "burnin", 0); 207s assert (mean (mean (smpl, 1), 3), 1, .01); 207s assert (mean (var (smpl, 1), 3), 1, .01) 212s ***** error mhsample (); 212s ***** error mhsample (1); 212s ***** error mhsample (1, 1); 212s ***** error mhsample (1, 1, "pdf", @(x)x); 212s ***** error mhsample (1, 1, "pdf", @(x)x, "proprnd", @(x)x+rand(size(x))); 212s 6 tests, 6 passed, 0 known failure, 0 skipped 212s [inst/binotest.m] 212s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/binotest.m 212s ***** demo 212s % flip a coin 1000 times, showing 475 heads 212s % Hypothesis: coin is fair, i.e. p=1/2 212s [h,p_val,ci] = binotest(475,1000,0.5) 212s % Result: h = 0 : null hypothesis not rejected, coin could be fair 212s % P value 0.12, i.e. hypothesis not rejected for alpha up to 12% 212s % 0.444 <= p <= 0.506 with 95% confidence 212s ***** demo 212s % flip a coin 100 times, showing 65 heads 212s % Hypothesis: coin shows less than 50% heads, i.e. p<=1/2 212s [h,p_val,ci] = binotest(65,100,0.5,'tail','left','alpha',0.01) 212s % Result: h = 1 : null hypothesis is rejected, i.e. coin shows more heads than tails 212s % P value 0.0018, i.e. hypothesis not rejected for alpha up to 0.18% 212s % 0 <= p <= 0.76 with 99% confidence 212s ***** test #example from https://en.wikipedia.org/wiki/Binomial_test 212s [h,p_val,ci] = binotest (51,235,1/6); 212s assert (p_val, 0.0437, 0.00005) 212s [h,p_val,ci] = binotest (51,235,1/6,'tail','left'); 212s assert (p_val, 0.027, 0.0005) 212s 1 test, 1 passed, 0 known failure, 0 skipped 212s [inst/squareform.m] 212s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/squareform.m 212s ***** shared v, m 212s v = 1:6; 212s m = [0 1 2 3;1 0 4 5;2 4 0 6;3 5 6 0]; 212s ***** assert (squareform (v), m) 212s ***** assert (squareform (squareform (v)), v) 212s ***** assert (squareform (m), v) 212s ***** assert (squareform (v'), m) 212s ***** assert (squareform (1), [0 1;1 0]) 212s ***** assert (squareform (1, "tomatrix"), [0 1; 1 0]) 212s ***** assert (squareform (0, "tovector"), zeros (1, 0)) 212s ***** warning squareform ([0 1 2; 3 0 4; 5 6 0]); 212s ***** test 212s for c = {@single, @double, @uint8, @uint32, @uint64} 212s f = c{1}; 212s assert (squareform (f (v)), f (m)) 212s assert (squareform (f (m)), f (v)) 212s endfor 212s 9 tests, 9 passed, 0 known failure, 0 skipped 212s [inst/signtest.m] 212s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/signtest.m 212s ***** test 212s [pval, h, stats] = signtest ([-ones(1, 1000) 1], 0, "tail", "left"); 212s assert (pval, 1.091701889420221e-218, 1e-14); 212s assert (h, 1); 212s assert (stats.zval, -31.5437631079266, 1e-14); 212s ***** test 212s [pval, h, stats] = signtest ([-2 -1 0 2 1 3 1], 0); 212s assert (pval, 0.6875000000000006, 1e-14); 212s assert (h, 0); 212s assert (stats.zval, NaN); 212s assert (stats.sign, 4); 212s ***** test 212s [pval, h, stats] = signtest ([-2 -1 0 2 1 3 1], 0, "method", "approximate"); 212s assert (pval, 0.6830913983096086, 1e-14); 212s assert (h, 0); 212s assert (stats.zval, 0.4082482904638631, 1e-14); 212s assert (stats.sign, 4); 212s ***** error signtest (ones (2)) 212s ***** error ... 212s signtest ([1, 2, 3, 4], ones (2)) 212s ***** error ... 212s signtest ([1, 2, 3, 4], [1, 2, 3]) 212s ***** error ... 212s signtest ([1, 2, 3, 4], [], 'tail') 212s ***** error ... 212s signtest ([1, 2, 3, 4], [], 'alpha', 1.2) 212s ***** error ... 212s signtest ([1, 2, 3, 4], [], 'alpha', 0) 212s ***** error ... 212s signtest ([1, 2, 3, 4], [], 'alpha', -0.05) 212s ***** error ... 212s signtest ([1, 2, 3, 4], [], 'alpha', "a") 212s ***** error ... 212s signtest ([1, 2, 3, 4], [], 'alpha', [0.01, 0.05]) 212s ***** error ... 212s signtest ([1, 2, 3, 4], [], 'tail', 0.01) 212s ***** error ... 212s signtest ([1, 2, 3, 4], [], 'tail', {"both"}) 212s ***** error ... 212s signtest ([1, 2, 3, 4], [], 'tail', "some") 212s ***** error ... 212s signtest ([1, 2, 3, 4], [], 'method', 'exact', 'tail', "some") 212s ***** error ... 212s signtest ([1, 2, 3, 4], [], 'method', 0.01) 212s ***** error ... 212s signtest ([1, 2, 3, 4], [], 'method', {"exact"}) 212s ***** error ... 212s signtest ([1, 2, 3, 4], [], 'method', "some") 212s ***** error ... 212s signtest ([1, 2, 3, 4], [], 'tail', "both", 'method', "some") 212s 20 tests, 20 passed, 0 known failure, 0 skipped 212s [inst/violin.m] 212s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/violin.m 212s ***** demo 212s clf 212s x = zeros (9e2, 10); 212s for i=1:10 212s x(:,i) = (0.1 * randn (3e2, 3) * (randn (3,1) + 1) + 2 * randn (1,3))(:); 212s endfor 212s h = violin (x, "color", "c"); 212s axis tight 212s set (h.violin, "linewidth", 2); 212s set (gca, "xgrid", "on"); 212s xlabel ("Variables") 212s ylabel ("Values") 212s ***** demo 212s clf 212s data = {randn(100,1)*5+140, randn(130,1)*8+135}; 212s subplot (1,2,1) 212s title ("Grade 3 heights - vertical"); 212s set (gca, "xtick", 1:2, "xticklabel", {"girls"; "boys"}); 212s violin (data, "Nbins", 10); 212s axis tight 212s 212s subplot(1,2,2) 212s title ("Grade 3 heights - horizontal"); 212s set (gca, "ytick", 1:2, "yticklabel", {"girls"; "boys"}); 212s violin (data, "horizontal", "Nbins", 10); 212s axis tight 212s ***** demo 212s clf 212s data = exprnd (0.1, 500,4); 212s violin (data, "nbins", {5,10,50,100}); 212s axis ([0 5 0 max(data(:))]) 212s ***** demo 212s clf 212s data = exprnd (0.1, 500,4); 212s violin (data, "color", jet(4)); 212s axis ([0 5 0 max(data(:))]) 212s ***** demo 212s clf 212s data = repmat(exprnd (0.1, 500,1), 1, 4); 212s violin (data, "width", linspace (0.1,0.5,4)); 212s axis ([0 5 0 max(data(:))]) 212s ***** demo 212s clf 212s data = repmat(exprnd (0.1, 500,1), 1, 4); 212s violin (data, "nbins", [5,10,50,100], "smoothfactor", [4 4 8 10]); 212s axis ([0 5 0 max(data(:))]) 212s ***** test 212s hf = figure ("visible", "off"); 212s unwind_protect 212s data = exprnd (0.1, 500,4); 212s violin (data, "color", jet(4)); 212s axis ([0 5 0 max(data(:))]) 212s unwind_protect_cleanup 212s close (hf); 212s end_unwind_protect 213s ***** test 213s hf = figure ("visible", "off"); 213s unwind_protect 213s data = {randn(100,1)*5+140, randn(130,1)*8+135}; 213s subplot (1,2,1) 213s title ("Grade 3 heights - vertical"); 213s set (gca, "xtick", 1:2, "xticklabel", {"girls"; "boys"}); 213s violin (data, "Nbins", 10); 213s axis tight 213s unwind_protect_cleanup 213s close (hf); 213s end_unwind_protect 214s ***** test 214s hf = figure ("visible", "off"); 214s unwind_protect 214s data = {randn(100,1)*5+140, randn(130,1)*8+135}; 214s subplot (1,2,1) 214s title ("Grade 3 heights - vertical"); 214s set (gca, "xtick", 1:2, "xticklabel", {"girls"; "boys"}); 214s violin (data, "Nbins", 10); 214s axis tight 214s subplot(1,2,2) 214s title ("Grade 3 heights - horizontal"); 214s set (gca, "ytick", 1:2, "yticklabel", {"girls"; "boys"}); 214s violin (data, "horizontal", "Nbins", 10); 214s axis tight 214s unwind_protect_cleanup 214s close (hf); 214s end_unwind_protect 214s ***** test 214s hf = figure ("visible", "off"); 214s unwind_protect 214s data = repmat(exprnd (0.1, 500,1), 1, 4); 214s violin (data, "nbins", [5,10,50,100], "smoothfactor", [4 4 8 10]); 214s axis ([0 5 0 max(data(:))]) 214s unwind_protect_cleanup 214s close (hf); 214s end_unwind_protect 215s ***** test 215s hf = figure ("visible", "off"); 215s unwind_protect 215s data = repmat(exprnd (0.1, 500,1), 1, 4); 215s violin (data, "width", linspace (0.1,0.5,4)); 215s axis ([0 5 0 max(data(:))]) 215s unwind_protect_cleanup 215s close (hf); 215s end_unwind_protect 216s 5 tests, 5 passed, 0 known failure, 0 skipped 216s [inst/qqplot.m] 216s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/qqplot.m 216s ***** test 216s hf = figure ("visible", "off"); 216s unwind_protect 216s qqplot ([2 3 3 4 4 5 6 5 6 7 8 9 8 7 8 9 0 8 7 6 5 4 6 13 8 15 9 9]); 216s unwind_protect_cleanup 216s close (hf); 216s end_unwind_protect 216s ***** error qqplot () 216s ***** error qqplot ({1}) 216s ***** error qqplot (ones (2,2)) 216s ***** error qqplot (1, "foobar") 216s ***** error qqplot ([1 2 3], "foobar") 216s 6 tests, 6 passed, 0 known failure, 0 skipped 216s [inst/logistic_regression.m] 216s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/logistic_regression.m 216s ***** test 216s # Output compared to following MATLAB commands 216s # [B, DEV, STATS] = mnrfit(X,Y+1,'model','ordinal'); 216s # P = mnrval(B,X) 216s X = [1.489381332449196, 1.1534152241851305; ... 216s 1.8110085304863965, 0.9449666896938425; ... 216s -0.04453299665130296, 0.34278203449678646; ... 216s -0.36616019468850347, 1.130254275908322; ... 216s 0.15339143291005095, -0.7921044310668951; ... 216s -1.6031878794469698, -1.8343471035233376; ... 216s -0.14349521143198166, -0.6762996896828459; ... 216s -0.4403818557740143, -0.7921044310668951; ... 216s -0.7372685001160434, -0.027793137932169563; ... 216s -0.11875465773681024, 0.5512305689880763]; 216s Y = [1,1,1,1,1,0,0,0,0,0]'; 216s [INTERCEPT, SLOPE, DEV, DL, D2L, P] = logistic_regression (Y, X, false); 216s ***** test 216s # Output compared to following MATLAB commands 216s # [B, DEV, STATS] = mnrfit(X,Y+1,'model','ordinal'); 216s load carbig 216s X = [Acceleration Displacement Horsepower Weight]; 216s miles = [1,1,1,1,1,1,1,1,1,1,NaN,NaN,NaN,NaN,NaN,1,1,NaN,1,1,2,2,1,2,2,2, ... 216s 2,2,2,2,2,1,1,1,1,2,2,2,2,NaN,2,1,1,2,1,1,1,1,1,1,1,1,1,2,2,1,2, ... 216s 2,3,3,3,3,2,2,2,2,2,2,2,1,1,1,1,1,1,1,1,1,2,1,1,1,1,1,2,2,2,2,2, ... 216s 2,2,2,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,1,2,2,1,1,1,1,1,2,2,2,1,2,2, ... 216s 2,1,1,3,2,2,2,1,2,2,1,2,2,2,1,3,2,3,2,1,1,1,1,1,1,1,1,3,2,2,3,3, ... 216s 2,2,2,2,2,3,2,1,1,1,1,1,1,1,1,1,1,1,2,2,1,3,2,2,2,2,2,2,1,3,2,2, ... 216s 2,2,2,3,2,2,2,2,2,1,1,1,1,2,2,2,2,3,2,3,3,2,1,1,1,3,3,2,2,2,1,2, ... 216s 2,1,1,1,1,1,3,3,3,2,3,1,1,1,1,1,2,2,1,1,1,1,1,3,2,2,2,3,3,3,3,2, ... 216s 2,2,4,3,3,4,3,2,2,2,2,2,2,2,2,2,2,2,1,1,2,1,1,1,3,2,2,3,2,2,2,2, ... 216s 2,1,2,1,3,3,2,2,2,2,2,1,1,1,1,1,1,2,1,3,3,3,2,2,2,2,2,3,3,3,3,2, ... 216s 2,2,3,4,3,3,3,2,2,2,2,3,3,3,3,3,4,2,4,4,4,3,3,4,4,3,3,3,2,3,2,3, ... 216s 2,2,2,2,3,4,4,3,3,3,3,3,3,3,3,3,3,3,3,3,3,2,NaN,3,2,2,2,2,2,1,2, ... 216s 2,3,3,3,2,2,2,3,3,3,3,3,3,3,3,3,3,3,2,3,2,2,3,3,2,2,4,3,2,3]'; 216s [INTERCEPT, SLOPE, DEV, DL, D2L, P] = logistic_regression (miles, X, false); 216s assert (DEV, 433.197174495549, 1e-05); 216s assert (INTERCEPT(1), -16.6895155618903, 1e-05); 216s assert (INTERCEPT(2), -11.7207818178493, 1e-05); 216s assert (INTERCEPT(3), -8.0605768506075, 1e-05); 216s assert (SLOPE(1), 0.104762463756714, 1e-05); 216s assert (SLOPE(2), 0.0103357623191891, 1e-05); 216s assert (SLOPE(3), 0.0645199313242276, 1e-05); 216s assert (SLOPE(4), 0.00166377028388103, 1e-05); 216s 2 tests, 2 passed, 0 known failure, 0 skipped 216s [inst/regress_gp.m] 216s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/regress_gp.m 216s ***** demo 216s ## Linear fitting of 1D Data 216s rand ("seed", 125); 216s X = 2 * rand (5, 1) - 1; 216s randn ("seed", 25); 216s Y = 2 * X - 1 + 0.3 * randn (5, 1); 216s 216s ## Points for interpolation/extrapolation 216s Xfit = linspace (-2, 2, 10)'; 216s 216s ## Fit regression model 216s [Yfit, Yint, m] = regress_gp (X, Y, Xfit); 216s 216s ## Plot fitted data 216s plot (X, Y, "xk", Xfit, Yfit, "r-", Xfit, Yint, "b-"); 216s title ("Gaussian process regression with linear kernel"); 216s ***** demo 216s ## Linear fitting of 2D Data 216s rand ("seed", 135); 216s X = 2 * rand (4, 2) - 1; 216s randn ("seed", 35); 216s Y = 2 * X(:,1) - 3 * X(:,2) - 1 + 1 * randn (4, 1); 216s 216s ## Mesh for interpolation/extrapolation 216s [x1, x2] = meshgrid (linspace (-1, 1, 10)); 216s Xfit = [x1(:), x2(:)]; 216s 216s ## Fit regression model 216s [Ypred, Yint, Ysd] = regress_gp (X, Y, Xfit); 216s Ypred = reshape (Ypred, 10, 10); 216s YintU = reshape (Yint(:,1), 10, 10); 216s YintL = reshape (Yint(:,2), 10, 10); 216s 216s ## Plot fitted data 216s plot3 (X(:,1), X(:,2), Y, ".k", "markersize", 16); 216s hold on; 216s h = mesh (x1, x2, Ypred, zeros (10, 10)); 216s set (h, "facecolor", "none", "edgecolor", "yellow"); 216s h = mesh (x1, x2, YintU, ones (10, 10)); 216s set (h, "facecolor", "none", "edgecolor", "cyan"); 216s h = mesh (x1, x2, YintL, ones (10, 10)); 216s set (h, "facecolor", "none", "edgecolor", "cyan"); 216s hold off 216s axis tight 216s view (75, 25) 216s title ("Gaussian process regression with linear kernel"); 216s ***** demo 216s ## Projection over basis function with linear kernel 216s pp = [2, 2, 0.3, 1]; 216s n = 10; 216s rand ("seed", 145); 216s X = 2 * rand (n, 1) - 1; 216s randn ("seed", 45); 216s Y = polyval (pp, X) + 0.3 * randn (n, 1); 216s 216s ## Powers 216s px = [sqrt(abs(X)), X, X.^2, X.^3]; 216s 216s ## Points for interpolation/extrapolation 216s Xfit = linspace (-1, 1, 100)'; 216s pxi = [sqrt(abs(Xfit)), Xfit, Xfit.^2, Xfit.^3]; 216s 216s ## Define a prior covariance assuming that the sqrt component is not present 216s Sp = 100 * eye (size (px, 2) + 1); 216s Sp(2,2) = 1; # We don't believe the sqrt(abs(X)) is present 216s 216s ## Fit regression model 216s [Yfit, Yint, Ysd] = regress_gp (px, Y, pxi, Sp); 216s 216s ## Plot fitted data 216s plot (X, Y, "xk;Data;", Xfit, Yfit, "r-;Estimation;", ... 216s Xfit, polyval (pp, Xfit), "g-;True;"); 216s axis tight 216s axis manual 216s hold on 216s plot (Xfit, Yint(:,1), "m-;Upper bound;", Xfit, Yint(:,2), "b-;Lower bound;"); 216s hold off 216s title ("Linear kernel over basis function with prior covariance"); 216s ***** demo 216s ## Projection over basis function with linear kernel 216s pp = [2, 2, 0.3, 1]; 216s n = 10; 216s rand ("seed", 145); 216s X = 2 * rand (n, 1) - 1; 216s randn ("seed", 45); 216s Y = polyval (pp, X) + 0.3 * randn (n, 1); 216s 216s ## Powers 216s px = [sqrt(abs(X)), X, X.^2, X.^3]; 216s 216s ## Points for interpolation/extrapolation 216s Xfit = linspace (-1, 1, 100)'; 216s pxi = [sqrt(abs(Xfit)), Xfit, Xfit.^2, Xfit.^3]; 216s 216s ## Fit regression model without any assumption on prior covariance 216s [Yfit, Yint, Ysd] = regress_gp (px, Y, pxi); 216s 216s ## Plot fitted data 216s plot (X, Y, "xk;Data;", Xfit, Yfit, "r-;Estimation;", ... 216s Xfit, polyval (pp, Xfit), "g-;True;"); 216s axis tight 216s axis manual 216s hold on 216s plot (Xfit, Yint(:,1), "m-;Upper bound;", Xfit, Yint(:,2), "b-;Lower bound;"); 216s hold off 216s title ("Linear kernel over basis function without prior covariance"); 216s ***** demo 216s ## Projection over basis function with rbf kernel 216s pp = [2, 2, 0.3, 1]; 216s n = 10; 216s rand ("seed", 145); 216s X = 2 * rand (n, 1) - 1; 216s randn ("seed", 45); 216s Y = polyval (pp, X) + 0.3 * randn (n, 1); 216s 216s ## Powers 216s px = [sqrt(abs(X)), X, X.^2, X.^3]; 216s 216s ## Points for interpolation/extrapolation 216s Xfit = linspace (-1, 1, 100)'; 216s pxi = [sqrt(abs(Xfit)), Xfit, Xfit.^2, Xfit.^3]; 216s 216s ## Fit regression model with RBF kernel (standard parameters) 216s [Yfit, Yint, Ysd] = regress_gp (px, Y, pxi, "rbf"); 216s 216s ## Plot fitted data 216s plot (X, Y, "xk;Data;", Xfit, Yfit, "r-;Estimation;", ... 216s Xfit, polyval (pp, Xfit), "g-;True;"); 216s axis tight 216s axis manual 216s hold on 216s plot (Xfit, Yint(:,1), "m-;Upper bound;", Xfit, Yint(:,2), "b-;Lower bound;"); 216s hold off 216s title ("RBF kernel over basis function with standard parameters"); 216s text (-0.5, 4, "theta = 5\n g = 0.01"); 216s ***** demo 216s ## Projection over basis function with rbf kernel 216s pp = [2, 2, 0.3, 1]; 216s n = 10; 216s rand ("seed", 145); 216s X = 2 * rand (n, 1) - 1; 216s randn ("seed", 45); 216s Y = polyval (pp, X) + 0.3 * randn (n, 1); 216s 216s ## Powers 216s px = [sqrt(abs(X)), X, X.^2, X.^3]; 216s 216s ## Points for interpolation/extrapolation 216s Xfit = linspace (-1, 1, 100)'; 216s pxi = [sqrt(abs(Xfit)), Xfit, Xfit.^2, Xfit.^3]; 216s 216s ## Fit regression model with RBF kernel with different parameters 216s [Yfit, Yint, Ysd] = regress_gp (px, Y, pxi, "rbf", 10, 0.01); 216s 216s ## Plot fitted data 216s plot (X, Y, "xk;Data;", Xfit, Yfit, "r-;Estimation;", ... 216s Xfit, polyval (pp, Xfit), "g-;True;"); 216s axis tight 216s axis manual 216s hold on 216s plot (Xfit, Yint(:,1), "m-;Upper bound;", Xfit, Yint(:,2), "b-;Lower bound;"); 216s hold off 216s title ("GP regression with RBF kernel and non default parameters"); 216s text (-0.5, 4, "theta = 10\n g = 0.01"); 216s 216s ## Fit regression model with RBF kernel with different parameters 216s [Yfit, Yint, Ysd] = regress_gp (px, Y, pxi, "rbf", 50, 0.01); 216s 216s ## Plot fitted data 216s figure 216s plot (X, Y, "xk;Data;", Xfit, Yfit, "r-;Estimation;", ... 216s Xfit, polyval (pp, Xfit), "g-;True;"); 216s axis tight 216s axis manual 216s hold on 216s plot (Xfit, Yint(:,1), "m-;Upper bound;", Xfit, Yint(:,2), "b-;Lower bound;"); 216s hold off 216s title ("GP regression with RBF kernel and non default parameters"); 216s text (-0.5, 4, "theta = 50\n g = 0.01"); 216s 216s ## Fit regression model with RBF kernel with different parameters 216s [Yfit, Yint, Ysd] = regress_gp (px, Y, pxi, "rbf", 50, 0.001); 216s 216s ## Plot fitted data 216s figure 216s plot (X, Y, "xk;Data;", Xfit, Yfit, "r-;Estimation;", ... 216s Xfit, polyval (pp, Xfit), "g-;True;"); 216s axis tight 216s axis manual 216s hold on 216s plot (Xfit, Yint(:,1), "m-;Upper bound;", Xfit, Yint(:,2), "b-;Lower bound;"); 216s hold off 216s title ("GP regression with RBF kernel and non default parameters"); 216s text (-0.5, 4, "theta = 50\n g = 0.001"); 216s 216s ## Fit regression model with RBF kernel with different parameters 216s [Yfit, Yint, Ysd] = regress_gp (px, Y, pxi, "rbf", 50, 0.05); 216s 216s ## Plot fitted data 216s figure 216s plot (X, Y, "xk;Data;", Xfit, Yfit, "r-;Estimation;", ... 216s Xfit, polyval (pp, Xfit), "g-;True;"); 216s axis tight 216s axis manual 216s hold on 216s plot (Xfit, Yint(:,1), "m-;Upper bound;", Xfit, Yint(:,2), "b-;Lower bound;"); 216s hold off 216s title ("GP regression with RBF kernel and non default parameters"); 216s text (-0.5, 4, "theta = 50\n g = 0.05"); 216s ***** demo 216s ## RBF fitting on noiseless 1D Data 216s x = [0:2*pi/7:2*pi]'; 216s y = 5 * sin (x); 216s 216s ## Predictive grid of 500 equally spaced locations 216s xi = [-0.5:(2*pi+1)/499:2*pi+0.5]'; 216s 216s ## Fit regression model with RBF kernel 216s [Yfit, Yint, Ysd] = regress_gp (x, y, xi, "rbf"); 216s 216s ## Plot fitted data 216s r = mvnrnd (Yfit, diag (Ysd)', 50); 216s plot (xi, r', "c-"); 216s hold on 216s plot (xi, Yfit, "r-;Estimation;", xi, Yint, "b-;Confidence interval;"); 216s plot (x, y, ".k;Predictor points;", "markersize", 20) 216s plot (xi, 5 * sin (xi), "-y;True Function;"); 216s xlim ([-0.5,2*pi+0.5]); 216s ylim ([-10,10]); 216s hold off 216s title ("GP regression with RBF kernel on noiseless 1D data"); 216s text (0, -7, "theta = 5\n g = 0.01"); 216s ***** demo 216s ## RBF fitting on noisy 1D Data 216s x = [0:2*pi/7:2*pi]'; 216s x = [x; x]; 216s y = 5 * sin (x) + randn (size (x)); 216s 216s ## Predictive grid of 500 equally spaced locations 216s xi = [-0.5:(2*pi+1)/499:2*pi+0.5]'; 216s 216s ## Fit regression model with RBF kernel 216s [Yfit, Yint, Ysd] = regress_gp (x, y, xi, "rbf"); 216s 216s ## Plot fitted data 216s r = mvnrnd (Yfit, diag (Ysd)', 50); 216s plot (xi, r', "c-"); 216s hold on 216s plot (xi, Yfit, "r-;Estimation;", xi, Yint, "b-;Confidence interval;"); 216s plot (x, y, ".k;Predictor points;", "markersize", 20) 216s plot (xi, 5 * sin (xi), "-y;True Function;"); 216s xlim ([-0.5,2*pi+0.5]); 216s ylim ([-10,10]); 216s hold off 216s title ("GP regression with RBF kernel on noisy 1D data"); 216s text (0, -7, "theta = 5\n g = 0.01"); 216s ***** error regress_gp (ones (20, 2)) 216s ***** error regress_gp (ones (20, 2), ones (20, 1)) 216s ***** error ... 216s regress_gp (ones (20, 2, 3), ones (20, 1), ones (20, 2)) 216s ***** error ... 216s regress_gp (ones (20, 2), ones (20, 2), ones (20, 2)) 216s ***** error ... 216s regress_gp (ones (20, 2), ones (15, 1), ones (20, 2)) 216s ***** error ... 216s regress_gp (ones (20, 2), ones (20, 1), ones (20, 3)) 216s ***** error ... 216s regress_gp (ones (20, 2), ones (20, 1), ones (10, 2), {[3]}) 216s ***** error ... 216s regress_gp (ones (20, 2), ones (20, 1), ones (10, 2), "kernel") 216s ***** error ... 216s regress_gp (ones (20, 2), ones (20, 1), ones (10, 2), "rbf", ones (4)) 216s ***** error ... 216s regress_gp (ones (20, 2), ones (20, 1), ones (10, 2), "linear", 1) 216s ***** error ... 216s regress_gp (ones (20, 2), ones (20, 1), ones (10, 2), "rbf", "value") 216s ***** error ... 216s regress_gp (ones (20, 2), ones (20, 1), ones (10, 2), "rbf", {5}) 216s ***** error ... 216s regress_gp (ones (20, 2), ones (20, 1), ones (10, 2), ones (3), 5) 216s ***** error ... 216s regress_gp (ones (20, 2), ones (20, 1), ones (10, 2), "linear", 5) 216s ***** error ... 216s regress_gp (ones (20, 2), ones (20, 1), ones (10, 2), "rbf", 5, {5}) 216s ***** error ... 216s regress_gp (ones (20, 2), ones (20, 1), ones (10, 2), "rbf", 5, ones (2)) 216s ***** error ... 216s regress_gp (ones (20, 2), ones (20, 1), ones (10, 2), 5, 0.01, [1, 1]) 216s ***** error ... 216s regress_gp (ones (20, 2), ones (20, 1), ones (10, 2), 5, 0.01, "f") 216s ***** error ... 216s regress_gp (ones (20, 2), ones (20, 1), ones (10, 2), 5, 0.01, "f") 216s ***** error ... 216s regress_gp (ones (20, 2), ones (20, 1), ones (10, 2), "rbf", 5, 0.01, "f") 216s ***** error ... 216s regress_gp (ones (20, 2), ones (20, 1), ones (10, 2), "rbf", 5, 0.01, [1, 1]) 216s ***** error ... 216s regress_gp (ones (20, 2), ones (20, 1), ones (10, 2), "linear", 1) 216s 22 tests, 22 passed, 0 known failure, 0 skipped 216s [inst/manovacluster.m] 216s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/manovacluster.m 216s ***** demo 216s load carbig 216s X = [MPG Acceleration Weight Displacement]; 216s [d, p, stats] = manova1 (X, Origin); 216s manovacluster (stats) 216s ***** test 216s hf = figure ("visible", "off"); 216s unwind_protect 216s load carbig 216s X = [MPG Acceleration Weight Displacement]; 216s [d, p, stats] = manova1 (X, Origin); 216s manovacluster (stats); 216s unwind_protect_cleanup 216s close (hf); 216s end_unwind_protect 217s ***** error manovacluster (stats, "some"); 217s 2 tests, 2 passed, 0 known failure, 0 skipped 217s [inst/tiedrank.m] 217s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/tiedrank.m 217s ***** test 217s [r,tieadj] = tiedrank ([10, 20, 30, 40, 20]); 217s assert (r, [1, 2.5, 4, 5, 2.5]); 217s assert (tieadj, 3); 217s ***** test 217s [r,tieadj] = tiedrank ([10; 20; 30; 40; 20]); 217s assert (r, [1; 2.5; 4; 5; 2.5]); 217s assert (tieadj, 3); 217s ***** test 217s [r,tieadj] = tiedrank ([10, 20, 30, 40, 20], 1); 217s assert (r, [1, 2.5, 4, 5, 2.5]); 217s assert (tieadj, [1; 0; 18]); 217s ***** test 217s [r,tieadj] = tiedrank ([10, 20, 30, 40, 20], 0, 1); 217s assert (r, [1, 2.5, 2, 1, 2.5]); 217s assert (tieadj, 3); 217s ***** test 217s [r,tieadj] = tiedrank ([10, 20, 30, 40, 20], 1, 1); 217s assert (r, [1, 2.5, 2, 1, 2.5]); 217s assert (tieadj, [1; 0; 18]); 217s ***** error tiedrank (ones (2)) 217s ***** error ... 217s tiedrank ([1, 2, 3, 4, 5], [1, 1]) 217s ***** error ... 217s tiedrank ([1, 2, 3, 4, 5], "A") 217s ***** error ... 217s tiedrank ([1, 2, 3, 4, 5], [true, true]) 217s ***** error ... 217s tiedrank ([1, 2, 3, 4, 5], 0, [1, 1]) 217s ***** error ... 217s tiedrank ([1, 2, 3, 4, 5], 0, "A") 217s ***** error ... 217s tiedrank ([1, 2, 3, 4, 5], 0, [true, true]) 217s 12 tests, 12 passed, 0 known failure, 0 skipped 217s [inst/probit.m] 217s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/probit.m 217s ***** assert (probit ([-1, 0, 0.5, 1, 2]), [NaN, -Inf, 0, Inf, NaN]) 217s ***** assert (probit ([0.2, 0.99]), norminv ([0.2, 0.99])) 217s ***** error probit () 217s ***** error probit (1, 2) 217s 4 tests, 4 passed, 0 known failure, 0 skipped 217s [inst/knnsearch.m] 217s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/knnsearch.m 217s ***** demo 217s ## find 10 nearest neighbour of a point using different distance metrics 217s ## and compare the results by plotting 217s load fisheriris 217s X = meas(:,3:4); 217s Y = species; 217s point = [5, 1.45]; 217s 217s ## calculate 10 nearest-neighbours by minkowski distance 217s [id, d] = knnsearch (X, point, "K", 10); 217s 217s ## calculate 10 nearest-neighbours by minkowski distance 217s [idm, dm] = knnsearch (X, point, "K", 10, "distance", "minkowski", "p", 5); 217s 217s ## calculate 10 nearest-neighbours by chebychev distance 217s [idc, dc] = knnsearch (X, point, "K", 10, "distance", "chebychev"); 217s 217s ## plotting the results 217s gscatter (X(:,1), X(:,2), species, [.75 .75 0; 0 .75 .75; .75 0 .75], ".", 20); 217s title ("Fisher's Iris Data - Nearest Neighbors with different types of distance metrics"); 217s xlabel("Petal length (cm)"); 217s ylabel("Petal width (cm)"); 217s 217s line (point(1), point(2), "marker", "X", "color", "k", ... 217s "linewidth", 2, "displayname", "query point") 217s line (X(id,1), X(id,2), "color", [0.5 0.5 0.5], "marker", "o", ... 217s "linestyle", "none", "markersize", 10, "displayname", "eulcidean") 217s line (X(idm,1), X(idm,2), "color", [0.5 0.5 0.5], "marker", "d", ... 217s "linestyle", "none", "markersize", 10, "displayname", "Minkowski") 217s line (X(idc,1), X(idc,2), "color", [0.5 0.5 0.5], "marker", "p", ... 217s "linestyle", "none", "markersize", 10, "displayname", "chebychev") 217s xlim ([4.5 5.5]); 217s ylim ([1 2]); 217s axis square; 217s ***** demo 217s ## knnsearch on iris dataset using kdtree method 217s load fisheriris 217s X = meas(:,3:4); 217s gscatter (X(:,1), X(:,2), species, [.75 .75 0; 0 .75 .75; .75 0 .75], ".", 20); 217s title ("Fisher's iris dataset : Nearest Neighbors with kdtree search"); 217s 217s ## new point to be predicted 217s point = [5 1.45]; 217s 217s line (point(1), point(2), "marker", "X", "color", "k", ... 217s "linewidth", 2, "displayname", "query point") 217s 217s ## knnsearch using kdtree method 217s [idx, d] = knnsearch (X, point, "K", 10, "NSMethod", "kdtree"); 217s 217s ## plotting predicted neighbours 217s line (X(idx,1), X(idx,2), "color", [0.5 0.5 0.5], "marker", "o", ... 217s "linestyle", "none", "markersize", 10, ... 217s "displayname", "nearest neighbour") 217s xlim ([4 6]) 217s ylim ([1 3]) 217s axis square 217s ## details of predicted labels 217s tabulate (species(idx)) 217s 217s ctr = point - d(end); 217s diameter = 2 * d(end); 217s ## Draw a circle around the 10 nearest neighbors. 217s h = rectangle ("position", [ctr, diameter, diameter], "curvature", [1 1]); 217s 217s ## here only 8 neighbours are plotted instead of 10 since the dataset 217s ## contains duplicate values 217s ***** shared X, Y 217s X = [1, 2, 3, 4; 2, 3, 4, 5; 3, 4, 5, 6]; 217s Y = [1, 2, 2, 3; 2, 3, 3, 4]; 217s ***** test 217s [idx, D] = knnsearch (X, Y, "Distance", "euclidean"); 217s assert (idx, [1; 1]); 217s assert (D, ones (2, 1) * sqrt (2)); 217s ***** test 217s eucldist = @(v,m) sqrt(sumsq(repmat(v,rows(m),1)-m,2)); 217s [idx, D] = knnsearch (X, Y, "Distance", eucldist); 217s assert (idx, [1; 1]); 217s assert (D, ones (2, 1) * sqrt (2)); 217s ***** test 217s [idx, D] = knnsearch (X, Y, "Distance", "euclidean", "includeties", true); 217s assert (iscell (idx), true); 217s assert (iscell (D), true) 217s assert (idx {1}, [1]); 217s assert (idx {2}, [1, 2]); 217s assert (D{1}, ones (1, 1) * sqrt (2)); 217s assert (D{2}, ones (1, 2) * sqrt (2)); 217s ***** test 217s [idx, D] = knnsearch (X, Y, "Distance", "euclidean", "k", 2); 217s assert (idx, [1, 2; 1, 2]); 217s assert (D, [sqrt(2), 3.162277660168380; sqrt(2), sqrt(2)], 1e-14); 217s ***** test 217s [idx, D] = knnsearch (X, Y, "Distance", "seuclidean"); 217s assert (idx, [1; 1]); 217s assert (D, ones (2, 1) * sqrt (2)); 217s ***** test 217s [idx, D] = knnsearch (X, Y, "Distance", "seuclidean", "k", 2); 217s assert (idx, [1, 2; 1, 2]); 217s assert (D, [sqrt(2), 3.162277660168380; sqrt(2), sqrt(2)], 1e-14); 217s ***** test 217s xx = [1, 2; 1, 3; 2, 4; 3, 6]; 217s yy = [2, 4; 2, 6]; 217s [idx, D] = knnsearch (xx, yy, "Distance", "mahalanobis"); 217s assert (idx, [3; 2]); 217s assert (D, [0; 3.162277660168377], 1e-14); 217s ***** test 217s [idx, D] = knnsearch (X, Y, "Distance", "minkowski"); 217s assert (idx, [1; 1]); 217s assert (D, ones (2, 1) * sqrt (2)); 217s ***** test 217s [idx, D] = knnsearch (X, Y, "Distance", "minkowski", "p", 3); 217s assert (idx, [1; 1]); 217s assert (D, ones (2, 1) * 1.259921049894873, 1e-14); 217s ***** test 217s [idx, D] = knnsearch (X, Y, "Distance", "cityblock"); 217s assert (idx, [1; 1]); 217s assert (D, [2; 2]); 217s ***** test 217s [idx, D] = knnsearch (X, Y, "Distance", "chebychev"); 217s assert (idx, [1; 1]); 217s assert (D, [1; 1]); 217s ***** test 217s [idx, D] = knnsearch (X, Y, "Distance", "cosine"); 217s assert (idx, [2; 3]); 217s assert (D, [0.005674536395645; 0.002911214328620], 1e-14); 217s ***** test 217s [idx, D] = knnsearch (X, Y, "Distance", "correlation"); 217s assert (idx, [1; 1]); 217s assert (D, ones (2, 1) * 0.051316701949486, 1e-14); 217s ***** test 217s [idx, D] = knnsearch (X, Y, "Distance", "spearman"); 217s assert (idx, [1; 1]); 217s assert (D, ones (2, 1) * 0.051316701949486, 1e-14); 217s ***** test 217s [idx, D] = knnsearch (X, Y, "Distance", "hamming"); 217s assert (idx, [1; 1]); 217s assert (D, [0.5; 0.5]); 217s ***** test 217s [idx, D] = knnsearch (X, Y, "Distance", "jaccard"); 217s assert (idx, [1; 1]); 217s assert (D, [0.5; 0.5]); 217s ***** test 217s [idx, D] = knnsearch (X, Y, "Distance", "jaccard", "k", 2); 217s assert (idx, [1, 2; 1, 2]); 217s assert (D, [0.5, 1; 0.5, 0.5]); 217s ***** test 217s a = [1, 5; 1, 2; 2, 2; 1.5, 1.5; 5, 1; 2 -1.34; 1, -3; 4, -4; -3, 1; 8, 9]; 217s b = [1, 1]; 217s [idx, D] = knnsearch (a, b, "K", 5, "NSMethod", "kdtree", "includeties", true); 217s assert (iscell (idx), true); 217s assert (iscell (D), true) 217s assert (cell2mat (idx), [4, 2, 3, 6, 1, 5, 7, 9]); 217s assert (cell2mat (D), [0.7071, 1.0000, 1.4142, 2.5447, 4.0000, 4.0000, 4.0000, 4.0000],1e-4); 217s ***** test 217s a = [1, 5; 1, 2; 2, 2; 1.5, 1.5; 5, 1; 2 -1.34; 1, -3; 4, -4; -3, 1; 8, 9]; 217s b = [1, 1]; 217s [idx, D] = knnsearch (a, b, "K", 5, "NSMethod", "exhaustive", "includeties", true); 217s assert (iscell (idx), true); 217s assert (iscell (D), true) 217s assert (cell2mat (idx), [4, 2, 3, 6, 1, 5, 7, 9]); 217s assert (cell2mat (D), [0.7071, 1.0000, 1.4142, 2.5447, 4.0000, 4.0000, 4.0000, 4.0000],1e-4); 217s ***** test 217s a = [1, 5; 1, 2; 2, 2; 1.5, 1.5; 5, 1; 2 -1.34; 1, -3; 4, -4; -3, 1; 8, 9]; 217s b = [1, 1]; 217s [idx, D] = knnsearch (a, b, "K", 5, "NSMethod", "kdtree", "includeties", false); 217s assert (iscell (idx), false); 217s assert (iscell (D), false) 217s assert (idx, [4, 2, 3, 6, 1]); 217s assert (D, [0.7071, 1.0000, 1.4142, 2.5447, 4.0000],1e-4); 218s ***** test 218s a = [1, 5; 1, 2; 2, 2; 1.5, 1.5; 5, 1; 2 -1.34; 1, -3; 4, -4; -3, 1; 8, 9]; 218s b = [1, 1]; 218s [idx, D] = knnsearch (a, b, "K", 5, "NSMethod", "exhaustive", "includeties", false); 218s assert (iscell (idx), false); 218s assert (iscell (D), false) 218s assert (idx, [4, 2, 3, 6, 1]); 218s assert (D, [0.7071, 1.0000, 1.4142, 2.5447, 4.0000],1e-4); 218s ***** test 218s load fisheriris 218s a = meas; 218s b = min(meas); 218s [idx, D] = knnsearch (a, b, "K", 5, "NSMethod", "kdtree"); 218s assert (idx, [42, 9, 14, 39, 13]); 218s assert (D, [0.5099, 0.9950, 1.0050, 1.0536, 1.1874],1e-4); 218s ***** test 218s load fisheriris 218s a = meas; 218s b = mean(meas); 218s [idx, D] = knnsearch (a, b, "K", 5, "NSMethod", "kdtree"); 218s assert (idx, [65, 83, 89, 72, 100]); 218s assert (D, [0.3451, 0.3869, 0.4354, 0.4481, 0.4625],1e-4); 218s ***** test 218s load fisheriris 218s a = meas; 218s b = max(meas); 218s [idx, D] = knnsearch (a, b, "K", 5, "NSMethod", "kdtree"); 218s assert (idx, [118, 132, 110, 106, 136]); 218s assert (D, [0.7280, 0.9274, 1.3304, 1.5166, 1.6371],1e-4); 218s 219s ***** test 219s load fisheriris 219s a = meas; 219s b = max(meas); 219s [idx, D] = knnsearch (a, b, "K", 5, "includeties", true); 219s assert ( iscell (idx), true); 219s assert ( iscell (D), true); 219s assert (cell2mat (idx), [118, 132, 110, 106, 136]); 219s assert (cell2mat (D), [0.7280, 0.9274, 1.3304, 1.5166, 1.6371],1e-4); 219s ***** error knnsearch (1) 219s ***** error ... 219s knnsearch (ones (4, 5), ones (4)) 219s ***** error ... 219s knnsearch (ones (4, 2), ones (3, 2), "Distance", "euclidean", "some", "some") 219s ***** error ... 219s knnsearch (ones (4, 5), ones (1, 5), "scale", ones (1, 5), "P", 3) 219s ***** error ... 219s knnsearch (ones (4, 5), ones (1, 5), "K", 0) 219s ***** error ... 219s knnsearch (ones (4, 5), ones (1, 5), "P",-2) 219s ***** error ... 219s knnsearch (ones (4, 5), ones (1, 5), "scale", ones(4,5), "distance", "euclidean") 219s ***** error ... 219s knnsearch (ones (4, 5), ones (1, 5), "cov", ["some" "some"]) 219s ***** error ... 219s knnsearch (ones (4, 5), ones (1, 5), "cov", ones(4,5), "distance", "euclidean") 219s ***** error ... 219s knnsearch (ones (4, 5), ones (1, 5), "bucketsize", -1) 219s ***** error ... 219s knnsearch (ones (4, 5), ones (1, 5), "NSmethod", "kdtree", "distance", "cosine") 219s ***** error ... 219s knnsearch (ones (4, 5), ones (1, 5), "NSmethod", "kdtree", "distance", "mahalanobis") 219s ***** error ... 219s knnsearch (ones (4, 5), ones (1, 5), "NSmethod", "kdtree", "distance", "correlation") 219s ***** error ... 219s knnsearch (ones (4, 5), ones (1, 5), "NSmethod", "kdtree", "distance", "seuclidean") 219s ***** error ... 219s knnsearch (ones (4, 5), ones (1, 5), "NSmethod", "kdtree", "distance", "spearman") 219s ***** error ... 219s knnsearch (ones (4, 5), ones (1, 5), "NSmethod", "kdtree", "distance", "hamming") 219s ***** error ... 219s knnsearch (ones (4, 5), ones (1, 5), "NSmethod", "kdtree", "distance", "jaccard") 219s 42 tests, 42 passed, 0 known failure, 0 skipped 219s [inst/canoncorr.m] 219s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/canoncorr.m 219s ***** shared X,Y,A,B,r,U,V,k 219s k = 10; 219s X = [1:k; sin(1:k); cos(1:k)]'; Y = [tan(1:k); tanh((1:k)/k)]'; 219s [A,B,r,U,V,stats] = canoncorr (X,Y); 219s ***** assert (A, [-0.329229 0.072908; 0.074870 1.389318; -0.069302 -0.024109], 1E-6); 219s ***** assert (B, [-0.017086 -0.398402; -4.475049 -0.824538], 1E-6); 219s ***** assert (r, [0.99590 0.26754], 1E-5); 219s ***** assert (U, center(X) * A, 10*eps); 219s ***** assert (V, center(Y) * B, 10*eps); 219s ***** assert (cov(U), eye(size(U, 2)), 10*eps); 219s ***** assert (cov(V), eye(size(V, 2)), 10*eps); 219s rand ("state", 1); [A,B,r] = canoncorr (rand(5, 10),rand(5, 20)); 219s ***** assert (r, ones(1, 5), 10*eps); 219s 8 tests, 8 passed, 0 known failure, 0 skipped 219s [inst/hist3.m] 219s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/hist3.m 219s ***** demo 219s X = [ 219s 1 1 219s 1 1 219s 1 10 219s 1 10 219s 5 5 219s 5 5 219s 5 5 219s 5 5 219s 5 5 219s 7 3 219s 7 3 219s 7 3 219s 10 10 219s 10 10]; 219s hist3 (X) 219s ***** test 219s N_exp = [ 0 0 0 5 20 219s 0 0 10 15 0 219s 0 15 10 0 0 219s 20 5 0 0 0]; 219s 219s n = 100; 219s x = [1:n]'; 219s y = [n:-1:1]'; 219s D = [x y]; 219s N = hist3 (D, [4 5]); 219s assert (N, N_exp); 219s ***** test 219s N_exp = [0 0 0 0 1 219s 0 0 0 0 1 219s 0 0 0 0 1 219s 1 1 1 1 93]; 219s 219s n = 100; 219s x = [1:n]'; 219s y = [n:-1:1]'; 219s D = [x y]; 219s C{1} = [1 1.7 3 4]; 219s C{2} = [1:5]; 219s N = hist3 (D, C); 219s assert (N, N_exp); 219s ***** test 219s D = [1 1; 3 1; 3 3; 3 1]; 219s [c, nn] = hist3 (D, {0:4, 0:4}); 219s exp_c = zeros (5); 219s exp_c([7 9 19]) = [1 2 1]; 219s assert (c, exp_c); 219s assert (nn, {0:4, 0:4}); 219s ***** test 219s for i = 10 219s assert (size (hist3 (rand (9, 2), "Edges", {[0:.2:1]; [0:.2:1]})), [6 6]) 219s endfor 219s ***** test 219s edge_1 = linspace (0, 10, 10); 219s edge_2 = linspace (0, 50, 10); 219s [c, nn] = hist3 ([1:10; 1:5:50]', "Edges", {edge_1, edge_2}); 219s exp_c = zeros (10, 10); 219s exp_c([1 12 13 24 35 46 57 68 79 90]) = 1; 219s assert (c, exp_c); 219s 219s assert (nn{1}, edge_1 + edge_1(2)/2, eps*10^4) 219s assert (nn{2}, edge_2 + edge_2(2)/2, eps*10^4) 219s ***** shared X 219s X = [ 219s 5 2 219s 5 3 219s 1 4 219s 5 3 219s 4 4 219s 1 2 219s 2 3 219s 3 3 219s 5 4 219s 5 3]; 219s ***** test 219s N = zeros (10); 219s N([1 10 53 56 60 91 98 100]) = [1 1 1 1 3 1 1 1]; 219s C = {(1.2:0.4:4.8), (2.1:0.2:3.9)}; 219s assert (nthargout ([1 2], @hist3, X), {N C}, eps*10^3) 219s ***** test 219s N = zeros (5, 7); 219s N([1 5 17 18 20 31 34 35]) = [1 1 1 1 3 1 1 1]; 219s C = {(1.4:0.8:4.6), ((2+(1/7)):(2/7):(4-(1/7)))}; 219s assert (nthargout ([1 2], @hist3, X, [5 7]), {N C}, eps*10^3) 219s assert (nthargout ([1 2], @hist3, X, "Nbins", [5 7]), {N C}, eps*10^3) 219s ***** test 219s N = [0 1 0; 0 1 0; 0 0 1; 0 0 0]; 219s C = {(2:5), (2.5:1:4.5)}; 219s assert (nthargout ([1 2], @hist3, X, "Edges", {(1.5:4.5), (2:4)}), {N C}) 219s ***** test 219s N = [0 0 1 0 1 0; 0 0 0 1 0 0; 0 0 1 4 2 0]; 219s C = {(1.2:3.2), (0:5)}; 219s assert (nthargout ([1 2], @hist3, X, "Ctrs", C), {N C}) 219s assert (nthargout ([1 2], @hist3, X, C), {N C}) 219s ***** test 219s [~, C] = hist3 (rand (10, 2), "Edges", {[0 .05 .15 .35 .55 .95], 219s [-1 .05 .07 .2 .3 .5 .89 1.2]}); 219s C_exp = {[ 0.025 0.1 0.25 0.45 0.75 1.15], ... 219s [-0.475 0.06 0.135 0.25 0.4 0.695 1.045 1.355]}; 219s assert (C, C_exp, eps*10^2) 219s ***** test 219s Xv = repmat ([1:10]', [1 2]); 219s 219s ## Test Centers 219s assert (hist3 (Xv, "Ctrs", {1:10, 1:10}), eye (10)) 219s 219s N_exp = eye (6); 219s N_exp([1 end]) = 3; 219s assert (hist3 (Xv, "Ctrs", {3:8, 3:8}), N_exp) 219s 219s N_exp = zeros (8, 6); 219s N_exp([1 2 11 20 29 38 47 48]) = [2 1 1 1 1 1 1 2]; 219s assert (hist3 (Xv, "Ctrs", {2:9, 3:8}), N_exp) 219s 219s ## Test Edges 219s assert (hist3 (Xv, "Edges", {1:10, 1:10}), eye (10)) 219s assert (hist3 (Xv, "Edges", {3:8, 3:8}), eye (6)) 219s assert (hist3 (Xv, "Edges", {2:9, 3:8}), [zeros(1, 6); eye(6); zeros(1, 6)]) 219s 219s N_exp = zeros (14); 219s N_exp(3:12, 3:12) = eye (10); 219s assert (hist3 (Xv, "Edges", {-1:12, -1:12}), N_exp) 219s 219s ## Test for Nbins 219s assert (hist3 (Xv), eye (10)) 219s assert (hist3 (Xv, [10 10]), eye (10)) 219s assert (hist3 (Xv, "nbins", [10 10]), eye (10)) 219s assert (hist3 (Xv, [5 5]), eye (5) * 2) 219s 219s N_exp = zeros (7, 5); 219s N_exp([1 9 10 18 26 27 35]) = [2 1 1 2 1 1 2]; 219s assert (hist3 (Xv, [7 5]), N_exp) 219s ***** test # bug #51059 219s D = [1 1; NaN 2; 3 1; 3 3; 1 NaN; 3 1]; 219s [c, nn] = hist3 (D, {0:4, 0:4}); 219s exp_c = zeros (5); 219s exp_c([7 9 19]) = [1 2 1]; 219s assert (c, exp_c) 219s assert (nn, {0:4, 0:4}) 219s ***** test 219s [c, nn] = hist3 ([1 8]); 219s exp_c = zeros (10, 10); 219s exp_c(6, 6) = 1; 219s exp_nn = {-4:5, 3:12}; 219s assert (c, exp_c) 219s assert (nn, exp_nn, eps) 219s 219s [c, nn] = hist3 ([1 8], [10 11]); 219s exp_c = zeros (10, 11); 219s exp_c(6, 6) = 1; 219s exp_nn = {-4:5, 3:13}; 219s assert (c, exp_c) 219s assert (nn, exp_nn, eps) 219s ***** test 219s [c, nn] = hist3 ([1 NaN; 2 3; 6 9; 8 NaN]); 219s exp_c = zeros (10, 10); 219s exp_c(2, 1) = 1; 219s exp_c(8, 10) = 1; 219s exp_nn = {linspace(1.35, 7.65, 10) linspace(3.3, 8.7, 10)}; 219s assert (c, exp_c) 219s assert (nn, exp_nn, eps*100) 219s ***** test 219s [c, nn] = hist3 ([1 NaN; 2 NaN; 6 NaN; 8 NaN]); 219s exp_c = zeros (10, 10); 219s exp_nn = {linspace(1.35, 7.65, 10) NaN(1, 10)}; 219s assert (c, exp_c) 219s assert (nn, exp_nn, eps*100) 219s ***** test 219s [c, nn] = hist3 ([1 NaN; NaN 3; NaN 9; 8 NaN]); 219s exp_c = zeros (10, 10); 219s exp_nn = {linspace(1.35, 7.65, 10) linspace(3.3, 8.7, 10)}; 219s assert (c, exp_c) 219s assert (nn, exp_nn, eps*100) 219s 16 tests, 16 passed, 0 known failure, 0 skipped 219s [inst/cholcov.m] 219s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/cholcov.m 219s ***** demo 219s C1 = [2, 1, 1, 2; 1, 2, 1, 2; 1, 1, 2, 2; 2, 2, 2, 3] 219s T = cholcov (C1) 219s C2 = T'*T 219s ***** test 219s C1 = [2, 1, 1, 2; 1, 2, 1, 2; 1, 1, 2, 2; 2, 2, 2, 3]; 219s T = cholcov (C1); 219s assert (C1, T'*T, 1e-15 * ones (size (C1))); 219s 1 test, 1 passed, 0 known failure, 0 skipped 219s [inst/rangesearch.m] 219s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/rangesearch.m 219s ***** demo 219s ## Generate 1000 random 2D points from each of five distinct multivariate 219s ## normal distributions that form five separate classes 219s N = 1000; 219s d = 10; 219s randn ("seed", 5); 219s X1 = mvnrnd (d * [0, 0], eye (2), 1000); 219s randn ("seed", 6); 219s X2 = mvnrnd (d * [1, 1], eye (2), 1000); 219s randn ("seed", 7); 219s X3 = mvnrnd (d * [-1, -1], eye (2), 1000); 219s randn ("seed", 8); 219s X4 = mvnrnd (d * [1, -1], eye (2), 1000); 219s randn ("seed", 8); 219s X5 = mvnrnd (d * [-1, 1], eye (2), 1000); 219s X = [X1; X2; X3; X4; X5]; 219s 219s ## For each point in X, find the points in X that are within a radius d 219s ## away from the points in X. 219s Idx = rangesearch (X, X, d, "NSMethod", "exhaustive"); 219s 219s ## Select the first point in X (corresponding to the first class) and find 219s ## its nearest neighbors within the radius d. Display these points in 219s ## one color and the remaining points in a different color. 219s x = X(1,:); 219s nearestPoints = X (Idx{1},:); 219s nonNearestIdx = true (size (X, 1), 1); 219s nonNearestIdx(Idx{1}) = false; 219s 219s scatter (X(nonNearestIdx,1), X(nonNearestIdx,2)) 219s hold on 219s scatter (nearestPoints(:,1),nearestPoints(:,2)) 219s scatter (x(1), x(2), "black", "filled") 219s hold off 219s 219s ## Select the last point in X (corresponding to the fifth class) and find 219s ## its nearest neighbors within the radius d. Display these points in 219s ## one color and the remaining points in a different color. 219s x = X(end,:); 219s nearestPoints = X (Idx{1},:); 219s nonNearestIdx = true (size (X, 1), 1); 219s nonNearestIdx(Idx{1}) = false; 219s 219s figure 219s scatter (X(nonNearestIdx,1), X(nonNearestIdx,2)) 219s hold on 219s scatter (nearestPoints(:,1),nearestPoints(:,2)) 219s scatter (x(1), x(2), "black", "filled") 219s hold off 219s ***** shared x, y, X, Y 219s x = [1, 2, 3; 4, 5, 6; 7, 8, 9; 3, 2, 1]; 219s y = [2, 3, 4; 1, 4, 3]; 219s X = [1, 2, 3, 4; 2, 3, 4, 5; 3, 4, 5, 6]; 219s Y = [1, 2, 2, 3; 2, 3, 3, 4]; 219s ***** test 219s [idx, D] = rangesearch (x, y, 4); 219s assert (idx, {[1, 4, 2]; [1, 4]}); 219s assert (D, {[1.7321, 3.3166, 3.4641]; [2, 3.4641]}, 1e-4); 219s ***** test 219s [idx, D] = rangesearch (x, y, 4, "NSMethod", "exhaustive"); 219s assert (idx, {[1, 4, 2]; [1, 4]}); 219s assert (D, {[1.7321, 3.3166, 3.4641]; [2, 3.4641]}, 1e-4); 219s ***** test 219s [idx, D] = rangesearch (x, y, 4, "NSMethod", "kdtree"); 219s assert (idx, {[1, 4, 2]; [1, 4]}); 219s assert (D, {[1.7321, 3.3166, 3.4641]; [2, 3.4641]}, 1e-4); 219s ***** test 219s [idx, D] = rangesearch (x, y, 4, "SortIndices", true); 219s assert (idx, {[1, 4, 2]; [1, 4]}); 219s assert (D, {[1.7321, 3.3166, 3.4641]; [2, 3.4641]}, 1e-4); 219s ***** test 219s [idx, D] = rangesearch (x, y, 4, "SortIndices", false); 219s assert (idx, {[1, 2, 4]; [1, 4]}); 219s assert (D, {[1.7321, 3.4641, 3.3166]; [2, 3.4641]}, 1e-4); 219s ***** test 219s [idx, D] = rangesearch (x, y, 4, "NSMethod", "exhaustive", ... 219s "SortIndices", false); 219s assert (idx, {[1, 2, 4]; [1, 4]}); 219s assert (D, {[1.7321, 3.4641, 3.3166]; [2, 3.4641]}, 1e-4); 219s ***** test 219s eucldist = @(v,m) sqrt(sumsq(repmat(v,rows(m),1)-m,2)); 219s [idx, D] = rangesearch (x, y, 4, "Distance", eucldist); 219s assert (idx, {[1, 4, 2]; [1, 4]}); 219s assert (D, {[1.7321, 3.3166, 3.4641]; [2, 3.4641]}, 1e-4); 219s ***** test 219s eucldist = @(v,m) sqrt(sumsq(repmat(v,rows(m),1)-m,2)); 219s [idx, D] = rangesearch (x, y, 4, "Distance", eucldist, ... 219s "NSMethod", "exhaustive"); 219s assert (idx, {[1, 4, 2]; [1, 4]}); 219s assert (D, {[1.7321, 3.3166, 3.4641]; [2, 3.4641]}, 1e-4); 219s ***** test 219s [idx, D] = rangesearch (x, y, 1.5, "Distance", "seuclidean", ... 219s "NSMethod", "exhaustive"); 219s assert (idx, {[1, 4, 2]; [1, 4]}); 219s assert (D, {[0.6024, 1.0079, 1.2047]; [0.6963, 1.2047]}, 1e-4); 219s ***** test 219s [idx, D] = rangesearch (x, y, 1.5, "Distance", "seuclidean", ... 219s "NSMethod", "exhaustive", "SortIndices", false); 219s assert (idx, {[1, 2, 4]; [1, 4]}); 219s assert (D, {[0.6024, 1.2047, 1.0079]; [0.6963, 1.2047]}, 1e-4); 219s ***** test 219s [idx, D] = rangesearch (X, Y, 4); 219s assert (idx, {[1, 2]; [1, 2, 3]}); 219s assert (D, {[1.4142, 3.1623]; [1.4142, 1.4142, 3.1623]}, 1e-4); 219s ***** test 219s [idx, D] = rangesearch (X, Y, 2); 219s assert (idx, {[1]; [1, 2]}); 219s assert (D, {[1.4142]; [1.4142, 1.4142]}, 1e-4); 220s ***** test 220s eucldist = @(v,m) sqrt(sumsq(repmat(v,rows(m),1)-m,2)); 220s [idx, D] = rangesearch (X, Y, 4, "Distance", eucldist); 220s assert (idx, {[1, 2]; [1, 2, 3]}); 220s assert (D, {[1.4142, 3.1623]; [1.4142, 1.4142, 3.1623]}, 1e-4); 220s ***** test 220s [idx, D] = rangesearch (X, Y, 4, "SortIndices", false); 220s assert (idx, {[1, 2]; [1, 2, 3]}); 220s assert (D, {[1.4142, 3.1623]; [1.4142, 1.4142, 3.1623]}, 1e-4); 220s ***** test 220s [idx, D] = rangesearch (X, Y, 4, "Distance", "seuclidean", ... 220s "NSMethod", "exhaustive"); 220s assert (idx, {[1, 2]; [1, 2, 3]}); 220s assert (D, {[1.4142, 3.1623]; [1.4142, 1.4142, 3.1623]}, 1e-4); 220s ***** error rangesearch (1) 220s ***** error ... 220s rangesearch (ones (4, 5), ones (4)) 220s ***** error ... 220s rangesearch (ones (4, 2), ones (3, 2), 1, "Distance", "euclidean", "some", "some") 220s ***** error ... 220s rangesearch (ones (4, 5), ones (1, 5), 1, "scale", ones (1, 5), "P", 3) 220s ***** error ... 220s rangesearch (ones (4, 5), ones (1, 5), 1, "P",-2) 220s ***** error ... 220s rangesearch (ones (4, 5), ones (1, 5), 1, "scale", ones(4,5), "distance", "euclidean") 220s ***** error ... 220s rangesearch (ones (4, 5), ones (1, 5), 1, "cov", ["some" "some"]) 220s ***** error ... 220s rangesearch (ones (4, 5), ones (1, 5), 1, "cov", ones(4,5), "distance", "euclidean") 220s ***** error ... 220s rangesearch (ones (4, 5), ones (1, 5), 1, "bucketsize", -1) 220s ***** error ... 220s rangesearch (ones (4, 5), ones (1, 5), 1, "NSmethod", "kdtree", "distance", "cosine") 220s ***** error ... 220s rangesearch (ones (4, 5), ones (1, 5), 1, "NSmethod", "kdtree", "distance", "mahalanobis") 220s ***** error ... 220s rangesearch (ones (4, 5), ones (1, 5), 1, "NSmethod", "kdtree", "distance", "correlation") 220s ***** error ... 220s rangesearch (ones (4, 5), ones (1, 5), 1, "NSmethod", "kdtree", "distance", "seuclidean") 220s ***** error ... 220s rangesearch (ones (4, 5), ones (1, 5), 1, "NSmethod", "kdtree", "distance", "spearman") 220s ***** error ... 220s rangesearch (ones (4, 5), ones (1, 5), 1, "NSmethod", "kdtree", "distance", "hamming") 220s ***** error ... 220s rangesearch (ones (4, 5), ones (1, 5), 1, "NSmethod", "kdtree", "distance", "jaccard") 220s 31 tests, 31 passed, 0 known failure, 0 skipped 220s [inst/sigma_pts.m] 220s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/sigma_pts.m 220s ***** demo 220s K = [1 0.5; 0.5 1]; # covaraince matrix 220s # calculate and build associated ellipse 220s [R,S,~] = svd (K); 220s theta = atan2 (R(2,1), R(1,1)); 220s v = sqrt (diag (S)); 220s v = v .* [cos(theta) sin(theta); -sin(theta) cos(theta)]; 220s t = linspace (0, 2*pi, 100).'; 220s xe = v(1,1) * cos (t) + v(2,1) * sin (t); 220s ye = v(1,2) * cos (t) + v(2,2) * sin (t); 220s 220s figure(1); clf; hold on 220s # Plot ellipse and axes 220s line ([0 0; v(:,1).'],[0 0; v(:,2).']) 220s plot (xe,ye,'-r'); 220s 220s col = 'rgb'; 220s l = [-1.8 -1 1.5]; 220s for li = 1:3 220s p = sigma_pts (2, [], K, l(li)); 220s tmp = plot (p(2:end,1), p(2:end,2), ['x' col(li)], ... 220s p(1,1), p(1,2), ['o' col(li)]); 220s h(li) = tmp(1); 220s endfor 220s hold off 220s axis image 220s legend (h, arrayfun (@(x) sprintf ("l:%.2g", x), l, "unif", 0)); 220s ***** test 220s p = sigma_pts (5); 220s assert (mean (p), zeros(1,5), sqrt(eps)); 220s assert (cov (p), eye(5), sqrt(eps)); 220s ***** test 220s m = randn(1, 5); 220s p = sigma_pts (5, m); 220s assert (mean (p), m, sqrt(eps)); 220s assert (cov (p), eye(5), sqrt(eps)); 220s ***** test 220s x = linspace (0,1,5); 220s K = exp (- (x.' - x).^2/ 0.5); 220s p = sigma_pts (5, [], K); 220s assert (mean (p), zeros(1,5), sqrt(eps)); 220s assert (cov (p), K, sqrt(eps)); 220s ***** error sigma_pts(2,1); 220s ***** error sigma_pts(2,[],1); 220s ***** error sigma_pts(2,1,1); 220s ***** error sigma_pts(2,[0.5 0.5],[-1 0; 0 0]); 220s 7 tests, 7 passed, 0 known failure, 0 skipped 220s [inst/anova2.m] 220s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/anova2.m 220s ***** demo 220s 220s # Factorial (Crossed) Two-way ANOVA with Interaction 220s 220s popcorn = [5.5, 4.5, 3.5; 5.5, 4.5, 4.0; 6.0, 4.0, 3.0; ... 220s 6.5, 5.0, 4.0; 7.0, 5.5, 5.0; 7.0, 5.0, 4.5]; 220s 220s [p, atab, stats] = anova2(popcorn, 3, "on"); 220s ***** demo 220s 220s # One-way Repeated Measures ANOVA (Rows are a crossed random factor) 220s 220s data = [54, 43, 78, 111; 220s 23, 34, 37, 41; 220s 45, 65, 99, 78; 220s 31, 33, 36, 35; 220s 15, 25, 30, 26]; 220s 220s [p, atab, stats] = anova2 (data, 1, "on", "linear"); 220s ***** demo 220s 220s # Balanced Nested One-way ANOVA (Rows are a nested random factor) 220s 220s data = [4.5924 7.3809 21.322; -0.5488 9.2085 25.0426; ... 220s 6.1605 13.1147 22.66; 2.3374 15.2654 24.1283; ... 220s 5.1873 12.4188 16.5927; 3.3579 14.3951 10.2129; ... 220s 6.3092 8.5986 9.8934; 3.2831 3.4945 10.0203]; 220s 220s [p, atab, stats] = anova2 (data, 4, "on", "nested"); 220s ***** test 220s ## Test for anova2 ("interaction") 220s ## comparison with results from Matlab for column effect 220s popcorn = [5.5, 4.5, 3.5; 5.5, 4.5, 4.0; 6.0, 4.0, 3.0; ... 220s 6.5, 5.0, 4.0; 7.0, 5.5, 5.0; 7.0, 5.0, 4.5]; 220s [p, atab, stats] = anova2 (popcorn, 3, "off"); 220s assert (p(1), 7.678957383294716e-07, 1e-14); 220s assert (p(2), 0.0001003738963050171, 1e-14); 220s assert (p(3), 0.7462153966366274, 1e-14); 220s assert (atab{2,5}, 56.700, 1e-14); 220s assert (atab{2,3}, 2, 0); 220s assert (atab{4,2}, 0.08333333333333348, 1e-14); 220s assert (atab{5,4}, 0.1388888888888889, 1e-14); 220s assert (atab{5,2}, 1.666666666666667, 1e-14); 220s assert (atab{6,2}, 22); 220s assert (stats.source, "anova2"); 220s assert (stats.colmeans, [6.25, 4.75, 4]); 220s assert (stats.inter, 1, 0); 220s assert (stats.pval, 0.7462153966366274, 1e-14); 220s assert (stats.df, 12); 220s ***** test 220s ## Test for anova2 ("linear") - comparison with results from GraphPad Prism 8 220s data = [54, 43, 78, 111; 220s 23, 34, 37, 41; 220s 45, 65, 99, 78; 220s 31, 33, 36, 35; 220s 15, 25, 30, 26]; 220s [p, atab, stats] = anova2 (data, 1, "off", "linear"); 220s assert (atab{2,2}, 2174.95, 1e-10); 220s assert (atab{3,2}, 8371.7, 1e-10); 220s assert (atab{4,2}, 2404.3, 1e-10); 220s assert (atab{5,2}, 12950.95, 1e-10); 220s assert (atab{2,4}, 724.983333333333, 1e-10); 220s assert (atab{3,4}, 2092.925, 1e-10); 220s assert (atab{4,4}, 200.358333333333, 1e-10); 220s assert (atab{2,5}, 3.61843363972882, 1e-10); 220s assert (atab{3,5}, 10.445909412303, 1e-10); 220s assert (atab{2,6}, 0.087266112738617, 1e-10); 220s assert (atab{3,6}, 0.000698397753556, 1e-10); 220s ***** test 220s ## Test for anova2 ("nested") - comparison with results from GraphPad Prism 8 220s data = [4.5924 7.3809 21.322; -0.5488 9.2085 25.0426; ... 220s 6.1605 13.1147 22.66; 2.3374 15.2654 24.1283; ... 220s 5.1873 12.4188 16.5927; 3.3579 14.3951 10.2129; ... 220s 6.3092 8.5986 9.8934; 3.2831 3.4945 10.0203]; 220s [p, atab, stats] = anova2 (data, 4, "off", "nested"); 220s assert (atab{2,2}, 745.360306290833, 1e-10); 220s assert (atab{3,2}, 278.01854140125, 1e-10); 220s assert (atab{4,2}, 180.180377467501, 1e-10); 220s assert (atab{5,2}, 1203.55922515958, 1e-10); 220s assert (atab{2,4}, 372.680153145417, 1e-10); 220s assert (atab{3,4}, 92.67284713375, 1e-10); 220s assert (atab{4,4}, 10.0100209704167, 1e-10); 220s assert (atab{2,5}, 4.02146005730833, 1e-10); 220s assert (atab{3,5}, 9.25800729165627, 1e-10); 220s assert (atab{2,6}, 0.141597630656771, 1e-10); 220s assert (atab{3,6}, 0.000636643812875719, 1e-10); 220s 3 tests, 3 passed, 0 known failure, 0 skipped 220s [inst/monotone_smooth.m] 220s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/monotone_smooth.m 220s ***** error ... 220s monotone_smooth (1) 220s ***** error ... 220s monotone_smooth ("char", 1) 220s ***** error ... 220s monotone_smooth ({1,2,3}, 1) 220s ***** error ... 220s monotone_smooth (ones(20,3), 1) 220s ***** error ... 220s monotone_smooth (1, "char") 220s ***** error ... 220s monotone_smooth (1, {1,2,3}) 220s ***** error ... 220s monotone_smooth (1, ones(20,3)) 220s ***** error monotone_smooth (ones (10,1), ones(10,1), [1, 2]) 220s ***** error monotone_smooth (ones (10,1), ones(10,1), {2}) 220s ***** error monotone_smooth (ones (10,1), ones(10,1), "char") 220s 10 tests, 10 passed, 0 known failure, 0 skipped 220s [inst/kmeans.m] 220s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/kmeans.m 220s ***** demo 220s ## Generate a two-cluster problem 220s randn ("seed", 31) # for reproducibility 220s C1 = randn (100, 2) + 1; 220s randn ("seed", 32) # for reproducibility 220s C2 = randn (100, 2) - 1; 220s data = [C1; C2]; 220s 220s ## Perform clustering 220s rand ("seed", 1) # for reproducibility 220s [idx, centers] = kmeans (data, 2); 220s 220s ## Plot the result 220s figure; 220s plot (data (idx==1, 1), data (idx==1, 2), "ro"); 220s hold on; 220s plot (data (idx==2, 1), data (idx==2, 2), "bs"); 220s plot (centers (:, 1), centers (:, 2), "kv", "markersize", 10); 220s hold off; 220s ***** demo 220s ## Cluster data using k-means clustering, then plot the cluster regions 220s ## Load Fisher's iris data set and use the petal lengths and widths as 220s ## predictors 220s 220s load fisheriris 220s X = meas(:,3:4); 220s 220s figure; 220s plot (X(:,1), X(:,2), "k*", "MarkerSize", 5); 220s title ("Fisher's Iris Data"); 220s xlabel ("Petal Lengths (cm)"); 220s ylabel ("Petal Widths (cm)"); 220s 220s ## Cluster the data. Specify k = 3 clusters 220s rand ("seed", 1) # for reproducibility 220s [idx, C] = kmeans (X, 3); 220s x1 = min (X(:,1)):0.01:max (X(:,1)); 220s x2 = min (X(:,2)):0.01:max (X(:,2)); 220s [x1G, x2G] = meshgrid (x1, x2); 220s XGrid = [x1G(:), x2G(:)]; 220s 220s idx2Region = kmeans (XGrid, 3, "MaxIter", 1, "Start", C); 220s figure; 220s gscatter (XGrid(:,1), XGrid(:,2), idx2Region, ... 220s [0, 0.75, 0.75; 0.75, 0, 0.75; 0.75, 0.75, 0], ".."); 220s hold on; 220s plot (X(:,1), X(:,2), "k*", "MarkerSize", 5); 220s title ("Fisher's Iris Data"); 220s xlabel ("Petal Lengths (cm)"); 220s ylabel ("Petal Widths (cm)"); 220s legend ("Region 1", "Region 2", "Region 3", "Data", "Location", "SouthEast"); 220s hold off 220s ***** demo 220s ## Partition Data into Two Clusters 220s 220s randn ("seed", 1) # for reproducibility 220s r1 = randn (100, 2) * 0.75 + ones (100, 2); 220s randn ("seed", 2) # for reproducibility 220s r2 = randn (100, 2) * 0.5 - ones (100, 2); 220s X = [r1; r2]; 220s 220s figure; 220s plot (X(:,1), X(:,2), "."); 220s title ("Randomly Generated Data"); 220s rand ("seed", 1) # for reproducibility 220s [idx, C] = kmeans (X, 2, "Distance", "cityblock", ... 220s "Replicates", 5, "Display", "final"); 220s figure; 220s plot (X(idx==1,1), X(idx==1,2), "r.", "MarkerSize", 12); 220s hold on 220s plot(X(idx==2,1), X(idx==2,2), "b.", "MarkerSize", 12); 220s plot (C(:,1), C(:,2), "kx", "MarkerSize", 15, "LineWidth", 3); 220s legend ("Cluster 1", "Cluster 2", "Centroids", "Location", "NorthWest"); 220s title ("Cluster Assignments and Centroids"); 220s hold off 220s ***** demo 220s ## Assign New Data to Existing Clusters 220s 220s ## Generate a training data set using three distributions 220s randn ("seed", 5) # for reproducibility 220s r1 = randn (100, 2) * 0.75 + ones (100, 2); 220s randn ("seed", 7) # for reproducibility 220s r2 = randn (100, 2) * 0.5 - ones (100, 2); 220s randn ("seed", 9) # for reproducibility 220s r3 = randn (100, 2) * 0.75; 220s X = [r1; r2; r3]; 220s 220s ## Partition the training data into three clusters by using kmeans 220s 220s rand ("seed", 1) # for reproducibility 220s [idx, C] = kmeans (X, 3); 220s 220s ## Plot the clusters and the cluster centroids 220s 220s figure 220s gscatter (X(:,1), X(:,2), idx, "bgm", "***"); 220s hold on 220s plot (C(:,1), C(:,2), "kx"); 220s legend ("Cluster 1", "Cluster 2", "Cluster 3", "Cluster Centroid") 220s 220s ## Generate a test data set 220s randn ("seed", 25) # for reproducibility 220s r1 = randn (100, 2) * 0.75 + ones (100, 2); 220s randn ("seed", 27) # for reproducibility 220s r2 = randn (100, 2) * 0.5 - ones (100, 2); 220s randn ("seed", 29) # for reproducibility 220s r3 = randn (100, 2) * 0.75; 220s Xtest = [r1; r2; r3]; 220s 220s ## Classify the test data set using the existing clusters 220s ## Find the nearest centroid from each test data point by using pdist2 220s 220s D = pdist2 (C, Xtest, "euclidean"); 220s [group, ~] = find (D == min (D)); 220s 220s ## Plot the test data and label the test data using idx_test with gscatter 220s 220s gscatter (Xtest(:,1), Xtest(:,2), group, "bgm", "ooo"); 220s legend ("Cluster 1", "Cluster 2", "Cluster 3", "Cluster Centroid", ... 220s "Data classified to Cluster 1", "Data classified to Cluster 2", ... 220s "Data classified to Cluster 3", "Location", "NorthWest"); 220s title ("Assign New Data to Existing Clusters"); 220s ***** test 220s samples = 4; 220s dims = 3; 220s k = 2; 220s [cls, c, d, z] = kmeans (rand (samples,dims), k, "start", rand (k,dims, 5), 220s "emptyAction", "singleton"); 220s assert (size (cls), [samples, 1]); 220s assert (size (c), [k, dims]); 220s assert (size (d), [k, 1]); 220s assert (size (z), [samples, k]); 220s ***** test 220s samples = 4; 220s dims = 3; 220s k = 2; 220s [cls, c, d, z] = kmeans (rand (samples,dims), [], "start", rand (k,dims, 5), 220s "emptyAction", "singleton"); 220s assert (size (cls), [samples, 1]); 220s assert (size (c), [k, dims]); 220s assert (size (d), [k, 1]); 220s assert (size (z), [samples, k]); 220s ***** test 220s [cls, c] = kmeans ([1 0; 2 0], 2, "start", [8,0;0,8], "emptyaction", "drop"); 220s assert (cls, [1; 1]); 220s assert (c, [1.5, 0; NA, NA]); 220s ***** test 220s kmeans (rand (4,3), 2, "start", rand (2,3, 5), "replicates", 5, 220s "emptyAction", "singleton"); 220s ***** test 220s kmeans (rand (3,4), 2, "start", "sample", "emptyAction", "singleton"); 220s ***** test 220s kmeans (rand (3,4), 2, "start", "plus", "emptyAction", "singleton"); 220s ***** test 220s kmeans (rand (3,4), 2, "start", "cluster", "emptyAction", "singleton"); 220s ***** test 220s kmeans (rand (3,4), 2, "start", "uniform", "emptyAction", "singleton"); 220s ***** test 220s kmeans (rand (4,3), 2, "distance", "sqeuclidean", "emptyAction", "singleton"); 220s ***** test 220s kmeans (rand (4,3), 2, "distance", "cityblock", "emptyAction", "singleton"); 220s ***** test 220s kmeans (rand (4,3), 2, "distance", "cosine", "emptyAction", "singleton"); 220s ***** test 220s kmeans (rand (4,3), 2, "distance", "correlation", "emptyAction", "singleton"); 220s ***** test 220s kmeans (rand (4,3), 2, "distance", "hamming", "emptyAction", "singleton"); 220s ***** test 220s kmeans ([1 0; 1.1 0], 2, "start", eye(2), "emptyaction", "singleton"); 220s ***** error kmeans (rand (3,2), 4); 220s ***** error kmeans ([1 0; 1.1 0], 2, "start", eye(2), "emptyaction", "panic"); 220s ***** error kmeans (rand (4,3), 2, "start", rand (2,3, 5), "replicates", 1); 220s ***** error kmeans (rand (4,3), 2, "start", rand (2,2)); 220s ***** error kmeans (rand (4,3), 2, "distance", "manhattan"); 220s ***** error kmeans (rand (3,4), 2, "start", "normal"); 220s ***** error kmeans (rand (4,3), 2, "replicates", i); 220s ***** error kmeans (rand (4,3), 2, "replicates", -1); 220s ***** error kmeans (rand (4,3), 2, "replicates", []); 220s ***** error kmeans (rand (4,3), 2, "replicates", [1 2]); 220s ***** error kmeans (rand (4,3), 2, "replicates", "one"); 220s ***** error kmeans (rand (4,3), 2, "MAXITER", i); 220s ***** error kmeans (rand (4,3), 2, "MaxIter", -1); 220s ***** error kmeans (rand (4,3), 2, "maxiter", []); 220s ***** error kmeans (rand (4,3), 2, "maxiter", [1 2]); 220s ***** error kmeans (rand (4,3), 2, "maxiter", "one"); 220s ***** error kmeans ([1 0; 1.1 0], 2, "start", eye(2), "emptyaction", "error"); 220s 31 tests, 31 passed, 0 known failure, 0 skipped 220s [inst/slicesample.m] 220s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/slicesample.m 220s ***** demo 220s ## Define function to sample 220s d = 2; 220s mu = [-1; 2]; 220s rand ("seed", 5) # for reproducibility 220s Sigma = rand (d); 220s Sigma = (Sigma + Sigma'); 220s Sigma += eye (d)*abs (eigs (Sigma, 1, "sa")) * 1.1; 220s pdf = @(x)(2*pi)^(-d/2)*det(Sigma)^-.5*exp(-.5*sum((x.'-mu).*(Sigma\(x.'-mu)),1)); 220s 220s ## Inputs 220s start = ones (1,2); 220s nsamples = 500; 220s K = 500; 220s m = 10; 220s rande ("seed", 4); rand ("seed", 5) # for reproducibility 220s [smpl, accept] = slicesample (start, nsamples, "pdf", pdf, "burnin", K, "thin", m, "width", [20, 30]); 220s figure; 220s hold on; 220s plot (smpl(:,1), smpl(:,2), 'x'); 220s [x, y] = meshgrid (linspace (-6,4), linspace(-3,7)); 220s z = reshape (pdf ([x(:), y(:)]), size(x)); 220s mesh (x, y, z, "facecolor", "None"); 220s 220s ## Using sample points to find the volume of half a sphere with radius of .5 220s f = @(x) ((.25-(x(:,1)+1).^2-(x(:,2)-2).^2).^.5.*(((x(:,1)+1).^2+(x(:,2)-2).^2)<.25)).'; 220s int = mean (f (smpl) ./ pdf (smpl)); 220s errest = std (f (smpl) ./ pdf (smpl)) / nsamples^.5; 220s trueerr = abs (2/3*pi*.25^(3/2)-int); 220s fprintf ("Monte Carlo integral estimate int f(x) dx = %f\n", int); 220s fprintf ("Monte Carlo integral error estimate %f\n", errest); 220s fprintf ("The actual error %f\n", trueerr); 220s mesh (x,y,reshape (f([x(:), y(:)]), size(x)), "facecolor", "None"); 220s ***** demo 220s ## Integrate truncated normal distribution to find normilization constant 220s pdf = @(x) exp (-.5*x.^2)/(pi^.5*2^.5); 220s nsamples = 1e3; 220s rande ("seed", 4); rand ("seed", 5) # for reproducibility 220s [smpl, accept] = slicesample (1, nsamples, "pdf", pdf, "thin", 4); 220s f = @(x) exp (-.5 * x .^ 2) .* (x >= -2 & x <= 2); 220s x = linspace (-3, 3, 1000); 220s area (x, f(x)); 220s xlabel ("x"); 220s ylabel ("f(x)"); 220s int = mean (f (smpl) ./ pdf (smpl)); 220s errest = std (f (smpl) ./ pdf (smpl)) / nsamples ^ 0.5; 220s trueerr = abs (erf (2 ^ 0.5) * 2 ^ 0.5 * pi ^ 0.5 - int); 220s fprintf("Monte Carlo integral estimate int f(x) dx = %f\n", int); 220s fprintf("Monte Carlo integral error estimate %f\n", errest); 220s fprintf("The actual error %f\n", trueerr); 220s ***** test 220s start = 0.5; 220s nsamples = 1e3; 220s pdf = @(x) exp (-.5*(x-1).^2)/(2*pi)^.5; 220s [smpl, accept] = slicesample (start, nsamples, "pdf", pdf, "thin", 2, "burnin", 0, "width", 5); 220s assert (mean (smpl, 1), 1, .15); 220s assert (var (smpl, 1), 1, .25); 222s ***** error slicesample (); 222s ***** error slicesample (1); 222s ***** error slicesample (1, 1); 222s 4 tests, 4 passed, 0 known failure, 0 skipped 222s [inst/einstein.m] 222s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/einstein.m 222s ***** demo 222s einstein (0.4, 0.6) 222s ***** demo 222s einstein (0.2, 0.5) 222s ***** demo 222s einstein (0.6, 0.1) 222s ***** test 222s hf = figure ("visible", "off"); 222s unwind_protect 222s tiles = einstein (0.4, 0.6); 222s assert (isstruct (tiles), true); 222s unwind_protect_cleanup 222s close (hf); 222s end_unwind_protect 222s ***** error einstein 222s ***** error einstein (0.5) 222s ***** error einstein (0, 0.9) 222s ***** error einstein (0.4, 1) 222s ***** error einstein (-0.4, 1) 222s 6 tests, 6 passed, 0 known failure, 0 skipped 222s [inst/ridge.m] 222s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/ridge.m 222s ***** demo 222s ## Perform ridge regression for a range of ridge parameters and observe 222s ## how the coefficient estimates change based on the acetylene dataset. 222s 222s load acetylene 222s 222s X = [x1, x2, x3]; 222s 222s x1x2 = x1 .* x2; 222s x1x3 = x1 .* x3; 222s x2x3 = x2 .* x3; 222s 222s D = [x1, x2, x3, x1x2, x1x3, x2x3]; 222s 222s k = 0:1e-5:5e-3; 222s 222s b = ridge (y, D, k); 222s 222s figure 222s plot (k, b, "LineWidth", 2) 222s ylim ([-100, 100]) 222s grid on 222s xlabel ("Ridge Parameter") 222s ylabel ("Standardized Coefficient") 222s title ("Ridge Trace") 222s legend ("x1", "x2", "x3", "x1x2", "x1x3", "x2x3") 222s 222s ***** demo 222s 222s load carbig 222s X = [Acceleration Weight Displacement Horsepower]; 222s y = MPG; 222s 222s n = length(y); 222s 222s rand("seed",1); % For reproducibility 222s 222s c = cvpartition(n,'HoldOut',0.3); 222s idxTrain = training(c,1); 222s idxTest = ~idxTrain; 222s 222s idxTrain = training(c,1); 222s idxTest = ~idxTrain; 222s 222s k = 5; 222s b = ridge(y(idxTrain),X(idxTrain,:),k,0); 222s 222s % Predict MPG values for the test data using the model. 222s yhat = b(1) + X(idxTest,:)*b(2:end); 222s scatter(y(idxTest),yhat) 222s 222s hold on 222s plot(y(idxTest),y(idxTest),"r") 222s xlabel('Actual MPG') 222s ylabel('Predicted MPG') 222s hold off 222s 222s ***** test 222s b = ridge ([1 2 3 4]', [1 2 3 4; 2 3 4 5]', 1); 222s assert (b, [0.5533; 0.5533], 1e-4); 222s ***** test 222s b = ridge ([1 2 3 4]', [1 2 3 4; 2 3 4 5]', 2); 222s assert (b, [0.4841; 0.4841], 1e-4); 222s ***** test 222s load acetylene 222s x = [x1, x2, x3]; 222s b = ridge (y, x, 0); 222s assert (b,[10.2273;1.97128;-0.601818],1e-4); 222s ***** test 222s load acetylene 222s x = [x1, x2, x3]; 222s b = ridge (y, x, 0.0005); 222s assert (b,[10.2233;1.9712;-0.6056],1e-4); 222s ***** test 222s load acetylene 222s x = [x1, x2, x3]; 222s b = ridge (y, x, 0.001); 222s assert (b,[10.2194;1.9711;-0.6094],1e-4); 222s ***** test 222s load acetylene 222s x = [x1, x2, x3]; 222s b = ridge (y, x, 0.002); 222s assert (b,[10.2116;1.9709;-0.6169],1e-4); 222s ***** test 222s load acetylene 222s x = [x1, x2, x3]; 222s b = ridge (y, x, 0.005); 222s assert (b,[10.1882;1.9704;-0.6393],1e-4); 222s ***** test 222s load acetylene 222s x = [x1, x2, x3]; 222s b = ridge (y, x, 0.01); 222s assert (b,[10.1497;1.9695;-0.6761],1e-4); 222s ***** error ridge (1) 222s ***** error ridge (1, 2) 222s ***** error ridge (ones (3), ones (3), 2) 222s ***** error ridge ([1, 2], ones (2), 2) 222s ***** error ridge ([], ones (3), 2) 222s ***** error ridge (ones (5,1), [], 2) 222s ***** error ... 222s ridge ([1; 2; 3; 4; 5], ones (3), 3) 222s ***** error ... 222s ridge ([1; 2; 3], ones (3), 3, 2) 222s ***** error ... 222s ridge ([1; 2; 3], ones (3), 3, "some") 222s 17 tests, 17 passed, 0 known failure, 0 skipped 222s [inst/cl_multinom.m] 222s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/cl_multinom.m 222s ***** demo 222s CL = cl_multinom ([27; 43; 19; 11], 10000, 0.05) 222s ***** error cl_multinom (); 223s ***** error cl_multinom (1, 2, 3, 4, 5); 223s ***** error ... 223s cl_multinom (1, 2, 3, 4); 223s ***** error ... 223s cl_multinom (1, 2, 3, "some string"); 223s 4 tests, 4 passed, 0 known failure, 0 skipped 223s [inst/linkage.m] 223s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/linkage.m 223s ***** shared x, t 223s x = reshape (mod (magic (6),5), [], 3); 223s t = 1e-6; 223s ***** assert (cond (linkage (pdist (x))), 34.119045, t); 223s ***** assert (cond (linkage (pdist (x), "complete")), 21.793345, t); 223s ***** assert (cond (linkage (pdist (x), "average")), 27.045012, t); 223s ***** assert (cond (linkage (pdist (x), "weighted")), 27.412889, t); 223s lastwarn(); # Clear last warning before the test 223s ***** warning linkage (pdist (x), "centroid"); 223s ***** test 223s warning off Octave:clustering 223s assert (cond (linkage (pdist (x), "centroid")), 27.457477, t); 223s warning on Octave:clustering 223s ***** warning linkage (pdist (x), "median"); 223s ***** test 223s warning off Octave:clustering 223s assert (cond (linkage (pdist (x), "median")), 27.683325, t); 223s warning on Octave:clustering 223s ***** assert (cond (linkage (pdist (x), "ward")), 17.195198, t); 223s ***** assert (cond (linkage (x, "ward", "euclidean")), 17.195198, t); 223s ***** assert (cond (linkage (x, "ward", {"euclidean"})), 17.195198, t); 223s ***** assert (cond (linkage (x, "ward", {"minkowski", 2})), 17.195198, t); 223s 12 tests, 12 passed, 0 known failure, 0 skipped 223s [inst/fishertest.m] 223s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/fishertest.m 223s ***** demo 223s ## A Fisher's exact test example 223s 223s x = [3, 1; 1, 3] 223s [h, p, stats] = fishertest(x) 223s ***** assert (fishertest ([3, 4; 5, 7]), false); 223s ***** assert (isa (fishertest ([3, 4; 5, 7]), "logical"), true); 223s ***** test 223s [h, pval, stats] = fishertest ([3, 4; 5, 7]); 223s assert (pval, 1, 1e-14); 223s assert (stats.OddsRatio, 1.05); 223s CI = [0.159222057151289, 6.92429189601808]; 223s assert (stats.ConfidenceInterval, CI, 1e-14) 223s ***** test 223s [h, pval, stats] = fishertest ([3, 4; 5, 0]); 223s assert (pval, 0.08080808080808080, 1e-14); 223s assert (stats.OddsRatio, 0); 223s assert (stats.ConfidenceInterval, [-Inf, Inf]) 223s ***** error fishertest (); 223s ***** error fishertest (1, 2, 3, 4, 5, 6); 223s ***** error ... 223s fishertest (ones (2, 2, 2)); 223s ***** error ... 223s fishertest ([1, 2; -3, 4]); 223s ***** error ... 223s fishertest ([1, 2; 3, 4+i]); 223s ***** error ... 223s fishertest ([1, 2; 3, 4.2]); 223s ***** error ... 223s fishertest ([NaN, 2; 3, 4]); 223s ***** error ... 223s fishertest ([1, Inf; 3, 4]); 223s ***** error ... 223s fishertest (ones (2) * 1e8); 223s ***** error ... 223s fishertest ([1, 2; 3, 4], "alpha", 0); 223s ***** error ... 223s fishertest ([1, 2; 3, 4], "alpha", 1.2); 223s ***** error ... 223s fishertest ([1, 2; 3, 4], "alpha", "val"); 223s ***** error ... 223s fishertest ([1, 2; 3, 4], "tail", "val"); 223s ***** error ... 223s fishertest ([1, 2; 3, 4], "alpha", 0.01, "tail", "val"); 223s ***** error ... 223s fishertest ([1, 2; 3, 4], "alpha", 0.01, "badoption", 3); 223s 19 tests, 19 passed, 0 known failure, 0 skipped 223s [inst/ztest2.m] 223s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/ztest2.m 223s ***** error ztest2 (); 223s ***** error ztest2 (1); 223s ***** error ztest2 (1, 2); 223s ***** error ztest2 (1, 2, 3); 223s ***** error ... 223s ztest2 (1, 2, 3, 4, "alpha") 223s ***** error ... 223s ztest2 (1, 2, 3, 4, "alpha", 0); 223s ***** error ... 223s ztest2 (1, 2, 3, 4, "alpha", 1.2); 223s ***** error ... 223s ztest2 (1, 2, 3, 4, "alpha", "val"); 223s ***** error ... 223s ztest2 (1, 2, 3, 4, "tail", "val"); 223s ***** error ... 223s ztest2 (1, 2, 3, 4, "alpha", 0.01, "tail", "val"); 223s ***** error ... 223s ztest2 (1, 2, 3, 4, "alpha", 0.01, "tail", "both", "badoption", 3); 223s 11 tests, 11 passed, 0 known failure, 0 skipped 223s [inst/chi2test.m] 224s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/chi2test.m 224s ***** error chi2test (); 224s ***** error chi2test ([1, 2, 3, 4, 5]); 224s ***** error chi2test ([1, 2; 2, 1+3i]); 224s ***** error chi2test ([NaN, 6; 34, 12]); 224s ***** error ... 224s p = chi2test (ones (3, 3), "mutual", []); 224s ***** error ... 224s p = chi2test (ones (3, 3, 3), "testtype", 2); 224s ***** error ... 224s p = chi2test (ones (3, 3, 3), "mutual"); 224s ***** error ... 224s p = chi2test (ones (3, 3, 3), "joint", ["a"]); 224s ***** error ... 224s p = chi2test (ones (3, 3, 3), "joint", [2, 3]); 224s ***** error ... 224s p = chi2test (ones (3, 3, 3, 4), "mutual", []) 224s ***** warning p = chi2test (ones (2)); 224s ***** warning p = chi2test (ones (3, 2)); 224s ***** warning p = chi2test (0.4 * ones (3)); 224s ***** test 224s x = [11, 3, 8; 2, 9, 14; 12, 13, 28]; 224s p = chi2test (x); 224s assert (p, 0.017787, 1e-6); 224s ***** test 224s x = [11, 3, 8; 2, 9, 14; 12, 13, 28]; 224s [p, chisq] = chi2test (x); 224s assert (chisq, 11.9421, 1e-4); 224s ***** test 224s x = [11, 3, 8; 2, 9, 14; 12, 13, 28]; 224s [p, chisq, df] = chi2test (x); 224s assert (df, 4); 224s ***** test 224s ***** shared x 224s x(:,:,1) = [59, 32; 9,16]; 224s x(:,:,2) = [55, 24;12,33]; 224s x(:,:,3) = [107,80;17,56];%! 224s ***** assert (chi2test (x), 2.282063427117009e-11, 1e-14); 224s ***** assert (chi2test (x, "mutual", []), 2.282063427117009e-11, 1e-14); 224s ***** assert (chi2test (x, "joint", 1), 1.164834895206468e-11, 1e-14); 224s ***** assert (chi2test (x, "joint", 2), 7.771350230001417e-11, 1e-14); 224s ***** assert (chi2test (x, "joint", 3), 0.07151361728026107, 1e-14); 224s ***** assert (chi2test (x, "marginal", 1), 0, 1e-14); 224s ***** assert (chi2test (x, "marginal", 2), 6.347555814301131e-11, 1e-14); 224s ***** assert (chi2test (x, "marginal", 3), 0, 1e-14); 224s ***** assert (chi2test (x, "conditional", 1), 0.2303114201312508, 1e-14); 224s ***** assert (chi2test (x, "conditional", 2), 0.0958810684407079, 1e-14); 224s ***** assert (chi2test (x, "conditional", 3), 2.648037344954446e-11, 1e-14); 224s ***** assert (chi2test (x, "homogeneous", []), 0.4485579470993741, 1e-14); 224s ***** test 224s [pval, chisq, df, E] = chi2test (x); 224s assert (chisq, 64.0982, 1e-4); 224s assert (df, 7); 224s assert (E(:,:,1), [42.903, 39.921; 17.185, 15.991], ones (2, 2) * 1e-3); 224s ***** test 224s [pval, chisq, df, E] = chi2test (x, "joint", 2); 224s assert (chisq, 56.0943, 1e-4); 224s assert (df, 5); 224s assert (E(:,:,2), [40.922, 23.310; 38.078, 21.690], ones (2, 2) * 1e-3); 224s ***** test 224s [pval, chisq, df, E] = chi2test (x, "marginal", 3); 224s assert (chisq, 146.6058, 1e-4); 224s assert (df, 9); 224s assert (E(:,1,1), [61.642; 57.358], ones (2, 1) * 1e-3); 224s ***** test 224s [pval, chisq, df, E] = chi2test (x, "conditional", 3); 224s assert (chisq, 52.2509, 1e-4); 224s assert (df, 3); 224s assert (E(:,:,1), [53.345, 37.655; 14.655, 10.345], ones (2, 2) * 1e-3); 224s ***** test 224s [pval, chisq, df, E] = chi2test (x, "homogeneous", []); 224s assert (chisq, 1.6034, 1e-4); 224s assert (df, 2); 224s assert (E(:,:,1), [60.827, 31.382; 7.173, 16.618], ones (2, 2) * 1e-3); 224s 34 tests, 34 passed, 0 known failure, 0 skipped 224s [inst/fitgmdist.m] 224s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/fitgmdist.m 224s ***** demo 224s ## Generate a two-cluster problem 224s C1 = randn (100, 2) + 2; 224s C2 = randn (100, 2) - 2; 224s data = [C1; C2]; 224s 224s ## Perform clustering 224s GMModel = fitgmdist (data, 2); 224s 224s ## Plot the result 224s figure 224s [heights, bins] = hist3([C1; C2]); 224s [xx, yy] = meshgrid(bins{1}, bins{2}); 224s bbins = [xx(:), yy(:)]; 224s contour (reshape (GMModel.pdf (bbins), size (heights))); 224s ***** demo 224s Angle_Theta = [ 30 + 10 * randn(1, 10), 60 + 10 * randn(1, 10) ]'; 224s nbOrientations = 2; 224s initial_orientations = [38.0; 18.0]; 224s initial_weights = ones (1, nbOrientations) / nbOrientations; 224s initial_Sigma = 10 * ones (1, 1, nbOrientations); 224s start = struct ("mu", initial_orientations, "Sigma", initial_Sigma, ... 224s "ComponentProportion", initial_weights); 224s GMModel_Theta = fitgmdist (Angle_Theta, nbOrientations, "Start", start , ... 224s "RegularizationValue", 0.0001) 224s ***** test 224s load fisheriris 224s classes = unique (species); 224s [~, score] = pca (meas, "NumComponents", 2); 224s options.MaxIter = 1000; 224s options.TolFun = 1e-6; 224s options.Display = "off"; 224s GMModel = fitgmdist (score, 2, "Options", options); 224s assert (isa (GMModel, "gmdistribution"), true); 224s assert (GMModel.mu, [1.3212, -0.0954; -2.6424, 0.1909], 1e-4); 224s 1 test, 1 passed, 0 known failure, 0 skipped 224s [inst/kstest.m] 224s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/kstest.m 224s ***** demo 224s ## Use the stock return data set to test the null hypothesis that the data 224s ## come from a standard normal distribution against the alternative 224s ## hypothesis that the population CDF of the data is larger that the 224s ## standard normal CDF. 224s 224s load stockreturns; 224s x = stocks(:,2); 224s [h, p, k, c] = kstest (x, "Tail", "larger") 224s 224s ## Compute the empirical CDF and plot against the standard normal CDF 224s [f, x_values] = ecdf (x); 224s h1 = plot (x_values, f); 224s hold on; 224s h2 = plot (x_values, normcdf (x_values), 'r--'); 224s set (h1, "LineWidth", 2); 224s set (h2, "LineWidth", 2); 224s legend ([h1, h2], "Empirical CDF", "Standard Normal CDF", ... 224s "Location", "southeast"); 224s title ("Empirical CDF of stock return data against standard normal CDF") 224s ***** error kstest () 224s ***** error kstest (ones (2, 4)) 224s ***** error kstest ([2, 3, 5, 3+3i]) 224s ***** error kstest ([2, 3, 4, 5, 6], "opt", 0.51) 224s ***** error ... 224s kstest ([2, 3, 4, 5, 6], "tail") 224s ***** error ... 224s kstest ([2,3,4,5,6],"alpha", [0.05, 0.05]) 224s ***** error ... 224s kstest ([2, 3, 4, 5, 6], "alpha", NaN) 224s ***** error ... 224s kstest ([2, 3, 4, 5, 6], "tail", 0) 224s ***** error ... 224s kstest ([2,3,4,5,6], "tail", "whatever") 224s ***** error ... 224s kstest ([1, 2, 3, 4, 5], "CDF", @(x) repmat (x, 2, 3)) 224s ***** error ... 224s kstest ([1, 2, 3, 4, 5], "CDF", "somedist") 224s ***** error ... 224s kstest ([1, 2, 3, 4, 5], "CDF", cvpartition (5)) 224s ***** error ... 224s kstest ([2, 3, 4, 5, 6], "alpha", 0.05, "CDF", [2, 3, 4; 1, 3, 4; 1, 2, 1]) 224s ***** error ... 224s kstest ([2, 3, 4, 5, 6], "alpha", 0.05, "CDF", nan (5, 2)) 224s ***** error ... 224s kstest ([2, 3, 4, 5, 6], "CDF", [2, 3; 1, 4; 3, 2]) 224s ***** error ... 224s kstest ([2, 3, 4, 5, 6], "CDF", [2, 3; 2, 4; 3, 5]) 224s ***** error ... 224s kstest ([2, 3, 4, 5, 6], "CDF", {1, 2, 3, 4, 5}) 224s ***** test 224s load examgrades 224s [h, p] = kstest (grades(:,1)); 224s assert (h, true); 224s assert (p, 7.58603305206105e-107, 1e-14); 224s ***** test 224s load examgrades 224s [h, p] = kstest (grades(:,1), "CDF", @(x) normcdf(x, 75, 10)); 224s assert (h, false); 224s assert (p, 0.5612, 1e-4); 224s ***** test 224s load examgrades 224s x = grades(:,1); 224s test_cdf = makedist ("tlocationscale", "mu", 75, "sigma", 10, "nu", 1); 224s [h, p] = kstest (x, "alpha", 0.01, "CDF", test_cdf); 224s assert (h, true); 224s assert (p, 0.0021, 1e-4); 224s ***** test 224s load stockreturns 224s x = stocks(:,3); 224s [h,p,k,c] = kstest (x, "Tail", "larger"); 224s assert (h, true); 224s assert (p, 5.085438806199252e-05, 1e-14); 224s assert (k, 0.2197, 1e-4); 224s assert (c, 0.1207, 1e-4); 224s 21 tests, 21 passed, 0 known failure, 0 skipped 224s [inst/chi2gof.m] 224s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/chi2gof.m 224s ***** demo 224s x = normrnd (50, 5, 100, 1); 224s [h, p, stats] = chi2gof (x) 224s [h, p, stats] = chi2gof (x, "cdf", @(x)normcdf (x, mean(x), std(x))) 224s [h, p, stats] = chi2gof (x, "cdf", {@normcdf, mean(x), std(x)}) 224s ***** demo 224s x = rand (100,1 ); 224s n = length (x); 224s binedges = linspace (0, 1, 11); 224s expectedCounts = n * diff (binedges); 224s [h, p, stats] = chi2gof (x, "binedges", binedges, "expected", expectedCounts) 224s ***** demo 224s bins = 0:5; 224s obsCounts = [6 16 10 12 4 2]; 224s n = sum(obsCounts); 224s lambdaHat = sum(bins.*obsCounts) / n; 224s expCounts = n * poisspdf(bins,lambdaHat); 224s [h, p, stats] = chi2gof (bins, "binctrs", bins, "frequency", obsCounts, ... 224s "expected", expCounts, "nparams",1) 224s ***** error chi2gof () 224s ***** error chi2gof ([2,3;3,4]) 224s ***** error chi2gof ([1,2,3,4], "nbins", 3, "ctrs", [2,3,4]) 224s ***** error chi2gof ([1,2,3,4], "frequency", [2,3,2]) 224s ***** error chi2gof ([1,2,3,4], "frequency", [2,3,2,-2]) 224s ***** error chi2gof ([1,2,3,4], "frequency", [2,3,2,2], "nparams", i) 224s ***** error chi2gof ([1,2,3,4], "frequency", [2,3,2,2], "alpha", 1.3) 224s ***** error chi2gof ([1,2,3,4], "expected", [-3,2,2]) 224s ***** error chi2gof ([1,2,3,4], "expected", [3,2,2], "nbins", 5) 224s ***** error chi2gof ([1,2,3,4], "cdf", @normcdff) 224s ***** test 224s x = [1 2 1 3 2 4 3 2 4 3 2 2]; 224s [h, p, stats] = chi2gof (x); 224s assert (h, 0); 224s assert (p, NaN); 224s assert (stats.chi2stat, 0.1205375022748029, 1e-14); 224s assert (stats.df, 0); 224s assert (stats.edges, [1, 2.5, 4], 1e-14); 224s assert (stats.O, [7, 5], 1e-14); 224s assert (stats.E, [6.399995519909668, 5.600004480090332], 1e-14); 224s 11 tests, 11 passed, 0 known failure, 0 skipped 224s [inst/fitlm.m] 224s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/fitlm.m 224s ***** demo 224s y = [ 8.706 10.362 11.552 6.941 10.983 10.092 6.421 14.943 15.931 ... 224s 22.968 18.590 16.567 15.944 21.637 14.492 17.965 18.851 22.891 ... 224s 22.028 16.884 17.252 18.325 25.435 19.141 21.238 22.196 18.038 ... 224s 22.628 31.163 26.053 24.419 32.145 28.966 30.207 29.142 33.212 ... 224s 25.694 ]'; 224s X = [1 1 1 1 1 1 1 1 2 2 2 2 2 3 3 3 3 3 3 3 3 4 4 4 4 4 4 4 5 5 5 5 5 5 5 5 5]'; 224s 224s [TAB,STATS] = fitlm (X,y,"linear","CategoricalVars",1,"display","on"); 224s ***** demo 224s popcorn = [5.5, 4.5, 3.5; 5.5, 4.5, 4.0; 6.0, 4.0, 3.0; ... 224s 6.5, 5.0, 4.0; 7.0, 5.5, 5.0; 7.0, 5.0, 4.5]; 224s brands = {'Gourmet', 'National', 'Generic'; ... 224s 'Gourmet', 'National', 'Generic'; ... 224s 'Gourmet', 'National', 'Generic'; ... 224s 'Gourmet', 'National', 'Generic'; ... 224s 'Gourmet', 'National', 'Generic'; ... 224s 'Gourmet', 'National', 'Generic'}; 224s popper = {'oil', 'oil', 'oil'; 'oil', 'oil', 'oil'; 'oil', 'oil', 'oil'; ... 224s 'air', 'air', 'air'; 'air', 'air', 'air'; 'air', 'air', 'air'}; 224s 224s [TAB, STATS] = fitlm ({brands(:),popper(:)},popcorn(:),"interactions",... 224s "CategoricalVars",[1,2],"display","on"); 224s ***** test 224s y = [ 8.706 10.362 11.552 6.941 10.983 10.092 6.421 14.943 15.931 ... 224s 22.968 18.590 16.567 15.944 21.637 14.492 17.965 18.851 22.891 ... 224s 22.028 16.884 17.252 18.325 25.435 19.141 21.238 22.196 18.038 ... 224s 22.628 31.163 26.053 24.419 32.145 28.966 30.207 29.142 33.212 ... 224s 25.694 ]'; 224s X = [1 1 1 1 1 1 1 1 2 2 2 2 2 3 3 3 3 3 3 3 3 4 4 4 4 4 4 4 5 5 5 5 5 5 5 5 5]'; 224s [TAB,STATS] = fitlm (X,y,"continuous",[],"display","off"); 224s [TAB,STATS] = fitlm (X,y,"CategoricalVars",1,"display","off"); 224s [TAB,STATS] = fitlm (X,y,"constant","categorical",1,"display","off"); 224s [TAB,STATS] = fitlm (X,y,"linear","categorical",1,"display","off"); 224s [TAB,STATS] = fitlm (X,y,[0,0;1,0],"categorical",1,"display","off"); 224s assert (TAB{2,2}, 10, 1e-04); 224s assert (TAB{3,2}, 7.99999999999999, 1e-09); 224s assert (TAB{4,2}, 8.99999999999999, 1e-09); 224s assert (TAB{5,2}, 11.0001428571429, 1e-09); 224s assert (TAB{6,2}, 19.0001111111111, 1e-09); 224s assert (TAB{2,3}, 1.01775379540949, 1e-09); 224s assert (TAB{3,3}, 1.64107868458008, 1e-09); 224s assert (TAB{4,3}, 1.43932122062479, 1e-09); 224s assert (TAB{5,3}, 1.48983900477565, 1e-09); 224s assert (TAB{6,3}, 1.3987687997822, 1e-09); 224s assert (TAB{2,6}, 9.82555903510687, 1e-09); 224s assert (TAB{3,6}, 4.87484242844031, 1e-09); 224s assert (TAB{4,6}, 6.25294748040552, 1e-09); 224s assert (TAB{5,6}, 7.38344399756088, 1e-09); 224s assert (TAB{6,6}, 13.5834536158296, 1e-09); 224s assert (TAB{3,7}, 2.85812420217862e-05, 1e-12); 224s assert (TAB{4,7}, 5.22936741204002e-07, 1e-06); 224s assert (TAB{5,7}, 2.12794763209106e-08, 1e-07); 224s assert (TAB{6,7}, 7.82091664406755e-15, 1e-08); 224s ***** test 224s popcorn = [5.5, 4.5, 3.5; 5.5, 4.5, 4.0; 6.0, 4.0, 3.0; ... 224s 6.5, 5.0, 4.0; 7.0, 5.5, 5.0; 7.0, 5.0, 4.5]; 224s brands = bsxfun (@times, ones(6,1), [1,2,3]); 224s popper = bsxfun (@times, [1;1;1;2;2;2], ones(1,3)); 224s 224s [TAB, STATS] = fitlm ({brands(:),popper(:)},popcorn(:),"interactions",... 224s "categoricalvars",[1,2],"display","off"); 224s assert (TAB{2,2}, 5.66666666666667, 1e-09); 224s assert (TAB{3,2}, -1.33333333333333, 1e-09); 224s assert (TAB{4,2}, -2.16666666666667, 1e-09); 224s assert (TAB{5,2}, 1.16666666666667, 1e-09); 224s assert (TAB{6,2}, -0.333333333333334, 1e-09); 224s assert (TAB{7,2}, -0.166666666666667, 1e-09); 224s assert (TAB{2,3}, 0.215165741455965, 1e-09); 224s assert (TAB{3,3}, 0.304290309725089, 1e-09); 224s assert (TAB{4,3}, 0.304290309725089, 1e-09); 224s assert (TAB{5,3}, 0.304290309725089, 1e-09); 224s assert (TAB{6,3}, 0.43033148291193, 1e-09); 224s assert (TAB{7,3}, 0.43033148291193, 1e-09); 224s assert (TAB{2,6}, 26.3362867542108, 1e-09); 224s assert (TAB{3,6}, -4.38178046004138, 1e-09); 224s assert (TAB{4,6}, -7.12039324756724, 1e-09); 224s assert (TAB{5,6}, 3.83405790253621, 1e-09); 224s assert (TAB{6,6}, -0.774596669241495, 1e-09); 224s assert (TAB{7,6}, -0.387298334620748, 1e-09); 224s assert (TAB{2,7}, 5.49841502258254e-12, 1e-09); 224s assert (TAB{3,7}, 0.000893505495903642, 1e-09); 224s assert (TAB{4,7}, 1.21291454302428e-05, 1e-09); 224s assert (TAB{5,7}, 0.00237798044119407, 1e-09); 224s assert (TAB{6,7}, 0.453570536021938, 1e-09); 224s assert (TAB{7,7}, 0.705316781644046, 1e-09); 224s ## Test with string ids for categorical variables 224s brands = {'Gourmet', 'National', 'Generic'; ... 224s 'Gourmet', 'National', 'Generic'; ... 224s 'Gourmet', 'National', 'Generic'; ... 224s 'Gourmet', 'National', 'Generic'; ... 224s 'Gourmet', 'National', 'Generic'; ... 224s 'Gourmet', 'National', 'Generic'}; 224s popper = {'oil', 'oil', 'oil'; 'oil', 'oil', 'oil'; 'oil', 'oil', 'oil'; ... 224s 'air', 'air', 'air'; 'air', 'air', 'air'; 'air', 'air', 'air'}; 224s [TAB, STATS] = fitlm ({brands(:),popper(:)},popcorn(:),"interactions",... 224s "categoricalvars",[1,2],"display","off"); 224s ***** test 224s load carsmall 224s X = [Weight,Horsepower,Acceleration]; 224s [TAB, STATS] = fitlm (X, MPG,"constant","display","off"); 224s [TAB, STATS] = fitlm (X, MPG,"linear","display","off"); 224s assert (TAB{2,2}, 47.9767628118615, 1e-09); 224s assert (TAB{3,2}, -0.00654155878851796, 1e-09); 224s assert (TAB{4,2}, -0.0429433065881864, 1e-09); 224s assert (TAB{5,2}, -0.0115826516894871, 1e-09); 224s assert (TAB{2,3}, 3.87851641748551, 1e-09); 224s assert (TAB{3,3}, 0.00112741016370336, 1e-09); 224s assert (TAB{4,3}, 0.0243130608813806, 1e-09); 224s assert (TAB{5,3}, 0.193325043113178, 1e-09); 224s assert (TAB{2,6}, 12.369874881944, 1e-09); 224s assert (TAB{3,6}, -5.80228828790225, 1e-09); 224s assert (TAB{4,6}, -1.76626492228599, 1e-09); 224s assert (TAB{5,6}, -0.0599128364487485, 1e-09); 224s assert (TAB{2,7}, 4.89570341688996e-21, 1e-09); 224s assert (TAB{3,7}, 9.87424814144e-08, 1e-09); 224s assert (TAB{4,7}, 0.0807803098213114, 1e-09); 224s assert (TAB{5,7}, 0.952359384151778, 1e-09); 225s 3 tests, 3 passed, 0 known failure, 0 skipped 225s [inst/kruskalwallis.m] 225s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/kruskalwallis.m 225s ***** demo 225s x = meshgrid (1:6); 225s x = x + normrnd (0, 1, 6, 6); 225s kruskalwallis (x, [], 'off'); 225s ***** demo 225s x = meshgrid (1:6); 225s x = x + normrnd (0, 1, 6, 6); 225s [p, atab] = kruskalwallis(x); 225s ***** demo 225s x = ones (30, 4) .* [-2, 0, 1, 5]; 225s x = x + normrnd (0, 2, 30, 4); 225s group = {"A", "B", "C", "D"}; 225s kruskalwallis (x, group); 225s ***** test 225s data = [1.006, 0.996, 0.998, 1.000, 0.992, 0.993, 1.002, 0.999, 0.994, 1.000, ... 225s 0.998, 1.006, 1.000, 1.002, 0.997, 0.998, 0.996, 1.000, 1.006, 0.988, ... 225s 0.991, 0.987, 0.997, 0.999, 0.995, 0.994, 1.000, 0.999, 0.996, 0.996, ... 225s 1.005, 1.002, 0.994, 1.000, 0.995, 0.994, 0.998, 0.996, 1.002, 0.996, ... 225s 0.998, 0.998, 0.982, 0.990, 1.002, 0.984, 0.996, 0.993, 0.980, 0.996, ... 225s 1.009, 1.013, 1.009, 0.997, 0.988, 1.002, 0.995, 0.998, 0.981, 0.996, ... 225s 0.990, 1.004, 0.996, 1.001, 0.998, 1.000, 1.018, 1.010, 0.996, 1.002, ... 225s 0.998, 1.000, 1.006, 1.000, 1.002, 0.996, 0.998, 0.996, 1.002, 1.006, ... 225s 1.002, 0.998, 0.996, 0.995, 0.996, 1.004, 1.004, 0.998, 0.999, 0.991, ... 225s 0.991, 0.995, 0.984, 0.994, 0.997, 0.997, 0.991, 0.998, 1.004, 0.997]; 225s group = [1:10] .* ones (10,10); 225s group = group(:); 225s [p, tbl] = kruskalwallis (data, group, "off"); 225s assert (p, 0.048229, 1e-6); 225s assert (tbl{2,5}, 17.03124, 1e-5); 225s assert (tbl{2,3}, 9, 0); 225s assert (tbl{4,2}, 82655.5, 1e-16); 225s data = reshape (data, 10, 10); 225s [p, tbl, stats] = kruskalwallis (data, [], "off"); 225s assert (p, 0.048229, 1e-6); 225s assert (tbl{2,5}, 17.03124, 1e-5); 225s assert (tbl{2,3}, 9, 0); 225s assert (tbl{4,2}, 82655.5, 1e-16); 225s means = [51.85, 60.45, 37.6, 51.1, 29.5, 54.25, 64.55, 66.7, 53.65, 35.35]; 225s N = 10 * ones (1, 10); 225s assert (stats.meanranks, means, 1e-6); 225s assert (length (stats.gnames), 10, 0); 225s assert (stats.n, N, 0); 225s 1 test, 1 passed, 0 known failure, 0 skipped 225s [inst/cophenet.m] 225s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/cophenet.m 225s ***** demo 225s randn ("seed", 5) # for reproducibility 225s X = randn (10,2); 225s y = pdist (X); 225s Z = linkage (y, "average"); 225s cophenet (Z, y) 225s ***** error cophenet () 225s ***** error cophenet (1) 225s ***** error ... 225s cophenet (ones (2,2), 1) 225s ***** error ... 225s cophenet ([1 2 1], "a") 225s ***** error ... 225s cophenet ([1 2 1], [1 2]) 225s 5 tests, 5 passed, 0 known failure, 0 skipped 225s [inst/nansum.m] 225s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/nansum.m 225s ***** assert (nansum ([2 4 NaN 7]), 13) 225s ***** assert (nansum ([2 4 NaN Inf]), Inf) 225s ***** assert (nansum ([1 NaN 3; NaN 5 6; 7 8 NaN]), [8 13 9]) 225s ***** assert (nansum ([1 NaN 3; NaN 5 6; 7 8 NaN], 2), [4; 11; 15]) 225s ***** assert (nansum (single ([1 NaN 3; NaN 5 6; 7 8 NaN])), single ([8 13 9])) 225s ***** assert (nansum (single ([1 NaN 3; NaN 5 6; 7 8 NaN]), "double"), [8 13 9]) 225s ***** assert (nansum (uint8 ([2 4 1 7])), 14) 225s ***** assert (nansum (uint8 ([2 4 1 7]), "native"), uint8 (14)) 225s ***** assert (nansum (uint8 ([2 4 1 7])), 14) 225s 9 tests, 9 passed, 0 known failure, 0 skipped 225s [inst/cdfcalc.m] 225s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/cdfcalc.m 225s ***** test 225s x = [2, 4, 3, 2, 4, 3, 2, 5, 6, 4]; 225s [yCDF, xCDF, n, emsg, eid] = cdfcalc (x); 225s assert (yCDF, [0, 0.3, 0.5, 0.8, 0.9, 1]'); 225s assert (xCDF, [2, 3, 4, 5, 6]'); 225s assert (n, 10); 225s ***** shared x 225s x = [2, 4, 3, 2, 4, 3, 2, 5, 6, 4]; 225s ***** error yCDF = cdfcalc (x); 225s ***** error [yCDF, xCDF] = cdfcalc (); 225s ***** error [yCDF, xCDF] = cdfcalc (x, x); 225s ***** warning [yCDF, xCDF] = cdfcalc (ones(10,2)); 225s 5 tests, 5 passed, 0 known failure, 0 skipped 225s [inst/dist_fit/invgfit.m] 225s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fit/invgfit.m 225s ***** demo 225s ## Sample 3 populations from different inverse Gaussian distibutions 225s rand ("seed", 5); randn ("seed", 5); # for reproducibility 225s r1 = invgrnd (1, 0.2, 2000, 1); 225s rand ("seed", 2); randn ("seed", 2); # for reproducibility 225s r2 = invgrnd (1, 3, 2000, 1); 225s rand ("seed", 7); randn ("seed", 7); # for reproducibility 225s r3 = invgrnd (3, 1, 2000, 1); 225s r = [r1, r2, r3]; 225s 225s ## Plot them normalized and fix their colors 225s hist (r, [0.1:0.1:3.2], 9); 225s h = findobj (gca, "Type", "patch"); 225s set (h(1), "facecolor", "c"); 225s set (h(2), "facecolor", "g"); 225s set (h(3), "facecolor", "r"); 225s ylim ([0, 3]); 225s xlim ([0, 3]); 225s hold on 225s 225s ## Estimate their MU and LAMBDA parameters 225s mu_lambdaA = invgfit (r(:,1)); 225s mu_lambdaB = invgfit (r(:,2)); 225s mu_lambdaC = invgfit (r(:,3)); 225s 225s ## Plot their estimated PDFs 225s x = [0:0.1:3]; 225s y = invgpdf (x, mu_lambdaA(1), mu_lambdaA(2)); 225s plot (x, y, "-pr"); 225s y = invgpdf (x, mu_lambdaB(1), mu_lambdaB(2)); 225s plot (x, y, "-sg"); 225s y = invgpdf (x, mu_lambdaC(1), mu_lambdaC(2)); 225s plot (x, y, "-^c"); 225s hold off 225s legend ({"Normalized HIST of sample 1 with μ=1 and λ=0.5", ... 225s "Normalized HIST of sample 2 with μ=2 and λ=0.3", ... 225s "Normalized HIST of sample 3 with μ=4 and λ=0.5", ... 225s sprintf("PDF for sample 1 with estimated μ=%0.2f and λ=%0.2f", ... 225s mu_lambdaA(1), mu_lambdaA(2)), ... 225s sprintf("PDF for sample 2 with estimated μ=%0.2f and λ=%0.2f", ... 225s mu_lambdaB(1), mu_lambdaB(2)), ... 225s sprintf("PDF for sample 3 with estimated μ=%0.2f and λ=%0.2f", ... 225s mu_lambdaC(1), mu_lambdaC(2))}) 225s title ("Three population samples from different inverse Gaussian distibutions") 225s hold off 225s ***** test 225s paramhat = invgfit ([1:50]); 225s paramhat_out = [25.5, 19.6973]; 225s assert (paramhat, paramhat_out, 1e-4); 225s ***** test 225s paramhat = invgfit ([1:5]); 225s paramhat_out = [3, 8.1081]; 225s assert (paramhat, paramhat_out, 1e-4); 225s ***** error invgfit (ones (2,5)); 225s ***** error invgfit ([-1 2 3 4]); 225s ***** error invgfit ([1, 2, 3, 4, 5], 1.2); 225s ***** error invgfit ([1, 2, 3, 4, 5], 0); 225s ***** error invgfit ([1, 2, 3, 4, 5], "alpha"); 225s ***** error ... 225s invgfit ([1, 2, 3, 4, 5], 0.05, [1 1 0]); 225s ***** error ... 225s invgfit ([1, 2, 3, 4, 5], [], [1 1 0 1 1]'); 225s ***** error ... 225s invgfit ([1, 2, 3, 4, 5], 0.05, zeros (1,5), [1 1 0]); 225s ***** error ... 225s invgfit ([1, 2, 3, 4, 5], [], [], [1 1 0 1 1]'); 225s ***** error ... 225s invgfit ([1, 2, 3, 4, 5], 0.05, [], [], 2); 225s 12 tests, 12 passed, 0 known failure, 0 skipped 225s [inst/dist_fit/poissfit.m] 225s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fit/poissfit.m 225s ***** demo 225s ## Sample 3 populations from 3 different Poisson distibutions 225s randp ("seed", 2); # for reproducibility 225s r1 = poissrnd (1, 1000, 1); 225s randp ("seed", 2); # for reproducibility 225s r2 = poissrnd (4, 1000, 1); 225s randp ("seed", 3); # for reproducibility 225s r3 = poissrnd (10, 1000, 1); 225s r = [r1, r2, r3]; 225s 225s ## Plot them normalized and fix their colors 225s hist (r, [0:20], 1); 225s h = findobj (gca, "Type", "patch"); 225s set (h(1), "facecolor", "c"); 225s set (h(2), "facecolor", "g"); 225s set (h(3), "facecolor", "r"); 225s hold on 225s 225s ## Estimate their lambda parameter 225s lambdahat = poissfit (r); 225s 225s ## Plot their estimated PDFs 225s x = [0:20]; 225s y = poisspdf (x, lambdahat(1)); 225s plot (x, y, "-pr"); 225s y = poisspdf (x, lambdahat(2)); 225s plot (x, y, "-sg"); 225s y = poisspdf (x, lambdahat(3)); 225s plot (x, y, "-^c"); 225s xlim ([0, 20]) 225s ylim ([0, 0.4]) 225s legend ({"Normalized HIST of sample 1 with λ=1", ... 225s "Normalized HIST of sample 2 with λ=4", ... 225s "Normalized HIST of sample 3 with λ=10", ... 225s sprintf("PDF for sample 1 with estimated λ=%0.2f", ... 225s lambdahat(1)), ... 225s sprintf("PDF for sample 2 with estimated λ=%0.2f", ... 225s lambdahat(2)), ... 225s sprintf("PDF for sample 3 with estimated λ=%0.2f", ... 225s lambdahat(3))}) 225s title ("Three population samples from different Poisson distibutions") 225s hold off 225s ***** test 225s x = [1 3 2 4 5 4 3 4]; 225s [lhat, lci] = poissfit (x); 225s assert (lhat, 3.25) 225s assert (lci, [2.123007901949543; 4.762003010390628], 1e-14) 225s ***** test 225s x = [1 3 2 4 5 4 3 4]; 225s [lhat, lci] = poissfit (x, 0.01); 225s assert (lhat, 3.25) 225s assert (lci, [1.842572740234582; 5.281369033298528], 1e-14) 225s ***** test 225s x = [1 2 3 4 5]; 225s f = [1 1 2 3 1]; 225s [lhat, lci] = poissfit (x, [], f); 225s assert (lhat, 3.25) 225s assert (lci, [2.123007901949543; 4.762003010390628], 1e-14) 225s ***** test 225s x = [1 2 3 4 5]; 225s f = [1 1 2 3 1]; 225s [lhat, lci] = poissfit (x, 0.01, f); 225s assert (lhat, 3.25) 225s assert (lci, [1.842572740234582; 5.281369033298528], 1e-14) 225s ***** error poissfit ([1 2 -1 3]) 225s ***** error poissfit ([1 2 3], 0) 225s ***** error poissfit ([1 2 3], 1.2) 225s ***** error poissfit ([1 2 3], [0.02 0.05]) 225s ***** error 225s poissfit ([1 2 3], [], [1 5]) 225s ***** error 225s poissfit ([1 2 3], [], [1 5 -1]) 225s 10 tests, 10 passed, 0 known failure, 0 skipped 225s [inst/dist_fit/gamlike.m] 225s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fit/gamlike.m 225s ***** test 225s [nlogL, acov] = gamlike([2, 3], [2, 3, 4, 5, 6, 7, 8, 9]); 225s assert (nlogL, 19.4426, 1e-4); 225s assert (acov, [2.7819, -5.0073; -5.0073, 9.6882], 1e-4); 225s ***** test 225s [nlogL, acov] = gamlike([2, 3], [5:45]); 225s assert (nlogL, 305.8070, 1e-4); 225s assert (acov, [0.0423, -0.0087; -0.0087, 0.0167], 1e-4); 225s ***** test 225s [nlogL, acov] = gamlike([2, 13], [5:45]); 225s assert (nlogL, 163.2261, 1e-4); 225s assert (acov, [0.2362, -1.6631; -1.6631, 13.9440], 1e-4); 225s ***** error ... 225s gamlike ([12, 15]) 225s ***** error gamlike ([12, 15, 3], [1:50]) 225s ***** error gamlike ([12, 3], ones (10, 2)) 225s ***** error ... 225s gamlike ([12, 15], [1:50], [1, 2, 3]) 225s ***** error ... 225s gamlike ([12, 15], [1:50], [], [1, 2, 3]) 225s 8 tests, 8 passed, 0 known failure, 0 skipped 225s [inst/dist_fit/binolike.m] 225s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fit/binolike.m 225s ***** assert (binolike ([3, 0.333], [0:3]), 6.8302, 1e-4) 225s ***** assert (binolike ([3, 0.333], 0), 1.2149, 1e-4) 225s ***** assert (binolike ([3, 0.333], 1), 0.8109, 1e-4) 225s ***** assert (binolike ([3, 0.333], 2), 1.5056, 1e-4) 225s ***** assert (binolike ([3, 0.333], 3), 3.2988, 1e-4) 225s ***** test 225s [nlogL, acov] = binolike ([3, 0.333], 3); 225s assert (acov(4), 0.0740, 1e-4) 225s ***** error binolike (3.25) 225s ***** error binolike ([5, 0.2], ones (2)) 225s ***** error ... 225s binolike ([1, 0.2, 3], [1, 3, 5, 7]) 225s ***** error binolike ([1.5, 0.2], 1) 225s ***** error binolike ([-1, 0.2], 1) 225s ***** error binolike ([Inf, 0.2], 1) 225s ***** error binolike ([5, 1.2], [3, 5]) 225s ***** error binolike ([5, -0.2], [3, 5]) 225s ***** error ... 225s binolike ([5, 0.5], ones (10, 1), ones (8,1)) 225s ***** error ... 225s binolike ([5, 0.5], ones (1, 8), [1 1 1 1 1 1 1 -1]) 225s ***** error binolike ([5, 0.2], [-1, 3]) 225s ***** error binolike ([5, 0.2], [3, 5, 7]) 225s 18 tests, 18 passed, 0 known failure, 0 skipped 225s [inst/dist_fit/rayllike.m] 225s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fit/rayllike.m 225s ***** test 225s x = [1 3 2 4 5 4 3 4]; 225s [nlogL, acov] = rayllike (3.25, x); 225s assert (nlogL, 14.7442, 1e-4) 225s ***** test 225s x = [1 2 3 4 5]; 225s f = [1 1 2 3 1]; 225s [nlogL, acov] = rayllike (3.25, x, [], f); 225s assert (nlogL, 14.7442, 1e-4) 225s ***** test 225s x = [1 2 3 4 5 6]; 225s f = [1 1 2 3 1 0]; 225s [nlogL, acov] = rayllike (3.25, x, [], f); 225s assert (nlogL, 14.7442, 1e-4) 225s ***** test 225s x = [1 2 3 4 5 6]; 225s c = [0 0 0 0 0 1]; 225s f = [1 1 2 3 1 0]; 225s [nlogL, acov] = rayllike (3.25, x, c, f); 225s assert (nlogL, 14.7442, 1e-4) 225s ***** error rayllike (1) 225s ***** error rayllike ([1 2 3], [1 2]) 225s ***** error ... 225s rayllike (3.25, ones (10, 2)) 225s ***** error ... 225s rayllike (3.25, [1 2 3 -4 5]) 225s ***** error ... 225s rayllike (3.25, [1, 2, 3, 4, 5], [1 1 0]); 225s ***** error ... 225s rayllike (3.25, [1, 2, 3, 4, 5], [1 1 0 1 1]'); 225s ***** error ... 225s rayllike (3.25, [1, 2, 3, 4, 5], zeros (1,5), [1 1 0]); 225s ***** error ... 225s rayllike (3.25, [1, 2, 3, 4, 5], [], [1 1 0 1 1]'); 225s ***** error ... 225s rayllike (3.25, ones (1, 8), [], [1 1 1 1 1 1 1 -1]) 225s 13 tests, 13 passed, 0 known failure, 0 skipped 225s [inst/dist_fit/hnlike.m] 225s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fit/hnlike.m 225s ***** test 225s x = 1:20; 225s paramhat = hnfit (x, 0); 225s [nlogL, acov] = hnlike (paramhat, x); 225s assert (nlogL, 64.179177404891300, 1e-14); 225s ***** test 225s x = 1:20; 225s paramhat = hnfit (x, 0); 225s [nlogL, acov] = hnlike (paramhat, x, ones (1, 20)); 225s assert (nlogL, 64.179177404891300, 1e-14); 225s ***** error ... 225s hnlike ([12, 15]); 225s ***** error hnlike ([12, 15, 3], [1:50]); 225s ***** error hnlike ([3], [1:50]); 225s ***** error ... 225s hnlike ([0, 3], ones (2)); 225s ***** error ... 225s hnlike ([0, 3], [1, 2, 3, 4, 5+i]); 225s ***** error ... 225s hnlike ([1, 2], ones (10, 1), ones (8,1)) 225s ***** error ... 225s hnlike ([1, 2], ones (1, 8), [1 1 1 1 1 1 1 -1]) 225s 9 tests, 9 passed, 0 known failure, 0 skipped 225s [inst/dist_fit/loglfit.m] 225s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fit/loglfit.m 225s ***** demo 225s ## Sample 3 populations from different log-logistic distibutions 225s rand ("seed", 5) # for reproducibility 225s r1 = loglrnd (0, 1, 2000, 1); 225s rand ("seed", 2) # for reproducibility 225s r2 = loglrnd (0, 0.5, 2000, 1); 225s rand ("seed", 7) # for reproducibility 225s r3 = loglrnd (0, 0.125, 2000, 1); 225s r = [r1, r2, r3]; 225s 225s ## Plot them normalized and fix their colors 225s hist (r, [0.05:0.1:2.5], 10); 225s h = findobj (gca, "Type", "patch"); 225s set (h(1), "facecolor", "c"); 225s set (h(2), "facecolor", "g"); 225s set (h(3), "facecolor", "r"); 225s ylim ([0, 3.5]); 225s xlim ([0, 2.0]); 225s hold on 225s 225s ## Estimate their MU and LAMBDA parameters 225s a_bA = loglfit (r(:,1)); 225s a_bB = loglfit (r(:,2)); 225s a_bC = loglfit (r(:,3)); 225s 225s ## Plot their estimated PDFs 225s x = [0.01:0.1:2.01]; 225s y = loglpdf (x, a_bA(1), a_bA(2)); 225s plot (x, y, "-pr"); 225s y = loglpdf (x, a_bB(1), a_bB(2)); 225s plot (x, y, "-sg"); 225s y = loglpdf (x, a_bC(1), a_bC(2)); 225s plot (x, y, "-^c"); 225s legend ({"Normalized HIST of sample 1 with α=1 and β=1", ... 225s "Normalized HIST of sample 2 with α=1 and β=2", ... 225s "Normalized HIST of sample 3 with α=1 and β=8", ... 225s sprintf("PDF for sample 1 with estimated α=%0.2f and β=%0.2f", ... 225s a_bA(1), a_bA(2)), ... 225s sprintf("PDF for sample 2 with estimated α=%0.2f and β=%0.2f", ... 225s a_bB(1), a_bB(2)), ... 225s sprintf("PDF for sample 3 with estimated α=%0.2f and β=%0.2f", ... 225s a_bC(1), a_bC(2))}) 225s title ("Three population samples from different log-logistic distibutions") 225s hold off 225s ***** test 225s [paramhat, paramci] = loglfit ([1:50]); 225s paramhat_out = [3.09717, 0.468525]; 225s paramci_out = [2.87261, 0.370616; 3.32174, 0.5923]; 225s assert (paramhat, paramhat_out, 1e-5); 225s assert (paramci, paramci_out, 1e-5); 225s ***** test 225s paramhat = loglfit ([1:5]); 225s paramhat_out = [1.01124, 0.336449]; 225s assert (paramhat, paramhat_out, 1e-5); 225s ***** test 225s paramhat = loglfit ([1:6], [], [], [1 1 1 1 1 0]); 225s paramhat_out = [1.01124, 0.336449]; 225s assert (paramhat, paramhat_out, 1e-4); 225s ***** test 225s paramhat = loglfit ([1:5], [], [], [1 1 1 1 2]); 225s paramhat_out = loglfit ([1:5, 5]); 225s assert (paramhat, paramhat_out, 1e-4); 226s ***** error loglfit (ones (2,5)); 226s ***** error loglfit ([1, 2, 3, 4, 5], 1.2); 226s ***** error loglfit ([1, 2, 3, 4, 5], 0); 226s ***** error loglfit ([1, 2, 3, 4, 5], "alpha"); 226s ***** error ... 226s loglfit ([1, 2, 3, 4, 5], 0.05, [1 1 0]); 226s ***** error ... 226s loglfit ([1, 2, 3, 4, 5], [], [1 1 0 1 1]'); 226s ***** error ... 226s loglfit ([1, 2, 3, 4, 5], 0.05, zeros (1,5), [1 1 0]); 226s ***** error ... 226s loglfit ([1, 2, 3, 4, 5], [], [], [1 1 0 1 1]'); 226s ***** error ... 226s loglfit ([1, 2, 3, 4, 5], 0.05, [], [], 2); 226s 13 tests, 13 passed, 0 known failure, 0 skipped 226s [inst/dist_fit/unifit.m] 226s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fit/unifit.m 226s ***** demo 226s ## Sample 2 populations from different continuous uniform distibutions 226s rand ("seed", 5); # for reproducibility 226s r1 = unifrnd (2, 5, 2000, 1); 226s rand ("seed", 6); # for reproducibility 226s r2 = unifrnd (3, 9, 2000, 1); 226s r = [r1, r2]; 226s 226s ## Plot them normalized and fix their colors 226s hist (r, 0:0.5:10, 2); 226s h = findobj (gca, "Type", "patch"); 226s set (h(1), "facecolor", "c"); 226s set (h(2), "facecolor", "g"); 226s hold on 226s 226s ## Estimate their probability of success 226s a_bA = unifit (r(:,1)); 226s a_bB = unifit (r(:,2)); 226s 226s ## Plot their estimated PDFs 226s x = [0:10]; 226s y = unifpdf (x, a_bA(1), a_bA(2)); 226s plot (x, y, "-pg"); 226s y = unifpdf (x, a_bB(1), a_bB(2)); 226s plot (x, y, "-sc"); 226s xlim ([1, 10]) 226s ylim ([0, 0.5]) 226s legend ({"Normalized HIST of sample 1 with a=2 and b=5", ... 226s "Normalized HIST of sample 2 with a=3 and b=9", ... 226s sprintf("PDF for sample 1 with estimated a=%0.2f and b=%0.2f", ... 226s a_bA(1), a_bA(2)), ... 226s sprintf("PDF for sample 2 with estimated a=%0.2f and b=%0.2f", ... 226s a_bB(1), a_bB(2))}) 226s title ("Two population samples from different continuous uniform distibutions") 226s hold off 226s ***** test 226s x = 0:5; 226s [paramhat, paramci] = unifit (x); 226s assert (paramhat, [0, 5]); 226s assert (paramci, [-3.2377, 8.2377; 0, 5], 1e-4); 226s ***** test 226s x = 0:5; 226s [paramhat, paramci] = unifit (x, [], [1 1 1 1 1 1]); 226s assert (paramhat, [0, 5]); 226s assert (paramci, [-3.2377, 8.2377; 0, 5], 1e-4); 226s ***** assert (unifit ([1 1 2 3]), unifit ([1 2 3], [] ,[2 1 1])) 226s ***** error unifit () 226s ***** error unifit (-1, [1 2 3 3]) 226s ***** error unifit (1, 0) 226s ***** error unifit (1, 1.2) 226s ***** error unifit (1, [0.02 0.05]) 226s ***** error ... 226s unifit ([1.5, 0.2], [], [0, 0, 0, 0, 0]) 226s ***** error ... 226s unifit ([1.5, 0.2], [], [1, -1]) 226s ***** error ... 226s unifit ([1.5, 0.2], [], [1, 1, 1]) 226s 11 tests, 11 passed, 0 known failure, 0 skipped 226s [inst/dist_fit/poisslike.m] 226s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fit/poisslike.m 226s ***** test 226s x = [1 3 2 4 5 4 3 4]; 226s [nlogL, avar] = poisslike (3.25, x); 226s assert (nlogL, 13.9533, 1e-4) 226s ***** test 226s x = [1 2 3 4 5]; 226s f = [1 1 2 3 1]; 226s [nlogL, avar] = poisslike (3.25, x, f); 226s assert (nlogL, 13.9533, 1e-4) 226s ***** error poisslike (1) 226s ***** error poisslike ([1 2 3], [1 2]) 226s ***** error ... 226s poisslike (3.25, ones (10, 2)) 226s ***** error ... 226s poisslike (3.25, [1 2 3 -4 5]) 226s ***** error ... 226s poisslike (3.25, ones (10, 1), ones (8,1)) 226s ***** error ... 226s poisslike (3.25, ones (1, 8), [1 1 1 1 1 1 1 -1]) 226s 8 tests, 8 passed, 0 known failure, 0 skipped 226s [inst/dist_fit/hnfit.m] 226s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fit/hnfit.m 226s ***** demo 226s ## Sample 2 populations from different half-normal distibutions 226s rand ("seed", 1); # for reproducibility 226s r1 = hnrnd (0, 5, 5000, 1); 226s rand ("seed", 2); # for reproducibility 226s r2 = hnrnd (0, 2, 5000, 1); 226s r = [r1, r2]; 226s 226s ## Plot them normalized and fix their colors 226s hist (r, [0.5:20], 1); 226s h = findobj (gca, "Type", "patch"); 226s set (h(1), "facecolor", "c"); 226s set (h(2), "facecolor", "g"); 226s hold on 226s 226s ## Estimate their shape parameters 226s mu_sigmaA = hnfit (r(:,1), 0); 226s mu_sigmaB = hnfit (r(:,2), 0); 226s 226s ## Plot their estimated PDFs 226s x = [0:0.2:10]; 226s y = hnpdf (x, mu_sigmaA(1), mu_sigmaA(2)); 226s plot (x, y, "-pr"); 226s y = hnpdf (x, mu_sigmaB(1), mu_sigmaB(2)); 226s plot (x, y, "-sg"); 226s xlim ([0, 10]) 226s ylim ([0, 0.5]) 226s legend ({"Normalized HIST of sample 1 with μ=0 and σ=5", ... 226s "Normalized HIST of sample 2 with μ=0 and σ=2", ... 226s sprintf("PDF for sample 1 with estimated μ=%0.2f and σ=%0.2f", ... 226s mu_sigmaA(1), mu_sigmaA(2)), ... 226s sprintf("PDF for sample 2 with estimated μ=%0.2f and σ=%0.2f", ... 226s mu_sigmaB(1), mu_sigmaB(2))}) 226s title ("Two population samples from different half-normal distibutions") 226s hold off 226s ***** test 226s x = 1:20; 226s [paramhat, paramci] = hnfit (x, 0); 226s assert (paramhat, [0, 11.9791], 1e-4); 226s assert (paramci, [0, 9.1648; 0, 17.2987], 1e-4); 226s ***** test 226s x = 1:20; 226s [paramhat, paramci] = hnfit (x, 0, 0.01); 226s assert (paramci, [0, 8.4709; 0, 19.6487], 1e-4); 226s ***** error hnfit () 226s ***** error hnfit (1) 226s ***** error hnfit ([0.2, 0.5+i], 0); 226s ***** error hnfit (ones (2,2) * 0.5, 0); 226s ***** error ... 226s hnfit ([0.5, 1.2], [0, 1]); 226s ***** error ... 226s hnfit ([0.5, 1.2], 5+i); 226s ***** error ... 226s hnfit ([1:5], 2); 226s ***** error hnfit ([0.01:0.1:0.99], 0, 1.2); 226s ***** error hnfit ([0.01:0.1:0.99], 0, i); 226s ***** error hnfit ([0.01:0.1:0.99], 0, -1); 226s ***** error hnfit ([0.01:0.1:0.99], 0, [0.05, 0.01]); 226s ***** error 226s hnfit ([1 2 3], 0, [], [1 5]) 226s ***** error 226s hnfit ([1 2 3], 0, [], [1 5 -1]) 226s 15 tests, 15 passed, 0 known failure, 0 skipped 226s [inst/dist_fit/betalike.m] 226s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fit/betalike.m 226s ***** test 226s x = 0.01:0.02:0.99; 226s [nlogL, avar] = betalike ([2.3, 1.2], x); 226s avar_out = [0.03691678, 0.02803056; 0.02803056, 0.03965629]; 226s assert (nlogL, 17.873477715879040, 3e-14); 226s assert (avar, avar_out, 1e-7); 226s ***** test 226s x = 0.01:0.02:0.99; 226s [nlogL, avar] = betalike ([1, 4], x); 226s avar_out = [0.02793282, 0.02717274; 0.02717274, 0.03993361]; 226s assert (nlogL, 79.648061114839550, 1e-13); 226s assert (avar, avar_out, 1e-7); 226s ***** test 226s x = 0.00:0.02:1; 226s [nlogL, avar] = betalike ([1, 4], x); 226s avar_out = [0.00000801564765, 0.00000131397245; ... 226s 0.00000131397245, 0.00070827639442]; 226s assert (nlogL, 573.2008434477486, 1e-10); 226s assert (avar, avar_out, 1e-14); 226s ***** error ... 226s betalike ([12, 15]); 226s ***** error betalike ([12, 15, 3], [1:50]); 226s ***** error ... 226s betalike ([12, 15], ones (10, 1), ones (8,1)) 226s ***** error ... 226s betalike ([12, 15], ones (1, 8), [1 1 1 1 1 1 1 -1]) 226s ***** error ... 226s betalike ([12, 15], ones (1, 8), [1 1 1 1 1 1 1 1.5]) 226s 8 tests, 8 passed, 0 known failure, 0 skipped 226s [inst/dist_fit/burrlike.m] 226s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fit/burrlike.m 226s ***** error burrlike (3.25) 226s ***** error burrlike ([1, 2, 3], ones (2)) 226s ***** error burrlike ([1, 2, 3], [-1, 3]) 226s ***** error ... 226s burrlike ([1, 2], [1, 3, 5, 7]) 226s ***** error ... 226s burrlike ([1, 2, 3, 4], [1, 3, 5, 7]) 226s ***** error ... 226s burrlike ([1, 2, 3], [1:5], [0, 0, 0]) 226s ***** error ... 226s burrlike ([1, 2, 3], [1:5], [0, 0, 0, 0, 0], [1, 1, 1]) 226s ***** error ... 226s burrlike ([1, 2, 3], [1:5], [], [1, 1, 1]) 226s 8 tests, 8 passed, 0 known failure, 0 skipped 226s [inst/dist_fit/lognlike.m] 226s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fit/lognlike.m 226s ***** test 226s x = 1:50; 226s [nlogL, avar] = lognlike ([0, 0.25], x); 226s avar_out = [-5.4749e-03, 2.8308e-04; 2.8308e-04, -1.1916e-05]; 226s assert (nlogL, 3962.330333301793, 1e-10); 226s assert (avar, avar_out, 1e-7); 226s ***** test 226s x = 1:50; 226s [nlogL, avar] = lognlike ([0, 0.25], x * 0.5); 226s avar_out = [-7.6229e-03, 4.8722e-04; 4.8722e-04, -2.6754e-05]; 226s assert (nlogL, 2473.183051225747, 1e-10); 226s assert (avar, avar_out, 1e-7); 226s ***** test 226s x = 1:50; 226s [nlogL, avar] = lognlike ([0, 0.5], x); 226s avar_out = [-2.1152e-02, 2.2017e-03; 2.2017e-03, -1.8535e-04]; 226s assert (nlogL, 1119.072424020455, 1e-12); 226s assert (avar, avar_out, 1e-6); 226s ***** test 226s x = 1:50; 226s censor = ones (1, 50); 226s censor([2, 4, 6, 8, 12, 14]) = 0; 226s [nlogL, avar] = lognlike ([0, 0.5], x, censor); 226s avar_out = [-1.9823e-02, 2.0370e-03; 2.0370e-03, -1.6618e-04]; 226s assert (nlogL, 1091.746371145497, 1e-12); 226s assert (avar, avar_out, 1e-6); 226s ***** test 226s x = 1:50; 226s censor = ones (1, 50); 226s censor([2, 4, 6, 8, 12, 14]) = 0; 226s [nlogL, avar] = lognlike ([0, 1], x, censor); 226s avar_out = [-6.8634e-02, 1.3968e-02; 1.3968e-02, -2.1664e-03]; 226s assert (nlogL, 349.3969104144271, 1e-12); 226s assert (avar, avar_out, 1e-6); 226s ***** error ... 226s lognlike ([12, 15]); 226s ***** error lognlike ([12, 15], ones (2)); 226s ***** error ... 226s lognlike ([12, 15, 3], [1:50]); 226s ***** error ... 226s lognlike ([12, 15], [1:50], [1, 2, 3]); 226s ***** error ... 226s lognlike ([12, 15], [1:50], [], [1, 2, 3]); 226s 10 tests, 10 passed, 0 known failure, 0 skipped 226s [inst/dist_fit/lognfit.m] 226s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fit/lognfit.m 226s ***** demo 226s ## Sample 3 populations from 3 different log-normal distibutions 226s randn ("seed", 1); # for reproducibility 226s r1 = lognrnd (0, 0.25, 1000, 1); 226s randn ("seed", 2); # for reproducibility 226s r2 = lognrnd (0, 0.5, 1000, 1); 226s randn ("seed", 3); # for reproducibility 226s r3 = lognrnd (0, 1, 1000, 1); 226s r = [r1, r2, r3]; 226s 226s ## Plot them normalized and fix their colors 226s hist (r, 30, 2); 226s h = findobj (gca, "Type", "patch"); 226s set (h(1), "facecolor", "c"); 226s set (h(2), "facecolor", "g"); 226s set (h(3), "facecolor", "r"); 226s hold on 226s 226s ## Estimate their mu and sigma parameters 226s mu_sigmaA = lognfit (r(:,1)); 226s mu_sigmaB = lognfit (r(:,2)); 226s mu_sigmaC = lognfit (r(:,3)); 226s 226s ## Plot their estimated PDFs 226s x = [0:0.1:6]; 226s y = lognpdf (x, mu_sigmaA(1), mu_sigmaA(2)); 226s plot (x, y, "-pr"); 226s y = lognpdf (x, mu_sigmaB(1), mu_sigmaB(2)); 226s plot (x, y, "-sg"); 226s y = lognpdf (x, mu_sigmaC(1), mu_sigmaC(2)); 226s plot (x, y, "-^c"); 226s ylim ([0, 2]) 226s xlim ([0, 6]) 226s hold off 226s legend ({"Normalized HIST of sample 1 with mu=0, σ=0.25", ... 226s "Normalized HIST of sample 2 with mu=0, σ=0.5", ... 226s "Normalized HIST of sample 3 with mu=0, σ=1", ... 226s sprintf("PDF for sample 1 with estimated mu=%0.2f and σ=%0.2f", ... 226s mu_sigmaA(1), mu_sigmaA(2)), ... 226s sprintf("PDF for sample 2 with estimated mu=%0.2f and σ=%0.2f", ... 226s mu_sigmaB(1), mu_sigmaB(2)), ... 226s sprintf("PDF for sample 3 with estimated mu=%0.2f and σ=%0.2f", ... 226s mu_sigmaC(1), mu_sigmaC(2))}, "location", "northeast") 226s title ("Three population samples from different log-normal distibutions") 226s hold off 226s ***** test 226s randn ("seed", 1); 226s x = lognrnd (3, 5, [1000, 1]); 226s [paramhat, paramci] = lognfit (x, 0.01); 226s assert (paramci(1,1) < 3); 226s assert (paramci(1,2) > 3); 226s assert (paramci(2,1) < 5); 226s assert (paramci(2,2) > 5); 226s ***** error ... 226s lognfit (ones (20,3)) 226s ***** error ... 226s lognfit ({1, 2, 3, 4, 5}) 226s ***** error ... 226s lognfit ([-1, 2, 3, 4, 5]) 226s ***** error lognfit (ones (20,1), 0) 226s ***** error lognfit (ones (20,1), -0.3) 226s ***** error lognfit (ones (20,1), 1.2) 226s ***** error lognfit (ones (20,1), [0.05, 0.1]) 226s ***** error lognfit (ones (20,1), 0.02+i) 226s ***** error ... 226s lognfit (ones (20,1), [], zeros(15,1)) 226s ***** error ... 226s lognfit (ones (20,1), [], zeros(20,1), ones(25,1)) 226s ***** error lognfit (ones (20,1), [], zeros(20,1), ones(20,1), "options") 226s 12 tests, 12 passed, 0 known failure, 0 skipped 226s [inst/dist_fit/logifit.m] 226s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fit/logifit.m 226s ***** demo 226s ## Sample 3 populations from different logistic distibutions 226s rand ("seed", 5) # for reproducibility 226s r1 = logirnd (2, 1, 2000, 1); 226s rand ("seed", 2) # for reproducibility 226s r2 = logirnd (5, 2, 2000, 1); 226s rand ("seed", 7) # for reproducibility 226s r3 = logirnd (9, 4, 2000, 1); 226s r = [r1, r2, r3]; 226s 226s ## Plot them normalized and fix their colors 226s hist (r, [-6:20], 1); 226s h = findobj (gca, "Type", "patch"); 226s set (h(1), "facecolor", "c"); 226s set (h(2), "facecolor", "g"); 226s set (h(3), "facecolor", "r"); 226s ylim ([0, 0.3]); 226s xlim ([-5, 20]); 226s hold on 226s 226s ## Estimate their MU and LAMBDA parameters 226s mu_sA = logifit (r(:,1)); 226s mu_sB = logifit (r(:,2)); 226s mu_sC = logifit (r(:,3)); 226s 226s ## Plot their estimated PDFs 226s x = [-5:0.5:20]; 226s y = logipdf (x, mu_sA(1), mu_sA(2)); 226s plot (x, y, "-pr"); 226s y = logipdf (x, mu_sB(1), mu_sB(2)); 226s plot (x, y, "-sg"); 226s y = logipdf (x, mu_sC(1), mu_sC(2)); 226s plot (x, y, "-^c"); 226s hold off 226s legend ({"Normalized HIST of sample 1 with μ=1 and s=0.5", ... 226s "Normalized HIST of sample 2 with μ=2 and s=0.3", ... 226s "Normalized HIST of sample 3 with μ=4 and s=0.5", ... 226s sprintf("PDF for sample 1 with estimated μ=%0.2f and s=%0.2f", ... 226s mu_sA(1), mu_sA(2)), ... 226s sprintf("PDF for sample 2 with estimated μ=%0.2f and s=%0.2f", ... 226s mu_sB(1), mu_sB(2)), ... 226s sprintf("PDF for sample 3 with estimated μ=%0.2f and s=%0.2f", ... 226s mu_sC(1), mu_sC(2))}) 226s title ("Three population samples from different logistic distibutions") 226s hold off 226s ***** test 226s paramhat = logifit ([1:50]); 226s paramhat_out = [25.5, 8.7724]; 226s assert (paramhat, paramhat_out, 1e-4); 227s ***** test 227s paramhat = logifit ([1:5]); 227s paramhat_out = [3, 0.8645]; 227s assert (paramhat, paramhat_out, 1e-4); 227s ***** test 227s paramhat = logifit ([1:6], [], [], [1 1 1 1 1 0]); 227s paramhat_out = [3, 0.8645]; 227s assert (paramhat, paramhat_out, 1e-4); 227s ***** test 227s paramhat = logifit ([1:5], [], [], [1 1 1 1 2]); 227s paramhat_out = logifit ([1:5, 5]); 227s assert (paramhat, paramhat_out, 1e-4); 227s ***** error logifit (ones (2,5)); 227s ***** error logifit ([1, 2, 3, 4, 5], 1.2); 227s ***** error logifit ([1, 2, 3, 4, 5], 0); 227s ***** error logifit ([1, 2, 3, 4, 5], "alpha"); 227s ***** error ... 227s logifit ([1, 2, 3, 4, 5], 0.05, [1 1 0]); 227s ***** error ... 227s logifit ([1, 2, 3, 4, 5], [], [1 1 0 1 1]'); 227s ***** error ... 227s logifit ([1, 2, 3, 4, 5], 0.05, zeros (1,5), [1 1 0]); 227s ***** error ... 227s logifit ([1, 2, 3, 4, 5], [], [], [1 1 0 1 1]'); 227s ***** error ... 227s logifit ([1, 2, 3, 4, 5], 0.05, [], [], 2); 227s 13 tests, 13 passed, 0 known failure, 0 skipped 227s [inst/dist_fit/explike.m] 227s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fit/explike.m 227s ***** test 227s x = 12; 227s beta = 5; 227s [L, V] = explike (beta, x); 227s expected_L = 4.0094; 227s expected_V = 6.5789; 227s assert (L, expected_L, 0.001); 227s assert (V, expected_V, 0.001); 227s ***** test 227s x = 1:5; 227s beta = 2; 227s [L, V] = explike (beta, x); 227s expected_L = 10.9657; 227s expected_V = 0.4; 227s assert (L, expected_L, 0.001); 227s assert (V, expected_V, 0.001); 227s ***** error explike () 227s ***** error explike (2) 227s ***** error explike ([12, 3], [1:50]) 227s ***** error explike (3, ones (10, 2)) 227s ***** error ... 227s explike (3, [1:50], [1, 2, 3]) 227s ***** error ... 227s explike (3, [1:50], [], [1, 2, 3]) 227s 8 tests, 8 passed, 0 known failure, 0 skipped 227s [inst/dist_fit/geofit.m] 227s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fit/geofit.m 227s ***** demo 227s ## Sample 2 populations from different geometric distibutions 227s rande ("seed", 1); # for reproducibility 227s r1 = geornd (0.15, 1000, 1); 227s rande ("seed", 2); # for reproducibility 227s r2 = geornd (0.5, 1000, 1); 227s r = [r1, r2]; 227s 227s ## Plot them normalized and fix their colors 227s hist (r, 0:0.5:20.5, 1); 227s h = findobj (gca, "Type", "patch"); 227s set (h(1), "facecolor", "c"); 227s set (h(2), "facecolor", "g"); 227s hold on 227s 227s ## Estimate their probability of success 227s pshatA = geofit (r(:,1)); 227s pshatB = geofit (r(:,2)); 227s 227s ## Plot their estimated PDFs 227s x = [0:15]; 227s y = geopdf (x, pshatA); 227s plot (x, y, "-pg"); 227s y = geopdf (x, pshatB); 227s plot (x, y, "-sc"); 227s xlim ([0, 15]) 227s ylim ([0, 0.6]) 227s legend ({"Normalized HIST of sample 1 with ps=0.15", ... 227s "Normalized HIST of sample 2 with ps=0.50", ... 227s sprintf("PDF for sample 1 with estimated ps=%0.2f", ... 227s mean (pshatA)), ... 227s sprintf("PDF for sample 2 with estimated ps=%0.2f", ... 227s mean (pshatB))}) 227s title ("Two population samples from different geometric distibutions") 227s hold off 227s ***** test 227s x = 0:5; 227s [pshat, psci] = geofit (x); 227s assert (pshat, 0.2857, 1e-4); 227s assert (psci, [0.092499; 0.478929], 1e-5); 227s ***** test 227s x = 0:5; 227s [pshat, psci] = geofit (x, [], [1 1 1 1 1 1]); 227s assert (pshat, 0.2857, 1e-4); 227s assert (psci, [0.092499; 0.478929], 1e-5); 227s ***** assert (geofit ([1 1 2 3]), geofit ([1 2 3], [] ,[2 1 1])) 227s ***** error geofit () 227s ***** error geofit (-1, [1 2 3 3]) 227s ***** error geofit (1, 0) 227s ***** error geofit (1, 1.2) 227s ***** error geofit (1, [0.02 0.05]) 227s ***** error ... 227s geofit ([1.5, 0.2], [], [0, 0, 0, 0, 0]) 227s ***** error ... 227s geofit ([1.5, 0.2], [], [1, 1, 1]) 227s 10 tests, 10 passed, 0 known failure, 0 skipped 227s [inst/dist_fit/expfit.m] 227s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fit/expfit.m 227s ***** demo 227s ## Sample 3 populations from 3 different exponential distibutions 227s rande ("seed", 1); # for reproducibility 227s r1 = exprnd (2, 4000, 1); 227s rande ("seed", 2); # for reproducibility 227s r2 = exprnd (5, 4000, 1); 227s rande ("seed", 3); # for reproducibility 227s r3 = exprnd (12, 4000, 1); 227s r = [r1, r2, r3]; 227s 227s ## Plot them normalized and fix their colors 227s hist (r, 48, 0.52); 227s h = findobj (gca, "Type", "patch"); 227s set (h(1), "facecolor", "c"); 227s set (h(2), "facecolor", "g"); 227s set (h(3), "facecolor", "r"); 227s hold on 227s 227s ## Estimate their mu parameter 227s muhat = expfit (r); 227s 227s ## Plot their estimated PDFs 227s x = [0:max(r(:))]; 227s y = exppdf (x, muhat(1)); 227s plot (x, y, "-pr"); 227s y = exppdf (x, muhat(2)); 227s plot (x, y, "-sg"); 227s y = exppdf (x, muhat(3)); 227s plot (x, y, "-^c"); 227s ylim ([0, 0.6]) 227s xlim ([0, 40]) 227s legend ({"Normalized HIST of sample 1 with μ=2", ... 227s "Normalized HIST of sample 2 with μ=5", ... 227s "Normalized HIST of sample 3 with μ=12", ... 227s sprintf("PDF for sample 1 with estimated μ=%0.2f", muhat(1)), ... 227s sprintf("PDF for sample 2 with estimated μ=%0.2f", muhat(2)), ... 227s sprintf("PDF for sample 3 with estimated μ=%0.2f", muhat(3))}) 227s title ("Three population samples from different exponential distibutions") 227s hold off 227s ***** assert (expfit (1), 1) 227s ***** assert (expfit (1:3), 2) 227s ***** assert (expfit ([1:3]'), 2) 227s ***** assert (expfit (1:3, []), 2) 227s ***** assert (expfit (1:3, [], [], []), 2) 227s ***** assert (expfit (magic (3)), [5 5 5]) 227s ***** assert (expfit (cat (3, magic (3), 2*magic (3))), cat (3,[5 5 5], [10 10 10])) 227s ***** assert (expfit (1:3, 0.1, [0 0 0], [1 1 1]), 2) 227s ***** assert (expfit ([1:3]', 0.1, [0 0 0]', [1 1 1]'), 2) 227s ***** assert (expfit (1:3, 0.1, [0 0 0]', [1 1 1]'), 2) 227s ***** assert (expfit (1:3, 0.1, [1 0 0], [1 1 1]), 3) 227s ***** assert (expfit (1:3, 0.1, [0 0 0], [4 1 1]), 1.5) 227s ***** assert (expfit (1:3, 0.1, [1 0 0], [4 1 1]), 4.5) 227s ***** assert (expfit (1:3, 0.1, [1 0 1], [4 1 1]), 9) 227s ***** assert (expfit (1:3, 0.1, [], [-1 1 1]), 4) 227s ***** assert (expfit (1:3, 0.1, [], [0.5 1 1]), 2.2) 227s ***** assert (expfit (1:3, 0.1, [1 1 1]), NaN) 227s ***** assert (expfit (1:3, 0.1, [], [0 0 0]), NaN) 227s ***** assert (expfit (reshape (1:9, [3 3])), [2 5 8]) 227s ***** assert (expfit (reshape (1:9, [3 3]), [], eye(3)), [3 7.5 12]) 227s ***** assert (expfit (reshape (1:9, [3 3]), [], 2*eye(3)), [3 7.5 12]) 227s ***** assert (expfit (reshape (1:9, [3 3]), [], [], [2 2 2; 1 1 1; 1 1 1]), ... 227s [1.75 4.75 7.75]) 227s ***** assert (expfit (reshape (1:9, [3 3]), [], [], [2 2 2; 1 1 1; 1 1 1]), ... 227s [1.75 4.75 7.75]) 227s ***** assert (expfit (reshape (1:9, [3 3]), [], eye(3), [2 2 2; 1 1 1; 1 1 1]), ... 227s [3.5 19/3 31/3]) 227s ***** assert ([~,muci] = expfit (1:3, 0), [0; Inf]) 227s ***** assert ([~,muci] = expfit (1:3, 2), [Inf; 0]) 227s ***** assert ([~,muci] = expfit (1:3, 0.1, [1 1 1]), [NaN; NaN]) 227s ***** assert ([~,muci] = expfit (1:3, 0.1, [], [0 0 0]), [NaN; NaN]) 227s ***** assert ([~,muci] = expfit (1:3, -1), [NaN; NaN]) 227s ***** assert ([~,muci] = expfit (1:3, 5), [NaN; NaN]) 227s ***** assert ([~,muci] = expfit (1:3), [0.830485728373393; 9.698190330474096], ... 227s 1000*eps) 227s ***** assert ([~,muci] = expfit (1:3, 0.1), ... 227s [0.953017262058213; 7.337731146400207], 1000*eps) 227s ***** assert ([~,muci] = expfit ([1:3;2:4]), ... 227s [0.538440777613095, 0.897401296021825, 1.256361814430554; ... 227s 12.385982973214016, 20.643304955356694, 28.900626937499371], ... 227s 1000*eps) 227s ***** assert ([~,muci] = expfit ([1:3;2:4], [], [1 1 1; 0 0 0]), ... 227s 100*[0.008132550920455, 0.013554251534091, 0.018975952147727; ... 227s 1.184936706156216, 1.974894510260360, 2.764852314364504], ... 227s 1000*eps) 227s ***** assert ([~,muci] = expfit ([1:3;2:4], [], [], [3 3 3; 1 1 1]), ... 227s [0.570302756652583, 1.026544961974649, 1.482787167296715; ... 227s 4.587722594914109, 8.257900670845396, 11.928078746776684], ... 227s 1000*eps) 227s ***** assert ([~,muci] = expfit ([1:3;2:4], [], [0 0 0; 1 1 1], [3 3 3; 1 1 1]), ... 227s [0.692071440311161, 1.245728592560089, 1.799385744809018; ... 227s 8.081825275395081, 14.547285495711145, 21.012745716027212], ... 227s 1000*eps) 227s ***** test 227s x = reshape (1:8, [4 2]); 227s x(4) = NaN; 227s [muhat,muci] = expfit (x); 227s assert ({muhat, muci}, {[NaN, 6.5], ... 227s [NaN, 2.965574334593430;NaN, 23.856157493553368]}, 1000*eps); 227s ***** test 227s x = magic (3); 227s censor = [0 1 0; 0 1 0; 0 1 0]; 227s freq = [1 1 0; 1 1 0; 1 1 0]; 227s [muhat,muci] = expfit (x, [], censor, freq); 227s assert ({muhat, muci}, {[5 NaN NaN], ... 227s [[2.076214320933482; 24.245475826185242],NaN(2)]}, 1000*eps); 227s ***** error expfit () 227s ***** error expfit (1,2,3,4,5) 227s ***** error [a b censor] = expfit (1) 227s ***** error expfit (1, [1 2]) 227s ***** error expfit ([-1 2 3 4 5]) 227s ***** error expfit ([1:5], [], "test") 227s ***** error expfit ([1:5], [], [], "test") 227s ***** error expfit ([1:5], [], [0 0 0 0]) 227s ***** error expfit ([1:5], [], [], [1 1 1 1]) 227s 47 tests, 47 passed, 0 known failure, 0 skipped 227s [inst/dist_fit/raylfit.m] 227s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fit/raylfit.m 227s ***** demo 227s ## Sample 3 populations from 3 different Rayleigh distibutions 227s rand ("seed", 2); # for reproducibility 227s r1 = raylrnd (1, 1000, 1); 227s rand ("seed", 2); # for reproducibility 227s r2 = raylrnd (2, 1000, 1); 227s rand ("seed", 3); # for reproducibility 227s r3 = raylrnd (4, 1000, 1); 227s r = [r1, r2, r3]; 227s 227s ## Plot them normalized and fix their colors 227s hist (r, [0.5:0.5:10.5], 2); 227s h = findobj (gca, "Type", "patch"); 227s set (h(1), "facecolor", "c"); 227s set (h(2), "facecolor", "g"); 227s set (h(3), "facecolor", "r"); 227s hold on 227s 227s ## Estimate their lambda parameter 227s sigmaA = raylfit (r(:,1)); 227s sigmaB = raylfit (r(:,2)); 227s sigmaC = raylfit (r(:,3)); 227s 227s ## Plot their estimated PDFs 227s x = [0:0.1:10]; 227s y = raylpdf (x, sigmaA); 227s plot (x, y, "-pr"); 227s y = raylpdf (x, sigmaB); 227s plot (x, y, "-sg"); 227s y = raylpdf (x, sigmaC); 227s plot (x, y, "-^c"); 227s xlim ([0, 10]) 227s ylim ([0, 0.7]) 227s legend ({"Normalized HIST of sample 1 with σ=1", ... 227s "Normalized HIST of sample 2 with σ=2", ... 227s "Normalized HIST of sample 3 with σ=4", ... 227s sprintf("PDF for sample 1 with estimated σ=%0.2f", ... 227s sigmaA), ... 227s sprintf("PDF for sample 2 with estimated σ=%0.2f", ... 227s sigmaB), ... 227s sprintf("PDF for sample 3 with estimated σ=%0.2f", ... 227s sigmaC)}) 227s title ("Three population samples from different Rayleigh distibutions") 227s hold off 227s ***** test 227s x = [1 3 2 4 5 4 3 4]; 227s [shat, sci] = raylfit (x); 227s assert (shat, 2.4495, 1e-4) 227s assert (sci, [1.8243; 3.7279], 1e-4) 228s ***** test 228s x = [1 3 2 4 5 4 3 4]; 228s [shat, sci] = raylfit (x, 0.01); 228s assert (shat, 2.4495, 1e-4) 228s assert (sci, [1.6738; 4.3208], 1e-4) 228s ***** test 228s x = [1 2 3 4 5]; 228s f = [1 1 2 3 1]; 228s [shat, sci] = raylfit (x, [], [], f); 228s assert (shat, 2.4495, 1e-4) 228s assert (sci, [1.8243; 3.7279], 1e-4) 228s ***** test 228s x = [1 2 3 4 5]; 228s f = [1 1 2 3 1]; 228s [shat, sci] = raylfit (x, 0.01, [], f); 228s assert (shat, 2.4495, 1e-4) 228s assert (sci, [1.6738; 4.3208], 1e-4) 228s ***** test 228s x = [1 2 3 4 5 6]; 228s c = [0 0 0 0 0 1]; 228s f = [1 1 2 3 1 1]; 228s [shat, sci] = raylfit (x, 0.01, c, f); 228s assert (shat, 2.4495, 1e-4) 228s assert (sci, [1.6738; 4.3208], 1e-4) 228s ***** error raylfit (ones (2,5)); 228s ***** error raylfit ([1 2 -1 3]) 228s ***** error raylfit ([1 2 3], 0) 228s ***** error raylfit ([1 2 3], 1.2) 228s ***** error raylfit ([1 2 3], [0.02 0.05]) 228s ***** error ... 228s raylfit ([1, 2, 3, 4, 5], 0.05, [1 1 0]); 228s ***** error ... 228s raylfit ([1, 2, 3, 4, 5], [], [1 1 0 1 1]'); 228s ***** error ... 228s raylfit ([1, 2, 3, 4, 5], 0.05, zeros (1,5), [1 1 0]); 228s ***** error ... 228s raylfit ([1, 2, 3, 4, 5], [], [], [1 1 0 1 1]'); 228s ***** error 228s raylfit ([1 2 3], [], [], [1 5]) 228s ***** error 228s raylfit ([1 2 3], [], [], [1 5 -1]) 228s 16 tests, 16 passed, 0 known failure, 0 skipped 228s [inst/dist_fit/logllike.m] 228s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fit/logllike.m 228s ***** test 228s [nlogL, acov] = logllike ([3.09717, 0.468525], [1:50]); 228s assert (nlogL, 211.2965, 1e-4); 228s assert (acov, [0.0131, -0.0007; -0.0007, 0.0031], 1e-4); 228s ***** test 228s [nlogL, acov] = logllike ([1.01124, 0.336449], [1:5]); 228s assert (nlogL, 9.2206, 1e-4); 228s assert (acov, [0.0712, -0.0032; -0.0032, 0.0153], 1e-4); 228s ***** error logllike (3.25) 228s ***** error logllike ([5, 0.2], ones (2)) 228s ***** error ... 228s logllike ([1, 0.2, 3], [1, 3, 5, 7]) 228s ***** error ... 228s logllike ([1.5, 0.2], [1:5], [0, 0, 0]) 228s ***** error ... 228s logllike ([1.5, 0.2], [1:5], [0, 0, 0, 0, 0], [1, 1, 1]) 228s ***** error ... 228s logllike ([1.5, 0.2], [1:5], [], [1, 1, 1]) 228s 8 tests, 8 passed, 0 known failure, 0 skipped 228s [inst/dist_fit/wblfit.m] 228s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fit/wblfit.m 228s ***** demo 228s ## Sample 3 populations from 3 different Weibull distibutions 228s rande ("seed", 1); # for reproducibility 228s r1 = wblrnd(2, 4, 2000, 1); 228s rande ("seed", 2); # for reproducibility 228s r2 = wblrnd(5, 2, 2000, 1); 228s rande ("seed", 5); # for reproducibility 228s r3 = wblrnd(1, 5, 2000, 1); 228s r = [r1, r2, r3]; 228s 228s ## Plot them normalized and fix their colors 228s hist (r, 30, [2.5 2.1 3.2]); 228s h = findobj (gca, "Type", "patch"); 228s set (h(1), "facecolor", "c"); 228s set (h(2), "facecolor", "g"); 228s set (h(3), "facecolor", "r"); 228s ylim ([0, 2]); 228s xlim ([0, 10]); 228s hold on 228s 228s ## Estimate their lambda parameter 228s lambda_kA = wblfit (r(:,1)); 228s lambda_kB = wblfit (r(:,2)); 228s lambda_kC = wblfit (r(:,3)); 228s 228s ## Plot their estimated PDFs 228s x = [0:0.1:15]; 228s y = wblpdf (x, lambda_kA(1), lambda_kA(2)); 228s plot (x, y, "-pr"); 228s y = wblpdf (x, lambda_kB(1), lambda_kB(2)); 228s plot (x, y, "-sg"); 228s y = wblpdf (x, lambda_kC(1), lambda_kC(2)); 228s plot (x, y, "-^c"); 228s hold off 228s legend ({"Normalized HIST of sample 1 with λ=2 and k=4", ... 228s "Normalized HIST of sample 2 with λ=5 and k=2", ... 228s "Normalized HIST of sample 3 with λ=1 and k=5", ... 228s sprintf("PDF for sample 1 with estimated λ=%0.2f and k=%0.2f", ... 228s lambda_kA(1), lambda_kA(2)), ... 228s sprintf("PDF for sample 2 with estimated λ=%0.2f and k=%0.2f", ... 228s lambda_kB(1), lambda_kB(2)), ... 228s sprintf("PDF for sample 3 with estimated λ=%0.2f and k=%0.2f", ... 228s lambda_kC(1), lambda_kC(2))}) 228s title ("Three population samples from different Weibull distibutions") 228s hold off 228s ***** test 228s x = 1:50; 228s [paramhat, paramci] = wblfit (x); 228s paramhat_out = [28.3636, 1.7130]; 228s paramci_out = [23.9531, 1.3551; 33.5861, 2.1655]; 228s assert (paramhat, paramhat_out, 1e-4); 228s assert (paramci, paramci_out, 1e-4); 228s ***** test 228s x = 1:50; 228s [paramhat, paramci] = wblfit (x, 0.01); 228s paramci_out = [22.7143, 1.2589; 35.4179, 2.3310]; 228s assert (paramci, paramci_out, 1e-4); 228s ***** error wblfit (ones (2,5)); 228s ***** error wblfit ([-1 2 3 4]); 228s ***** error wblfit ([1, 2, 3, 4, 5], 1.2); 228s ***** error wblfit ([1, 2, 3, 4, 5], 0); 228s ***** error wblfit ([1, 2, 3, 4, 5], "alpha"); 228s ***** error ... 228s wblfit ([1, 2, 3, 4, 5], 0.05, [1 1 0]); 228s ***** error ... 228s wblfit ([1, 2, 3, 4, 5], [], [1 1 0 1 1]'); 228s ***** error ... 228s wblfit ([1, 2, 3, 4, 5], 0.05, zeros (1,5), [1 1 0]); 228s ***** error ... 228s wblfit ([1, 2, 3, 4, 5], [], [], [1 1 0 -1 1]); 228s ***** error ... 228s wblfit ([1, 2, 3, 4, 5], [], [], [1 1 0 1 1]'); 228s ***** error ... 228s wblfit ([1, 2, 3, 4, 5], 0.05, [], [], 2); 228s 13 tests, 13 passed, 0 known failure, 0 skipped 228s [inst/dist_fit/ricefit.m] 228s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fit/ricefit.m 228s ***** demo 228s ## Sample 3 populations from different Gamma distibutions 228s randg ("seed", 5); # for reproducibility 228s randp ("seed", 6); 228s r1 = ricernd (1, 2, 3000, 1); 228s randg ("seed", 2); # for reproducibility 228s randp ("seed", 8); 228s r2 = ricernd (2, 4, 3000, 1); 228s randg ("seed", 7); # for reproducibility 228s randp ("seed", 9); 228s r3 = ricernd (7.5, 1, 3000, 1); 228s r = [r1, r2, r3]; 228s 228s ## Plot them normalized and fix their colors 228s hist (r, 75, 4); 228s h = findobj (gca, "Type", "patch"); 228s set (h(1), "facecolor", "c"); 228s set (h(2), "facecolor", "g"); 228s set (h(3), "facecolor", "r"); 228s ylim ([0, 0.7]); 228s xlim ([0, 12]); 228s hold on 228s 228s ## Estimate their α and β parameters 228s s_sigmaA = ricefit (r(:,1)); 228s s_sigmaB = ricefit (r(:,2)); 228s s_sigmaC = ricefit (r(:,3)); 228s 228s ## Plot their estimated PDFs 228s x = [0.01,0.1:0.2:18]; 228s y = ricepdf (x, s_sigmaA(1), s_sigmaA(2)); 228s plot (x, y, "-pr"); 228s y = ricepdf (x, s_sigmaB(1), s_sigmaB(2)); 228s plot (x, y, "-sg"); 228s y = ricepdf (x, s_sigmaC(1), s_sigmaC(2)); 228s plot (x, y, "-^c"); 228s hold off 228s legend ({"Normalized HIST of sample 1 with s=1 and σ=2", ... 228s "Normalized HIST of sample 2 with s=2 and σ=4", ... 228s "Normalized HIST of sample 3 with s=7.5 and σ=1", ... 228s sprintf("PDF for sample 1 with estimated s=%0.2f and σ=%0.2f", ... 228s s_sigmaA(1), s_sigmaA(2)), ... 228s sprintf("PDF for sample 2 with estimated s=%0.2f and σ=%0.2f", ... 228s s_sigmaB(1), s_sigmaB(2)), ... 228s sprintf("PDF for sample 3 with estimated s=%0.2f and σ=%0.2f", ... 228s s_sigmaC(1), s_sigmaC(2))}) 228s title ("Three population samples from different Rician distibutions") 228s hold off 228s ***** test 228s [paramhat, paramci] = ricefit ([1:50]); 228s assert (paramhat, [15.3057, 17.6668], 1e-4); 228s assert (paramci, [9.5468, 11.7802; 24.5383, 26.4952], 1e-4); 228s ***** test 228s [paramhat, paramci] = ricefit ([1:50], 0.01); 228s assert (paramhat, [15.3057, 17.6668], 1e-4); 228s assert (paramci, [8.2309, 10.3717; 28.4615, 30.0934], 1e-4); 228s ***** test 228s [paramhat, paramci] = ricefit ([1:5]); 228s assert (paramhat, [2.3123, 1.6812], 1e-4); 228s assert (paramci, [1.0819, 0.6376; 4.9424, 4.4331], 1e-4); 228s ***** test 228s [paramhat, paramci] = ricefit ([1:5], 0.01); 228s assert (paramhat, [2.3123, 1.6812], 1e-4); 228s assert (paramci, [0.8521, 0.4702; 6.2747, 6.0120], 1e-4); 228s ***** test 228s freq = [1 1 1 1 5]; 228s [paramhat, paramci] = ricefit ([1:5], [], [], freq); 228s assert (paramhat, [3.5181, 1.5565], 1e-4); 228s assert (paramci, [2.5893, 0.9049; 4.7801, 2.6772], 1e-4); 228s ***** test 228s censor = [1 0 0 0 0]; 228s [paramhat, paramci] = ricefit ([1:5], [], censor); 228s assert (paramhat, [3.2978, 1.1527], 1e-4); 228s assert (paramci, [2.3192, 0.5476; 4.6895, 2.4261], 1e-4); 229s ***** assert (class (ricefit (single ([1:50]))), "single") 229s ***** error ricefit (ones (2)) 229s ***** error ricefit ([1:50], 1) 229s ***** error ricefit ([1:50], -1) 229s ***** error ricefit ([1:50], {0.05}) 229s ***** error ricefit ([1:50], "k") 229s ***** error ricefit ([1:50], i) 229s ***** error ricefit ([1:50], [0.01 0.02]) 229s ***** error ricefit ([1:50], [], [1 1]) 229s ***** error ricefit ([1:50], [], [], [1 1]) 229s ***** error ... 229s ricefit ([1:5], [], [], [1, 1, 2, 1, -1]) 229s ***** error ricefit ([1 2 3 -4]) 229s ***** error ricefit ([1 2 0], [], [1 0 0]) 229s 19 tests, 19 passed, 0 known failure, 0 skipped 229s [inst/dist_fit/normfit.m] 229s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fit/normfit.m 229s ***** demo 229s ## Sample 3 populations from 3 different normal distibutions 229s randn ("seed", 1); # for reproducibility 229s r1 = normrnd (2, 5, 5000, 1); 229s randn ("seed", 2); # for reproducibility 229s r2 = normrnd (5, 2, 5000, 1); 229s randn ("seed", 3); # for reproducibility 229s r3 = normrnd (9, 4, 5000, 1); 229s r = [r1, r2, r3]; 229s 229s ## Plot them normalized and fix their colors 229s hist (r, 15, 0.4); 229s h = findobj (gca, "Type", "patch"); 229s set (h(1), "facecolor", "c"); 229s set (h(2), "facecolor", "g"); 229s set (h(3), "facecolor", "r"); 229s hold on 229s 229s ## Estimate their mu and sigma parameters 229s [muhat, sigmahat] = normfit (r); 229s 229s ## Plot their estimated PDFs 229s x = [min(r(:)):max(r(:))]; 229s y = normpdf (x, muhat(1), sigmahat(1)); 229s plot (x, y, "-pr"); 229s y = normpdf (x, muhat(2), sigmahat(2)); 229s plot (x, y, "-sg"); 229s y = normpdf (x, muhat(3), sigmahat(3)); 229s plot (x, y, "-^c"); 229s ylim ([0, 0.5]) 229s xlim ([-20, 20]) 229s hold off 229s legend ({"Normalized HIST of sample 1 with mu=2, σ=5", ... 229s "Normalized HIST of sample 2 with mu=5, σ=2", ... 229s "Normalized HIST of sample 3 with mu=9, σ=4", ... 229s sprintf("PDF for sample 1 with estimated mu=%0.2f and σ=%0.2f", ... 229s muhat(1), sigmahat(1)), ... 229s sprintf("PDF for sample 2 with estimated mu=%0.2f and σ=%0.2f", ... 229s muhat(2), sigmahat(2)), ... 229s sprintf("PDF for sample 3 with estimated mu=%0.2f and σ=%0.2f", ... 229s muhat(3), sigmahat(3))}, "location", "northwest") 229s title ("Three population samples from different normal distibutions") 229s hold off 229s ***** test 229s load lightbulb 229s idx = find (lightbulb(:,2) == 0); 229s censoring = lightbulb(idx,3) == 1; 229s [muHat, sigmaHat] = normfit (lightbulb(idx,1), [], censoring); 229s assert (muHat, 9496.59586737857, 1e-11); 229s assert (sigmaHat, 3064.021012796456, 2e-12); 229s ***** test 229s randn ("seed", 234); 229s x = normrnd (3, 5, [1000, 1]); 229s [muHat, sigmaHat, muCI, sigmaCI] = normfit (x, 0.01); 229s assert (muCI(1) < 3); 229s assert (muCI(2) > 3); 229s assert (sigmaCI(1) < 5); 229s assert (sigmaCI(2) > 5); 229s ***** error ... 229s normfit (ones (3,3,3)) 229s ***** error ... 229s normfit (ones (20,3), [], zeros (20,1)) 229s ***** error normfit (ones (20,1), 0) 229s ***** error normfit (ones (20,1), -0.3) 229s ***** error normfit (ones (20,1), 1.2) 229s ***** error normfit (ones (20,1), [0.05 0.1]) 229s ***** error normfit (ones (20,1), 0.02+i) 229s ***** error ... 229s normfit (ones (20,1), [], zeros(15,1)) 229s ***** error ... 229s normfit (ones (20,1), [], zeros(20,1), ones(25,1)) 229s ***** error ... 229s normfit (ones (5,1), [], zeros(5,1), [1, 2, 1, 2, -1]') 229s ***** error normfit (ones (20,1), [], zeros(20,1), ones(20,1), "options") 229s 13 tests, 13 passed, 0 known failure, 0 skipped 229s [inst/dist_fit/gumbelfit.m] 229s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fit/gumbelfit.m 229s ***** demo 229s ## Sample 3 populations from different Gumbel distibutions 229s rand ("seed", 1); # for reproducibility 229s r1 = gumbelrnd (2, 5, 400, 1); 229s rand ("seed", 11); # for reproducibility 229s r2 = gumbelrnd (-5, 3, 400, 1); 229s rand ("seed", 16); # for reproducibility 229s r3 = gumbelrnd (14, 8, 400, 1); 229s r = [r1, r2, r3]; 229s 229s ## Plot them normalized and fix their colors 229s hist (r, 25, 0.32); 229s h = findobj (gca, "Type", "patch"); 229s set (h(1), "facecolor", "c"); 229s set (h(2), "facecolor", "g"); 229s set (h(3), "facecolor", "r"); 229s ylim ([0, 0.28]) 229s xlim ([-11, 50]); 229s hold on 229s 229s ## Estimate their MU and BETA parameters 229s mu_betaA = gumbelfit (r(:,1)); 229s mu_betaB = gumbelfit (r(:,2)); 229s mu_betaC = gumbelfit (r(:,3)); 229s 229s ## Plot their estimated PDFs 229s x = [min(r(:)):max(r(:))]; 229s y = gumbelpdf (x, mu_betaA(1), mu_betaA(2)); 229s plot (x, y, "-pr"); 229s y = gumbelpdf (x, mu_betaB(1), mu_betaB(2)); 229s plot (x, y, "-sg"); 229s y = gumbelpdf (x, mu_betaC(1), mu_betaC(2)); 229s plot (x, y, "-^c"); 229s legend ({"Normalized HIST of sample 1 with μ=2 and β=5", ... 229s "Normalized HIST of sample 2 with μ=-5 and β=3", ... 229s "Normalized HIST of sample 3 with μ=14 and β=8", ... 229s sprintf("PDF for sample 1 with estimated μ=%0.2f and β=%0.2f", ... 229s mu_betaA(1), mu_betaA(2)), ... 229s sprintf("PDF for sample 2 with estimated μ=%0.2f and β=%0.2f", ... 229s mu_betaB(1), mu_betaB(2)), ... 229s sprintf("PDF for sample 3 with estimated μ=%0.2f and β=%0.2f", ... 229s mu_betaC(1), mu_betaC(2))}) 229s title ("Three population samples from different Gumbel distibutions") 229s hold off 229s ***** test 229s x = 1:50; 229s [paramhat, paramci] = gumbelfit (x); 229s paramhat_out = [18.3188, 13.0509]; 229s paramci_out = [14.4882, 10.5294; 22.1495, 16.1763]; 229s assert (paramhat, paramhat_out, 1e-4); 229s assert (paramci, paramci_out, 1e-4); 229s ***** test 229s x = 1:50; 229s [paramhat, paramci] = gumbelfit (x, 0.01); 229s paramci_out = [13.2845, 9.8426; 23.3532, 17.3051]; 229s assert (paramci, paramci_out, 1e-4); 229s ***** error gumbelfit (ones (2,5)); 229s ***** error ... 229s gumbelfit (single (ones (1,5))); 229s ***** error ... 229s gumbelfit ([1, 2, 3, 4, NaN]); 229s ***** error gumbelfit ([1, 2, 3, 4, 5], 1.2); 229s ***** error ... 229s gumbelfit ([1, 2, 3, 4, 5], 0.05, [1 1 0]); 229s ***** error ... 229s gumbelfit ([1, 2, 3, 4, 5], 0.05, [], [1 1 0]); 229s ***** error 229s gamfit ([1, 2, 3], 0.05, [], [1 5 -1]) 229s ***** error ... 229s gumbelfit ([1, 2, 3, 4, 5], 0.05, [], [], 2); 229s 10 tests, 10 passed, 0 known failure, 0 skipped 229s [inst/dist_fit/gumbellike.m] 229s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fit/gumbellike.m 229s ***** test 229s x = 1:50; 229s [nlogL, avar] = gumbellike ([2.3, 1.2], x); 229s avar_out = [-1.2778e-13, 3.1859e-15; 3.1859e-15, -7.9430e-17]; 229s assert (nlogL, 3.242264755689906e+17, 1e-14); 229s assert (avar, avar_out, 1e-3); 229s ***** test 229s x = 1:50; 229s [nlogL, avar] = gumbellike ([2.3, 1.2], x * 0.5); 229s avar_out = [-7.6094e-05, 3.9819e-06; 3.9819e-06, -2.0836e-07]; 229s assert (nlogL, 481898704.0472211, 1e-6); 229s assert (avar, avar_out, 1e-3); 229s ***** test 229s x = 1:50; 229s [nlogL, avar] = gumbellike ([21, 15], x); 229s avar_out = [11.73913876598908, -5.9546128523121216; ... 229s -5.954612852312121, 3.708060045170236]; 229s assert (nlogL, 223.7612479380652, 1e-13); 229s assert (avar, avar_out, 1e-14); 229s ***** error gumbellike ([12, 15]); 229s ***** error gumbellike ([12, 15, 3], [1:50]); 229s ***** error gumbellike ([12, 3], ones (10, 2)); 229s ***** error gumbellike ([12, 15], [1:50], [1, 2, 3]); 229s ***** error gumbellike ([12, 15], [1:50], [], [1, 2, 3]); 229s 8 tests, 8 passed, 0 known failure, 0 skipped 229s [inst/dist_fit/evfit.m] 229s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fit/evfit.m 229s ***** demo 229s ## Sample 3 populations from different extreme value distibutions 229s rand ("seed", 1); # for reproducibility 229s r1 = evrnd (2, 5, 400, 1); 229s rand ("seed", 12); # for reproducibility 229s r2 = evrnd (-5, 3, 400, 1); 229s rand ("seed", 13); # for reproducibility 229s r3 = evrnd (14, 8, 400, 1); 229s r = [r1, r2, r3]; 229s 229s ## Plot them normalized and fix their colors 229s hist (r, 25, 0.4); 229s h = findobj (gca, "Type", "patch"); 229s set (h(1), "facecolor", "c"); 229s set (h(2), "facecolor", "g"); 229s set (h(3), "facecolor", "r"); 229s ylim ([0, 0.28]) 229s xlim ([-30, 30]); 229s hold on 229s 229s ## Estimate their MU and SIGMA parameters 229s mu_sigmaA = evfit (r(:,1)); 229s mu_sigmaB = evfit (r(:,2)); 229s mu_sigmaC = evfit (r(:,3)); 229s 229s ## Plot their estimated PDFs 229s x = [min(r(:)):max(r(:))]; 229s y = evpdf (x, mu_sigmaA(1), mu_sigmaA(2)); 229s plot (x, y, "-pr"); 229s y = evpdf (x, mu_sigmaB(1), mu_sigmaB(2)); 229s plot (x, y, "-sg"); 229s y = evpdf (x, mu_sigmaC(1), mu_sigmaC(2)); 229s plot (x, y, "-^c"); 229s legend ({"Normalized HIST of sample 1 with μ=2 and σ=5", ... 229s "Normalized HIST of sample 2 with μ=-5 and σ=3", ... 229s "Normalized HIST of sample 3 with μ=14 and σ=8", ... 229s sprintf("PDF for sample 1 with estimated μ=%0.2f and σ=%0.2f", ... 229s mu_sigmaA(1), mu_sigmaA(2)), ... 229s sprintf("PDF for sample 2 with estimated μ=%0.2f and σ=%0.2f", ... 229s mu_sigmaB(1), mu_sigmaB(2)), ... 229s sprintf("PDF for sample 3 with estimated μ=%0.2f and σ=%0.2f", ... 229s mu_sigmaC(1), mu_sigmaC(2))}) 229s title ("Three population samples from different extreme value distibutions") 229s hold off 229s ***** test 229s x = 1:50; 229s [paramhat, paramci] = evfit (x); 229s paramhat_out = [32.6811, 13.0509]; 229s paramci_out = [28.8504, 10.5294; 36.5118, 16.1763]; 229s assert (paramhat, paramhat_out, 1e-4); 229s assert (paramci, paramci_out, 1e-4); 229s ***** test 229s x = 1:50; 229s [paramhat, paramci] = evfit (x, 0.01); 229s paramci_out = [27.6468, 9.8426; 37.7155, 17.3051]; 229s assert (paramci, paramci_out, 1e-4); 229s ***** error evfit (ones (2,5)); 229s ***** error evfit (single (ones (1,5))); 229s ***** error evfit ([1, 2, 3, 4, NaN]); 229s ***** error evfit ([1, 2, 3, 4, 5], 1.2); 229s ***** error 229s evfit ([1 2 3], 0.05, [], [1 5]) 229s ***** error 229s evfit ([1 2 3], 0.05, [], [1 5 -1]) 229s ***** error ... 229s evfit ([1:10], 0.05, [], [], 5) 229s 9 tests, 9 passed, 0 known failure, 0 skipped 229s [inst/dist_fit/burrfit.m] 229s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fit/burrfit.m 229s ***** demo 229s ## Sample 3 populations from different Burr type XII distibutions 229s rand ("seed", 4); # for reproducibility 229s r1 = burrrnd (3.5, 2, 2.5, 10000, 1); 229s rand ("seed", 2); # for reproducibility 229s r2 = burrrnd (1, 3, 1, 10000, 1); 229s rand ("seed", 9); # for reproducibility 229s r3 = burrrnd (0.5, 2, 3, 10000, 1); 229s r = [r1, r2, r3]; 229s 229s ## Plot them normalized and fix their colors 229s hist (r, [0.1:0.2:20], [18, 5, 3]); 229s h = findobj (gca, "Type", "patch"); 229s set (h(1), "facecolor", "c"); 229s set (h(2), "facecolor", "g"); 229s set (h(3), "facecolor", "r"); 229s ylim ([0, 3]); 229s xlim ([0, 5]); 229s hold on 229s 229s ## Estimate their α and β parameters 229s lambda_c_kA = burrfit (r(:,1)); 229s lambda_c_kB = burrfit (r(:,2)); 229s lambda_c_kC = burrfit (r(:,3)); 229s 229s ## Plot their estimated PDFs 229s x = [0.01:0.15:15]; 229s y = burrpdf (x, lambda_c_kA(1), lambda_c_kA(2), lambda_c_kA(3)); 229s plot (x, y, "-pr"); 229s y = burrpdf (x, lambda_c_kB(1), lambda_c_kB(2), lambda_c_kB(3)); 229s plot (x, y, "-sg"); 229s y = burrpdf (x, lambda_c_kC(1), lambda_c_kC(2), lambda_c_kC(3)); 229s plot (x, y, "-^c"); 229s hold off 229s legend ({"Normalized HIST of sample 1 with λ=3.5, c=2, and k=2.5", ... 229s "Normalized HIST of sample 2 with λ=1, c=3, and k=1", ... 229s "Normalized HIST of sample 3 with λ=0.5, c=2, and k=3", ... 229s sprintf("PDF for sample 1 with estimated λ=%0.2f, c=%0.2f, and k=%0.2f", ... 229s lambda_c_kA(1), lambda_c_kA(2), lambda_c_kA(3)), ... 229s sprintf("PDF for sample 2 with estimated λ=%0.2f, c=%0.2f, and k=%0.2f", ... 229s lambda_c_kB(1), lambda_c_kB(2), lambda_c_kB(3)), ... 229s sprintf("PDF for sample 3 with estimated λ=%0.2f, c=%0.2f, and k=%0.2f", ... 229s lambda_c_kC(1), lambda_c_kC(2), lambda_c_kC(3))}) 229s title ("Three population samples from different Burr type XII distibutions") 229s hold off 229s ***** test 229s l = 1; c = 2; k = 3; 229s r = burrrnd (l, c, k, 100000, 1); 229s lambda_c_kA = burrfit (r); 229s assert (lambda_c_kA(1), l, 0.2); 229s assert (lambda_c_kA(2), c, 0.2); 229s assert (lambda_c_kA(3), k, 0.3); 232s ***** test 232s l = 0.5; c = 1; k = 3; 232s r = burrrnd (l, c, k, 100000, 1); 232s lambda_c_kA = burrfit (r); 232s assert (lambda_c_kA(1), l, 0.2); 232s assert (lambda_c_kA(2), c, 0.2); 232s assert (lambda_c_kA(3), k, 0.3); 235s ***** test 235s l = 1; c = 3; k = 1; 235s r = burrrnd (l, c, k, 100000, 1); 235s lambda_c_kA = burrfit (r); 235s assert (lambda_c_kA(1), l, 0.2); 235s assert (lambda_c_kA(2), c, 0.2); 235s assert (lambda_c_kA(3), k, 0.3); 237s ***** test 237s l = 3; c = 2; k = 1; 237s r = burrrnd (l, c, k, 100000, 1); 237s lambda_c_kA = burrfit (r); 237s assert (lambda_c_kA(1), l, 0.2); 237s assert (lambda_c_kA(2), c, 0.2); 237s assert (lambda_c_kA(3), k, 0.3); 240s ***** test 240s l = 4; c = 2; k = 4; 240s r = burrrnd (l, c, k, 100000, 1); 240s lambda_c_kA = burrfit (r); 240s assert (lambda_c_kA(1), l, 0.2); 240s assert (lambda_c_kA(2), c, 0.2); 240s assert (lambda_c_kA(3), k, 0.3); 243s ***** error burrfit (ones (2,5)); 243s ***** error burrfit ([-1 2 3 4]); 243s ***** error burrfit ([1, 2, 3, 4, 5], 1.2); 243s ***** error burrfit ([1, 2, 3, 4, 5], 0); 243s ***** error burrfit ([1, 2, 3, 4, 5], "alpha"); 243s ***** error ... 243s burrfit ([1, 2, 3, 4, 5], 0.05, [1 1 0]); 243s ***** error ... 243s burrfit ([1, 2, 3, 4, 5], [], [1 1 0 1 1]'); 243s ***** error 243s burrfit ([1, 2, 3, 4, 5], 0.05, [], [1, 1, 5]) 243s ***** error 243s burrfit ([1, 2, 3, 4, 5], 0.05, [], [1, 5, 1, 1, -1]) 243s ***** error ... 243s burrfit ([1:10], 0.05, [], [], 5) 243s 15 tests, 15 passed, 0 known failure, 0 skipped 243s [inst/dist_fit/unidfit.m] 243s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fit/unidfit.m 243s ***** demo 243s ## Sample 2 populations from different discrete uniform distibutions 243s rand ("seed", 1); # for reproducibility 243s r1 = unidrnd (5, 1000, 1); 243s rand ("seed", 2); # for reproducibility 243s r2 = unidrnd (9, 1000, 1); 243s r = [r1, r2]; 243s 243s ## Plot them normalized and fix their colors 243s hist (r, 0:0.5:20.5, 1); 243s h = findobj (gca, "Type", "patch"); 243s set (h(1), "facecolor", "c"); 243s set (h(2), "facecolor", "g"); 243s hold on 243s 243s ## Estimate their probability of success 243s NhatA = unidfit (r(:,1)); 243s NhatB = unidfit (r(:,2)); 243s 243s ## Plot their estimated PDFs 243s x = [0:10]; 243s y = unidpdf (x, NhatA); 243s plot (x, y, "-pg"); 243s y = unidpdf (x, NhatB); 243s plot (x, y, "-sc"); 243s xlim ([0, 10]) 243s ylim ([0, 0.4]) 243s legend ({"Normalized HIST of sample 1 with N=5", ... 243s "Normalized HIST of sample 2 with N=9", ... 243s sprintf("PDF for sample 1 with estimated N=%0.2f", NhatA), ... 243s sprintf("PDF for sample 2 with estimated N=%0.2f", NhatB)}) 243s title ("Two population samples from different discrete uniform distibutions") 243s hold off 243s ***** test 243s x = 0:5; 243s [Nhat, Nci] = unidfit (x); 243s assert (Nhat, 5); 243s assert (Nci, [5; 9]); 243s ***** test 243s x = 0:5; 243s [Nhat, Nci] = unidfit (x, [], [1 1 1 1 1 1]); 243s assert (Nhat, 5); 243s assert (Nci, [5; 9]); 243s ***** assert (unidfit ([1 1 2 3]), unidfit ([1 2 3], [] ,[2 1 1])) 243s ***** error unidfit () 243s ***** error unidfit (-1, [1 2 3 3]) 243s ***** error unidfit (1, 0) 243s ***** error unidfit (1, 1.2) 243s ***** error unidfit (1, [0.02 0.05]) 243s ***** error ... 243s unidfit ([1.5, 0.2], [], [0, 0, 0, 0, 0]) 243s ***** error ... 243s unidfit ([1.5, 0.2], [], [1, 1, 1]) 243s ***** error ... 243s unidfit ([1.5, 0.2], [], [1, -1]) 243s 11 tests, 11 passed, 0 known failure, 0 skipped 243s [inst/dist_fit/gpfit.m] 243s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fit/gpfit.m 243s ***** demo 243s ## Sample 2 populations from different generalized Pareto distibutions 243s ## Assume location parameter θ is known 243s theta = 0; 243s rand ("seed", 5); # for reproducibility 243s r1 = gprnd (1, 2, theta, 20000, 1); 243s rand ("seed", 2); # for reproducibility 243s r2 = gprnd (3, 1, theta, 20000, 1); 243s r = [r1, r2]; 243s 243s ## Plot them normalized and fix their colors 243s hist (r, [0.1:0.2:100], 5); 243s h = findobj (gca, "Type", "patch"); 243s set (h(1), "facecolor", "r"); 243s set (h(2), "facecolor", "c"); 243s ylim ([0, 1]); 243s xlim ([0, 5]); 243s hold on 243s 243s ## Estimate their α and β parameters 243s k_sigmaA = gpfit (r(:,1), theta); 243s k_sigmaB = gpfit (r(:,2), theta); 243s 243s ## Plot their estimated PDFs 243s x = [0.01, 0.1:0.2:18]; 243s y = gppdf (x, k_sigmaA(1), k_sigmaA(2), theta); 243s plot (x, y, "-pc"); 243s y = gppdf (x, k_sigmaB(1), k_sigmaB(2), theta); 243s plot (x, y, "-sr"); 243s hold off 243s legend ({"Normalized HIST of sample 1 with k=1 and σ=2", ... 243s "Normalized HIST of sample 2 with k=2 and σ=2", ... 243s sprintf("PDF for sample 1 with estimated k=%0.2f and σ=%0.2f", ... 243s k_sigmaA(1), k_sigmaA(2)), ... 243s sprintf("PDF for sample 3 with estimated k=%0.2f and σ=%0.2f", ... 243s k_sigmaB(1), k_sigmaB(2))}) 243s title ("Three population samples from different generalized Pareto distibutions") 243s text (2, 0.7, "Known location parameter θ = 0") 243s hold off 243s ***** test 243s k = 0.8937; sigma = 1.3230; theta = 1; 243s x = [2.2196, 11.9301, 4.3673, 1.0949, 6.5626, ... 243s 1.2109, 1.8576, 1.0039, 12.7917, 2.2590]; 243s [hat, ci] = gpfit (x, theta); 243s assert (hat, [k, sigma, theta], 1e-4); 243s assert (ci, [-0.7750, 0.2437, 1; 2.5624, 7.1820, 1], 1e-4); 243s ***** error gpfit () 243s ***** error gpfit (1) 243s ***** error gpfit ([0.2, 0.5+i], 0); 243s ***** error gpfit (ones (2,2) * 0.5, 0); 243s ***** error ... 243s gpfit ([0.5, 1.2], [0, 1]); 243s ***** error ... 243s gpfit ([0.5, 1.2], 5+i); 243s ***** error ... 243s gpfit ([1:5], 2); 243s ***** error gpfit ([0.01:0.1:0.99], 0, 1.2); 243s ***** error gpfit ([0.01:0.1:0.99], 0, i); 243s ***** error gpfit ([0.01:0.1:0.99], 0, -1); 243s ***** error gpfit ([0.01:0.1:0.99], 0, [0.05, 0.01]); 243s ***** error 243s gpfit ([1 2 3], 0, [], [1 5]) 243s ***** error 243s gpfit ([1 2 3], 0, [], [1 5 -1]) 243s ***** error ... 243s gpfit ([1:10], 1, 0.05, [], 5) 243s 15 tests, 15 passed, 0 known failure, 0 skipped 243s [inst/dist_fit/gevfit.m] 243s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fit/gevfit.m 243s ***** demo 243s ## Sample 2 populations from 2 different exponential distibutions 243s rand ("seed", 1); # for reproducibility 243s r1 = gevrnd (-0.5, 1, 2, 5000, 1); 243s rand ("seed", 2); # for reproducibility 243s r2 = gevrnd (0, 1, -4, 5000, 1); 243s r = [r1, r2]; 243s 243s ## Plot them normalized and fix their colors 243s hist (r, 50, 5); 243s h = findobj (gca, "Type", "patch"); 243s set (h(1), "facecolor", "c"); 243s set (h(2), "facecolor", "g"); 243s hold on 243s 243s ## Estimate their k, sigma, and mu parameters 243s k_sigma_muA = gevfit (r(:,1)); 243s k_sigma_muB = gevfit (r(:,2)); 243s 243s ## Plot their estimated PDFs 243s x = [-10:0.5:20]; 243s y = gevpdf (x, k_sigma_muA(1), k_sigma_muA(2), k_sigma_muA(3)); 243s plot (x, y, "-pr"); 243s y = gevpdf (x, k_sigma_muB(1), k_sigma_muB(2), k_sigma_muB(3)); 243s plot (x, y, "-sg"); 243s ylim ([0, 0.7]) 243s xlim ([-7, 5]) 243s legend ({"Normalized HIST of sample 1 with k=-0.5, σ=1, μ=2", ... 243s "Normalized HIST of sample 2 with k=0, σ=1, μ=-4", 243s sprintf("PDF for sample 1 with estimated k=%0.2f, σ=%0.2f, μ=%0.2f", ... 243s k_sigma_muA(1), k_sigma_muA(2), k_sigma_muA(3)), ... 243s sprintf("PDF for sample 3 with estimated k=%0.2f, σ=%0.2f, μ=%0.2f", ... 243s k_sigma_muB(1), k_sigma_muB(2), k_sigma_muB(3))}) 243s title ("Two population samples from different exponential distibutions") 243s hold off 243s ***** test 243s x = 1:50; 243s [pfit, pci] = gevfit (x); 243s pfit_out = [-0.4407, 15.1923, 21.5309]; 243s pci_out = [-0.7532, 11.5878, 16.5686; -0.1282, 19.9183, 26.4926]; 243s assert (pfit, pfit_out, 1e-3); 243s assert (pci, pci_out, 1e-3); 243s ***** test 243s x = 1:2:50; 243s [pfit, pci] = gevfit (x); 243s pfit_out = [-0.4434, 15.2024, 21.0532]; 243s pci_out = [-0.8904, 10.3439, 14.0168; 0.0035, 22.3429, 28.0896]; 243s assert (pfit, pfit_out, 1e-3); 243s assert (pci, pci_out, 1e-3); 243s ***** error gevfit (ones (2,5)); 243s ***** error gevfit ([1, 2, 3, 4, 5], 1.2); 243s ***** error gevfit ([1, 2, 3, 4, 5], 0); 243s ***** error gevfit ([1, 2, 3, 4, 5], "alpha"); 243s ***** error ... 243s gevfit ([1, 2, 3, 4, 5], 0.05, [1, 2, 3, 2]); 243s ***** error ... 243s gevfit ([1, 2, 3, 4, 5], 0.05, [1, 2, 3, 2, -1]); 243s ***** error ... 243s gevfit ([1, 2, 3, 4, 5], 0.05, [1, 2, 3, 2, 1.5]); 243s ***** error ... 243s gevfit ([1, 2, 3, 4, 5], 0.05, struct ("option", 234)); 243s ***** error ... 243s gevfit ([1, 2, 3, 4, 5], 0.05, ones (1,5), struct ("option", 234)); 243s 11 tests, 11 passed, 0 known failure, 0 skipped 243s [inst/dist_fit/nakalike.m] 243s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fit/nakalike.m 243s ***** test 243s nlogL = nakalike ([0.735504, 858.5], [1:50]); 243s assert (nlogL, 202.8689, 1e-4); 243s ***** test 243s nlogL = nakalike ([1.17404, 11], [1:5]); 243s assert (nlogL, 8.6976, 1e-4); 243s ***** test 243s nlogL = nakalike ([1.17404, 11], [1:5], [], [1, 1, 1, 1, 1]); 243s assert (nlogL, 8.6976, 1e-4); 243s ***** test 243s nlogL = nakalike ([1.17404, 11], [1:6], [], [1, 1, 1, 1, 1, 0]); 243s assert (nlogL, 8.6976, 1e-4); 243s ***** error nakalike (3.25) 243s ***** error nakalike ([5, 0.2], ones (2)) 243s ***** error ... 243s nakalike ([1, 0.2, 3], [1, 3, 5, 7]) 243s ***** error ... 243s nakalike ([1.5, 0.2], [1:5], [0, 0, 0]) 243s ***** error ... 243s nakalike ([1.5, 0.2], [1:5], [0, 0, 0, 0, 0], [1, 1, 1]) 243s ***** error ... 243s nakalike ([1.5, 0.2], [1:5], [], [1, 1, 1]) 243s ***** error ... 243s nakalike ([1.5, 0.2], [1:5], [], [1, 1, 1, 1, -1]) 243s 11 tests, 11 passed, 0 known failure, 0 skipped 243s [inst/dist_fit/normlike.m] 243s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fit/normlike.m 243s ***** error normlike ([12, 15]); 243s ***** error normlike ([12, 15], ones (2)); 243s ***** error ... 243s normlike ([12, 15, 3], [1:50]); 243s ***** error ... 243s normlike ([12, 15], [1:50], [1, 2, 3]); 243s ***** error ... 243s normlike ([12, 15], [1:50], [], [1, 2, 3]); 243s ***** error ... 243s normlike ([12, 15], [1:5], [], [1, 2, 3, 2, -1]); 243s ***** test 243s x = 1:50; 243s [nlogL, avar] = normlike ([2.3, 1.2], x); 243s avar_out = [7.5767e-01, -1.8850e-02; -1.8850e-02, 4.8750e-04]; 243s assert (nlogL, 13014.95883783327, 1e-10); 243s assert (avar, avar_out, 1e-4); 243s ***** test 243s x = 1:50; 243s [nlogL, avar] = normlike ([2.3, 1.2], x * 0.5); 243s avar_out = [3.0501e-01, -1.5859e-02; -1.5859e-02, 9.1057e-04]; 243s assert (nlogL, 2854.802587833265, 1e-10); 243s assert (avar, avar_out, 1e-4); 243s ***** test 243s x = 1:50; 243s [nlogL, avar] = normlike ([21, 15], x); 243s avar_out = [5.460474308300396, -1.600790513833993; ... 243s -1.600790513833993, 2.667984189723321]; 243s assert (nlogL, 206.738325604233, 1e-12); 243s assert (avar, avar_out, 1e-14); 243s ***** test 243s x = 1:50; 243s censor = ones (1, 50); 243s censor([2, 4, 6, 8, 12, 14]) = 0; 243s [nlogL, avar] = normlike ([2.3, 1.2], x, censor); 243s avar_out = [3.0501e-01, -1.5859e-02; -1.5859e-02, 9.1057e-04]; 243s assert (nlogL, Inf); 243s assert (avar, [NaN, NaN; NaN, NaN]); 243s ***** test 243s x = 1:50; 243s censor = ones (1, 50); 243s censor([2, 4, 6, 8, 12, 14]) = 0; 243s [nlogL, avar] = normlike ([21, 15], x, censor); 243s avar_out = [24.4824488866131, -10.6649544179636; ... 243s -10.6649544179636, 6.22827849965737]; 243s assert (nlogL, 86.9254371829733, 1e-12); 243s assert (avar, avar_out, 8e-14); 243s 11 tests, 11 passed, 0 known failure, 0 skipped 243s [inst/dist_fit/binofit.m] 243s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fit/binofit.m 243s ***** demo 243s ## Sample 2 populations from different binomial distibutions 243s rand ("seed", 1); # for reproducibility 243s r1 = binornd (50, 0.15, 1000, 1); 243s rand ("seed", 2); # for reproducibility 243s r2 = binornd (100, 0.5, 1000, 1); 243s r = [r1, r2]; 243s 243s ## Plot them normalized and fix their colors 243s hist (r, 23, 0.35); 243s h = findobj (gca, "Type", "patch"); 243s set (h(1), "facecolor", "c"); 243s set (h(2), "facecolor", "g"); 243s hold on 243s 243s ## Estimate their probability of success 243s pshatA = binofit (r(:,1), 50); 243s pshatB = binofit (r(:,2), 100); 243s 243s ## Plot their estimated PDFs 243s x = [min(r(:,1)):max(r(:,1))]; 243s y = binopdf (x, 50, mean (pshatA)); 243s plot (x, y, "-pg"); 243s x = [min(r(:,2)):max(r(:,2))]; 243s y = binopdf (x, 100, mean (pshatB)); 243s plot (x, y, "-sc"); 243s ylim ([0, 0.2]) 243s legend ({"Normalized HIST of sample 1 with ps=0.15", ... 243s "Normalized HIST of sample 2 with ps=0.50", ... 243s sprintf("PDF for sample 1 with estimated ps=%0.2f", ... 243s mean (pshatA)), ... 243s sprintf("PDF for sample 2 with estimated ps=%0.2f", ... 243s mean (pshatB))}) 243s title ("Two population samples from different binomial distibutions") 243s hold off 243s ***** test 243s x = 0:3; 243s [pshat, psci] = binofit (x, 3); 243s assert (pshat, [0, 0.3333, 0.6667, 1], 1e-4); 243s assert (psci(1,:), [0, 0.7076], 1e-4); 243s assert (psci(2,:), [0.0084, 0.9057], 1e-4); 243s assert (psci(3,:), [0.0943, 0.9916], 1e-4); 243s assert (psci(4,:), [0.2924, 1.0000], 1e-4); 243s ***** error ... 243s binofit ([1 2 3 4]) 243s ***** error ... 243s binofit ([-1, 4, 3, 2], [1, 2, 3, 3]) 243s ***** error binofit (ones(2), [1, 2, 3, 3]) 243s ***** error ... 243s binofit ([1, 4, 3, 2], [1, 2, -1, 3]) 243s ***** error ... 243s binofit ([1, 4, 3, 2], [5, 5, 5]) 243s ***** error ... 243s binofit ([1, 4, 3, 2], [5, 3, 5, 5]) 243s ***** error binofit ([1, 2, 1], 3, 1.2); 243s ***** error binofit ([1, 2, 1], 3, 0); 243s ***** error binofit ([1, 2, 1], 3, "alpha"); 243s 10 tests, 10 passed, 0 known failure, 0 skipped 243s [inst/dist_fit/nbinfit.m] 243s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fit/nbinfit.m 243s ***** demo 243s ## Sample 2 populations from different negative binomial distibutions 243s randp ("seed", 5); randg ("seed", 5); # for reproducibility 243s r1 = nbinrnd (2, 0.15, 5000, 1); 243s randp ("seed", 8); randg ("seed", 8); # for reproducibility 243s r2 = nbinrnd (5, 0.2, 5000, 1); 243s r = [r1, r2]; 243s 243s ## Plot them normalized and fix their colors 243s hist (r, [0:51], 1); 243s h = findobj (gca, "Type", "patch"); 243s set (h(1), "facecolor", "c"); 243s set (h(2), "facecolor", "g"); 243s hold on 243s 243s ## Estimate their probability of success 243s r_psA = nbinfit (r(:,1)); 243s r_psB = nbinfit (r(:,2)); 243s 243s ## Plot their estimated PDFs 243s x = [0:40]; 243s y = nbinpdf (x, r_psA(1), r_psA(2)); 243s plot (x, y, "-pg"); 243s x = [min(r(:,2)):max(r(:,2))]; 243s y = nbinpdf (x, r_psB(1), r_psB(2)); 243s plot (x, y, "-sc"); 243s ylim ([0, 0.1]) 243s xlim ([0, 50]) 243s legend ({"Normalized HIST of sample 1 with r=2 and ps=0.15", ... 243s "Normalized HIST of sample 2 with r=5 and ps=0.2", ... 243s sprintf("PDF for sample 1 with estimated r=%0.2f and ps=%0.2f", ... 243s r_psA(1), r_psA(2)), ... 243s sprintf("PDF for sample 2 with estimated r=%0.2f and ps=%0.2f", ... 243s r_psB(1), r_psB(2))}) 243s title ("Two population samples from negative different binomial distibutions") 243s hold off 243s ***** test 243s [paramhat, paramci] = nbinfit ([1:50]); 243s assert (paramhat, [2.420857, 0.086704], 1e-6); 243s assert (paramci(:,1), [1.382702; 3.459012], 1e-6); 243s assert (paramci(:,2), [0.049676; 0.123732], 1e-6); 243s ***** test 243s [paramhat, paramci] = nbinfit ([1:20]); 243s assert (paramhat, [3.588233, 0.254697], 1e-6); 243s assert (paramci(:,1), [0.451693; 6.724774], 1e-6); 243s assert (paramci(:,2), [0.081143; 0.428251], 1e-6); 243s ***** test 243s [paramhat, paramci] = nbinfit ([1:10]); 243s assert (paramhat, [8.8067, 0.6156], 1e-4); 243s assert (paramci(:,1), [0; 30.7068], 1e-4); 243s assert (paramci(:,2), [0.0217; 1], 1e-4); 243s ***** test 243s [paramhat, paramci] = nbinfit ([1:10], 0.05, ones (1, 10)); 243s assert (paramhat, [8.8067, 0.6156], 1e-4); 243s assert (paramci(:,1), [0; 30.7068], 1e-4); 243s assert (paramci(:,2), [0.0217; 1], 1e-4); 243s ***** test 243s [paramhat, paramci] = nbinfit ([1:11], 0.05, [ones(1, 10), 0]); 243s assert (paramhat, [8.8067, 0.6156], 1e-4); 243s assert (paramci(:,1), [0; 30.7068], 1e-4); 243s assert (paramci(:,2), [0.0217; 1], 1e-4); 244s ***** error nbinfit ([-1 2 3 3]) 244s ***** error nbinfit (ones (2)) 244s ***** error nbinfit ([1 2 1.2 3]) 244s ***** error nbinfit ([1 2 3], 0) 244s ***** error nbinfit ([1 2 3], 1.2) 244s ***** error nbinfit ([1 2 3], [0.02 0.05]) 244s ***** error ... 244s nbinfit ([1, 2, 3, 4, 5], 0.05, [1, 2, 3, 2]); 244s ***** error ... 244s nbinfit ([1, 2, 3, 4, 5], 0.05, [1, 2, 3, 2, -1]); 244s ***** error ... 244s nbinfit ([1, 2, 3, 4, 5], 0.05, [1, 2, 3, 2, 1.5]); 244s ***** error ... 244s nbinfit ([1, 2, 3, 4, 5], 0.05, struct ("option", 234)); 244s ***** error ... 244s nbinfit ([1, 2, 3, 4, 5], 0.05, ones (1,5), struct ("option", 234)); 244s 16 tests, 16 passed, 0 known failure, 0 skipped 244s [inst/dist_fit/evlike.m] 244s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fit/evlike.m 244s ***** test 244s x = 1:50; 244s [nlogL, acov] = evlike ([2.3, 1.2], x); 244s avar_out = [-1.2778e-13, 3.1859e-15; 3.1859e-15, -7.9430e-17]; 244s assert (nlogL, 3.242264755689906e+17, 1e-14); 244s assert (acov, avar_out, 1e-3); 244s ***** test 244s x = 1:50; 244s [nlogL, acov] = evlike ([2.3, 1.2], x * 0.5); 244s avar_out = [-7.6094e-05, 3.9819e-06; 3.9819e-06, -2.0836e-07]; 244s assert (nlogL, 481898704.0472211, 1e-6); 244s assert (acov, avar_out, 1e-3); 244s ***** test 244s x = 1:50; 244s [nlogL, acov] = evlike ([21, 15], x); 244s avar_out = [11.73913876598908, -5.9546128523121216; ... 244s -5.954612852312121, 3.708060045170236]; 244s assert (nlogL, 223.7612479380652, 1e-13); 244s assert (acov, avar_out, 1e-14); 244s ***** error evlike ([12, 15]) 244s ***** error evlike ([12, 15, 3], [1:50]) 244s ***** error evlike ([12, 3], ones (10, 2)) 244s ***** error ... 244s evlike ([12, 15], [1:50], [1, 2, 3]) 244s ***** error ... 244s evlike ([12, 15], [1:50], [], [1, 2, 3]) 244s 8 tests, 8 passed, 0 known failure, 0 skipped 244s [inst/dist_fit/ricelike.m] 244s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fit/ricelike.m 244s ***** test 244s nlogL = ricelike ([15.3057344, 17.6668458], [1:50]); 244s assert (nlogL, 204.5230311010569, 1e-12); 244s ***** test 244s nlogL = ricelike ([2.312346885, 1.681228265], [1:5]); 244s assert (nlogL, 8.65562164930058, 1e-12); 244s ***** error ricelike (3.25) 244s ***** error ricelike ([5, 0.2], ones (2)) 244s ***** error ... 244s ricelike ([1, 0.2, 3], [1, 3, 5, 7]) 244s ***** error ... 244s ricelike ([1.5, 0.2], [1:5], [0, 0, 0]) 244s ***** error ... 244s ricelike ([1.5, 0.2], [1:5], [0, 0, 0, 0, 0], [1, 1, 1]) 244s ***** error ... 244s ricelike ([1.5, 0.2], [1:5], [], [1, 1, 1]) 244s ***** error ... 244s ricelike ([1.5, 0.2], [1:5], [], [1, 1, 1, 0, -1]) 244s 9 tests, 9 passed, 0 known failure, 0 skipped 244s [inst/dist_fit/logilike.m] 244s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fit/logilike.m 244s ***** test 244s nlogL = logilike ([25.5, 8.7725], [1:50]); 244s assert (nlogL, 206.6769, 1e-4); 244s ***** test 244s nlogL = logilike ([3, 0.8645], [1:5]); 244s assert (nlogL, 9.0699, 1e-4); 244s ***** error logilike (3.25) 244s ***** error logilike ([5, 0.2], ones (2)) 244s ***** error ... 244s logilike ([1, 0.2, 3], [1, 3, 5, 7]) 244s ***** error ... 244s logilike ([1.5, 0.2], [1:5], [0, 0, 0]) 244s ***** error ... 244s logilike ([1.5, 0.2], [1:5], [0, 0, 0, 0, 0], [1, 1, 1]) 244s ***** error ... 244s logilike ([1.5, 0.2], [1:5], [], [1, 1, 1]) 244s 8 tests, 8 passed, 0 known failure, 0 skipped 244s [inst/dist_fit/tlslike.m] 244s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fit/tlslike.m 244s ***** test 244s x = [-1.2352, -0.2741, 0.1726, 7.4356, 1.0392, 16.4165]; 244s [nlogL, acov] = tlslike ([0.035893, 0.862711, 0.649261], x); 244s acov_out = [0.2525, 0.0670, 0.0288; ... 244s 0.0670, 0.5724, 0.1786; ... 244s 0.0288, 0.1786, 0.1789]; 244s assert (nlogL, 17.9979636579, 1e-10); 244s assert (acov, acov_out, 1e-4); 244s ***** error tlslike ([12, 15, 1]); 244s ***** error tlslike ([12, 15], [1:50]); 244s ***** error tlslike ([12, 3, 1], ones (10, 2)); 244s ***** error tlslike ([12, 15, 1], [1:50], [1, 2, 3]); 244s ***** error tlslike ([12, 15, 1], [1:50], [], [1, 2, 3]); 244s ***** error tlslike ([12, 15, 1], [1:3], [], [1, 2, -3]); 244s 7 tests, 7 passed, 0 known failure, 0 skipped 244s [inst/dist_fit/gevlike.m] 244s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fit/gevlike.m 244s ***** test 244s x = 1; 244s k = 0.2; 244s sigma = 0.3; 244s mu = 0.5; 244s [L, C] = gevlike ([k sigma mu], x); 244s expected_L = 0.75942; 244s expected_C = [-0.12547 1.77884 1.06731; 1.77884 16.40761 8.48877; 1.06731 8.48877 0.27979]; 244s assert (L, expected_L, 0.001); 244s assert (C, inv (expected_C), 0.001); 244s ***** test 244s x = 1; 244s k = 0; 244s sigma = 0.3; 244s mu = 0.5; 244s [L, C] = gevlike ([k sigma mu], x); 244s expected_L = 0.65157; 244s expected_C = [0.090036 3.41229 2.047337; 3.412229 24.760027 12.510190; 2.047337 12.510190 2.098618]; 244s assert (L, expected_L, 0.001); 244s assert (C, inv (expected_C), 0.001); 244s ***** test 244s x = -5:-1; 244s k = -0.2; 244s sigma = 0.3; 244s mu = 0.5; 244s [L, C] = gevlike ([k sigma mu], x); 244s expected_L = 3786.4; 244s expected_C = [1.6802e-07, 4.6110e-06, 8.7297e-05; ... 244s 4.6110e-06, 7.5693e-06, 1.2034e-05; ... 244s 8.7297e-05, 1.2034e-05, -0.0019125]; 244s assert (L, expected_L, -0.001); 244s assert (C, expected_C, -0.001); 244s ***** test 244s x = -5:0; 244s k = -0.2; 244s sigma = 0.3; 244s mu = 0.5; 244s [L, C] = gevlike ([k sigma mu], x, [1, 1, 1, 1, 1, 0]); 244s expected_L = 3786.4; 244s expected_C = [1.6802e-07, 4.6110e-06, 8.7297e-05; ... 244s 4.6110e-06, 7.5693e-06, 1.2034e-05; ... 244s 8.7297e-05, 1.2034e-05, -0.0019125]; 244s assert (L, expected_L, -0.001); 244s assert (C, expected_C, -0.001); 244s ***** error gevlike (3.25) 244s ***** error gevlike ([1, 2, 3], ones (2)) 244s ***** error ... 244s gevlike ([1, 2], [1, 3, 5, 7]) 244s ***** error ... 244s gevlike ([1, 2, 3, 4], [1, 3, 5, 7]) 244s ***** error ... 244s gevlike ([5, 0.2, 1], ones (10, 1), ones (8,1)) 244s ***** error ... 244s gevlike ([5, 0.2, 1], ones (1, 8), [1 1 1 1 1 1 1 -1]) 244s ***** error ... 244s gevlike ([5, 0.2, 1], ones (1, 8), [1 1 1 1 1 1 1 1.5]) 244s 11 tests, 11 passed, 0 known failure, 0 skipped 244s [inst/dist_fit/nbinlike.m] 244s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fit/nbinlike.m 244s ***** assert (nbinlike ([2.42086, 0.0867043], [1:50]), 205.5942, 1e-4) 244s ***** assert (nbinlike ([3.58823, 0.254697], [1:20]), 63.6435, 1e-4) 244s ***** assert (nbinlike ([8.80671, 0.615565], [1:10]), 24.7410, 1e-4) 244s ***** assert (nbinlike ([22.1756, 0.831306], [1:8]), 17.9528, 1e-4) 244s ***** assert (nbinlike ([22.1756, 0.831306], [1:9], [ones(1,8), 0]), 17.9528, 1e-4) 244s ***** error nbinlike (3.25) 244s ***** error nbinlike ([5, 0.2], ones (2)) 244s ***** error nbinlike ([5, 0.2], [-1, 3]) 244s ***** error ... 244s nbinlike ([1, 0.2, 3], [1, 3, 5, 7]) 244s ***** error nbinlike ([-5, 0.2], [1:15]) 244s ***** error nbinlike ([0, 0.2], [1:15]) 244s ***** error nbinlike ([5, 1.2], [3, 5]) 244s ***** error nbinlike ([5, -0.2], [3, 5]) 244s ***** error ... 244s nbinlike ([5, 0.2], ones (10, 1), ones (8,1)) 244s ***** error ... 244s nbinlike ([5, 0.2], ones (1, 8), [1 1 1 1 1 1 1 -1]) 244s ***** error ... 244s nbinlike ([5, 0.2], ones (1, 8), [1 1 1 1 1 1 1 1.5]) 244s 16 tests, 16 passed, 0 known failure, 0 skipped 244s [inst/dist_fit/invglike.m] 244s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fit/invglike.m 244s ***** test 244s nlogL = invglike ([25.5, 19.6973], [1:50]); 244s assert (nlogL, 219.1516, 1e-4); 244s ***** test 244s nlogL = invglike ([3, 8.1081], [1:5]); 244s assert (nlogL, 9.0438, 1e-4); 244s ***** error invglike (3.25) 244s ***** error invglike ([5, 0.2], ones (2)) 244s ***** error invglike ([5, 0.2], [-1, 3]) 244s ***** error ... 244s invglike ([1, 0.2, 3], [1, 3, 5, 7]) 244s ***** error ... 244s invglike ([1.5, 0.2], [1:5], [0, 0, 0]) 244s ***** error ... 244s invglike ([1.5, 0.2], [1:5], [0, 0, 0, 0, 0], [1, 1, 1]) 244s ***** error ... 244s invglike ([1.5, 0.2], [1:5], [], [1, 1, 1]) 244s 9 tests, 9 passed, 0 known failure, 0 skipped 244s [inst/dist_fit/tlsfit.m] 244s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fit/tlsfit.m 244s ***** demo 244s ## Sample 3 populations from 3 different location-scale T distibutions 244s randn ("seed", 1); # for reproducibility 244s randg ("seed", 2); # for reproducibility 244s r1 = tlsrnd (-4, 3, 1, 2000, 1); 244s randn ("seed", 3); # for reproducibility 244s randg ("seed", 4); # for reproducibility 244s r2 = tlsrnd (0, 3, 1, 2000, 1); 244s randn ("seed", 5); # for reproducibility 244s randg ("seed", 6); # for reproducibility 244s r3 = tlsrnd (5, 5, 4, 2000, 1); 244s r = [r1, r2, r3]; 244s 244s ## Plot them normalized and fix their colors 244s hist (r, [-21:21], [1, 1, 1]); 244s h = findobj (gca, "Type", "patch"); 244s set (h(1), "facecolor", "c"); 244s set (h(2), "facecolor", "g"); 244s set (h(3), "facecolor", "r"); 244s ylim ([0, 0.25]); 244s xlim ([-20, 20]); 244s hold on 244s 244s ## Estimate their lambda parameter 244s mu_sigma_nuA = tlsfit (r(:,1)); 244s mu_sigma_nuB = tlsfit (r(:,2)); 244s mu_sigma_nuC = tlsfit (r(:,3)); 244s 244s ## Plot their estimated PDFs 244s x = [-20:0.1:20]; 244s y = tlspdf (x, mu_sigma_nuA(1), mu_sigma_nuA(2), mu_sigma_nuA(3)); 244s plot (x, y, "-pr"); 244s y = tlspdf (x, mu_sigma_nuB(1), mu_sigma_nuB(2), mu_sigma_nuB(3)); 244s plot (x, y, "-sg"); 244s y = tlspdf (x, mu_sigma_nuC(1), mu_sigma_nuC(2), mu_sigma_nuC(3)); 244s plot (x, y, "-^c"); 244s hold off 244s legend ({"Normalized HIST of sample 1 with μ=0, σ=2 and nu=1", ... 244s "Normalized HIST of sample 2 with μ=5, σ=2 and nu=1", ... 244s "Normalized HIST of sample 3 with μ=3, σ=4 and nu=3", ... 244s sprintf("PDF for sample 1 with estimated μ=%0.2f, σ=%0.2f, and ν=%0.2f", ... 244s mu_sigma_nuA(1), mu_sigma_nuA(2), mu_sigma_nuA(3)), ... 244s sprintf("PDF for sample 2 with estimated μ=%0.2f, σ=%0.2f, and ν=%0.2f", ... 244s mu_sigma_nuB(1), mu_sigma_nuB(2), mu_sigma_nuB(3)), ... 244s sprintf("PDF for sample 3 with estimated μ=%0.2f, σ=%0.2f, and ν=%0.2f", ... 244s mu_sigma_nuC(1), mu_sigma_nuC(2), mu_sigma_nuC(3))}) 244s title ("Three population samples from different location-scale T distibutions") 244s hold off 244s ***** test 244s x = [-1.2352, -0.2741, 0.1726, 7.4356, 1.0392, 16.4165]; 244s [paramhat, paramci] = tlsfit (x); 244s paramhat_out = [0.035893, 0.862711, 0.649261]; 244s paramci_out = [-0.949034, 0.154655, 0.181080; 1.02082, 4.812444, 2.327914]; 244s assert (paramhat, paramhat_out, 1e-6); 244s assert (paramci, paramci_out, 1e-5); 244s ***** test 244s x = [-1.2352, -0.2741, 0.1726, 7.4356, 1.0392, 16.4165]; 244s [paramhat, paramci] = tlsfit (x, 0.01); 244s paramci_out = [-1.2585, 0.0901, 0.1212; 1.3303, 8.2591, 3.4771]; 244s assert (paramci, paramci_out, 1e-4); 244s ***** error tlsfit (ones (2,5)); 244s ***** error tlsfit ([1, 2, 3, 4, 5], 1.2); 244s ***** error tlsfit ([1, 2, 3, 4, 5], 0); 244s ***** error tlsfit ([1, 2, 3, 4, 5], "alpha"); 244s ***** error ... 244s tlsfit ([1, 2, 3, 4, 5], 0.05, [1 1 0]); 244s ***** error ... 244s tlsfit ([1, 2, 3, 4, 5], [], [1 1 0 1 1]'); 244s ***** error ... 244s tlsfit ([1, 2, 3, 4, 5], 0.05, zeros (1,5), [1 1 0]); 244s ***** error ... 244s tlsfit ([1, 2, 3, 4, 5], [], [], [1 1 0 1 1]'); 244s ***** error ... 244s tlsfit ([1, 2, 3, 4, 5], [], [], [1 1 0 1 -1]); 244s ***** error ... 244s tlsfit ([1, 2, 3, 4, 5], 0.05, [], [], 2); 244s 12 tests, 12 passed, 0 known failure, 0 skipped 244s [inst/dist_fit/gplike.m] 245s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fit/gplike.m 245s ***** test 245s k = 0.8937; sigma = 1.3230; theta = 1; 245s x = [2.2196, 11.9301, 4.3673, 1.0949, 6.5626, ... 245s 1.2109, 1.8576, 1.0039, 12.7917, 2.2590]; 245s [nlogL, acov] = gplike ([k, sigma, theta], x); 245s assert (nlogL, 21.736, 1e-3); 245s assert (acov, [0.7249, -0.7351, 0; -0.7351, 1.3040, 0; 0, 0, 0], 1e-4); 245s ***** assert (gplike ([2, 3, 0], 4), 3.047536764863501, 1e-14) 245s ***** assert (gplike ([2, 3, 4], 8), 3.047536764863501, 1e-14) 245s ***** assert (gplike ([1, 2, 0], 4), 2.890371757896165, 1e-14) 245s ***** assert (gplike ([1, 2, 4], 8), 2.890371757896165, 1e-14) 245s ***** assert (gplike ([2, 3, 0], [1:10]), 32.57864322725392, 1e-14) 245s ***** assert (gplike ([2, 3, 2], [1:10] + 2), 32.57864322725392, 1e-14) 245s ***** assert (gplike ([2, 3, 0], [1:10], ones (1,10)), 32.57864322725392, 1e-14) 245s ***** assert (gplike ([1, 2, 0], [1:10]), 31.65666282460443, 1e-14) 245s ***** assert (gplike ([1, 2, 3], [1:10] + 3), 31.65666282460443, 1e-14) 245s ***** assert (gplike ([1, 2, 0], [1:10], ones (1,10)), 31.65666282460443, 1e-14) 245s ***** assert (gplike ([1, NaN, 0], [1:10]), NaN) 245s ***** error gplike () 245s ***** error gplike (1) 245s ***** error gplike ([1, 2, 0], []) 245s ***** error gplike ([1, 2, 0], ones (2)) 245s ***** error gplike (2, [1:10]) 245s ***** error gplike ([2, 3], [1:10]) 245s ***** error ... 245s gplike ([1, 2, 0], ones (10, 1), ones (8,1)) 245s ***** error ... 245s gplike ([1, 2, 0], ones (1, 8), [1 1 1 1 1 1 1 -1]) 245s 20 tests, 20 passed, 0 known failure, 0 skipped 245s [inst/dist_fit/nakafit.m] 245s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fit/nakafit.m 245s ***** demo 245s ## Sample 3 populations from different Nakagami distibutions 245s randg ("seed", 5) # for reproducibility 245s r1 = nakarnd (0.5, 1, 2000, 1); 245s randg ("seed", 2) # for reproducibility 245s r2 = nakarnd (5, 1, 2000, 1); 245s randg ("seed", 7) # for reproducibility 245s r3 = nakarnd (2, 2, 2000, 1); 245s r = [r1, r2, r3]; 245s 245s ## Plot them normalized and fix their colors 245s hist (r, [0.05:0.1:3.5], 10); 245s h = findobj (gca, "Type", "patch"); 245s set (h(1), "facecolor", "c"); 245s set (h(2), "facecolor", "g"); 245s set (h(3), "facecolor", "r"); 245s ylim ([0, 2.5]); 245s xlim ([0, 3.0]); 245s hold on 245s 245s ## Estimate their MU and LAMBDA parameters 245s mu_omegaA = nakafit (r(:,1)); 245s mu_omegaB = nakafit (r(:,2)); 245s mu_omegaC = nakafit (r(:,3)); 245s 245s ## Plot their estimated PDFs 245s x = [0.01:0.1:3.01]; 245s y = nakapdf (x, mu_omegaA(1), mu_omegaA(2)); 245s plot (x, y, "-pr"); 245s y = nakapdf (x, mu_omegaB(1), mu_omegaB(2)); 245s plot (x, y, "-sg"); 245s y = nakapdf (x, mu_omegaC(1), mu_omegaC(2)); 245s plot (x, y, "-^c"); 245s legend ({"Normalized HIST of sample 1 with μ=0.5 and ω=1", ... 245s "Normalized HIST of sample 2 with μ=5 and ω=1", ... 245s "Normalized HIST of sample 3 with μ=2 and ω=2", ... 245s sprintf("PDF for sample 1 with estimated μ=%0.2f and ω=%0.2f", ... 245s mu_omegaA(1), mu_omegaA(2)), ... 245s sprintf("PDF for sample 2 with estimated μ=%0.2f and ω=%0.2f", ... 245s mu_omegaB(1), mu_omegaB(2)), ... 245s sprintf("PDF for sample 3 with estimated μ=%0.2f and ω=%0.2f", ... 245s mu_omegaC(1), mu_omegaC(2))}) 245s title ("Three population samples from different Nakagami distibutions") 245s hold off 245s ***** test 245s paramhat = nakafit ([1:50]); 245s paramhat_out = [0.7355, 858.5]; 245s assert (paramhat, paramhat_out, 1e-4); 245s ***** test 245s paramhat = nakafit ([1:5]); 245s paramhat_out = [1.1740, 11]; 245s assert (paramhat, paramhat_out, 1e-4); 245s ***** test 245s paramhat = nakafit ([1:6], [], [], [1 1 1 1 1 0]); 245s paramhat_out = [1.1740, 11]; 245s assert (paramhat, paramhat_out, 1e-4); 245s ***** test 245s paramhat = nakafit ([1:5], [], [], [1 1 1 1 2]); 245s paramhat_out = nakafit ([1:5, 5]); 245s assert (paramhat, paramhat_out, 1e-4); 245s ***** error nakafit (ones (2,5)); 245s ***** error nakafit ([1, 2, 3, 4, 5], 1.2); 245s ***** error nakafit ([1, 2, 3, 4, 5], 0); 245s ***** error nakafit ([1, 2, 3, 4, 5], "alpha"); 245s ***** error ... 245s nakafit ([1, 2, 3, 4, 5], 0.05, [1 1 0]); 245s ***** error ... 245s nakafit ([1, 2, 3, 4, 5], [], [1 1 0 1 1]'); 245s ***** error ... 245s nakafit ([1, 2, 3, 4, 5], 0.05, zeros (1,5), [1 1 0]); 245s ***** error ... 245s nakafit ([1, 2, 3, 4, 5], [], [], [1 1 0 1 1]'); 245s ***** error ... 245s nakafit ([1, 2, 3, 4, 5], [], [], [1 1 -1 1 1]); 245s ***** error ... 245s nakafit ([1, 2, 3, 4, 5], [], [], [1 1 1.5 1 1]); 245s ***** error ... 245s nakafit ([1, 2, 3, 4, 5], 0.05, [], [], 2); 245s 15 tests, 15 passed, 0 known failure, 0 skipped 245s [inst/dist_fit/bisalike.m] 245s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fit/bisalike.m 245s ***** test 245s nlogL = bisalike ([16.2649, 1.0156], [1:50]); 245s assert (nlogL, 215.5905, 1e-4); 245s ***** test 245s nlogL = bisalike ([2.5585, 0.5839], [1:5]); 245s assert (nlogL, 8.9950, 1e-4); 245s ***** error bisalike (3.25) 245s ***** error bisalike ([5, 0.2], ones (2)) 245s ***** error bisalike ([5, 0.2], [-1, 3]) 245s ***** error ... 245s bisalike ([1, 0.2, 3], [1, 3, 5, 7]) 245s ***** error ... 245s bisalike ([1.5, 0.2], [1:5], [0, 0, 0]) 245s ***** error ... 245s bisalike ([1.5, 0.2], [1:5], [0, 0, 0, 0, 0], [1, 1, 1]) 245s ***** error ... 245s bisalike ([1.5, 0.2], [1:5], [], [1, 1, 1]) 245s 9 tests, 9 passed, 0 known failure, 0 skipped 245s [inst/dist_fit/betafit.m] 245s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fit/betafit.m 245s ***** demo 245s ## Sample 2 populations from different Beta distibutions 245s randg ("seed", 1); # for reproducibility 245s r1 = betarnd (2, 5, 500, 1); 245s randg ("seed", 2); # for reproducibility 245s r2 = betarnd (2, 2, 500, 1); 245s r = [r1, r2]; 245s 245s ## Plot them normalized and fix their colors 245s hist (r, 12, 15); 245s h = findobj (gca, "Type", "patch"); 245s set (h(1), "facecolor", "c"); 245s set (h(2), "facecolor", "g"); 245s hold on 245s 245s ## Estimate their shape parameters 245s a_b_A = betafit (r(:,1)); 245s a_b_B = betafit (r(:,2)); 245s 245s ## Plot their estimated PDFs 245s x = [min(r(:)):0.01:max(r(:))]; 245s y = betapdf (x, a_b_A(1), a_b_A(2)); 245s plot (x, y, "-pr"); 245s y = betapdf (x, a_b_B(1), a_b_B(2)); 245s plot (x, y, "-sg"); 245s ylim ([0, 4]) 245s legend ({"Normalized HIST of sample 1 with α=2 and β=5", ... 245s "Normalized HIST of sample 2 with α=2 and β=2", ... 245s sprintf("PDF for sample 1 with estimated α=%0.2f and β=%0.2f", ... 245s a_b_A(1), a_b_A(2)), ... 245s sprintf("PDF for sample 2 with estimated α=%0.2f and β=%0.2f", ... 245s a_b_B(1), a_b_B(2))}) 245s title ("Two population samples from different Beta distibutions") 245s hold off 245s ***** test 245s x = 0.01:0.02:0.99; 245s [paramhat, paramci] = betafit (x); 245s paramhat_out = [1.0199, 1.0199]; 245s paramci_out = [0.6947, 0.6947; 1.4974, 1.4974]; 245s assert (paramhat, paramhat_out, 1e-4); 245s assert (paramci, paramci_out, 1e-4); 245s ***** test 245s x = 0.01:0.02:0.99; 245s [paramhat, paramci] = betafit (x, 0.01); 245s paramci_out = [0.6157, 0.6157; 1.6895, 1.6895]; 245s assert (paramci, paramci_out, 1e-4); 245s ***** test 245s x = 0.00:0.02:1; 245s [paramhat, paramci] = betafit (x); 245s paramhat_out = [0.0875, 0.1913]; 245s paramci_out = [0.0822, 0.1490; 0.0931, 0.2455]; 245s assert (paramhat, paramhat_out, 1e-4); 245s assert (paramci, paramci_out, 1e-4); 245s ***** error betafit ([0.2, 0.5+i]); 245s ***** error betafit (ones (2,2) * 0.5); 245s ***** error betafit ([0.5, 1.2]); 245s ***** error betafit ([0.1, 0.1]); 245s ***** error betafit ([0.01:0.1:0.99], 1.2); 245s ***** error ... 245s betafit ([0.01:0.01:0.05], 0.05, [1, 2, 3, 2]); 245s ***** error ... 245s betafit ([0.01:0.01:0.05], 0.05, [1, 2, 3, 2, -1]); 245s ***** error ... 245s betafit ([0.01:0.01:0.05], 0.05, [1, 2, 3, 2, 1.5]); 245s ***** error ... 245s betafit ([0.01:0.01:0.05], 0.05, struct ("option", 234)); 245s ***** error ... 245s betafit ([0.01:0.01:0.05], 0.05, ones (1,5), struct ("option", 234)); 245s 13 tests, 13 passed, 0 known failure, 0 skipped 245s [inst/dist_fit/bisafit.m] 245s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fit/bisafit.m 245s ***** demo 245s ## Sample 3 populations from different Birnbaum-Saunders distibutions 245s rand ("seed", 5); # for reproducibility 245s r1 = bisarnd (1, 0.5, 2000, 1); 245s rand ("seed", 2); # for reproducibility 245s r2 = bisarnd (2, 0.3, 2000, 1); 245s rand ("seed", 7); # for reproducibility 245s r3 = bisarnd (4, 0.5, 2000, 1); 245s r = [r1, r2, r3]; 245s 245s ## Plot them normalized and fix their colors 245s hist (r, 80, 4.2); 245s h = findobj (gca, "Type", "patch"); 245s set (h(1), "facecolor", "c"); 245s set (h(2), "facecolor", "g"); 245s set (h(3), "facecolor", "r"); 245s ylim ([0, 1.1]); 245s xlim ([0, 8]); 245s hold on 245s 245s ## Estimate their α and β parameters 245s beta_gammaA = bisafit (r(:,1)); 245s beta_gammaB = bisafit (r(:,2)); 245s beta_gammaC = bisafit (r(:,3)); 245s 245s ## Plot their estimated PDFs 245s x = [0:0.1:8]; 245s y = bisapdf (x, beta_gammaA(1), beta_gammaA(2)); 245s plot (x, y, "-pr"); 245s y = bisapdf (x, beta_gammaB(1), beta_gammaB(2)); 245s plot (x, y, "-sg"); 245s y = bisapdf (x, beta_gammaC(1), beta_gammaC(2)); 245s plot (x, y, "-^c"); 245s hold off 245s legend ({"Normalized HIST of sample 1 with β=1 and γ=0.5", ... 245s "Normalized HIST of sample 2 with β=2 and γ=0.3", ... 245s "Normalized HIST of sample 3 with β=4 and γ=0.5", ... 245s sprintf("PDF for sample 1 with estimated β=%0.2f and γ=%0.2f", ... 245s beta_gammaA(1), beta_gammaA(2)), ... 245s sprintf("PDF for sample 2 with estimated β=%0.2f and γ=%0.2f", ... 245s beta_gammaB(1), beta_gammaB(2)), ... 245s sprintf("PDF for sample 3 with estimated β=%0.2f and γ=%0.2f", ... 245s beta_gammaC(1), beta_gammaC(2))}) 245s title ("Three population samples from different Birnbaum-Saunders distibutions") 245s hold off 245s ***** test 245s paramhat = bisafit ([1:50]); 245s paramhat_out = [16.2649, 1.0156]; 245s assert (paramhat, paramhat_out, 1e-4); 245s ***** test 245s paramhat = bisafit ([1:5]); 245s paramhat_out = [2.5585, 0.5839]; 245s assert (paramhat, paramhat_out, 1e-4); 245s ***** error bisafit (ones (2,5)); 245s ***** error bisafit ([-1 2 3 4]); 245s ***** error bisafit ([1, 2, 3, 4, 5], 1.2); 245s ***** error bisafit ([1, 2, 3, 4, 5], 0); 245s ***** error bisafit ([1, 2, 3, 4, 5], "alpha"); 245s ***** error ... 245s bisafit ([1, 2, 3, 4, 5], 0.05, [1 1 0]); 245s ***** error ... 245s bisafit ([1, 2, 3, 4, 5], [], [1 1 0 1 1]'); 245s ***** error ... 245s bisafit ([1, 2, 3, 4, 5], 0.05, zeros (1,5), [1 1 0]); 245s ***** error ... 245s bisafit ([1, 2, 3, 4, 5], [], [], [1 1 0 1 1]'); 245s ***** error ... 245s bisafit ([1, 2, 3, 4, 5], 0.05, [], [], 2); 245s 12 tests, 12 passed, 0 known failure, 0 skipped 245s [inst/dist_fit/gamfit.m] 245s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fit/gamfit.m 245s ***** demo 245s ## Sample 3 populations from different Gamma distibutions 245s randg ("seed", 5); # for reproducibility 245s r1 = gamrnd (1, 2, 2000, 1); 245s randg ("seed", 2); # for reproducibility 245s r2 = gamrnd (2, 2, 2000, 1); 245s randg ("seed", 7); # for reproducibility 245s r3 = gamrnd (7.5, 1, 2000, 1); 245s r = [r1, r2, r3]; 245s 245s ## Plot them normalized and fix their colors 245s hist (r, 75, 4); 245s h = findobj (gca, "Type", "patch"); 245s set (h(1), "facecolor", "c"); 245s set (h(2), "facecolor", "g"); 245s set (h(3), "facecolor", "r"); 245s ylim ([0, 0.62]); 245s xlim ([0, 12]); 245s hold on 245s 245s ## Estimate their α and β parameters 245s a_bA = gamfit (r(:,1)); 245s a_bB = gamfit (r(:,2)); 245s a_bC = gamfit (r(:,3)); 245s 245s ## Plot their estimated PDFs 245s x = [0.01,0.1:0.2:18]; 245s y = gampdf (x, a_bA(1), a_bA(2)); 245s plot (x, y, "-pr"); 245s y = gampdf (x, a_bB(1), a_bB(2)); 245s plot (x, y, "-sg"); 245s y = gampdf (x, a_bC(1), a_bC(2)); 245s plot (x, y, "-^c"); 245s hold off 245s legend ({"Normalized HIST of sample 1 with α=1 and β=2", ... 245s "Normalized HIST of sample 2 with α=2 and β=2", ... 245s "Normalized HIST of sample 3 with α=7.5 and β=1", ... 245s sprintf("PDF for sample 1 with estimated α=%0.2f and β=%0.2f", ... 245s a_bA(1), a_bA(2)), ... 245s sprintf("PDF for sample 2 with estimated α=%0.2f and β=%0.2f", ... 245s a_bB(1), a_bB(2)), ... 245s sprintf("PDF for sample 3 with estimated α=%0.2f and β=%0.2f", ... 245s a_bC(1), a_bC(2))}) 245s title ("Three population samples from different Gamma distibutions") 245s hold off 245s ***** shared x 245s x = [1.2 1.6 1.7 1.8 1.9 2.0 2.2 2.6 3.0 3.5 4.0 4.8 5.6 6.6 7.6]; 245s ***** test 245s [paramhat, paramci] = gamfit (x); 245s assert (paramhat, [3.4248, 0.9752], 1e-4); 245s assert (paramci, [1.7287, 0.4670; 6.7852, 2.0366], 1e-4); 245s ***** test 245s [paramhat, paramci] = gamfit (x, 0.01); 245s assert (paramhat, [3.4248, 0.9752], 1e-4); 245s assert (paramci, [1.3945, 0.3705; 8.4113, 2.5668], 1e-4); 245s ***** test 245s freq = [1 1 1 1 2 1 1 1 1 2 1 1 1 1 2]; 245s [paramhat, paramci] = gamfit (x, [], [], freq); 245s assert (paramhat, [3.3025, 1.0615], 1e-4); 245s assert (paramci, [1.7710, 0.5415; 6.1584, 2.0806], 1e-4); 245s ***** test 245s [paramhat, paramci] = gamfit (x, [], [], [1:15]); 245s assert (paramhat, [4.4484, 0.9689], 1e-4); 245s assert (paramci, [3.4848, 0.7482; 5.6785, 1.2546], 1e-4); 245s ***** test 245s [paramhat, paramci] = gamfit (x, 0.01, [], [1:15]); 245s assert (paramhat, [4.4484, 0.9689], 1e-4); 245s assert (paramci, [3.2275, 0.6899; 6.1312, 1.3608], 1e-4); 245s ***** test 245s cens = [0 0 0 0 1 0 0 0 0 0 0 0 0 0 0]; 245s [paramhat, paramci] = gamfit (x, [], cens, [1:15]); 245s assert (paramhat, [4.7537, 0.9308], 1e-4); 245s assert (paramci, [3.7123, 0.7162; 6.0872, 1.2097], 1e-4); 246s ***** test 246s cens = [0 0 0 0 1 0 0 0 0 0 0 0 0 0 0]; 246s freq = [1 1 1 1 2 1 1 1 1 2 1 1 1 1 2]; 246s [paramhat, paramci] = gamfit (x, [], cens, freq); 246s assert (paramhat, [3.4736, 1.0847], 1e-4); 246s assert (paramci, [1.8286, 0.5359; 6.5982, 2.1956], 1e-4); 246s ***** test 246s [paramhat, paramci] = gamfit ([1 1 1 1 1 1]); 246s assert (paramhat, [Inf, 0]); 246s assert (paramci, [Inf, 0; Inf, 0]); 246s ***** test 246s [paramhat, paramci] = gamfit ([1 1 1 1 1 1], [], [1 1 1 1 1 1]); 246s assert (paramhat, [NaN, NaN]); 246s assert (paramci, [NaN, NaN; NaN, NaN]); 246s ***** test 246s [paramhat, paramci] = gamfit ([1 1 1 1 1 1], [], [], [1 1 1 1 1 1]); 246s assert (paramhat, [Inf, 0]); 246s assert (paramci, [Inf, 0; Inf, 0]); 246s ***** assert (class (gamfit (single (x))), "single") 246s ***** error gamfit (ones (2)) 246s ***** error gamfit (x, 1) 246s ***** error gamfit (x, -1) 246s ***** error gamfit (x, {0.05}) 246s ***** error gamfit (x, "a") 246s ***** error gamfit (x, i) 246s ***** error gamfit (x, [0.01 0.02]) 246s ***** error 246s gamfit ([1 2 3], 0.05, [], [1 5]) 246s ***** error 246s gamfit ([1 2 3], 0.05, [], [1 5 -1]) 246s ***** error ... 246s gamfit ([1:10], 0.05, [], [], 5) 246s ***** error gamfit ([1 2 3 -4]) 246s ***** error ... 246s gamfit ([1 2 0], [], [1 0 0]) 246s 23 tests, 23 passed, 0 known failure, 0 skipped 246s [inst/dist_fit/gevfit_lmom.m] 246s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fit/gevfit_lmom.m 246s ***** xtest <31070> 246s data = 1:50; 246s [pfit, pci] = gevfit_lmom (data); 246s expected_p = [-0.28 15.01 20.22]'; 246s assert (pfit, expected_p, 0.1); 246s 1 test, 1 passed, 0 known failure, 0 skipped 246s [inst/dist_fit/wbllike.m] 246s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fit/wbllike.m 246s ***** test 246s x = 1:50; 246s [nlogL, acov] = wbllike ([2.3, 1.2], x); 246s avar_out = [0.0250, 0.0062; 0.0062, 0.0017]; 246s assert (nlogL, 945.9589180651594, 1e-12); 246s assert (acov, avar_out, 1e-4); 246s ***** test 246s x = 1:50; 246s [nlogL, acov] = wbllike ([2.3, 1.2], x * 0.5); 246s avar_out = [-0.3238, -0.1112; -0.1112, -0.0376]; 246s assert (nlogL, 424.9879809704742, 6e-14); 246s assert (acov, avar_out, 1e-4); 246s ***** test 246s x = 1:50; 246s [nlogL, acov] = wbllike ([21, 15], x); 246s avar_out = [-0.00001236, -0.00001166; -0.00001166, -0.00001009]; 246s assert (nlogL, 1635190.328991511, 1e-8); 246s assert (acov, avar_out, 1e-8); 246s ***** error wbllike ([12, 15]); 246s ***** error wbllike ([12, 15, 3], [1:50]); 246s ***** error wbllike ([12, 3], ones (10, 2)); 246s ***** error wbllike ([12, 15], [1:50], [1, 2, 3]); 246s ***** error wbllike ([12, 15], [1:50], [], [1, 2, 3]); 246s ***** error ... 246s wbllike ([12, 15], [1:5], [], [1, 2, 3, -1, 0]); 246s 9 tests, 9 passed, 0 known failure, 0 skipped 246s [inst/clusterdata.m] 246s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/clusterdata.m 246s ***** demo 246s randn ("seed", 1) # for reproducibility 246s r1 = randn (10, 2) * 0.25 + 1; 246s randn ("seed", 5) # for reproducibility 246s r2 = randn (20, 2) * 0.5 - 1; 246s X = [r1; r2]; 246s 246s wnl = warning ("off", "Octave:linkage_savemem", "local"); 246s T = clusterdata (X, "linkage", "ward", "MaxClust", 2); 246s scatter (X(:,1), X(:,2), 36, T, "filled"); 246s ***** error ... 246s clusterdata () 246s ***** error ... 246s clusterdata (1) 246s ***** error clusterdata ([1 1], "Bogus", 1) 246s ***** error clusterdata ([1 1], "Depth", 1) 246s 4 tests, 4 passed, 0 known failure, 0 skipped 246s [inst/Classification/ClassificationKNN.m] 247s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/Classification/ClassificationKNN.m 247s ***** demo 247s ## Create a k-nearest neighbor classifier for Fisher's iris data with k = 5. 247s ## Evaluate some model predictions on new data. 247s 247s load fisheriris 247s x = meas; 247s y = species; 247s xc = [min(x); mean(x); max(x)]; 247s obj = fitcknn (x, y, "NumNeighbors", 5, "Standardize", 1); 247s [label, score, cost] = predict (obj, xc) 247s ***** demo 247s load fisheriris 247s x = meas; 247s y = species; 247s obj = fitcknn (x, y, "NumNeighbors", 5, "Standardize", 1); 247s 247s ## Create a cross-validated model 247s CVMdl = crossval (obj) 247s ***** demo 247s load fisheriris 247s x = meas; 247s y = species; 247s covMatrix = cov (x); 247s 247s ## Fit the k-NN model using the 'mahalanobis' distance 247s ## and the custom covariance matrix 247s obj = fitcknn(x, y, 'NumNeighbors', 5, 'Distance','mahalanobis', ... 247s 'Cov', covMatrix); 247s 247s ## Create a partition model using cvpartition 247s Partition = cvpartition (size (x, 1), 'kfold', 12); 247s 247s ## Create cross-validated model using 'cvPartition' name-value argument 247s CVMdl = crossval (obj, 'cvPartition', Partition) 247s 247s ## Access the trained model from first fold of cross-validation 247s CVMdl.Trained{1} 247s ***** demo 247s X = [1, 2; 3, 4; 5, 6]; 247s Y = {'A'; 'B'; 'A'}; 247s model = fitcknn (X, Y); 247s customLossFun = @(C, S, W, Cost) sum (W .* sum (abs (C - S), 2)); 247s ## Calculate loss using custom loss function 247s L = loss (model, X, Y, 'LossFun', customLossFun) 247s ***** demo 247s X = [1, 2; 3, 4; 5, 6]; 247s Y = {'A'; 'B'; 'A'}; 247s model = fitcknn (X, Y); 247s ## Calculate loss using 'mincost' loss function 247s L = loss (model, X, Y, 'LossFun', 'mincost') 247s ***** demo 247s X = [1, 2; 3, 4; 5, 6]; 247s Y = ['1'; '2'; '3']; 247s model = fitcknn (X, Y); 247s X_test = [3, 3; 5, 7]; 247s Y_test = ['1'; '2']; 247s ## Specify custom Weights 247s W = [1; 2]; 247s L = loss (model, X_test, Y_test, 'LossFun', 'logit', 'Weights', W); 247s ***** demo 247s load fisheriris 247s mdl = fitcknn (meas, species); 247s X = mean (meas); 247s Y = {'versicolor'}; 247s m = margin (mdl, X, Y) 247s ***** demo 247s X = [1, 2; 4, 5; 7, 8; 3, 2]; 247s Y = [2; 1; 3; 2]; 247s ## Train the model 247s mdl = fitcknn (X, Y); 247s ## Specify Vars and Labels 247s Vars = 1; 247s Labels = 2; 247s ## Calculate partialDependence 247s [pd, x, y] = partialDependence (mdl, Vars, Labels); 247s ***** demo 247s X = [1, 2; 4, 5; 7, 8; 3, 2]; 247s Y = [2; 1; 3; 2]; 247s ## Train the model 247s mdl = fitcknn (X, Y); 247s ## Specify Vars and Labels 247s Vars = 1; 247s Labels = 1; 247s queryPoints = [linspace(0, 1, 3)', linspace(0, 1, 3)']; 247s ## Calculate partialDependence using queryPoints 247s [pd, x, y] = partialDependence (mdl, Vars, Labels, 'QueryPoints', ... 247s queryPoints) 247s ***** test 247s x = [1, 2, 3; 4, 5, 6; 7, 8, 9; 3, 2, 1]; 247s y = ["a"; "a"; "b"; "b"]; 247s a = ClassificationKNN (x, y); 247s assert (class (a), "ClassificationKNN"); 247s assert ({a.X, a.Y, a.NumNeighbors}, {x, y, 1}) 247s assert ({a.NSMethod, a.Distance}, {"kdtree", "euclidean"}) 247s assert ({a.BucketSize}, {50}) 247s ***** test 247s x = [1, 2, 3; 4, 5, 6; 7, 8, 9; 3, 2, 1]; 247s y = ["a"; "a"; "b"; "b"]; 247s a = ClassificationKNN (x, y, "NSMethod", "exhaustive"); 247s assert (class (a), "ClassificationKNN"); 247s assert ({a.X, a.Y, a.NumNeighbors}, {x, y, 1}) 247s assert ({a.NSMethod, a.Distance}, {"exhaustive", "euclidean"}) 247s assert ({a.BucketSize}, {50}) 247s ***** test 247s x = [1, 2, 3; 4, 5, 6; 7, 8, 9; 3, 2, 1]; 247s y = ["a"; "a"; "b"; "b"]; 247s k = 10; 247s a = ClassificationKNN (x, y, "NumNeighbors" ,k); 247s assert (class (a), "ClassificationKNN"); 247s assert ({a.X, a.Y, a.NumNeighbors}, {x, y, 10}) 247s assert ({a.NSMethod, a.Distance}, {"kdtree", "euclidean"}) 247s assert ({a.BucketSize}, {50}) 247s ***** test 247s x = ones (4, 11); 247s y = ["a"; "a"; "b"; "b"]; 247s k = 10; 247s a = ClassificationKNN (x, y, "NumNeighbors" ,k); 247s assert (class (a), "ClassificationKNN"); 247s assert ({a.X, a.Y, a.NumNeighbors}, {x, y, 10}) 247s assert ({a.NSMethod, a.Distance}, {"exhaustive", "euclidean"}) 247s assert ({a.BucketSize}, {50}) 247s ***** test 247s x = [1, 2, 3; 4, 5, 6; 7, 8, 9; 3, 2, 1]; 247s y = ["a"; "a"; "b"; "b"]; 247s k = 10; 247s a = ClassificationKNN (x, y, "NumNeighbors" ,k, "NSMethod", "exhaustive"); 247s assert (class (a), "ClassificationKNN"); 247s assert ({a.X, a.Y, a.NumNeighbors}, {x, y, 10}) 247s assert ({a.NSMethod, a.Distance}, {"exhaustive", "euclidean"}) 247s assert ({a.BucketSize}, {50}) 247s ***** test 247s x = [1, 2, 3; 4, 5, 6; 7, 8, 9; 3, 2, 1]; 247s y = ["a"; "a"; "b"; "b"]; 247s k = 10; 247s a = ClassificationKNN (x, y, "NumNeighbors" ,k, "Distance", "hamming"); 247s assert (class (a), "ClassificationKNN"); 247s assert ({a.X, a.Y, a.NumNeighbors}, {x, y, 10}) 247s assert ({a.NSMethod, a.Distance}, {"exhaustive", "hamming"}) 247s assert ({a.BucketSize}, {50}) 247s ***** test 247s x = [1, 2, 3; 4, 5, 6; 7, 8, 9; 3, 2, 1]; 247s y = ["a"; "a"; "b"; "b"]; 247s weights = ones (4,1); 247s a = ClassificationKNN (x, y, "Standardize", 1); 247s assert (class (a), "ClassificationKNN"); 247s assert ({a.X, a.Y, a.NumNeighbors}, {x, y, 1}) 247s assert ({a.NSMethod, a.Distance}, {"kdtree", "euclidean"}) 247s assert ({a.Standardize}, {true}) 247s assert ({a.Sigma}, {std(x, [], 1)}) 247s assert ({a.Mu}, {[3.75, 4.25, 4.75]}) 247s ***** test 247s x = [1, 2, 3; 4, 5, 6; 7, 8, 9; 3, 2, 1]; 247s y = ["a"; "a"; "b"; "b"]; 247s weights = ones (4,1); 247s a = ClassificationKNN (x, y, "Standardize", false); 247s assert (class (a), "ClassificationKNN"); 247s assert ({a.X, a.Y, a.NumNeighbors}, {x, y, 1}) 247s assert ({a.NSMethod, a.Distance}, {"kdtree", "euclidean"}) 247s assert ({a.Standardize}, {false}) 247s assert ({a.Sigma}, {[]}) 247s assert ({a.Mu}, {[]}) 247s ***** test 247s x = [1, 2, 3; 4, 5, 6; 7, 8, 9; 3, 2, 1]; 247s y = ["a"; "a"; "b"; "b"]; 247s s = ones (1, 3); 247s a = ClassificationKNN (x, y, "Scale" , s, "Distance", "seuclidean"); 247s assert (class (a), "ClassificationKNN"); 247s assert ({a.DistParameter}, {s}) 247s assert ({a.NSMethod, a.Distance}, {"exhaustive", "seuclidean"}) 247s assert ({a.BucketSize}, {50}) 247s ***** test 247s x = [1, 2, 3; 4, 5, 6; 7, 8, 9; 3, 2, 1]; 247s y = ["a"; "a"; "b"; "b"]; 247s a = ClassificationKNN (x, y, "Exponent" , 5, "Distance", "minkowski"); 247s assert (class (a), "ClassificationKNN"); 247s assert (a.DistParameter, 5) 247s assert ({a.NSMethod, a.Distance}, {"kdtree", "minkowski"}) 247s ***** test 247s x = [1, 2, 3; 4, 5, 6; 7, 8, 9; 3, 2, 1]; 247s y = ["a"; "a"; "b"; "b"]; 247s a = ClassificationKNN (x, y, "Exponent" , 5, "Distance", "minkowski", ... 247s "NSMethod", "exhaustive"); 247s assert (class (a), "ClassificationKNN"); 247s assert (a.DistParameter, 5) 247s assert ({a.NSMethod, a.Distance}, {"exhaustive", "minkowski"}) 247s ***** test 247s x = [1, 2, 3; 4, 5, 6; 7, 8, 9; 3, 2, 1]; 247s y = ["a"; "a"; "b"; "b"]; 247s a = ClassificationKNN (x, y, "BucketSize" , 20, "distance", "mahalanobis"); 247s assert (class (a), "ClassificationKNN"); 247s assert ({a.NSMethod, a.Distance}, {"exhaustive", "mahalanobis"}) 247s assert ({a.BucketSize}, {20}) 247s ***** test 247s x = [1, 2, 3; 4, 5, 6; 7, 8, 9; 3, 2, 1]; 247s y = ["a"; "a"; "b"; "b"]; 247s a = ClassificationKNN (x, y, "IncludeTies", true); 247s assert (class (a), "ClassificationKNN"); 247s assert (a.IncludeTies, true); 247s assert ({a.NSMethod, a.Distance}, {"kdtree", "euclidean"}) 247s ***** test 247s x = [1, 2, 3; 4, 5, 6; 7, 8, 9; 3, 2, 1]; 247s y = ["a"; "a"; "b"; "b"]; 247s a = ClassificationKNN (x, y); 247s assert (class (a), "ClassificationKNN"); 247s assert (a.IncludeTies, false); 247s assert ({a.NSMethod, a.Distance}, {"kdtree", "euclidean"}) 247s ***** test 247s x = [1, 2, 3; 4, 5, 6; 7, 8, 9; 3, 2, 1]; 247s y = ["a"; "a"; "b"; "b"]; 247s a = ClassificationKNN (x, y); 247s assert (class (a), "ClassificationKNN") 247s assert (a.Prior, [0.5; 0.5]) 247s assert ({a.NSMethod, a.Distance}, {"kdtree", "euclidean"}) 247s assert ({a.BucketSize}, {50}) 247s ***** test 247s x = [1, 2, 3; 4, 5, 6; 7, 8, 9; 3, 2, 1]; 247s y = ["a"; "a"; "b"; "b"]; 247s prior = [0.5; 0.5]; 247s a = ClassificationKNN (x, y, "Prior", "empirical"); 247s assert (class (a), "ClassificationKNN") 247s assert (a.Prior, prior) 247s assert ({a.NSMethod, a.Distance}, {"kdtree", "euclidean"}) 247s assert ({a.BucketSize}, {50}) 247s ***** test 247s x = [1, 2, 3; 4, 5, 6; 7, 8, 9; 3, 2, 1]; 247s y = ["a"; "a"; "a"; "b"]; 247s prior = [0.75; 0.25]; 247s a = ClassificationKNN (x, y, "Prior", "empirical"); 247s assert (class (a), "ClassificationKNN") 247s assert (a.Prior, prior) 247s assert ({a.NSMethod, a.Distance}, {"kdtree", "euclidean"}) 247s assert ({a.BucketSize}, {50}) 247s ***** test 247s x = [1, 2, 3; 4, 5, 6; 7, 8, 9; 3, 2, 1]; 247s y = ["a"; "a"; "a"; "b"]; 247s prior = [0.5; 0.5]; 247s a = ClassificationKNN (x, y, "Prior", "uniform"); 247s assert (class (a), "ClassificationKNN") 247s assert (a.Prior, prior) 247s assert ({a.NSMethod, a.Distance}, {"kdtree", "euclidean"}) 247s assert ({a.BucketSize}, {50}) 247s ***** test 247s x = [1, 2, 3; 4, 5, 6; 7, 8, 9; 3, 2, 1]; 247s y = ["a"; "a"; "b"; "b"]; 247s cost = eye (2); 247s a = ClassificationKNN (x, y, "Cost", cost); 247s assert (class (a), "ClassificationKNN") 247s assert (a.Cost, [1, 0; 0, 1]) 247s assert ({a.NSMethod, a.Distance}, {"kdtree", "euclidean"}) 247s assert ({a.BucketSize}, {50}) 247s ***** test 247s x = [1, 2, 3; 4, 5, 6; 7, 8, 9; 3, 2, 1]; 247s y = ["a"; "a"; "b"; "b"]; 247s cost = eye (2); 247s a = ClassificationKNN (x, y, "Cost", cost, "Distance", "hamming" ); 247s assert (class (a), "ClassificationKNN") 247s assert (a.Cost, [1, 0; 0, 1]) 247s assert ({a.NSMethod, a.Distance}, {"exhaustive", "hamming"}) 247s assert ({a.BucketSize}, {50}) 247s ***** test 247s x = [1, 2; 3, 4; 5,6; 5, 8]; 247s y = {'9'; '9'; '6'; '7'}; 247s a = ClassificationKNN (x, y); 247s assert (a.Prior, [0.5; 0.25; 0.25]) 247s ***** test 247s load fisheriris 247s x = meas; 247s y = species; 247s ClassNames = {'setosa', 'versicolor', 'virginica'}; 247s a = ClassificationKNN (x, y, 'ClassNames', ClassNames); 247s assert (a.ClassNames, ClassNames') 247s ***** error ClassificationKNN () 247s ***** error ... 247s ClassificationKNN (ones(4, 1)) 247s ***** error ... 247s ClassificationKNN (ones (4,2), ones (1,4)) 247s ***** error ... 247s ClassificationKNN (ones (5,3), ones (5,1), "standardize", "a") 247s ***** error ... 247s ClassificationKNN (ones (5,2), ones (5,1), "scale", [1 1], "standardize", true) 247s ***** error ... 247s ClassificationKNN (ones (5,2), ones (5,1), "PredictorNames", ["A"]) 247s ***** error ... 247s ClassificationKNN (ones (5,2), ones (5,1), "PredictorNames", "A") 247s ***** error ... 247s ClassificationKNN (ones (5,2), ones (5,1), "PredictorNames", {"A", "B", "C"}) 247s ***** error ... 247s ClassificationKNN (ones (5,2), ones (5,1), "ResponseName", {"Y"}) 247s ***** error ... 247s ClassificationKNN (ones (5,2), ones (5,1), "ResponseName", 1) 247s ***** error ... 247s ClassificationKNN (ones(10,2), ones (10,1), "ClassNames", @(x)x) 247s ***** error ... 247s ClassificationKNN (ones(10,2), ones (10,1), "ClassNames", ['a']) 247s ***** error ... 247s ClassificationKNN (ones(10,2), ones (10,1), "ClassNames", [1, 2]) 247s ***** error ... 247s ClassificationKNN (ones(5,2), {'a';'b';'a';'a';'b'}, "ClassNames", {'a','c'}) 247s ***** error ... 247s ClassificationKNN (ones(10,2), logical (ones (10,1)), "ClassNames", [true, false]) 247s ***** error ... 247s ClassificationKNN (ones (5,2), ones (5,1), "BreakTies", 1) 247s ***** error ... 247s ClassificationKNN (ones (5,2), ones (5,1), "BreakTies", {"1"}) 247s ***** error ... 247s ClassificationKNN (ones (5,2), ones (5,1), "BreakTies", "some") 247s ***** error ... 247s ClassificationKNN (ones (5,2), ones (5,1), "Prior", {"1", "2"}) 247s ***** error ... 247s ClassificationKNN (ones (5,2), ones (5,1), "Cost", [1, 2]) 247s ***** error ... 247s ClassificationKNN (ones (5,2), ones (5,1), "Cost", "string") 247s ***** error ... 247s ClassificationKNN (ones (5,2), ones (5,1), "Cost", {eye(2)}) 247s ***** error ... 247s ClassificationKNN (ones (5,2), ones (5,1), "NumNeighbors", 0) 247s ***** error ... 247s ClassificationKNN (ones (5,2), ones (5,1), "NumNeighbors", 15.2) 247s ***** error ... 247s ClassificationKNN (ones (5,2), ones (5,1), "NumNeighbors", "asd") 247s ***** error ... 247s ClassificationKNN (ones (5,2), ones (5,1), "Distance", "somemetric") 247s ***** error ... 247s ClassificationKNN (ones (5,2), ones (5,1), "Distance", ... 247s @(v,m)sqrt(repmat(v,rows(m),1)-m,2)) 247s ***** error ... 247s ClassificationKNN (ones (5,2), ones (5,1), "Distance", ... 247s @(v,m)sqrt(sum(sumsq(repmat(v,rows(m),1)-m,2)))) 247s ***** error ... 247s ClassificationKNN (ones (5,2), ones (5,1), "Distance", [1 2 3]) 247s ***** error ... 247s ClassificationKNN (ones (5,2), ones (5,1), "Distance", {"mahalanobis"}) 247s ***** error ... 247s ClassificationKNN (ones (5,2), ones (5,1), "Distance", logical (5)) 247s ***** error ... 247s ClassificationKNN (ones (5,2), ones (5,1), "DistanceWeight", @(x)sum(x)) 247s ***** error ... 247s ClassificationKNN (ones (5,2), ones (5,1), "DistanceWeight", "text") 247s ***** error ... 247s ClassificationKNN (ones (5,2), ones (5,1), "DistanceWeight", [1 2 3]) 247s ***** error ... 247s ClassificationKNN (ones (5,2), ones (5,1), "Scale", "scale") 247s ***** error ... 247s ClassificationKNN (ones (5,2), ones (5,1), "Scale", {[1 2 3]}) 247s ***** error ... 247s ClassificationKNN (ones (5,2), ones (5,1), "standardize", true, "scale", [1 1]) 247s ***** error ... 247s ClassificationKNN (ones (5,2), ones (5,1), "Cov", ones (2), "Distance", "mahalanobis") 247s ***** error ... 247s ClassificationKNN (ones (5,2), ones (5,1), "scale", [1 1], "Cov", ones (2)) 247s ***** error ... 247s ClassificationKNN (ones (5,2), ones (5,1), "Exponent", 12.5) 247s ***** error ... 247s ClassificationKNN (ones (5,2), ones (5,1), "Exponent", -3) 247s ***** error ... 247s ClassificationKNN (ones (5,2), ones (5,1), "Exponent", "three") 247s ***** error ... 247s ClassificationKNN (ones (5,2), ones (5,1), "Exponent", {3}) 247s ***** error ... 247s ClassificationKNN (ones (5,2), ones (5,1), "NSMethod", {"kdtree"}) 247s ***** error ... 247s ClassificationKNN (ones (5,2), ones (5,1), "NSMethod", 3) 247s ***** error ... 247s ClassificationKNN (ones (5,2), ones (5,1), "NSMethod", "some") 247s ***** error ... 247s ClassificationKNN (ones (5,2), ones (5,1), "IncludeTies", "some") 247s ***** error ... 247s ClassificationKNN (ones (5,2), ones (5,1), "BucketSize", 42.5) 247s ***** error ... 247s ClassificationKNN (ones (5,2), ones (5,1), "BucketSize", -50) 247s ***** error ... 247s ClassificationKNN (ones (5,2), ones (5,1), "BucketSize", "some") 247s ***** error ... 247s ClassificationKNN (ones (5,2), ones (5,1), "BucketSize", {50}) 247s ***** error ... 247s ClassificationKNN (ones (5,2), ones (5,1), "some", "some") 247s ***** error ... 247s ClassificationKNN ([1;2;3;'a';4], ones (5,1)) 247s ***** error ... 247s ClassificationKNN ([1;2;3;Inf;4], ones (5,1)) 247s ***** error ... 247s ClassificationKNN (ones (5,2), ones (5,1), "Prior", [1 2]) 247s ***** error ... 247s ClassificationKNN (ones (5,2), ones (5,1), "Cost", [1 2; 1 3]) 247s ***** error ... 247s ClassificationKNN (ones (5,2), ones (5,1), "Scale", [1 1]) 247s ***** error ... 247s ClassificationKNN (ones (5,2), ones (5,1), "Scale", [1 1 1], "Distance", "seuclidean") 247s ***** error ... 247s ClassificationKNN (ones (5,2), ones (5,1), "Scale", [1 -1], "Distance", "seuclidean") 247s ***** error ... 247s ClassificationKNN (ones (5,2), ones (5,1), "Cov", eye (2)) 247s ***** error ... 247s ClassificationKNN (ones (5,2), ones (5,1), "Cov", eye (3), "Distance", "mahalanobis") 247s ***** error ... 247s ClassificationKNN (ones (5,2), ones (5,1), "Exponent", 3) 247s ***** error ... 247s ClassificationKNN (ones (5,2), ones (5,1), "Distance", "hamming", "NSMethod", "kdtree") 247s ***** shared x, y 247s load fisheriris 247s x = meas; 247s y = species; 247s ***** test 247s xc = [min(x); mean(x); max(x)]; 247s obj = fitcknn (x, y, "NumNeighbors", 5); 247s [l, s, c] = predict (obj, xc); 247s assert (l, {"setosa"; "versicolor"; "virginica"}) 247s assert (s, [1, 0, 0; 0, 1, 0; 0, 0, 1]) 247s assert (c, [0, 1, 1; 1, 0, 1; 1, 1, 0]) 247s ***** test 247s xc = [min(x); mean(x); max(x)]; 247s obj = fitcknn (x, y, "NumNeighbors", 5, "Standardize", 1); 247s [l, s, c] = predict (obj, xc); 247s assert (l, {"versicolor"; "versicolor"; "virginica"}) 247s assert (s, [0.4, 0.6, 0; 0, 1, 0; 0, 0, 1]) 247s assert (c, [0.6, 0.4, 1; 1, 0, 1; 1, 1, 0]) 247s ***** test 247s xc = [min(x); mean(x); max(x)]; 247s obj = fitcknn (x, y, "NumNeighbors", 10, "distance", "mahalanobis"); 247s [l, s, c] = predict (obj, xc); 247s assert (s, [0.3, 0.7, 0; 0, 0.9, 0.1; 0.2, 0.2, 0.6], 1e-4) 247s assert (c, [0.7, 0.3, 1; 1, 0.1, 0.9; 0.8, 0.8, 0.4], 1e-4) 248s ***** test 248s xc = [min(x); mean(x); max(x)]; 248s obj = fitcknn (x, y, "NumNeighbors", 10, "distance", "cosine"); 248s [l, s, c] = predict (obj, xc); 248s assert (l, {"setosa"; "versicolor"; "virginica"}) 248s assert (s, [1, 0, 0; 0, 1, 0; 0, 0.3, 0.7], 1e-4) 248s assert (c, [0, 1, 1; 1, 0, 1; 1, 0.7, 0.3], 1e-4) 248s ***** test 248s xc = [5.2, 4.1, 1.5, 0.1; 5.1, 3.8, 1.9, 0.4; ... 248s 5.1, 3.8, 1.5, 0.3; 4.9, 3.6, 1.4, 0.1]; 248s obj = fitcknn (x, y, "NumNeighbors", 5); 248s [l, s, c] = predict (obj, xc); 248s assert (l, {"setosa"; "setosa"; "setosa"; "setosa"}) 248s assert (s, [1, 0, 0; 1, 0, 0; 1, 0, 0; 1, 0, 0]) 248s assert (c, [0, 1, 1; 0, 1, 1; 0, 1, 1; 0, 1, 1]) 248s ***** test 248s xc = [5, 3, 5, 1.45]; 248s obj = fitcknn (x, y, "NumNeighbors", 5); 248s [l, s, c] = predict (obj, xc); 248s assert (l, {"versicolor"}) 248s assert (s, [0, 0.6, 0.4], 1e-4) 248s assert (c, [1, 0.4, 0.6], 1e-4) 248s ***** test 248s xc = [5, 3, 5, 1.45]; 248s obj = fitcknn (x, y, "NumNeighbors", 10, "distance", "minkowski", "Exponent", 5); 248s [l, s, c] = predict (obj, xc); 248s assert (l, {"versicolor"}) 248s assert (s, [0, 0.5, 0.5], 1e-4) 248s assert (c, [1, 0.5, 0.5], 1e-4) 248s ***** test 248s xc = [5, 3, 5, 1.45]; 248s obj = fitcknn (x, y, "NumNeighbors", 10, "distance", "jaccard"); 248s [l, s, c] = predict (obj, xc); 248s assert (l, {"setosa"}) 248s assert (s, [0.9, 0.1, 0], 1e-4) 248s assert (c, [0.1, 0.9, 1], 1e-4) 248s ***** test 248s xc = [5, 3, 5, 1.45]; 248s obj = fitcknn (x, y, "NumNeighbors", 10, "distance", "mahalanobis"); 248s [l, s, c] = predict (obj, xc); 248s assert (l, {"versicolor"}) 248s assert (s, [0.1000, 0.5000, 0.4000], 1e-4) 248s assert (c, [0.9000, 0.5000, 0.6000], 1e-4) 248s ***** test 248s xc = [5, 3, 5, 1.45]; 248s obj = fitcknn (x, y, "NumNeighbors", 5, "distance", "jaccard"); 248s [l, s, c] = predict (obj, xc); 248s assert (l, {"setosa"}) 248s assert (s, [0.8, 0.2, 0], 1e-4) 248s assert (c, [0.2, 0.8, 1], 1e-4) 248s ***** test 248s xc = [5, 3, 5, 1.45]; 248s obj = fitcknn (x, y, "NumNeighbors", 5, "distance", "seuclidean"); 248s [l, s, c] = predict (obj, xc); 248s assert (l, {"versicolor"}) 248s assert (s, [0, 1, 0], 1e-4) 248s assert (c, [1, 0, 1], 1e-4) 248s ***** test 248s xc = [5, 3, 5, 1.45]; 248s obj = fitcknn (x, y, "NumNeighbors", 10, "distance", "chebychev"); 248s [l, s, c] = predict (obj, xc); 248s assert (l, {"versicolor"}) 248s assert (s, [0, 0.7, 0.3], 1e-4) 248s assert (c, [1, 0.3, 0.7], 1e-4) 248s ***** test 248s xc = [5, 3, 5, 1.45]; 248s obj = fitcknn (x, y, "NumNeighbors", 10, "distance", "cityblock"); 248s [l, s, c] = predict (obj, xc); 248s assert (l, {"versicolor"}) 248s assert (s, [0, 0.6, 0.4], 1e-4) 248s assert (c, [1, 0.4, 0.6], 1e-4) 248s ***** test 248s xc = [5, 3, 5, 1.45]; 248s obj = fitcknn (x, y, "NumNeighbors", 10, "distance", "cosine"); 248s [l, s, c] = predict (obj, xc); 248s assert (l, {"virginica"}) 248s assert (s, [0, 0.1, 0.9], 1e-4) 248s assert (c, [1, 0.9, 0.1], 1e-4) 248s ***** test 248s xc = [5, 3, 5, 1.45]; 248s obj = fitcknn (x, y, "NumNeighbors", 10, "distance", "correlation"); 248s [l, s, c] = predict (obj, xc); 248s assert (l, {"virginica"}) 248s assert (s, [0, 0.1, 0.9], 1e-4) 248s assert (c, [1, 0.9, 0.1], 1e-4) 248s ***** test 248s xc = [5, 3, 5, 1.45]; 248s obj = fitcknn (x, y, "NumNeighbors", 30, "distance", "spearman"); 248s [l, s, c] = predict (obj, xc); 248s assert (l, {"versicolor"}) 248s assert (s, [0, 1, 0], 1e-4) 248s assert (c, [1, 0, 1], 1e-4) 248s ***** test 248s xc = [5, 3, 5, 1.45]; 248s obj = fitcknn (x, y, "NumNeighbors", 30, "distance", "hamming"); 248s [l, s, c] = predict (obj, xc); 248s assert (l, {"setosa"}) 248s assert (s, [0.4333, 0.3333, 0.2333], 1e-4) 248s assert (c, [0.5667, 0.6667, 0.7667], 1e-4) 248s ***** test 248s xc = [5, 3, 5, 1.45]; 248s obj = fitcknn (x, y, "NumNeighbors", 5, "distance", "hamming"); 248s [l, s, c] = predict (obj, xc); 248s assert (l, {"setosa"}) 248s assert (s, [0.8, 0.2, 0], 1e-4) 248s assert (c, [0.2, 0.8, 1], 1e-4) 248s ***** test 248s xc = [min(x); mean(x); max(x)]; 248s obj = fitcknn (x, y, "NumNeighbors", 10, "distance", "correlation"); 248s [l, s, c] = predict (obj, xc); 248s assert (l, {"setosa"; "versicolor"; "virginica"}) 248s assert (s, [1, 0, 0; 0, 1, 0; 0, 0.4, 0.6], 1e-4) 248s assert (c, [0, 1, 1; 1, 0, 1; 1, 0.6, 0.4], 1e-4) 248s ***** test 248s xc = [min(x); mean(x); max(x)]; 248s obj = fitcknn (x, y, "NumNeighbors", 10, "distance", "hamming"); 248s [l, s, c] = predict (obj, xc); 248s assert (l, {"setosa";"setosa";"setosa"}) 248s assert (s, [0.9, 0.1, 0; 1, 0, 0; 0.5, 0, 0.5], 1e-4) 248s assert (c, [0.1, 0.9, 1; 0, 1, 1; 0.5, 1, 0.5], 1e-4) 248s ***** error ... 248s predict (ClassificationKNN (ones (4,2), ones (4,1))) 248s ***** error ... 248s predict (ClassificationKNN (ones (4,2), ones (4,1)), []) 249s ***** error ... 249s predict (ClassificationKNN (ones (4,2), ones (4,1)), 1) 249s ***** test 249s load fisheriris 249s model = fitcknn (meas, species, 'NumNeighbors', 5); 249s X = mean (meas); 249s Y = {'versicolor'}; 249s L = loss (model, X, Y); 249s assert (L, 0) 249s ***** test 249s X = [1, 2; 3, 4; 5, 6]; 249s Y = {'A'; 'B'; 'A'}; 249s model = fitcknn (X, Y); 249s X_test = [1, 6; 3, 3]; 249s Y_test = {'A'; 'B'}; 249s L = loss (model, X_test, Y_test); 249s assert (abs (L - 0.6667) > 1e-5) 249s ***** test 249s X = [1, 2; 3, 4; 5, 6]; 249s Y = {'A'; 'B'; 'A'}; 249s model = fitcknn (X, Y); 249s X_with_nan = [1, 2; NaN, 4]; 249s Y_test = {'A'; 'B'}; 249s L = loss (model, X_with_nan, Y_test); 249s assert (abs (L - 0.3333) < 1e-4) 249s ***** test 249s X = [1, 2; 3, 4; 5, 6]; 249s Y = {'A'; 'B'; 'A'}; 249s model = fitcknn (X, Y); 249s X_with_nan = [1, 2; NaN, 4]; 249s Y_test = {'A'; 'B'}; 249s L = loss (model, X_with_nan, Y_test, 'LossFun', 'logit'); 249s assert (isnan (L)) 249s ***** test 249s X = [1, 2; 3, 4; 5, 6]; 249s Y = {'A'; 'B'; 'A'}; 249s model = fitcknn (X, Y); 249s customLossFun = @(C, S, W, Cost) sum (W .* sum (abs (C - S), 2)); 249s L = loss (model, X, Y, 'LossFun', customLossFun); 249s assert (L, 0) 249s ***** test 249s X = [1, 2; 3, 4; 5, 6]; 249s Y = [1; 2; 1]; 249s model = fitcknn (X, Y); 249s L = loss (model, X, Y, 'LossFun', 'classiferror'); 249s assert (L, 0) 249s ***** test 249s X = [1, 2; 3, 4; 5, 6]; 249s Y = [true; false; true]; 249s model = fitcknn (X, Y); 249s L = loss (model, X, Y, 'LossFun', 'binodeviance'); 249s assert (abs (L - 0.1269) < 1e-4) 249s ***** test 249s X = [1, 2; 3, 4; 5, 6]; 249s Y = ['1'; '2'; '1']; 249s model = fitcknn (X, Y); 249s L = loss (model, X, Y, 'LossFun', 'classiferror'); 249s assert (L, 0) 249s ***** test 249s X = [1, 2; 3, 4; 5, 6]; 249s Y = ['1'; '2'; '3']; 249s model = fitcknn (X, Y); 249s X_test = [3, 3]; 249s Y_test = ['1']; 249s L = loss (model, X_test, Y_test, 'LossFun', 'quadratic'); 249s assert (L, 1) 249s ***** test 249s X = [1, 2; 3, 4; 5, 6]; 249s Y = ['1'; '2'; '3']; 249s model = fitcknn (X, Y); 249s X_test = [3, 3; 5, 7]; 249s Y_test = ['1'; '2']; 249s L = loss (model, X_test, Y_test, 'LossFun', 'classifcost'); 249s assert (L, 1) 249s ***** test 249s X = [1, 2; 3, 4; 5, 6]; 249s Y = ['1'; '2'; '3']; 249s model = fitcknn (X, Y); 249s X_test = [3, 3; 5, 7]; 249s Y_test = ['1'; '2']; 249s L = loss (model, X_test, Y_test, 'LossFun', 'hinge'); 249s assert (L, 1) 249s ***** test 249s X = [1, 2; 3, 4; 5, 6]; 249s Y = ['1'; '2'; '3']; 249s model = fitcknn (X, Y); 249s X_test = [3, 3; 5, 7]; 249s Y_test = ['1'; '2']; 249s W = [1; 2]; 249s L = loss (model, X_test, Y_test, 'LossFun', 'logit', 'Weights', W); 249s assert (abs (L - 0.6931) < 1e-4) 249s ***** error ... 249s loss (ClassificationKNN (ones (4,2), ones (4,1))) 249s ***** error ... 249s loss (ClassificationKNN (ones (4,2), ones (4,1)), ones (4,2)) 249s ***** error ... 249s loss (ClassificationKNN (ones (40,2), randi ([1, 2], 40, 1)), [], zeros (2)) 249s ***** error ... 249s loss (ClassificationKNN (ones (40,2), randi ([1, 2], 40, 1)), 1, zeros (2)) 249s ***** error ... 249s loss (ClassificationKNN (ones (4,2), ones (4,1)), ones (4,2), ... 249s ones (4,1), 'LossFun') 249s ***** error ... 249s loss (ClassificationKNN (ones (4,2), ones (4,1)), ones (4,2), ones (3,1)) 249s ***** error ... 249s loss (ClassificationKNN (ones (4,2), ones (4,1)), ones (4,2), ... 249s ones (4,1), 'LossFun', 'a') 249s ***** error ... 249s loss (ClassificationKNN (ones (4,2), ones (4,1)), ones (4,2), ... 249s ones (4,1), 'Weights', 'w') 249s ***** test 249s load fisheriris 249s mdl = fitcknn (meas, species, 'NumNeighbors', 5); 249s X = mean (meas); 249s Y = {'versicolor'}; 249s m = margin (mdl, X, Y); 249s assert (m, 1) 249s ***** test 249s X = [1, 2; 3, 4; 5, 6]; 249s Y = [1; 2; 3]; 249s mdl = fitcknn (X, Y); 249s m = margin (mdl, X, Y); 249s assert (m, [1; 1; 1]) 249s ***** test 249s X = [7, 8; 9, 10]; 249s Y = ['1'; '2']; 249s mdl = fitcknn (X, Y); 249s m = margin (mdl, X, Y); 249s assert (m, [1; 1]) 249s ***** test 249s X = [11, 12]; 249s Y = {'1'}; 249s mdl = fitcknn (X, Y); 249s m = margin (mdl, X, Y); 249s assert (isnan (m)) 249s ***** test 249s X = [1, 2; 3, 4; 5, 6]; 249s Y = [1; 2; 3]; 249s mdl = fitcknn (X, Y); 249s X1 = [15, 16]; 249s Y1 = [1]; 249s m = margin (mdl, X1, Y1); 249s assert (m, -1) 249s ***** error ... 249s margin (ClassificationKNN (ones (4,2), ones (4,1))) 249s ***** error ... 249s margin (ClassificationKNN (ones (4,2), ones (4,1)), ones (4,2)) 249s ***** error ... 249s margin (ClassificationKNN (ones (40,2), randi ([1, 2], 40, 1)), [], zeros (2)) 249s ***** error ... 249s margin (ClassificationKNN (ones (40,2), randi ([1, 2], 40, 1)), 1, zeros (2)) 249s ***** error ... 249s margin (ClassificationKNN (ones (4,2), ones (4,1)), ones (4,2), ones (3,1)) 249s ***** shared X, Y, mdl 249s X = [1, 2; 4, 5; 7, 8; 3, 2]; 249s Y = [2; 1; 3; 2]; 249s mdl = fitcknn (X, Y); 249s ***** test 249s Vars = 1; 249s Labels = 2; 249s [pd, x, y] = partialDependence (mdl, Vars, Labels); 249s pdm = [0.7500, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, ... 249s 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, ... 249s 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, ... 249s 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, ... 249s 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, ... 249s 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, ... 249s 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, ... 249s 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, ... 249s 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, ... 249s 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, ... 249s 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, ... 249s 0.5000, 0.5000]; 249s assert (pd, pdm) 249s ***** test 249s Vars = 1; 249s Labels = 2; 249s [pd, x, y] = partialDependence (mdl, Vars, Labels, ... 249s 'NumObservationsToSample', 5); 249s pdm = [0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, ... 249s 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, ... 249s 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, ... 249s 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, ... 249s 0, 0, 0, 0, 0, 0, 0, 0, 0, 0]; 249s assert (abs (pdm - pd) < 1) 250s ***** test 250s Vars = 1; 250s Labels = 2; 250s [pd, x, y] = partialDependence (mdl, Vars, Labels, 'UseParallel', true); 250s pdm = [0.7500, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, ... 250s 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, ... 250s 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, ... 250s 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, ... 250s 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, ... 250s 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, ... 250s 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, ... 250s 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, ... 250s 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, ... 250s 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, ... 250s 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, ... 250s 0.5000, 0.5000]; 250s assert (pd, pdm) 251s ***** test 251s Vars = [1, 2]; 251s Labels = 1; 251s queryPoints = {linspace(0, 1, 3)', linspace(0, 1, 3)'}; 251s [pd, x, y] = partialDependence (mdl, Vars, Labels, 'QueryPoints', ... 251s queryPoints, 'UseParallel', true); 251s pdm = [0, 0, 0; 0, 0, 0; 0, 0, 0]; 251s assert (pd, pdm) 251s ***** test 251s Vars = 1; 251s Labels = [1; 2]; 251s [pd, x, y] = partialDependence (mdl, Vars, Labels); 251s pdm = [0.2500, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, ... 251s 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, ... 251s 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, ... 251s 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, ... 251s 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, ... 251s 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.2500, 0.2500, 0.2500, ... 251s 0.2500, 0.2500, 0.2500, 0.2500, 0.2500, 0.2500, 0.2500, 0.2500, 0.2500, ... 251s 0.2500, 0.2500, 0.2500, 0.2500, 0.2500, 0.2500, 0.2500, 0.2500, 0.2500, ... 251s 0.2500, 0.2500, 0.2500, 0.2500, 0.2500, 0.2500, 0.2500, 0.2500, 0.2500, ... 251s 0.2500, 0.2500, 0.2500, 0.2500, 0.2500, 0.2500, 0.2500, 0.2500, 0.2500, ... 251s 0.2500, 0.2500, 0.2500, 0.2500, 0.2500, 0.2500, 0.2500, 0.2500, 0.2500, ... 251s 0.2500, 0.2500; 0.7500, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, ... 251s 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, ... 251s 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, ... 251s 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, ... 251s 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, ... 251s 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, ... 251s 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, ... 251s 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, ... 251s 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, ... 251s 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, ... 251s 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, 0.5000, ... 251s 0.5000, 0.5000, 0.5000]; 251s assert (pd, pdm) 252s ***** test 252s Vars = [1, 2]; 252s Labels = [1; 2]; 252s queryPoints = {linspace(0, 1, 3)', linspace(0, 1, 3)'}; 252s [pd, x, y] = partialDependence (mdl, Vars, Labels, 'QueryPoints', queryPoints); 252s pdm(:,:,1) = [0, 0, 0; 1, 1, 1]; 252s pdm(:,:,2) = [0, 0, 0; 1, 1, 1]; 252s pdm(:,:,3) = [0, 0, 0; 1, 1, 1]; 252s assert (pd, pdm) 252s ***** test 252s X1 = [1; 2; 4; 5; 7; 8; 3; 2]; 252s X2 = ['2'; '3'; '1'; '3'; '1'; '3'; '2'; '2']; 252s X = [X1, double(X2)]; 252s Y = [1; 2; 3; 3; 2; 1; 2; 1]; 252s mdl = fitcknn (X, Y, 'ClassNames', {'1', '2', '3'}); 252s Vars = 1; 252s Labels = 1; 252s [pd, x, y] = partialDependence (mdl, Vars, Labels); 252s pdm = [1.0000, 0.6250, 0.6250, 0.6250, 0.6250, 0.6250, 0.6250, 0.6250, ... 252s 0.6250, 0.6250, 0.6250, 0.6250, 0.6250, 0.6250, 0.6250, 0.6250, 0.6250, ... 252s 0.6250, 0.6250, 0.6250, 0.6250, 0.6250, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, ... 252s 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, ... 252s 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0.3750, ... 252s 0.3750, 0.3750, 0.3750, 0.3750, 0.3750, 0.3750, 0.3750, 0.3750, 0.3750, ... 252s 0.3750, 0.3750, 0.3750, 0.3750, 0.7500, 0.7500, 0.7500, 0.7500, 0.7500, ... 252s 0.7500, 0.7500, 0.7500]; 252s assert (pd, pdm) 253s ***** test 253s X1 = [1; 2; 4; 5; 7; 8; 3; 2]; 253s X2 = ['2'; '3'; '1'; '3'; '1'; '3'; '2'; '2']; 253s X = [X1, double(X2)]; 253s Y = [1; 2; 3; 3; 2; 1; 2; 1]; 253s predictorNames = {'Feature1', 'Feature2'}; 253s mdl = fitcknn (X, Y, 'PredictorNames', predictorNames); 253s Vars = 'Feature1'; 253s Labels = 1; 253s [pd, x, y] = partialDependence (mdl, Vars, Labels); 253s pdm = [1.0000, 0.6250, 0.6250, 0.6250, 0.6250, 0.6250, 0.6250, 0.6250, ... 253s 0.6250, 0.6250, 0.6250, 0.6250, 0.6250, 0.6250, 0.6250, 0.6250, 0.6250, ... 253s 0.6250, 0.6250, 0.6250, 0.6250, 0.6250, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, ... 253s 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, ... 253s 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0, 0.3750, ... 253s 0.3750, 0.3750, 0.3750, 0.3750, 0.3750, 0.3750, 0.3750, 0.3750, 0.3750, ... 253s 0.3750, 0.3750, 0.3750, 0.3750, 0.7500, 0.7500, 0.7500, 0.7500, 0.7500, ... 253s 0.7500, 0.7500, 0.7500]; 253s assert (pd, pdm) 254s ***** test 254s X1 = [1; 2; 4; 5; 7; 8; 3; 2]; 254s X2 = ['2'; '3'; '1'; '3'; '1'; '3'; '2'; '2']; 254s X = [X1, double(X2)]; 254s Y = [1; 2; 3; 3; 2; 1; 2; 1]; 254s predictorNames = {'Feature1', 'Feature2'}; 254s mdl = fitcknn (X, Y, 'PredictorNames', predictorNames); 254s new_X1 = [10; 5; 6; 8; 9; 20; 35; 6]; 254s new_X2 = ['2'; '2'; '1'; '2'; '1'; '3'; '3'; '2']; 254s new_X = [new_X1, double(new_X2)]; 254s Vars = 'Feature1'; 254s Labels = 1; 254s [pd, x, y] = partialDependence (mdl, Vars, Labels, new_X); 254s pdm = [0, 0, 0, 0, 0, 0.2500, 0.2500, 0.2500, 0.2500, 0.7500, 0.7500, ... 254s 0.7500, 0.7500, 0.7500, 0.7500, 1.0000, 1.0000, 1.0000, 1.0000, 1.0000, ... 254s 1.0000, 1.0000, 1.0000, 1.0000, 1.0000, 1.0000, 1.0000, 1.0000, 1.0000, ... 254s 1.0000, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, ... 254s 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, ... 254s 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1, 1]; 254s assert (pd, pdm) 255s ***** error ... 255s partialDependence (ClassificationKNN (ones (4,2), ones (4,1))) 255s ***** error ... 255s partialDependence (ClassificationKNN (ones (4,2), ones (4,1)), 1) 255s ***** error ... 255s partialDependence (ClassificationKNN (ones (4,2), ones (4,1)), 1, ... 255s ones (4,1), 'NumObservationsToSample') 255s ***** error ... 255s partialDependence (ClassificationKNN (ones (4,2), ones (4,1)), 1, ... 255s ones (4,1), 2) 255s ***** shared x, y, obj 255s load fisheriris 255s x = meas; 255s y = species; 255s covMatrix = cov (x); 255s obj = fitcknn (x, y, 'NumNeighbors', 5, 'Distance', ... 255s 'mahalanobis', 'Cov', covMatrix); 255s ***** test 255s CVMdl = crossval (obj); 255s assert (class (CVMdl), "ClassificationPartitionedModel") 255s assert ({CVMdl.X, CVMdl.Y}, {x, y}) 255s assert (CVMdl.KFold == 10) 255s assert (CVMdl.ModelParameters.NumNeighbors == 5) 255s assert (strcmp (CVMdl.ModelParameters.Distance, "mahalanobis")) 255s assert (class (CVMdl.Trained{1}), "ClassificationKNN") 255s assert (!CVMdl.ModelParameters.Standardize) 255s ***** test 255s CVMdl = crossval (obj, "KFold", 5); 255s assert (class (CVMdl), "ClassificationPartitionedModel") 255s assert ({CVMdl.X, CVMdl.Y}, {x, y}) 255s assert (CVMdl.KFold == 5) 255s assert (CVMdl.ModelParameters.NumNeighbors == 5) 255s assert (strcmp (CVMdl.ModelParameters.Distance, "mahalanobis")) 255s assert (class (CVMdl.Trained{1}), "ClassificationKNN") 255s assert (CVMdl.ModelParameters.Standardize == obj.Standardize) 255s ***** test 255s obj = fitcknn (x, y, "NumNeighbors", 5, "Distance", "cityblock"); 255s CVMdl = crossval (obj, "HoldOut", 0.2); 255s assert (class (CVMdl), "ClassificationPartitionedModel") 255s assert ({CVMdl.X, CVMdl.Y}, {x, y}) 255s assert (CVMdl.ModelParameters.NumNeighbors == 5) 255s assert (strcmp (CVMdl.ModelParameters.Distance, "cityblock")) 255s assert (class (CVMdl.Trained{1}), "ClassificationKNN") 255s assert (CVMdl.ModelParameters.Standardize == obj.Standardize) 255s ***** test 255s obj = fitcknn (x, y, "NumNeighbors", 10, "Distance", "cityblock"); 255s CVMdl = crossval (obj, "LeaveOut", 'on'); 255s assert (class (CVMdl), "ClassificationPartitionedModel") 255s assert ({CVMdl.X, CVMdl.Y}, {x, y}) 255s assert (CVMdl.ModelParameters.NumNeighbors == 10) 255s assert (strcmp (CVMdl.ModelParameters.Distance, "cityblock")) 255s assert (class (CVMdl.Trained{1}), "ClassificationKNN") 255s assert (CVMdl.ModelParameters.Standardize == obj.Standardize) 256s ***** test 256s obj = fitcknn (x, y, "NumNeighbors", 10, "Distance", "cityblock"); 256s partition = cvpartition (y, 'KFold', 3); 256s CVMdl = crossval (obj, 'cvPartition', partition); 256s assert (class (CVMdl), "ClassificationPartitionedModel") 256s assert (CVMdl.KFold == 3) 256s assert (CVMdl.ModelParameters.NumNeighbors == 10) 256s assert (strcmp (CVMdl.ModelParameters.Distance, "cityblock")) 256s assert (class (CVMdl.Trained{1}), "ClassificationKNN") 256s assert (CVMdl.ModelParameters.Standardize == obj.Standardize) 256s ***** error ... 256s crossval (ClassificationKNN (ones (4,2), ones (4,1)), "kfold") 256s ***** error... 256s crossval (ClassificationKNN (ones (4,2), ones (4,1)), "kfold", 12, "holdout", 0.2) 256s ***** error ... 256s crossval (ClassificationKNN (ones (4,2), ones (4,1)), "kfold", 'a') 256s ***** error ... 256s crossval (ClassificationKNN (ones (4,2), ones (4,1)), "holdout", 2) 256s ***** error ... 256s crossval (ClassificationKNN (ones (4,2), ones (4,1)), "leaveout", 1) 256s ***** error ... 256s crossval (ClassificationKNN (ones (4,2), ones (4,1)), "cvpartition", 1) 256s 162 tests, 162 passed, 0 known failure, 0 skipped 256s [inst/Classification/ConfusionMatrixChart.m] 256s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/Classification/ConfusionMatrixChart.m 256s ***** demo 256s ## Create a simple ConfusionMatrixChart Object 256s 256s cm = ConfusionMatrixChart (gca, [1 2; 1 2], {"A","B"}, {"XLabel","LABEL A"}) 256s NormalizedValues = cm.NormalizedValues 256s ClassLabels = cm.ClassLabels 256s ***** test 256s hf = figure ("visible", "off"); 256s unwind_protect 256s cm = ConfusionMatrixChart (gca, [1 2; 1 2], {"A","B"}, {"XLabel","LABEL A"}); 256s assert (isa (cm, "ConfusionMatrixChart"), true); 256s unwind_protect_cleanup 256s close (hf); 256s end_unwind_protect 257s 1 test, 1 passed, 0 known failure, 0 skipped 257s [inst/Classification/ClassificationNeuralNetwork.m] 257s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/Classification/ClassificationNeuralNetwork.m 257s ***** error ... 257s ClassificationNeuralNetwork () 257s ***** error ... 257s ClassificationNeuralNetwork (ones(10,2)) 257s ***** error ... 257s ClassificationNeuralNetwork (ones(10,2), ones (5,1)) 257s ***** error ... 257s ClassificationNeuralNetwork (ones (5,3), ones (5,1), "standardize", "a") 257s ***** error ... 257s ClassificationNeuralNetwork (ones (5,2), ones (5,1), "PredictorNames", ["A"]) 257s ***** error ... 257s ClassificationNeuralNetwork (ones (5,2), ones (5,1), "PredictorNames", "A") 257s ***** error ... 257s ClassificationNeuralNetwork (ones (5,2), ones (5,1), "PredictorNames", {"A", "B", "C"}) 257s ***** error ... 257s ClassificationNeuralNetwork (ones (5,2), ones (5,1), "ResponseName", {"Y"}) 257s ***** error ... 257s ClassificationNeuralNetwork (ones (5,2), ones (5,1), "ResponseName", 1) 257s ***** error ... 257s ClassificationNeuralNetwork (ones(10,2), ones (10,1), "ClassNames", @(x)x) 257s ***** error ... 257s ClassificationNeuralNetwork (ones(10,2), ones (10,1), "ClassNames", ['a']) 257s ***** error ... 257s ClassificationNeuralNetwork (ones(10,2), ones (10,1), "ClassNames", [1, 2]) 257s ***** error ... 257s ClassificationNeuralNetwork (ones(5,2), {'a';'b';'a';'a';'b'}, "ClassNames", {'a','c'}) 257s ***** error ... 257s ClassificationNeuralNetwork (ones(10,2), logical (ones (10,1)), "ClassNames", [true, false]) 257s ***** error ... 257s ClassificationNeuralNetwork (ones(10,2), ones(10,1), "LayerSizes", -1) 257s ***** error ... 257s ClassificationNeuralNetwork (ones(10,2), ones(10,1), "LayerSizes", 0.5) 257s ***** error ... 257s ClassificationNeuralNetwork (ones(10,2), ones(10,1), "LayerSizes", [1,-2]) 257s ***** error ... 257s ClassificationNeuralNetwork (ones(10,2), ones(10,1), "LayerSizes", [10,20,30.5]) 257s ***** error ... 257s ClassificationNeuralNetwork (ones(10,2), ones(10,1), "LearningRate", -0.1) 257s ***** error ... 257s ClassificationNeuralNetwork (ones(10,2), ones(10,1), "LearningRate", [0.1, 0.01]) 257s ***** error ... 257s ClassificationNeuralNetwork (ones(10,2), ones(10,1), "LearningRate", "a") 257s ***** error ... 257s ClassificationNeuralNetwork (ones(10,2), ones(10,1), "Activations", 123) 257s ***** error ... 257s ClassificationNeuralNetwork (ones(10,2), ones(10,1), "Activations", "unsupported_type") 257s ***** error ... 257s ClassificationNeuralNetwork (ones(10,2), ones(10,1), "LayerSizes", [10, 5], ... 257s "Activations", {"sigmoid", "unsupported_type"}) 257s ***** error ... 257s ClassificationNeuralNetwork (ones(10,2), ones(10,1), "Activations", {"sigmoid", "relu", "softmax"}) 257s ***** error ... 257s ClassificationNeuralNetwork (ones(10,2), ones(10,1), "OutputLayerActivation", 123) 257s ***** error ... 257s ClassificationNeuralNetwork (ones(10,2), ones(10,1), "OutputLayerActivation", "unsupported_type") 257s ***** error ... 257s ClassificationNeuralNetwork (ones(10,2), ones(10,1), "IterationLimit", -1) 257s ***** error ... 257s ClassificationNeuralNetwork (ones(10,2), ones(10,1), "IterationLimit", 0.5) 257s ***** error ... 257s ClassificationNeuralNetwork (ones(10,2), ones(10,1), "IterationLimit", [1,2]) 257s ***** error ... 257s ClassificationNeuralNetwork (ones(10,2), ones(10,1), "ScoreTransform", [1,2]) 257s ***** error ... 257s ClassificationNeuralNetwork (ones(10,2), ones(10,1), "ScoreTransform", "unsupported_type") 257s ***** error ... 257s ClassificationNeuralNetwork (ones(10,2), ones(10,1), "some", "some") 257s ***** error ... 257s ClassificationNeuralNetwork ([1;2;3;'a';4], ones (5,1)) 257s ***** error ... 257s ClassificationNeuralNetwork ([1;2;3;Inf;4], ones (5,1)) 257s 35 tests, 35 passed, 0 known failure, 0 skipped 257s [inst/Classification/ClassificationGAM.m] 257s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/Classification/ClassificationGAM.m 257s ***** demo 257s ## Train a GAM classifier for binary classification 257s ## using specific data and plot the decision boundaries. 257s 257s ## Define specific data 257s X = [1, 2; 2, 3; 3, 3; 4, 5; 5, 5; ... 257s 6, 7; 7, 8; 8, 8; 9, 9; 10, 10]; 257s Y = [0; 0; 0; 0; 0; ... 257s 1; 1; 1; 1; 1]; 257s 257s ## Train the GAM model 257s obj = fitcgam (X, Y, "Interactions", "all") 257s 257s ## Create a grid of values for prediction 257s x1 = [min(X(:,1)):0.1:max(X(:,1))]; 257s x2 = [min(X(:,2)):0.1:max(X(:,2))]; 257s [x1G, x2G] = meshgrid (x1, x2); 257s XGrid = [x1G(:), x2G(:)]; 257s [labels, score] = predict (obj, XGrid); 257s ***** test 257s x = [1, 2, 3; 4, 5, 6; 7, 8, 9; 3, 2, 1]; 257s y = [0; 0; 1; 1]; 257s PredictorNames = {'Feature1', 'Feature2', 'Feature3'}; 257s a = ClassificationGAM (x, y, "PredictorNames", PredictorNames); 257s assert (class (a), "ClassificationGAM"); 257s assert ({a.X, a.Y, a.NumObservations}, {x, y, 4}) 257s assert ({a.NumPredictors, a.ResponseName}, {3, "Y"}) 257s assert (a.ClassNames, {'0'; '1'}) 257s assert (a.PredictorNames, PredictorNames) 257s assert (a.BaseModel.Intercept, 0) 260s ***** test 260s load fisheriris 260s inds = strcmp (species,'versicolor') | strcmp (species,'virginica'); 260s X = meas(inds, :); 260s Y = species(inds, :)'; 260s Y = strcmp (Y, 'virginica')'; 260s a = ClassificationGAM (X, Y, 'Formula', 'Y ~ x1 + x2 + x3 + x4 + x1:x2 + x2:x3'); 260s assert (class (a), "ClassificationGAM"); 260s assert ({a.X, a.Y, a.NumObservations}, {X, Y, 100}) 260s assert ({a.NumPredictors, a.ResponseName}, {4, "Y"}) 260s assert (a.ClassNames, {'0'; '1'}) 260s assert (a.Formula, 'Y ~ x1 + x2 + x3 + x4 + x1:x2 + x2:x3') 260s assert (a.PredictorNames, {'x1', 'x2', 'x3', 'x4'}) 260s assert (a.ModelwInt.Intercept, 0) 268s ***** test 268s X = [2, 3, 5; 4, 6, 8; 1, 2, 3; 7, 8, 9; 5, 4, 3]; 268s Y = [0; 1; 0; 1; 1]; 268s a = ClassificationGAM (X, Y, 'Knots', [4, 4, 4], 'Order', [3, 3, 3]); 268s assert (class (a), "ClassificationGAM"); 268s assert ({a.X, a.Y, a.NumObservations}, {X, Y, 5}) 268s assert ({a.NumPredictors, a.ResponseName}, {3, "Y"}) 268s assert (a.ClassNames, {'0'; '1'}) 268s assert (a.PredictorNames, {'x1', 'x2', 'x3'}) 268s assert (a.Knots, [4, 4, 4]) 268s assert (a.Order, [3, 3, 3]) 268s assert (a.DoF, [7, 7, 7]) 268s assert (a.BaseModel.Intercept, 0.4055, 1e-1) 271s ***** error ClassificationGAM () 271s ***** error ... 271s ClassificationGAM (ones(4, 1)) 271s ***** error ... 271s ClassificationGAM (ones (4,2), ones (1,4)) 271s ***** error ... 271s ClassificationGAM (ones (5,2), ones (5,1), "PredictorNames", ["A"]) 271s ***** error ... 271s ClassificationGAM (ones (5,2), ones (5,1), "PredictorNames", "A") 271s ***** error ... 271s ClassificationGAM (ones (5,2), ones (5,1), "PredictorNames", {"A", "B", "C"}) 271s ***** error ... 271s ClassificationGAM (ones (5,2), ones (5,1), "ResponseName", {"Y"}) 271s ***** error ... 271s ClassificationGAM (ones (5,2), ones (5,1), "ResponseName", 1) 271s ***** error ... 271s ClassificationGAM (ones(10,2), ones (10,1), "ClassNames", @(x)x) 271s ***** error ... 271s ClassificationGAM (ones(10,2), ones (10,1), "ClassNames", ['a']) 271s ***** error ... 271s ClassificationGAM (ones(10,2), ones (10,1), "ClassNames", [1, 2]) 271s ***** error ... 271s ClassificationGAM (ones(5,2), {'a';'b';'a';'a';'b'}, "ClassNames", {'a','c'}) 271s ***** error ... 271s ClassificationGAM (ones(10,2), logical (ones (10,1)), "ClassNames", [true, false]) 271s ***** error ... 271s ClassificationGAM (ones (5,2), ones (5,1), "Cost", [1, 2]) 271s ***** error ... 271s ClassificationGAM (ones (5,2), ones (5,1), "Cost", "string") 271s ***** error ... 271s ClassificationGAM (ones (5,2), ones (5,1), "Cost", {eye(2)}) 271s ***** test 271s x = [1, 2; 3, 4; 5, 6; 7, 8; 9, 10]; 271s y = [1; 0; 1; 0; 1]; 271s a = ClassificationGAM (x, y, "interactions", "all"); 271s l = {'0'; '0'; '0'; '0'; '0'}; 271s s = [0.3760, 0.6240; 0.4259, 0.5741; 0.3760, 0.6240; ... 271s 0.4259, 0.5741; 0.3760, 0.6240]; 271s [labels, scores] = predict (a, x); 271s assert (class (a), "ClassificationGAM"); 271s assert ({a.X, a.Y, a.NumObservations}, {x, y, 5}) 271s assert ({a.NumPredictors, a.ResponseName}, {2, "Y"}) 271s assert (a.ClassNames, {'1'; '0'}) 271s assert (a.PredictorNames, {'x1', 'x2'}) 271s assert (a.ModelwInt.Intercept, 0.4055, 1e-1) 271s assert (labels, l) 271s assert (scores, s, 1e-1) 275s ***** test 275s x = [1, 2, 3; 4, 5, 6; 7, 8, 9; 3, 2, 1]; 275s y = [0; 0; 1; 1]; 275s interactions = [false, true, false; true, false, true; false, true, false]; 275s a = fitcgam (x, y, "learningrate", 0.2, "interactions", interactions); 275s [label, score] = predict (a, x, "includeinteractions", true); 275s l = {'0'; '0'; '1'; '1'}; 275s s = [0.5106, 0.4894; 0.5135, 0.4865; 0.4864, 0.5136; 0.4847, 0.5153]; 275s assert (class (a), "ClassificationGAM"); 275s assert ({a.X, a.Y, a.NumObservations}, {x, y, 4}) 275s assert ({a.NumPredictors, a.ResponseName}, {3, "Y"}) 275s assert (a.ClassNames, {'0'; '1'}) 275s assert (a.PredictorNames, {'x1', 'x2', 'x3'}) 275s assert (a.ModelwInt.Intercept, 0) 275s assert (label, l) 275s assert (score, s, 1e-1) 283s ***** error ... 283s predict (ClassificationGAM (ones (4,2), ones (4,1))) 284s ***** error ... 284s predict (ClassificationGAM (ones (4,2), ones (4,1)), []) 286s ***** error ... 286s predict (ClassificationGAM (ones (4,2), ones (4,1)), 1) 287s ***** shared x, y, obj 287s x = [1, 2, 3; 4, 5, 6; 7, 8, 9; 3, 2, 1]; 287s y = [0; 0; 1; 1]; 287s obj = fitcgam (x, y); 290s ***** test 290s CVMdl = crossval (obj); 290s assert (class (CVMdl), "ClassificationPartitionedModel") 290s assert ({CVMdl.X, CVMdl.Y}, {x, y}) 290s assert (CVMdl.KFold == 10) 290s assert (class (CVMdl.Trained{1}), "CompactClassificationGAM") 290s assert (CVMdl.CrossValidatedModel, "ClassificationGAM") 316s ***** test 316s CVMdl = crossval (obj, "KFold", 5); 316s assert (class (CVMdl), "ClassificationPartitionedModel") 316s assert ({CVMdl.X, CVMdl.Y}, {x, y}) 316s assert (CVMdl.KFold == 5) 316s assert (class (CVMdl.Trained{1}), "CompactClassificationGAM") 316s assert (CVMdl.CrossValidatedModel, "ClassificationGAM") 329s ***** test 329s CVMdl = crossval (obj, "HoldOut", 0.2); 329s assert (class (CVMdl), "ClassificationPartitionedModel") 329s assert ({CVMdl.X, CVMdl.Y}, {x, y}) 329s assert (class (CVMdl.Trained{1}), "CompactClassificationGAM") 329s assert (CVMdl.CrossValidatedModel, "ClassificationGAM") 332s ***** test 332s partition = cvpartition (y, 'KFold', 3); 332s CVMdl = crossval (obj, 'cvPartition', partition); 332s assert (class (CVMdl), "ClassificationPartitionedModel") 332s assert (CVMdl.KFold == 3) 332s assert (class (CVMdl.Trained{1}), "CompactClassificationGAM") 332s assert (CVMdl.CrossValidatedModel, "ClassificationGAM") 339s ***** error ... 339s crossval (obj, "kfold") 339s ***** error... 339s crossval (obj, "kfold", 12, "holdout", 0.2) 339s ***** error ... 339s crossval (obj, "kfold", 'a') 339s ***** error ... 339s crossval (obj, "holdout", 2) 339s ***** error ... 339s crossval (obj, "leaveout", 1) 339s ***** error ... 339s crossval (obj, "cvpartition", 1) 339s 34 tests, 34 passed, 0 known failure, 0 skipped 339s [inst/Classification/CompactClassificationDiscriminant.m] 339s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/Classification/CompactClassificationDiscriminant.m 339s ***** demo 339s ## Create a discriminant analysis classifier and its compact version 339s # and compare their size 339s 339s load fisheriris 339s X = meas; 339s Y = species; 339s 339s Mdl = fitcdiscr (X, Y, 'ClassNames', unique (species)) 339s CMdl = crossval (Mdl); 339s 339s whos ('Mdl', 'CMdl') 339s ***** test 339s load fisheriris 339s x = meas; 339s y = species; 339s PredictorNames = {'Sepal Length', 'Sepal Width', 'Petal Length', 'Petal Width'}; 339s Mdl = fitcdiscr (x, y, "PredictorNames", PredictorNames); 339s CMdl = compact (Mdl); 339s sigma = [0.265008, 0.092721, 0.167514, 0.038401; ... 339s 0.092721, 0.115388, 0.055244, 0.032710; ... 339s 0.167514, 0.055244, 0.185188, 0.042665; ... 339s 0.038401, 0.032710, 0.042665, 0.041882]; 339s mu = [5.0060, 3.4280, 1.4620, 0.2460; ... 339s 5.9360, 2.7700, 4.2600, 1.3260; ... 339s 6.5880, 2.9740, 5.5520, 2.0260]; 339s xCentered = [ 9.4000e-02, 7.2000e-02, -6.2000e-02, -4.6000e-02; ... 339s -1.0600e-01, -4.2800e-01, -6.2000e-02, -4.6000e-02; ... 339s -3.0600e-01, -2.2800e-01, -1.6200e-01, -4.6000e-02]; 339s assert (class (CMdl), "CompactClassificationDiscriminant"); 339s assert ({CMdl.DiscrimType, CMdl.ResponseName}, {"linear", "Y"}) 339s assert ({CMdl.Gamma, CMdl.MinGamma}, {0, 0}, 1e-15) 339s assert (CMdl.ClassNames, unique (species)) 339s assert (CMdl.Sigma, sigma, 1e-6) 339s assert (CMdl.Mu, mu, 1e-14) 339s assert (CMdl.XCentered([1:3],:), xCentered, 1e-14) 339s assert (CMdl.LogDetSigma, -9.9585, 1e-4) 339s assert (CMdl.PredictorNames, PredictorNames) 339s ***** test 339s load fisheriris 339s x = meas; 339s y = species; 339s Mdl = fitcdiscr (x, y, "Gamma", 0.5); 339s CMdl = compact (Mdl); 339s sigma = [0.265008, 0.046361, 0.083757, 0.019201; ... 339s 0.046361, 0.115388, 0.027622, 0.016355; ... 339s 0.083757, 0.027622, 0.185188, 0.021333; ... 339s 0.019201, 0.016355, 0.021333, 0.041882]; 339s mu = [5.0060, 3.4280, 1.4620, 0.2460; ... 339s 5.9360, 2.7700, 4.2600, 1.3260; ... 339s 6.5880, 2.9740, 5.5520, 2.0260]; 339s xCentered = [ 9.4000e-02, 7.2000e-02, -6.2000e-02, -4.6000e-02; ... 339s -1.0600e-01, -4.2800e-01, -6.2000e-02, -4.6000e-02; ... 339s -3.0600e-01, -2.2800e-01, -1.6200e-01, -4.6000e-02]; 339s assert (class (CMdl), "CompactClassificationDiscriminant"); 339s assert ({CMdl.DiscrimType, CMdl.ResponseName}, {"linear", "Y"}) 339s assert ({CMdl.Gamma, CMdl.MinGamma}, {0.5, 0}) 339s assert (CMdl.ClassNames, unique (species)) 339s assert (CMdl.Sigma, sigma, 1e-6) 339s assert (CMdl.Mu, mu, 1e-14) 339s assert (CMdl.XCentered([1:3],:), xCentered, 1e-14) 339s assert (CMdl.LogDetSigma, -8.6884, 1e-4) 339s ***** error ... 339s CompactClassificationDiscriminant (1) 339s ***** test 339s load fisheriris 339s x = meas; 339s y = species; 339s Mdl = fitcdiscr (meas, species, "Gamma", 0.5); 339s CMdl = compact (Mdl); 339s [label, score, cost] = predict (CMdl, [2, 2, 2, 2]); 339s assert (label, {'versicolor'}) 339s assert (score, [0, 0.9999, 0.0001], 1e-4) 339s assert (cost, [1, 0.0001, 0.9999], 1e-4) 339s [label, score, cost] = predict (CMdl, [2.5, 2.5, 2.5, 2.5]); 339s assert (label, {'versicolor'}) 339s assert (score, [0, 0.6368, 0.3632], 1e-4) 339s assert (cost, [1, 0.3632, 0.6368], 1e-4) 339s ***** test 339s load fisheriris 339s x = meas; 339s y = species; 339s xc = [min(x); mean(x); max(x)]; 339s Mdl = fitcdiscr (x, y); 339s CMdl = compact (Mdl); 339s [label, score, cost] = predict (CMdl, xc); 339s l = {'setosa'; 'versicolor'; 'virginica'}; 339s s = [1, 0, 0; 0, 1, 0; 0, 0, 1]; 339s c = [0, 1, 1; 1, 0, 1; 1, 1, 0]; 339s assert (label, l) 339s assert (score, s, 1e-4) 339s assert (cost, c, 1e-4) 339s ***** shared MODEL 339s X = rand (10,2); 339s Y = [ones(5,1);2*ones(5,1)]; 339s MODEL = compact (ClassificationDiscriminant (X, Y)); 339s ***** error ... 339s predict (MODEL) 339s ***** error ... 339s predict (MODEL, []) 339s ***** error ... 339s predict (MODEL, 1) 339s ***** test 339s load fisheriris 339s model = fitcdiscr (meas, species); 339s x = mean (meas); 339s y = {'versicolor'}; 339s L = loss (model, x, y); 339s assert (L, 0) 340s ***** test 340s x = [1, 2; 3, 4; 5, 6]; 340s y = {'A'; 'B'; 'A'}; 340s model = fitcdiscr (x, y, "Gamma", 0.4); 340s x_test = [1, 6; 3, 3]; 340s y_test = {'A'; 'B'}; 340s L = loss (model, x_test, y_test); 340s assert (L, 0.3333, 1e-4) 340s ***** test 340s x = [1, 2; 3, 4; 5, 6; 7, 8]; 340s y = ['1'; '2'; '3'; '1']; 340s model = fitcdiscr (x, y, "gamma" , 0.5); 340s x_test = [3, 3]; 340s y_test = ['1']; 340s L = loss (model, x_test, y_test, 'LossFun', 'quadratic'); 340s assert (L, 0.2423, 1e-4) 340s ***** test 340s x = [1, 2; 3, 4; 5, 6; 7, 8]; 340s y = ['1'; '2'; '3'; '1']; 340s model = fitcdiscr (x, y, "gamma" , 0.5); 340s x_test = [3, 3; 5, 7]; 340s y_test = ['1'; '2']; 340s L = loss (model, x_test, y_test, 'LossFun', 'classifcost'); 340s assert (L, 0.3333, 1e-4) 340s ***** test 340s x = [1, 2; 3, 4; 5, 6; 7, 8]; 340s y = ['1'; '2'; '3'; '1']; 340s model = fitcdiscr (x, y, "gamma" , 0.5); 340s x_test = [3, 3; 5, 7]; 340s y_test = ['1'; '2']; 340s L = loss (model, x_test, y_test, 'LossFun', 'hinge'); 340s assert (L, 0.5886, 1e-4) 340s ***** test 340s x = [1, 2; 3, 4; 5, 6; 7, 8]; 340s y = ['1'; '2'; '3'; '1']; 340s model = fitcdiscr (x, y, "gamma" , 0.5); 340s x_test = [3, 3; 5, 7]; 340s y_test = ['1'; '2']; 340s W = [1; 2]; 340s L = loss (model, x_test, y_test, 'LossFun', 'logit', 'Weights', W); 340s assert (L, 0.5107, 1e-4) 340s ***** test 340s x = [1, 2; 3, 4; 5, 6]; 340s y = {'A'; 'B'; 'A'}; 340s model = fitcdiscr (x, y, "gamma" , 0.5); 340s x_with_nan = [1, 2; NaN, 4]; 340s y_test = {'A'; 'B'}; 340s L = loss (model, x_with_nan, y_test); 340s assert (L, 0.3333, 1e-4) 340s ***** test 340s x = [1, 2; 3, 4; 5, 6]; 340s y = {'A'; 'B'; 'A'}; 340s model = fitcdiscr (x, y); 340s x_with_nan = [1, 2; NaN, 4]; 340s y_test = {'A'; 'B'}; 340s L = loss (model, x_with_nan, y_test, 'LossFun', 'logit'); 340s assert (isnan (L)) 340s ***** test 340s x = [1, 2; 3, 4; 5, 6]; 340s y = {'A'; 'B'; 'A'}; 340s model = fitcdiscr (x, y); 340s customLossFun = @(C, S, W, Cost) sum (W .* sum (abs (C - S), 2)); 340s L = loss (model, x, y, 'LossFun', customLossFun); 340s assert (L, 0.8889, 1e-4) 340s ***** test 340s x = [1, 2; 3, 4; 5, 6]; 340s y = [1; 2; 1]; 340s model = fitcdiscr (x, y); 340s L = loss (model, x, y, 'LossFun', 'classiferror'); 340s assert (L, 0.3333, 1e-4) 340s ***** error ... 340s loss (MODEL) 340s ***** error ... 340s loss (MODEL, ones (4,2)) 340s ***** error ... 340s loss (MODEL, ones (4,2), ones (4,1), 'LossFun') 340s ***** error ... 340s loss (MODEL, ones (4,2), ones (3,1)) 340s ***** error ... 340s loss (MODEL, ones (4,2), ones (4,1), 'LossFun', 'a') 340s ***** error ... 340s loss (MODEL, ones (4,2), ones (4,1), 'Weights', 'w') 340s load fisheriris 340s mdl = fitcdiscr (meas, species); 340s X = mean (meas); 340s Y = {'versicolor'}; 340s m = margin (mdl, X, Y); 340s assert (m, 1, 1e-6) 340s ***** test 340s X = [1, 2; 3, 4; 5, 6]; 340s Y = [1; 2; 1]; 340s mdl = fitcdiscr (X, Y, "gamma", 0.5); 340s m = margin (mdl, X, Y); 340s assert (m, [0.3333; -0.3333; 0.3333], 1e-4) 340s ***** error ... 340s margin (MODEL) 340s ***** error ... 340s margin (MODEL, ones (4,2)) 340s ***** error ... 340s margin (MODEL, ones (4,2), ones (3,1)) 340s 28 tests, 28 passed, 0 known failure, 0 skipped 340s [inst/Classification/ClassificationPartitionedModel.m] 340s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/Classification/ClassificationPartitionedModel.m 340s ***** demo 340s 340s load fisheriris 340s x = meas; 340s y = species; 340s 340s ## Create a KNN classifier model 340s obj = fitcknn (x, y, "NumNeighbors", 5, "Standardize", 1); 340s 340s ## Create a partition for 5-fold cross-validation 340s partition = cvpartition (y, "KFold", 5); 340s 340s ## Create the ClassificationPartitionedModel object 340s cvModel = crossval (obj, 'cvPartition', partition) 340s ***** demo 340s 340s load fisheriris 340s x = meas; 340s y = species; 340s 340s ## Create a KNN classifier model 340s obj = fitcknn (x, y, "NumNeighbors", 5, "Standardize", 1); 340s 340s ## Create the ClassificationPartitionedModel object 340s cvModel = crossval (obj); 340s 340s ## Predict the class labels for the observations not used for training 340s [label, score, cost] = kfoldPredict (cvModel); 340s fprintf ("Cross-validated accuracy = %1.2f%% (%d/%d)\n", ... 340s sum (strcmp (label, y)) / numel (y) *100, ... 340s sum (strcmp (label, y)), numel (y)) 340s ***** test 340s load fisheriris 340s a = fitcdiscr (meas, species, "gamma", 0.3); 340s cvModel = crossval (a, "KFold", 5); 340s assert (class (cvModel), "ClassificationPartitionedModel"); 340s assert (cvModel.NumObservations, 150); 340s assert (numel (cvModel.Trained), 5); 340s assert (class (cvModel.Trained{1}), "CompactClassificationDiscriminant"); 340s assert (cvModel.CrossValidatedModel, "ClassificationDiscriminant"); 340s assert (cvModel.KFold, 5); 340s ***** test 340s load fisheriris 340s a = fitcdiscr (meas, species, "gamma", 0.5, "fillcoeffs", "off"); 340s cvModel = crossval (a, "HoldOut", 0.3); 340s assert (class (cvModel), "ClassificationPartitionedModel"); 340s assert ({cvModel.X, cvModel.Y}, {meas, species}); 340s assert (cvModel.NumObservations, 150); 340s assert (numel (cvModel.Trained), 1); 340s assert (class (cvModel.Trained{1}), "CompactClassificationDiscriminant"); 340s assert (cvModel.CrossValidatedModel, "ClassificationDiscriminant"); 340s ***** test 340s x = [1, 2, 3; 4, 5, 6; 7, 8, 9; 3, 2, 1]; 340s y = ["a"; "a"; "b"; "b"]; 340s a = fitcgam (x, y, "Interactions", "all"); 340s cvModel = crossval (a, "KFold", 5); 340s assert (class (cvModel), "ClassificationPartitionedModel"); 340s assert (cvModel.NumObservations, 4); 340s assert (numel (cvModel.Trained), 5); 340s assert (class (cvModel.Trained{1}), "CompactClassificationGAM"); 340s assert (cvModel.CrossValidatedModel, "ClassificationGAM"); 340s assert (cvModel.KFold, 5); 393s ***** test 393s x = [1, 2, 3; 4, 5, 6; 7, 8, 9; 3, 2, 1]; 393s y = ["a"; "a"; "b"; "b"]; 393s a = fitcgam (x, y); 393s cvModel = crossval (a, "LeaveOut", "on"); 393s assert (class (cvModel), "ClassificationPartitionedModel"); 393s assert ({cvModel.X, cvModel.Y}, {x, y}); 393s assert (cvModel.NumObservations, 4); 393s assert (numel (cvModel.Trained), 4); 393s assert (class (cvModel.Trained{1}), "CompactClassificationGAM"); 393s assert (cvModel.CrossValidatedModel, "ClassificationGAM"); 407s ***** test 407s x = [1, 2, 3; 4, 5, 6; 7, 8, 9; 3, 2, 1]; 407s y = ["a"; "a"; "b"; "b"]; 407s a = fitcknn (x, y); 407s partition = cvpartition (y, "KFold", 5); 407s cvModel = ClassificationPartitionedModel (a, partition); 407s assert (class (cvModel), "ClassificationPartitionedModel"); 407s assert (class (cvModel.Trained{1}), "ClassificationKNN"); 407s assert (cvModel.NumObservations, 4); 407s assert (cvModel.ModelParameters.NumNeighbors, 1); 407s assert (cvModel.ModelParameters.NSMethod, "kdtree"); 407s assert (cvModel.ModelParameters.Distance, "euclidean"); 407s assert (! cvModel.ModelParameters.Standardize); 407s ***** test 407s x = [1, 2, 3; 4, 5, 6; 7, 8, 9; 3, 2, 1]; 407s y = ["a"; "a"; "b"; "b"]; 407s a = fitcknn (x, y, "NSMethod", "exhaustive"); 407s partition = cvpartition (y, "HoldOut", 0.2); 407s cvModel = ClassificationPartitionedModel (a, partition); 407s assert (class (cvModel), "ClassificationPartitionedModel"); 407s assert (class (cvModel.Trained{1}), "ClassificationKNN"); 407s assert ({cvModel.X, cvModel.Y}, {x, y}); 407s assert (cvModel.NumObservations, 4); 407s assert (cvModel.ModelParameters.NumNeighbors, 1); 407s assert (cvModel.ModelParameters.NSMethod, "exhaustive"); 407s assert (cvModel.ModelParameters.Distance, "euclidean"); 407s assert (! cvModel.ModelParameters.Standardize); 407s ***** test 407s x = [1, 2, 3; 4, 5, 6; 7, 8, 9; 3, 2, 1]; 407s y = ["a"; "a"; "b"; "b"]; 407s k = 3; 407s a = fitcknn (x, y, "NumNeighbors" ,k); 407s partition = cvpartition (y, "LeaveOut"); 407s cvModel = ClassificationPartitionedModel (a, partition); 407s assert (class (cvModel), "ClassificationPartitionedModel"); 407s assert (class (cvModel.Trained{1}), "ClassificationKNN"); 407s assert ({cvModel.X, cvModel.Y}, {x, y}); 407s assert (cvModel.NumObservations, 4); 407s assert (cvModel.ModelParameters.NumNeighbors, k); 407s assert (cvModel.ModelParameters.NSMethod, "kdtree"); 407s assert (cvModel.ModelParameters.Distance, "euclidean"); 407s assert (! cvModel.ModelParameters.Standardize); 407s ***** test 407s load fisheriris 407s inds = ! strcmp (species, 'setosa'); 407s x = meas(inds, 3:4); 407s y = grp2idx (species(inds)); 407s SVMModel = fitcsvm (x,y); 407s CVMdl = crossval (SVMModel, "KFold", 5); 407s assert (class (CVMdl), "ClassificationPartitionedModel") 407s assert ({CVMdl.X, CVMdl.Y}, {x, y}) 407s assert (CVMdl.KFold == 5) 407s assert (class (CVMdl.Trained{1}), "CompactClassificationSVM") 407s assert (CVMdl.CrossValidatedModel, "ClassificationSVM"); 407s ***** test 407s load fisheriris 407s inds = ! strcmp (species, 'setosa'); 407s x = meas(inds, 3:4); 407s y = grp2idx (species(inds)); 407s obj = fitcsvm (x, y); 407s CVMdl = crossval (obj, "HoldOut", 0.2); 407s assert (class (CVMdl), "ClassificationPartitionedModel") 407s assert ({CVMdl.X, CVMdl.Y}, {x, y}) 407s assert (class (CVMdl.Trained{1}), "CompactClassificationSVM") 407s assert (CVMdl.CrossValidatedModel, "ClassificationSVM"); 407s ***** test 407s load fisheriris 407s inds = ! strcmp (species, 'setosa'); 407s x = meas(inds, 3:4); 407s y = grp2idx (species(inds)); 407s obj = fitcsvm (x, y); 407s CVMdl = crossval (obj, "LeaveOut", 'on'); 407s assert (class (CVMdl), "ClassificationPartitionedModel") 407s assert ({CVMdl.X, CVMdl.Y}, {x, y}) 407s assert (class (CVMdl.Trained{1}), "CompactClassificationSVM") 407s assert (CVMdl.CrossValidatedModel, "ClassificationSVM"); 408s ***** error ... 408s ClassificationPartitionedModel () 408s ***** error ... 408s ClassificationPartitionedModel (ClassificationKNN (ones (4,2), ones (4,1))) 408s ***** error ... 408s ClassificationPartitionedModel (RegressionGAM (ones (40,2), ... 408s randi ([1, 2], 40, 1)), cvpartition (randi ([1, 2], 40, 1), 'Holdout', 0.3)) 408s ***** error ... 408s ClassificationPartitionedModel (ClassificationKNN (ones (4,2), ... 408s ones (4,1)), 'Holdout') 408s ***** test 408s load fisheriris 408s a = fitcdiscr (meas, species, "gamma", 0.5, "fillcoeffs", "off"); 408s cvModel = crossval (a, "Kfold", 4); 408s [label, score, cost] = kfoldPredict (cvModel); 408s assert (class(cvModel), "ClassificationPartitionedModel"); 408s assert ({cvModel.X, cvModel.Y}, {meas, species}); 408s assert (cvModel.NumObservations, 150); 409s ***** # assert (label, {"b"; "b"; "a"; "a"}); 409s ***** # assert (score, [4.5380e-01, 5.4620e-01; 2.4404e-01, 7.5596e-01; ... 409s ***** # 9.9392e-01, 6.0844e-03; 9.9820e-01, 1.8000e-03], 1e-4); 409s ***** # assert (cost, [5.4620e-01, 4.5380e-01; 7.5596e-01, 2.4404e-01; ... 409s ***** # 6.0844e-03, 9.9392e-01; 1.8000e-03, 9.9820e-01], 1e-4); 409s ***** test 409s x = ones(4, 11); 409s y = {"a"; "a"; "b"; "b"}; 409s k = 3; 409s a = fitcknn (x, y, "NumNeighbors", k); 409s partition = cvpartition (y, "LeaveOut"); 409s cvModel = ClassificationPartitionedModel (a, partition); 409s [label, score, cost] = kfoldPredict (cvModel); 409s assert (class(cvModel), "ClassificationPartitionedModel"); 409s assert ({cvModel.X, cvModel.Y}, {x, y}); 409s assert (cvModel.NumObservations, 4); 409s assert (cvModel.ModelParameters.NumNeighbors, k); 409s assert (cvModel.ModelParameters.NSMethod, "exhaustive"); 409s assert (cvModel.ModelParameters.Distance, "euclidean"); 409s assert (! cvModel.ModelParameters.Standardize); 409s assert (label, {"b"; "b"; "a"; "a"}); 409s assert (score, [0.3333, 0.6667; 0.3333, 0.6667; 0.6667, 0.3333; ... 409s 0.6667, 0.3333], 1e-4); 409s assert (cost, [0.6667, 0.3333; 0.6667, 0.3333; 0.3333, 0.6667; ... 409s 0.3333, 0.6667], 1e-4); 409s ***** error ... 409s [label, score, cost] = kfoldPredict (crossval (ClassificationSVM (ones (40,2), randi ([1, 2], 40, 1)))) 409s 17 tests, 17 passed, 0 known failure, 0 skipped 409s [inst/Classification/CompactClassificationSVM.m] 409s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/Classification/CompactClassificationSVM.m 409s ***** demo 409s ## Create a support vectors machine classifier and its compact version 409s # and compare their size 409s 409s load fisheriris 409s X = meas; 409s Y = species; 409s 409s Mdl = fitcsvm (X, Y, 'ClassNames', unique (species)) 409s CMdl = crossval (Mdl); 409s 409s whos ('Mdl', 'CMdl') 409s ***** error ... 409s CompactClassificationSVM (1) 409s ***** shared x, y, CMdl 409s load fisheriris 409s inds = ! strcmp (species, 'setosa'); 409s x = meas(inds, 3:4); 409s y = grp2idx (species(inds)); 409s ***** test 409s xc = [min(x); mean(x); max(x)]; 409s Mdl = fitcsvm (x, y, 'KernelFunction', 'rbf', 'Tolerance', 1e-7); 409s CMdl = compact (Mdl); 409s assert (isempty (CMdl.Alpha), true) 409s assert (sum (CMdl.IsSupportVector), numel (CMdl.Beta)) 409s [label, score] = predict (CMdl, xc); 409s assert (label, [1; 2; 2]); 409s assert (score(:,1), [0.99285; -0.080296; -0.93694], 1e-5); 409s assert (score(:,1), -score(:,2), eps) 409s ***** test 409s Mdl = fitcsvm (x, y); 409s CMdl = compact (Mdl); 409s assert (isempty (CMdl.Beta), true) 409s assert (sum (CMdl.IsSupportVector), numel (CMdl.Alpha)) 409s assert (numel (CMdl.Alpha), 24) 409s assert (CMdl.Bias, -14.415, 1e-3) 409s xc = [min(x); mean(x); max(x)]; 409s label = predict (CMdl, xc); 409s assert (label, [1; 2; 2]); 409s ***** error ... 409s predict (CMdl) 409s ***** error ... 409s predict (CMdl, []) 409s ***** error ... 409s predict (CMdl, 1) 409s ***** test 409s CMdl.ScoreTransform = "a"; 409s ***** error ... 409s [labels, scores] = predict (CMdl, x); 409s ***** test 409s rand ("seed", 1); 409s C = cvpartition (y, 'HoldOut', 0.15); 409s Mdl = fitcsvm (x(training (C),:), y(training (C)), ... 409s 'KernelFunction', 'rbf', 'Tolerance', 1e-7); 409s CMdl = compact (Mdl); 409s testInds = test (C); 409s expected_margin = [2.0000; 0.8579; 1.6690; 3.4141; 3.4552; ... 409s 2.6605; 3.5251; -4.0000; -6.3411; -6.4511; ... 409s -3.0532; -7.5054; -1.6700; -5.6227; -7.3640]; 409s computed_margin = margin (CMdl, x(testInds,:), y(testInds,:)); 409s assert (computed_margin, expected_margin, 1e-4); 409s ***** error ... 409s margin (CMdl) 409s ***** error ... 409s margin (CMdl, zeros (2)) 409s ***** error ... 409s margin (CMdl, [], 1) 409s ***** error ... 409s margin (CMdl, 1, 1) 409s ***** error ... 409s margin (CMdl, [1, 2], []) 409s ***** error ... 409s margin (CMdl, [1, 2], [1; 2]) 409s ***** test 409s rand ("seed", 1); 409s C = cvpartition (y, 'HoldOut', 0.15); 409s Mdl = fitcsvm (x(training (C),:), y(training (C)), ... 409s 'KernelFunction', 'rbf', 'Tolerance', 1e-7); 409s CMdl = compact (Mdl); 409s testInds = test (C); 409s L1 = loss (CMdl, x(testInds,:), y(testInds,:), 'LossFun', 'binodeviance'); 409s L2 = loss (CMdl, x(testInds,:), y(testInds,:), 'LossFun', 'classiferror'); 409s L3 = loss (CMdl, x(testInds,:), y(testInds,:), 'LossFun', 'exponential'); 409s L4 = loss (CMdl, x(testInds,:), y(testInds,:), 'LossFun', 'hinge'); 409s L5 = loss (CMdl, x(testInds,:), y(testInds,:), 'LossFun', 'logit'); 409s L6 = loss (CMdl, x(testInds,:), y(testInds,:), 'LossFun', 'quadratic'); 409s assert (L1, 2.8711, 1e-4); 409s assert (L2, 0.5333, 1e-4); 409s assert (L3, 10.9685, 1e-4); 409s assert (L4, 1.9827, 1e-4); 409s assert (L5, 1.5849, 1e-4); 409s assert (L6, 7.6739, 1e-4); 409s ***** error ... 409s loss (CMdl) 409s ***** error ... 409s loss (CMdl, zeros (2)) 409s ***** error ... 409s loss (CMdl, [1, 2], 1, "LossFun") 409s ***** error ... 409s loss (CMdl, [], zeros (2)) 409s ***** error ... 409s loss (CMdl, 1, zeros (2)) 409s ***** error ... 409s loss (CMdl, [1, 2], []) 409s ***** error ... 409s loss (CMdl, [1, 2], [1; 2]) 409s ***** error ... 409s loss (CMdl, [1, 2], 1, "LossFun", 1) 409s ***** error ... 409s loss (CMdl, [1, 2], 1, "LossFun", "some") 409s ***** error ... 409s loss (CMdl, [1, 2], 1, "Weights", ['a', 'b']) 409s ***** error ... 409s loss (CMdl, [1, 2], 1, "Weights", 'a') 409s ***** error ... 409s loss (CMdl, [1, 2], 1, "Weights", [1, 2]) 409s ***** error ... 409s loss (CMdl, [1, 2], 1, "some", "some") 409s 29 tests, 29 passed, 0 known failure, 0 skipped 409s [inst/Classification/ClassificationDiscriminant.m] 409s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/Classification/ClassificationDiscriminant.m 409s ***** demo 409s ## Create discriminant classifier 409s ## Evaluate some model predictions on new data. 409s 409s load fisheriris 409s x = meas; 409s y = species; 409s xc = [min(x); mean(x); max(x)]; 409s obj = fitcdiscr (x, y); 409s [label, score, cost] = predict (obj, xc); 409s ***** demo 409s load fisheriris 409s model = fitcdiscr (meas, species); 409s X = mean (meas); 409s Y = {'versicolor'}; 409s ## Compute loss for discriminant model 409s L = loss (model, X, Y) 409s ***** demo 409s load fisheriris 409s mdl = fitcdiscr (meas, species); 409s X = mean (meas); 409s Y = {'versicolor'}; 409s ## Margin for discriminant model 409s m = margin (mdl, X, Y) 409s ***** demo 409s load fisheriris 409s x = meas; 409s y = species; 409s obj = fitcdiscr (x, y, "gamma", 0.4); 409s ## Cross-validation for discriminant model 409s CVMdl = crossval (obj) 409s ***** test 409s load fisheriris 409s x = meas; 409s y = species; 409s PredictorNames = {'Sepal Length', 'Sepal Width', 'Petal Length', 'Petal Width'}; 409s Mdl = ClassificationDiscriminant (x, y, "PredictorNames", PredictorNames); 409s sigma = [0.265008, 0.092721, 0.167514, 0.038401; ... 409s 0.092721, 0.115388, 0.055244, 0.032710; ... 409s 0.167514, 0.055244, 0.185188, 0.042665; ... 409s 0.038401, 0.032710, 0.042665, 0.041882]; 409s mu = [5.0060, 3.4280, 1.4620, 0.2460; ... 409s 5.9360, 2.7700, 4.2600, 1.3260; ... 409s 6.5880, 2.9740, 5.5520, 2.0260]; 409s xCentered = [ 9.4000e-02, 7.2000e-02, -6.2000e-02, -4.6000e-02; ... 409s -1.0600e-01, -4.2800e-01, -6.2000e-02, -4.6000e-02; ... 409s -3.0600e-01, -2.2800e-01, -1.6200e-01, -4.6000e-02]; 409s assert (class (Mdl), "ClassificationDiscriminant"); 409s assert ({Mdl.X, Mdl.Y, Mdl.NumObservations}, {x, y, 150}) 409s assert ({Mdl.DiscrimType, Mdl.ResponseName}, {"linear", "Y"}) 409s assert ({Mdl.Gamma, Mdl.MinGamma}, {0, 0}, 1e-15) 409s assert (Mdl.ClassNames, unique (species)) 409s assert (Mdl.Sigma, sigma, 1e-6) 409s assert (Mdl.Mu, mu, 1e-14) 409s assert (Mdl.XCentered([1:3],:), xCentered, 1e-14) 409s assert (Mdl.LogDetSigma, -9.9585, 1e-4) 409s assert (Mdl.PredictorNames, PredictorNames) 409s ***** test 409s load fisheriris 409s x = meas; 409s y = species; 409s Mdl = ClassificationDiscriminant (x, y, "Gamma", 0.5); 409s sigma = [0.265008, 0.046361, 0.083757, 0.019201; ... 409s 0.046361, 0.115388, 0.027622, 0.016355; ... 409s 0.083757, 0.027622, 0.185188, 0.021333; ... 409s 0.019201, 0.016355, 0.021333, 0.041882]; 409s mu = [5.0060, 3.4280, 1.4620, 0.2460; ... 409s 5.9360, 2.7700, 4.2600, 1.3260; ... 409s 6.5880, 2.9740, 5.5520, 2.0260]; 409s xCentered = [ 9.4000e-02, 7.2000e-02, -6.2000e-02, -4.6000e-02; ... 409s -1.0600e-01, -4.2800e-01, -6.2000e-02, -4.6000e-02; ... 409s -3.0600e-01, -2.2800e-01, -1.6200e-01, -4.6000e-02]; 409s assert (class (Mdl), "ClassificationDiscriminant"); 409s assert ({Mdl.X, Mdl.Y, Mdl.NumObservations}, {x, y, 150}) 409s assert ({Mdl.DiscrimType, Mdl.ResponseName}, {"linear", "Y"}) 409s assert ({Mdl.Gamma, Mdl.MinGamma}, {0.5, 0}) 409s assert (Mdl.ClassNames, unique (species)) 409s assert (Mdl.Sigma, sigma, 1e-6) 409s assert (Mdl.Mu, mu, 1e-14) 409s assert (Mdl.XCentered([1:3],:), xCentered, 1e-14) 409s assert (Mdl.LogDetSigma, -8.6884, 1e-4) 409s ***** shared X, Y, MODEL 409s X = rand (10,2); 409s Y = [ones(5,1);2*ones(5,1)]; 409s MODEL = ClassificationDiscriminant (X, Y); 409s ***** error ClassificationDiscriminant () 409s ***** error ... 409s ClassificationDiscriminant (ones(4, 1)) 409s ***** error ... 409s ClassificationDiscriminant (ones (4,2), ones (1,4)) 409s ***** error ... 409s ClassificationDiscriminant (X, Y, "PredictorNames", ["A"]) 409s ***** error ... 409s ClassificationDiscriminant (X, Y, "PredictorNames", "A") 409s ***** error ... 409s ClassificationDiscriminant (X, Y, "PredictorNames", {"A", "B", "C"}) 409s ***** error ... 409s ClassificationDiscriminant (X, Y, "ResponseName", {"Y"}) 409s ***** error ... 409s ClassificationDiscriminant (X, Y, "ResponseName", 1) 409s ***** error ... 409s ClassificationDiscriminant (X, Y, "ClassNames", @(x)x) 409s ***** error ... 409s ClassificationDiscriminant (X, Y, "ClassNames", ['a']) 409s ***** error ... 409s ClassificationDiscriminant (X, ones (10,1), "ClassNames", [1, 2]) 409s ***** error ... 409s ClassificationDiscriminant ([1;2;3;4;5], {'a';'b';'a';'a';'b'}, "ClassNames", {'a','c'}) 410s ***** error ... 410s ClassificationDiscriminant (X, logical (ones (10,1)), "ClassNames", [true, false]) 410s ***** error ... 410s ClassificationDiscriminant (X, Y, "Prior", {"1", "2"}) 410s ***** error ... 410s ClassificationDiscriminant (X, ones (10,1), "Prior", [1 2]) 410s ***** error ... 410s ClassificationDiscriminant (X, Y, "Cost", [1, 2]) 410s ***** error ... 410s ClassificationDiscriminant (X, Y, "Cost", "string") 410s ***** error ... 410s ClassificationDiscriminant (X, Y, "Cost", {eye(2)}) 410s ***** error ... 410s ClassificationDiscriminant (X, Y, "Cost", ones (3)) 410s ***** error ... 410s ClassificationDiscriminant (ones (5,2), [1; 1; 2; 2; 2]) 410s ***** error ... 410s ClassificationDiscriminant (ones (5,2), [1; 1; 2; 2; 2], "PredictorNames", {"A", "B"}) 410s ***** error ... 410s ClassificationDiscriminant ([1,2;2,2;3,2;4,2;5,2], ones (5, 1)) 410s ***** error ... 410s ClassificationDiscriminant ([1,2;2,2;3,2;4,2;5,2], ones (5, 1), "PredictorNames", {"A", "B"}) 410s ***** test 410s load fisheriris 410s x = meas; 410s y = species; 410s Mdl = fitcdiscr (meas, species, "Gamma", 0.5); 410s [label, score, cost] = predict (Mdl, [2, 2, 2, 2]); 410s assert (label, {'versicolor'}) 410s assert (score, [0, 0.9999, 0.0001], 1e-4) 410s assert (cost, [1, 0.0001, 0.9999], 1e-4) 410s [label, score, cost] = predict (Mdl, [2.5, 2.5, 2.5, 2.5]); 410s assert (label, {'versicolor'}) 410s assert (score, [0, 0.6368, 0.3632], 1e-4) 410s assert (cost, [1, 0.3632, 0.6368], 1e-4) 410s ***** test 410s load fisheriris 410s x = meas; 410s y = species; 410s xc = [min(x); mean(x); max(x)]; 410s Mdl = fitcdiscr (x, y); 410s [label, score, cost] = predict (Mdl, xc); 410s l = {'setosa'; 'versicolor'; 'virginica'}; 410s s = [1, 0, 0; 0, 1, 0; 0, 0, 1]; 410s c = [0, 1, 1; 1, 0, 1; 1, 1, 0]; 410s assert (label, l) 410s assert (score, s, 1e-4) 410s assert (cost, c, 1e-4) 410s ***** error ... 410s predict (MODEL) 410s ***** error ... 410s predict (MODEL, []) 410s ***** error ... 410s predict (MODEL, 1) 410s ***** test 410s load fisheriris 410s model = fitcdiscr (meas, species); 410s x = mean (meas); 410s y = {'versicolor'}; 410s L = loss (model, x, y); 410s assert (L, 0) 410s ***** test 410s x = [1, 2; 3, 4; 5, 6]; 410s y = {'A'; 'B'; 'A'}; 410s model = fitcdiscr (x, y, "Gamma", 0.4); 410s x_test = [1, 6; 3, 3]; 410s y_test = {'A'; 'B'}; 410s L = loss (model, x_test, y_test); 410s assert (L, 0.3333, 1e-4) 410s ***** test 410s x = [1, 2; 3, 4; 5, 6; 7, 8]; 410s y = ['1'; '2'; '3'; '1']; 410s model = fitcdiscr (x, y, "gamma" , 0.5); 410s x_test = [3, 3]; 410s y_test = ['1']; 410s L = loss (model, x_test, y_test, 'LossFun', 'quadratic'); 410s assert (L, 0.2423, 1e-4) 410s ***** test 410s x = [1, 2; 3, 4; 5, 6; 7, 8]; 410s y = ['1'; '2'; '3'; '1']; 410s model = fitcdiscr (x, y, "gamma" , 0.5); 410s x_test = [3, 3; 5, 7]; 410s y_test = ['1'; '2']; 410s L = loss (model, x_test, y_test, 'LossFun', 'classifcost'); 410s assert (L, 0.3333, 1e-4) 410s ***** test 410s x = [1, 2; 3, 4; 5, 6; 7, 8]; 410s y = ['1'; '2'; '3'; '1']; 410s model = fitcdiscr (x, y, "gamma" , 0.5); 410s x_test = [3, 3; 5, 7]; 410s y_test = ['1'; '2']; 410s L = loss (model, x_test, y_test, 'LossFun', 'hinge'); 410s assert (L, 0.5886, 1e-4) 410s ***** test 410s x = [1, 2; 3, 4; 5, 6; 7, 8]; 410s y = ['1'; '2'; '3'; '1']; 410s model = fitcdiscr (x, y, "gamma" , 0.5); 410s x_test = [3, 3; 5, 7]; 410s y_test = ['1'; '2']; 410s W = [1; 2]; 410s L = loss (model, x_test, y_test, 'LossFun', 'logit', 'Weights', W); 410s assert (L, 0.5107, 1e-4) 410s ***** test 410s x = [1, 2; 3, 4; 5, 6]; 410s y = {'A'; 'B'; 'A'}; 410s model = fitcdiscr (x, y, "gamma" , 0.5); 410s x_with_nan = [1, 2; NaN, 4]; 410s y_test = {'A'; 'B'}; 410s L = loss (model, x_with_nan, y_test); 410s assert (L, 0.3333, 1e-4) 410s ***** test 410s x = [1, 2; 3, 4; 5, 6]; 410s y = {'A'; 'B'; 'A'}; 410s model = fitcdiscr (x, y); 410s x_with_nan = [1, 2; NaN, 4]; 410s y_test = {'A'; 'B'}; 410s L = loss (model, x_with_nan, y_test, 'LossFun', 'logit'); 410s assert (isnan (L)) 410s ***** test 410s x = [1, 2; 3, 4; 5, 6]; 410s y = {'A'; 'B'; 'A'}; 410s model = fitcdiscr (x, y); 410s customLossFun = @(C, S, W, Cost) sum (W .* sum (abs (C - S), 2)); 410s L = loss (model, x, y, 'LossFun', customLossFun); 410s assert (L, 0.8889, 1e-4) 410s ***** test 410s x = [1, 2; 3, 4; 5, 6]; 410s y = [1; 2; 1]; 410s model = fitcdiscr (x, y); 410s L = loss (model, x, y, 'LossFun', 'classiferror'); 410s assert (L, 0.3333, 1e-4) 410s ***** error ... 410s loss (MODEL) 410s ***** error ... 410s loss (MODEL, ones (4,2)) 410s ***** error ... 410s loss (MODEL, [], zeros (2)) 410s ***** error ... 410s loss (MODEL, 1, zeros (2)) 410s ***** error ... 410s loss (MODEL, ones (4,2), ones (4,1), 'LossFun') 410s ***** error ... 410s loss (MODEL, ones (4,2), ones (3,1)) 410s ***** error ... 410s loss (MODEL, ones (4,2), ones (4,1), 'LossFun', 'a') 410s ***** error ... 410s loss (MODEL, ones (4,2), ones (4,1), 'Weights', 'w') 410s load fisheriris 410s mdl = fitcdiscr (meas, species); 410s X = mean (meas); 410s Y = {'versicolor'}; 410s m = margin (mdl, X, Y); 410s assert (m, 1, 1e-6) 410s ***** test 410s X = [1, 2; 3, 4; 5, 6]; 410s Y = [1; 2; 1]; 410s mdl = fitcdiscr (X, Y, "gamma", 0.5); 410s m = margin (mdl, X, Y); 410s assert (m, [0.3333; -0.3333; 0.3333], 1e-4) 410s ***** error ... 410s margin (MODEL) 410s ***** error ... 410s margin (MODEL, ones (4,2)) 410s ***** error ... 410s margin (MODEL, [], zeros (2)) 410s ***** error ... 410s margin (MODEL, 1, zeros (2)) 410s ***** error ... 410s margin (MODEL, ones (4,2), ones (3,1)) 410s ***** shared x, y, obj 410s load fisheriris 410s x = meas; 410s y = species; 410s obj = fitcdiscr (x, y, "gamma", 0.4); 410s ***** test 410s CVMdl = crossval (obj); 410s assert (class (CVMdl), "ClassificationPartitionedModel") 410s assert ({CVMdl.X, CVMdl.Y}, {x, y}) 410s assert (CVMdl.KFold == 10) 410s assert (class (CVMdl.Trained{1}), "CompactClassificationDiscriminant") 410s assert (CVMdl.CrossValidatedModel, "ClassificationDiscriminant") 410s ***** test 410s CVMdl = crossval (obj, "KFold", 3); 410s assert (class (CVMdl), "ClassificationPartitionedModel") 410s assert ({CVMdl.X, CVMdl.Y}, {x, y}) 410s assert (CVMdl.KFold == 3) 410s assert (class (CVMdl.Trained{1}), "CompactClassificationDiscriminant") 410s assert (CVMdl.CrossValidatedModel, "ClassificationDiscriminant") 410s ***** test 410s CVMdl = crossval (obj, "HoldOut", 0.2); 410s assert (class (CVMdl), "ClassificationPartitionedModel") 410s assert ({CVMdl.X, CVMdl.Y}, {x, y}) 410s assert (class (CVMdl.Trained{1}), "CompactClassificationDiscriminant") 410s assert (CVMdl.CrossValidatedModel, "ClassificationDiscriminant") 410s ***** test 410s CVMdl = crossval (obj, "LeaveOut", 'on'); 410s assert (class (CVMdl), "ClassificationPartitionedModel") 410s assert ({CVMdl.X, CVMdl.Y}, {x, y}) 410s assert (class (CVMdl.Trained{1}), "CompactClassificationDiscriminant") 410s assert (CVMdl.CrossValidatedModel, "ClassificationDiscriminant") 414s ***** test 414s partition = cvpartition (y, 'KFold', 3); 414s CVMdl = crossval (obj, 'cvPartition', partition); 414s assert (class (CVMdl), "ClassificationPartitionedModel") 414s assert (CVMdl.KFold == 3) 414s assert (class (CVMdl.Trained{1}), "CompactClassificationDiscriminant") 414s assert (CVMdl.CrossValidatedModel, "ClassificationDiscriminant") 414s ***** error ... 414s crossval (obj, "kfold") 414s ***** error... 414s crossval (obj, "kfold", 12, "holdout", 0.2) 414s ***** error ... 414s crossval (obj, "kfold", 'a') 414s ***** error ... 414s crossval (obj, "holdout", 2) 414s ***** error ... 414s crossval (obj, "leaveout", 1) 414s ***** error ... 414s crossval (obj, "cvpartition", 1) 414s 65 tests, 65 passed, 0 known failure, 0 skipped 414s [inst/Classification/CompactClassificationNeuralNetwork.m] 414s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/Classification/CompactClassificationNeuralNetwork.m 414s ***** demo 414s ## Create a neural network classifier and its compact version 414s # and compare their size 414s 414s load fisheriris 414s X = meas; 414s Y = species; 414s 414s Mdl = fitcnet (X, Y, 'ClassNames', unique (species)) 414s CMdl = crossval (Mdl); 414s 414s whos ('Mdl', 'CMdl') 414s ***** error ... 414s CompactClassificationDiscriminant (1) 414s 1 test, 1 passed, 0 known failure, 0 skipped 414s [inst/Classification/ClassificationSVM.m] 414s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/Classification/ClassificationSVM.m 414s ***** demo 414s ## Create a Support Vector Machine classifier and determine margin for test 414s ## data. 414s load fisheriris 414s rng(1); ## For reproducibility 414s 414s ## Select indices of the non-setosa species 414s inds = !strcmp(species, 'setosa'); 414s 414s ## Select features and labels for non-setosa species 414s X = meas(inds, 3:4); 414s Y = grp2idx(species(inds)); 414s 414s ## Convert labels to +1 and -1 414s unique_classes = unique(Y); 414s Y(Y == unique_classes(1)) = -1; 414s Y(Y == unique_classes(2)) = 1; 414s 414s ## Partition data for training and testing 414s cv = cvpartition(Y, 'HoldOut', 0.15); 414s X_train = X(training(cv), :); 414s Y_train = Y(training(cv)); 414s X_test = X(test(cv), :); 414s Y_test = Y(test(cv)); 414s 414s ## Train the SVM model 414s CVSVMModel = fitcsvm(X_train, Y_train); 414s 414s ## Calculate margins 414s m = margin(CVSVMModel, X_test, Y_test); 414s disp(m); 414s ***** demo 414s ## Create a Support Vector Machine classifier and determine loss for test 414s ## data. 414s load fisheriris 414s rng(1); ## For reproducibility 414s 414s ## Select indices of the non-setosa species 414s inds = !strcmp(species, 'setosa'); 414s 414s ## Select features and labels for non-setosa species 414s X = meas(inds, 3:4); 414s Y = grp2idx(species(inds)); 414s 414s ## Convert labels to +1 and -1 414s unique_classes = unique(Y); 414s Y(Y == unique_classes(1)) = -1; 414s Y(Y == unique_classes(2)) = 1; 414s 414s ## Randomly partition the data into training and testing sets 414s cv = cvpartition(Y, 'HoldOut', 0.3); # 30% data for testing, 60% for training 414s 414s X_train = X(training(cv), :); 414s Y_train = Y(training(cv)); 414s 414s X_test = X(test(cv), :); 414s Y_test = Y(test(cv)); 414s 414s ## Train the SVM model 414s SVMModel = fitcsvm(X_train, Y_train); 414s 414s ## Calculate loss 414s 414s L = loss(SVMModel,X_test,Y_test,'LossFun','binodeviance') 414s L = loss(SVMModel,X_test,Y_test,'LossFun','classiferror') 414s L = loss(SVMModel,X_test,Y_test,'LossFun','exponential') 414s L = loss(SVMModel,X_test,Y_test,'LossFun','hinge') 414s L = loss(SVMModel,X_test,Y_test,'LossFun','logit') 414s L = loss(SVMModel,X_test,Y_test,'LossFun','quadratic') 414s ***** test 414s x = [1, 2, 3; 4, 5, 6; 7, 8, 9; 3, 2, 1; 4, 5, 6; 7, 8, 9; ... 414s 3, 2, 1; 4, 5, 6; 7, 8, 9; 3, 2, 1; 4, 5, 6; 7, 8, 9; 3, 2, 1]; 414s y = [1; 2; 3; 4; 2; 3; 4; 2; 3; 4; 2; 3; 4]; 414s a = ClassificationSVM (x, y, "ClassNames", [1, 2]); 414s assert (class (a), "ClassificationSVM"); 414s assert (a.RowsUsed, [1, 1, 0, 0, 1, 0, 0, 1, 0, 0, 1, 0, 0]'); 414s assert ({a.X, a.Y}, {x, y}) 414s assert (a.NumObservations, 5) 414s assert ({a.ResponseName, a.PredictorNames}, {"Y", {"x1", "x2", "x3"}}) 414s assert ({a.ClassNames, a.ModelParameters.SVMtype}, {[1; 2], "c_svc"}) 414s ***** test 414s x = [1, 2; 2, 3; 3, 4; 4, 5; 2, 3; 3, 4; 2, 3; 3, 4; 2, 3; 3, 4]; 414s y = [1; 1; -1; -1; 1; -1; -1; -1; -1; -1]; 414s a = ClassificationSVM (x, y); 414s assert (class (a), "ClassificationSVM"); 414s assert ({a.X, a.Y, a.ModelParameters.KernelFunction}, {x, y, "linear"}) 414s assert (a.ModelParameters.BoxConstraint, 1) 414s assert (a.ClassNames, [1; -1]) 414s assert (a.ModelParameters.KernelOffset, 0) 414s ***** test 414s x = [1, 2; 2, 3; 3, 4; 4, 5; 2, 3; 3, 4; 2, 3; 3, 4; 2, 3; 3, 4]; 414s y = [1; 1; -1; -1; 1; -1; -1; -1; -1; -1]; 414s a = ClassificationSVM (x, y, "KernelFunction", "rbf", "BoxConstraint", 2, ... 414s "KernelOffset", 2); 414s assert (class (a), "ClassificationSVM"); 414s assert ({a.X, a.Y, a.ModelParameters.KernelFunction}, {x, y, "rbf"}) 414s assert (a.ModelParameters.BoxConstraint, 2) 414s assert (a.ModelParameters.KernelOffset, 2) 414s ***** test 414s x = [1, 2; 2, 3; 3, 4; 4, 5; 2, 3; 3, 4; 2, 3; 3, 4; 2, 3; 3, 4]; 414s y = [1; 1; -1; -1; 1; -1; -1; -1; -1; -1]; 414s a = ClassificationSVM (x, y, "KernelFunction", "polynomial", ... 414s "PolynomialOrder", 3); 414s assert (class (a), "ClassificationSVM"); 414s assert ({a.X, a.Y, a.ModelParameters.KernelFunction}, {x, y, "polynomial"}) 414s assert (a.ModelParameters.PolynomialOrder, 3) 414s ***** error ClassificationSVM () 414s ***** error ... 414s ClassificationSVM (ones(10,2)) 414s ***** error ... 414s ClassificationSVM (ones(10,2), ones (5,1)) 414s ***** error ... 414s ClassificationSVM (ones(10,2), ones (10,1), "Standardize", 'a') 414s ***** error ... 414s ClassificationSVM (ones(10,2), ones (10,1), "PredictorNames", ['x1';'x2']) 414s ***** error ... 414s ClassificationSVM (ones(10,2), ones (10,1), "PredictorNames", {'x1','x2','x3'}) 414s ***** error ... 414s ClassificationSVM (ones(10,2), ones (10,1), "ResponseName", {'Y'}) 414s ***** error ... 414s ClassificationSVM (ones(10,2), ones (10,1), "ResponseName", 21) 414s ***** error ... 414s ClassificationSVM (ones(10,2), ones (10,1), "ClassNames", @(x)x) 414s ***** error ... 414s ClassificationSVM (ones(10,2), ones (10,1), "ClassNames", ['a']) 414s ***** error ... 414s ClassificationSVM (ones(10,2), ones (10,1), "ClassNames", [1, 2]) 414s ***** error ... 414s ClassificationSVM (ones(5,2), {'a';'b';'a';'a';'b'}, "ClassNames", {'a','c'}) 414s ***** error ... 414s ClassificationSVM (ones(10,2), logical (ones (10,1)), "ClassNames", [true, false]) 414s ***** error ... 414s ClassificationSVM (ones(10,2), ones(10,1), "Prior", {"asd"}) 414s ***** error ... 414s ClassificationSVM (ones(10,2), ones(10,1), "Prior", ones (2)) 414s ***** error ... 414s ClassificationSVM (ones(10,2), ones(10,1), "Cost", [1:4]) 414s ***** error ... 414s ClassificationSVM (ones(10,2), ones(10,1), "Cost", {0,1;1,0}) 414s ***** error ... 414s ClassificationSVM (ones(10,2), ones(10,1), "Cost", 'a') 414s ***** error ... 414s ClassificationSVM (ones(10,2), ones(10,1), "svmtype", 123) 414s ***** error ... 414s ClassificationSVM (ones(10,2), ones(10,1), "svmtype", 'some_type') 414s ***** error ... 414s ClassificationSVM (ones(10,2), ones(10,1), "OutlierFraction", -1) 414s ***** error ... 414s ClassificationSVM (ones(10,2), ones(10,1), "KernelFunction", 123) 414s ***** error ... 414s ClassificationSVM (ones(10,2), ones(10,1), "KernelFunction", "fcn") 414s ***** error ... 414s ClassificationSVM (ones(10,2), ones(10,1), "PolynomialOrder", -1) 414s ***** error ... 414s ClassificationSVM (ones(10,2), ones(10,1), "PolynomialOrder", 0.5) 414s ***** error ... 414s ClassificationSVM (ones(10,2), ones(10,1), "PolynomialOrder", [1,2]) 414s ***** error ... 414s ClassificationSVM (ones(10,2), ones (10,1), "KernelScale", -1) 414s ***** error ... 414s ClassificationSVM (ones(10,2), ones (10,1), "KernelScale", 0) 414s ***** error ... 414s ClassificationSVM (ones(10,2), ones (10,1), "KernelScale", [1, 2]) 414s ***** error ... 414s ClassificationSVM (ones(10,2), ones (10,1), "KernelScale", "invalid") 414s ***** error ... 414s ClassificationSVM (ones(10,2), ones(10,1), "KernelOffset", -1) 414s ***** error ... 414s ClassificationSVM (ones(10,2), ones(10,1), "KernelOffset", [1,2]) 414s ***** error ... 414s ClassificationSVM (ones(10,2), ones (10,1), "BoxConstraint", -1) 414s ***** error ... 414s ClassificationSVM (ones(10,2), ones (10,1), "BoxConstraint", 0) 414s ***** error ... 414s ClassificationSVM (ones(10,2), ones (10,1), "BoxConstraint", [1, 2]) 414s ***** error ... 414s ClassificationSVM (ones(10,2), ones (10,1), "BoxConstraint", "invalid") 414s ***** error ... 414s ClassificationSVM (ones(10,2), ones(10,1), "nu", -0.5) 414s ***** error ... 414s ClassificationSVM (ones(10,2), ones(10,1), "nu", 0) 414s ***** error ... 414s ClassificationSVM (ones(10,2), ones(10,1), "nu", 1.5) 414s ***** error ... 414s ClassificationSVM (ones(10,2), ones(10,1), "CacheSize", -1) 414s ***** error ... 414s ClassificationSVM (ones(10,2), ones(10,1), "CacheSize", [1,2]) 414s ***** error ... 414s ClassificationSVM (ones(10,2), ones(10,1), "Tolerance", -0.1) 414s ***** error ... 414s ClassificationSVM (ones(10,2), ones(10,1), "Tolerance", [0.1,0.2]) 414s ***** error ... 414s ClassificationSVM (ones(10,2), ones(10,1), "shrinking", 2) 414s ***** error ... 414s ClassificationSVM (ones(10,2), ones(10,1), "shrinking", -1) 414s ***** error ... 414s ClassificationSVM (ones(10,2), ones(10,1), "shrinking", [1 0]) 414s ***** error ... 414s ClassificationSVM (ones(10,2), ones(10,1), "invalid_name", 'c_svc') 414s ***** error ... 414s ClassificationSVM (ones(10,2), ones(10,1), "SVMtype", 'c_svc') 414s ***** error ... 414s ClassificationSVM (ones(10,2), [1;1;1;1;2;2;2;2;3;3]) 414s ***** error ... 414s ClassificationSVM ([ones(9,2);2,Inf], ones(10,1)) 414s ***** error ... 414s ClassificationSVM (ones (5,2), ones (5,1), "Prior", [0,1]) 414s ***** error ... 414s ClassificationSVM (ones (5,2), [1;1;2;2;3], "ClassNames", [1,2], "Prior", [0,0.4,0.6]) 414s ***** error ... 414s ClassificationSVM (ones (5,2), [1;1;2;2;3], "ClassNames", [1,2], "Cost", ones (3)) 414s ***** shared x, y, x_train, x_test, y_train, y_test, objST 414s load fisheriris 414s inds = ! strcmp (species, 'setosa'); 414s x = meas(inds, 3:4); 414s y = grp2idx (species(inds)); 414s ***** test 414s xc = [min(x); mean(x); max(x)]; 414s obj = fitcsvm (x, y, 'KernelFunction', 'rbf', 'Tolerance', 1e-7); 414s assert (isempty (obj.Alpha), true) 414s assert (sum (obj.IsSupportVector), numel (obj.Beta)) 414s [label, score] = predict (obj, xc); 414s assert (label, [1; 2; 2]); 414s assert (score(:,1), [0.99285; -0.080296; -0.93694], 1e-5); 414s assert (score(:,1), -score(:,2), eps) 414s obj = fitPosterior (obj); 414s [label, probs] = predict (obj, xc); 414s assert (probs(:,2), [0.97555; 0.428164; 0.030385], 1e-5); 414s assert (probs(:,1) + probs(:,2), [1; 1; 1], 0.05) 415s ***** test 415s obj = fitcsvm (x, y); 415s assert (isempty (obj.Beta), true) 415s assert (sum (obj.IsSupportVector), numel (obj.Alpha)) 415s assert (numel (obj.Alpha), 24) 415s assert (obj.Bias, -14.415, 1e-3) 415s xc = [min(x); mean(x); max(x)]; 415s label = predict (obj, xc); 415s assert (label, [1; 2; 2]); 415s ***** error ... 415s predict (ClassificationSVM (ones (40,2), ones (40,1))) 415s ***** error ... 415s predict (ClassificationSVM (ones (40,2), ones (40,1)), []) 415s ***** error ... 415s predict (ClassificationSVM (ones (40,2), ones (40,1)), 1) 415s ***** test 415s objST = fitcsvm (x, y); 415s objST.ScoreTransform = "a"; 415s ***** error ... 415s [labels, scores] = predict (objST, x); 415s ***** error ... 415s [labels, scores] = resubPredict (objST); 415s ***** test 415s rand ("seed", 1); 415s CVSVMModel = fitcsvm (x, y, 'KernelFunction', 'rbf', 'HoldOut', 0.15, ... 415s 'Tolerance', 1e-7); 415s obj = CVSVMModel.Trained{1}; 415s testInds = test (CVSVMModel.Partition); 415s expected_margin = [2.0000; 0.8579; 1.6690; 3.4141; 3.4552; ... 415s 2.6605; 3.5251; -4.0000; -6.3411; -6.4511; ... 415s -3.0532; -7.5054; -1.6700; -5.6227; -7.3640]; 415s computed_margin = margin (obj, x(testInds,:), y(testInds,:)); 415s assert (computed_margin, expected_margin, 1e-4); 415s ***** error ... 415s margin (ClassificationSVM (ones (40,2), randi ([1, 2], 40, 1))) 415s ***** error ... 415s margin (ClassificationSVM (ones (40,2), randi ([1, 2], 40, 1)), zeros (2)) 415s ***** error ... 415s margin (ClassificationSVM (ones (40,2), randi ([1, 2], 40, 1)), [], zeros (2)) 415s ***** error ... 415s margin (ClassificationSVM (ones (40,2), randi ([1, 2], 40, 1)), 1, zeros (2)) 415s ***** error ... 415s margin (ClassificationSVM (ones (40,2), randi ([1, 2], 40, 1)), zeros (2), []) 415s ***** error ... 415s margin (ClassificationSVM (ones (40,2), randi ([1, 2], 40, 1)), zeros (2), 1) 415s ***** test 415s rand ("seed", 1); 415s CVSVMModel = fitcsvm (x, y, 'KernelFunction', 'rbf', 'HoldOut', 0.15); 415s obj = CVSVMModel.Trained{1}; 415s testInds = test (CVSVMModel.Partition); 415s L1 = loss (obj, x(testInds,:), y(testInds,:), 'LossFun', 'binodeviance'); 415s L2 = loss (obj, x(testInds,:), y(testInds,:), 'LossFun', 'classiferror'); 415s L3 = loss (obj, x(testInds,:), y(testInds,:), 'LossFun', 'exponential'); 415s L4 = loss (obj, x(testInds,:), y(testInds,:), 'LossFun', 'hinge'); 415s L5 = loss (obj, x(testInds,:), y(testInds,:), 'LossFun', 'logit'); 415s L6 = loss (obj, x(testInds,:), y(testInds,:), 'LossFun', 'quadratic'); 415s assert (L1, 2.8711, 1e-4); 415s assert (L2, 0.5333, 1e-4); 415s assert (L3, 10.9685, 1e-4); 415s assert (L4, 1.9827, 1e-4); 415s assert (L5, 1.5849, 1e-4); 415s assert (L6, 7.6739, 1e-4); 415s ***** error ... 415s loss (ClassificationSVM (ones (40,2), randi ([1, 2], 40, 1))) 415s ***** error ... 415s loss (ClassificationSVM (ones (40,2), randi ([1, 2], 40, 1)), zeros (2)) 415s ***** error ... 415s loss (ClassificationSVM (ones (40,2), randi ([1, 2], 40, 1)), zeros (2), ... 415s ones(2,1), "LossFun") 415s ***** error ... 415s loss (ClassificationSVM (ones (40,2), randi ([1, 2], 40, 1)), [], zeros (2)) 415s ***** error ... 415s loss (ClassificationSVM (ones (40,2), randi ([1, 2], 40, 1)), 1, zeros (2)) 415s ***** error ... 415s loss (ClassificationSVM (ones (40,2), randi ([1, 2], 40, 1)), zeros (2), []) 415s ***** error ... 415s loss (ClassificationSVM (ones (40,2), randi ([1, 2], 40, 1)), zeros (2), 1) 415s ***** error ... 415s loss (ClassificationSVM (ones (40,2), randi ([1, 2], 40, 1)), zeros (2), ... 415s ones (2,1), "LossFun", 1) 415s ***** error ... 415s loss (ClassificationSVM (ones (40,2), randi ([1, 2], 40, 1)), zeros (2), ... 415s ones (2,1), "LossFun", "some") 415s ***** error ... 415s loss (ClassificationSVM (ones (40,2), randi ([1, 2], 40, 1)), zeros (2), ... 415s ones (2,1), "Weights", ['a','b']) 415s ***** error ... 415s loss (ClassificationSVM (ones (40,2), randi ([1, 2], 40, 1)), zeros (2), ... 415s ones (2,1), "Weights", 'a') 415s ***** error ... 415s loss (ClassificationSVM (ones (40,2), randi ([1, 2], 40, 1)), zeros (2), ... 415s ones (2,1), "Weights", [1,2,3]) 415s ***** error ... 415s loss (ClassificationSVM (ones (40,2), randi ([1, 2], 40, 1)), zeros (2), ... 415s ones (2,1), "Weights", 3) 415s ***** error ... 415s loss (ClassificationSVM (ones (40,2), randi ([1, 2], 40, 1)), zeros (2), ... 415s ones (2,1), "some", "some") 415s ***** error ... 415s resubLoss (ClassificationSVM (ones (40,2), randi ([1, 2], 40, 1)), "LossFun") 415s ***** error ... 415s resubLoss (ClassificationSVM (ones (40,2), randi ([1, 2], 40, 1)), "LossFun", 1) 415s ***** error ... 415s resubLoss (ClassificationSVM (ones (40,2), randi ([1, 2], 40, 1)), "LossFun", "some") 415s ***** error ... 415s resubLoss (ClassificationSVM (ones (40,2), randi ([1, 2], 40, 1)), "Weights", ['a','b']) 415s ***** error ... 415s resubLoss (ClassificationSVM (ones (40,2), randi ([1, 2], 40, 1)), "Weights", 'a') 415s ***** error ... 415s resubLoss (ClassificationSVM (ones (40,2), randi ([1, 2], 40, 1)), "Weights", [1,2,3]) 415s ***** error ... 415s resubLoss (ClassificationSVM (ones (40,2), randi ([1, 2], 40, 1)), "Weights", 3) 415s ***** error ... 415s resubLoss (ClassificationSVM (ones (40,2), randi ([1, 2], 40, 1)), "some", "some") 415s ***** test 415s SVMModel = fitcsvm (x, y); 415s CVMdl = crossval (SVMModel, "KFold", 5); 415s assert (class (CVMdl), "ClassificationPartitionedModel") 415s assert ({CVMdl.X, CVMdl.Y}, {x, y}) 415s assert (CVMdl.KFold == 5) 415s assert (class (CVMdl.Trained{1}), "CompactClassificationSVM") 415s assert (CVMdl.CrossValidatedModel, "ClassificationSVM") 415s ***** test 415s obj = fitcsvm (x, y); 415s CVMdl = crossval (obj, "HoldOut", 0.2); 415s assert (class (CVMdl), "ClassificationPartitionedModel") 415s assert ({CVMdl.X, CVMdl.Y}, {x, y}) 415s assert (class (CVMdl.Trained{1}), "CompactClassificationSVM") 415s assert (CVMdl.CrossValidatedModel, "ClassificationSVM") 415s ***** test 415s obj = fitcsvm (x, y); 415s CVMdl = crossval (obj, "LeaveOut", 'on'); 415s assert (class (CVMdl), "ClassificationPartitionedModel") 415s assert ({CVMdl.X, CVMdl.Y}, {x, y}) 415s assert (class (CVMdl.Trained{1}), "CompactClassificationSVM") 415s assert (CVMdl.CrossValidatedModel, "ClassificationSVM") 416s ***** error ... 416s crossval (ClassificationSVM (ones (40,2),randi([1, 2], 40, 1)), "KFold") 416s ***** error ... 416s crossval (ClassificationSVM (ones (40,2),randi([1, 2], 40, 1)), ... 416s "KFold", 5, "leaveout", 'on') 416s ***** error ... 416s crossval (ClassificationSVM (ones (40,2),randi([1, 2], 40, 1)), "KFold", 'a') 417s ***** error ... 417s crossval (ClassificationSVM (ones (40,2),randi([1, 2], 40, 1)), "KFold", 1) 417s ***** error ... 417s crossval (ClassificationSVM (ones (40,2),randi([1, 2], 40, 1)), "KFold", -1) 417s ***** error ... 417s crossval (ClassificationSVM (ones (40,2),randi([1, 2], 40, 1)), "KFold", 11.5) 417s ***** error ... 417s crossval (ClassificationSVM (ones (40,2),randi([1, 2], 40, 1)), "KFold", [1,2]) 417s ***** error ... 417s crossval (ClassificationSVM (ones (40,2),randi([1, 2], 40, 1)), "Holdout", 'a') 417s ***** error ... 417s crossval (ClassificationSVM (ones (40,2),randi([1, 2], 40, 1)), "Holdout", 11.5) 417s ***** error ... 417s crossval (ClassificationSVM (ones (40,2),randi([1, 2], 40, 1)), "Holdout", -1) 417s ***** error ... 417s crossval (ClassificationSVM (ones (40,2),randi([1, 2], 40, 1)), "Holdout", 0) 417s ***** error ... 417s crossval (ClassificationSVM (ones (40,2),randi([1, 2], 40, 1)), "Holdout", 1) 417s ***** error ... 417s crossval (ClassificationSVM (ones (40,2),randi([1, 2], 40, 1)), "Leaveout", 1) 417s ***** error ... 417s crossval (ClassificationSVM (ones (40,2),randi([1, 2], 40, 1)), "CVPartition", 1) 417s ***** error ... 417s crossval (ClassificationSVM (ones (40,2),randi([1, 2], 40, 1)), "CVPartition", 'a') 417s ***** error ... 417s crossval (ClassificationSVM (ones (40,2),randi([1, 2], 40, 1)), "some", "some") 417s 114 tests, 114 passed, 0 known failure, 0 skipped 417s [inst/Classification/CompactClassificationGAM.m] 417s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/Classification/CompactClassificationGAM.m 417s ***** demo 417s ## Create a generalized additive model classifier and its compact version 417s # and compare their size 417s 417s load fisheriris 417s X = meas; 417s Y = species; 417s 417s Mdl = fitcdiscr (X, Y, 'ClassNames', unique (species)) 417s CMdl = crossval (Mdl); 417s 417s whos ('Mdl', 'CMdl') 417s ***** test 417s Mdl = CompactClassificationGAM (); 417s assert (class (Mdl), "CompactClassificationGAM") 417s ***** test 417s x = [1, 2, 3; 4, 5, 6; 7, 8, 9; 3, 2, 1]; 417s y = [0; 0; 1; 1]; 417s PredictorNames = {'Feature1', 'Feature2', 'Feature3'}; 417s Mdl = fitcgam (x, y, "PredictorNames", PredictorNames); 417s CMdl = compact (Mdl); 417s assert (class (CMdl), "CompactClassificationGAM"); 417s assert ({CMdl.NumPredictors, CMdl.ResponseName}, {3, "Y"}) 417s assert (CMdl.ClassNames, {'0'; '1'}) 417s assert (CMdl.PredictorNames, PredictorNames) 417s assert (CMdl.BaseModel.Intercept, 0) 419s ***** test 419s load fisheriris 419s inds = strcmp (species,'versicolor') | strcmp (species,'virginica'); 419s X = meas(inds, :); 419s Y = species(inds, :)'; 419s Y = strcmp (Y, 'virginica')'; 419s Mdl = fitcgam (X, Y, 'Formula', 'Y ~ x1 + x2 + x3 + x4 + x1:x2 + x2:x3'); 419s CMdl = compact (Mdl); 419s assert (class (CMdl), "CompactClassificationGAM"); 419s assert ({CMdl.NumPredictors, CMdl.ResponseName}, {4, "Y"}) 419s assert (CMdl.ClassNames, {'0'; '1'}) 419s assert (CMdl.Formula, 'Y ~ x1 + x2 + x3 + x4 + x1:x2 + x2:x3') 419s assert (CMdl.PredictorNames, {'x1', 'x2', 'x3', 'x4'}) 419s assert (CMdl.ModelwInt.Intercept, 0) 429s ***** test 429s X = [2, 3, 5; 4, 6, 8; 1, 2, 3; 7, 8, 9; 5, 4, 3]; 429s Y = [0; 1; 0; 1; 1]; 429s Mdl = fitcgam (X, Y, 'Knots', [4, 4, 4], 'Order', [3, 3, 3]); 429s CMdl = compact (Mdl); 429s assert (class (CMdl), "CompactClassificationGAM"); 429s assert ({CMdl.NumPredictors, CMdl.ResponseName}, {3, "Y"}) 429s assert (CMdl.ClassNames, {'0'; '1'}) 429s assert (CMdl.PredictorNames, {'x1', 'x2', 'x3'}) 429s assert (CMdl.Knots, [4, 4, 4]) 429s assert (CMdl.Order, [3, 3, 3]) 429s assert (CMdl.DoF, [7, 7, 7]) 429s assert (CMdl.BaseModel.Intercept, 0.4055, 1e-1) 431s ***** error ... 432s CompactClassificationGAM (1) 432s ***** test 432s x = [1, 2; 3, 4; 5, 6; 7, 8; 9, 10]; 432s y = [1; 0; 1; 0; 1]; 432s Mdl = fitcgam (x, y, "interactions", "all"); 432s CMdl = compact (Mdl); 432s l = {'0'; '0'; '0'; '0'; '0'}; 432s s = [0.3760, 0.6240; 0.4259, 0.5741; 0.3760, 0.6240; ... 432s 0.4259, 0.5741; 0.3760, 0.6240]; 432s [labels, scores] = predict (CMdl, x); 432s assert (class (CMdl), "CompactClassificationGAM"); 432s assert ({CMdl.NumPredictors, CMdl.ResponseName}, {2, "Y"}) 432s assert (CMdl.ClassNames, {'1'; '0'}) 432s assert (CMdl.PredictorNames, {'x1', 'x2'}) 432s assert (CMdl.ModelwInt.Intercept, 0.4055, 1e-1) 432s assert (labels, l) 432s assert (scores, s, 1e-1) 436s ***** test 436s x = [1, 2, 3; 4, 5, 6; 7, 8, 9; 3, 2, 1]; 436s y = [0; 0; 1; 1]; 436s interactions = [false, true, false; true, false, true; false, true, false]; 436s Mdl = fitcgam (x, y, "learningrate", 0.2, "interactions", interactions); 436s CMdl = compact (Mdl); 436s [label, score] = predict (CMdl, x, "includeinteractions", true); 436s l = {'0'; '0'; '1'; '1'}; 436s s = [0.5106, 0.4894; 0.5135, 0.4865; 0.4864, 0.5136; 0.4847, 0.5153]; 436s assert (class (CMdl), "CompactClassificationGAM"); 436s assert ({CMdl.NumPredictors, CMdl.ResponseName}, {3, "Y"}) 436s assert (CMdl.ClassNames, {'0'; '1'}) 436s assert (CMdl.PredictorNames, {'x1', 'x2', 'x3'}) 436s assert (CMdl.ModelwInt.Intercept, 0) 436s assert (label, l) 436s assert (score, s, 1e-1) 444s ***** shared CMdl 444s Mdl = fitcgam (ones (4,2), ones (4,1)); 444s CMdl = compact (Mdl); 445s ***** error ... 445s predict (CMdl) 445s ***** error ... 445s predict (CMdl, []) 445s ***** error ... 445s predict (CMdl, 1) 445s 10 tests, 10 passed, 0 known failure, 0 skipped 445s [inst/x2fx.m] 445s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/x2fx.m 445s ***** test 445s X = [1, 10; 2, 20; 3, 10; 4, 20; 5, 15; 6, 15]; 445s D = x2fx(X,'quadratic'); 445s assert (D(1,:) , [1, 1, 10, 10, 1, 100]); 445s assert (D(2,:) , [1, 2, 20, 40, 4, 400]); 445s ***** test 445s X = [1, 10; 2, 20; 3, 10; 4, 20; 5, 15; 6, 15]; 445s model = [0, 0; 1, 0; 0, 1; 1, 1; 2, 0]; 445s D = x2fx(X,model); 445s assert (D(1,:) , [1, 1, 10, 10, 1]); 445s assert (D(2,:) , [1, 2, 20, 40, 4]); 445s assert (D(4,:) , [1, 4, 20, 80, 16]); 445s ***** error x2fx ([1, 10; 2, 20; 3, 10], [0; 1]); 445s ***** error x2fx ([1, 10, 15; 2, 20, 40; 3, 10, 25], [0, 0; 1, 0; 0, 1; 1, 1; 2, 0]); 445s ***** error x2fx ([1, 10; 2, 20; 3, 10], "whatever"); 445s 5 tests, 5 passed, 0 known failure, 0 skipped 445s [inst/ttest.m] 445s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/ttest.m 445s ***** test 445s x = 8:0.1:12; 445s [h, pval, ci] = ttest (x, 10); 445s assert (h, 0) 445s assert (pval, 1, 10*eps) 445s assert (ci, [9.6219 10.3781], 1E-5) 445s [h, pval, ci0] = ttest (x, 0); 445s assert (h, 1) 445s assert (pval, 0) 445s assert (ci0, ci, 2e-15) 445s [h, pval, ci] = ttest (x, 10, "tail", "right", "dim", 2, "alpha", 0.05); 445s assert (h, 0) 445s assert (pval, 0.5, 10*eps) 445s assert (ci, [9.68498 Inf], 1E-5) 446s ***** error ttest ([8:0.1:12], 10, "tail", "invalid"); 446s ***** error ttest ([8:0.1:12], 10, "tail", 25); 446s 3 tests, 3 passed, 0 known failure, 0 skipped 446s [inst/anova1.m] 446s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/anova1.m 446s ***** demo 446s x = meshgrid (1:6); 446s randn ("seed", 15); # for reproducibility 446s x = x + normrnd (0, 1, 6, 6); 446s anova1 (x, [], 'off'); 446s ***** demo 446s x = meshgrid (1:6); 446s randn ("seed", 15); # for reproducibility 446s x = x + normrnd (0, 1, 6, 6); 446s [p, atab] = anova1(x); 446s ***** demo 446s x = ones (50, 4) .* [-2, 0, 1, 5]; 446s randn ("seed", 13); # for reproducibility 446s x = x + normrnd (0, 2, 50, 4); 446s groups = {"A", "B", "C", "D"}; 446s anova1 (x, groups); 446s ***** demo 446s y = [54 87 45; 23 98 39; 45 64 51; 54 77 49; 45 89 50; 47 NaN 55]; 446s g = [1 2 3 ; 1 2 3 ; 1 2 3 ; 1 2 3 ; 1 2 3 ; 1 2 3 ]; 446s anova1 (y(:), g(:), "on", "unequal"); 446s ***** test 446s data = [1.006, 0.996, 0.998, 1.000, 0.992, 0.993, 1.002, 0.999, 0.994, 1.000, ... 446s 0.998, 1.006, 1.000, 1.002, 0.997, 0.998, 0.996, 1.000, 1.006, 0.988, ... 446s 0.991, 0.987, 0.997, 0.999, 0.995, 0.994, 1.000, 0.999, 0.996, 0.996, ... 446s 1.005, 1.002, 0.994, 1.000, 0.995, 0.994, 0.998, 0.996, 1.002, 0.996, ... 446s 0.998, 0.998, 0.982, 0.990, 1.002, 0.984, 0.996, 0.993, 0.980, 0.996, ... 446s 1.009, 1.013, 1.009, 0.997, 0.988, 1.002, 0.995, 0.998, 0.981, 0.996, ... 446s 0.990, 1.004, 0.996, 1.001, 0.998, 1.000, 1.018, 1.010, 0.996, 1.002, ... 446s 0.998, 1.000, 1.006, 1.000, 1.002, 0.996, 0.998, 0.996, 1.002, 1.006, ... 446s 1.002, 0.998, 0.996, 0.995, 0.996, 1.004, 1.004, 0.998, 0.999, 0.991, ... 446s 0.991, 0.995, 0.984, 0.994, 0.997, 0.997, 0.991, 0.998, 1.004, 0.997]; 446s group = [1:10] .* ones (10,10); 446s group = group(:); 446s [p, tbl] = anova1 (data, group, "off"); 446s assert (p, 0.022661, 1e-6); 446s assert (tbl{2,5}, 2.2969, 1e-4); 446s assert (tbl{2,3}, 9, 0); 446s assert (tbl{4,2}, 0.003903, 1e-6); 446s data = reshape (data, 10, 10); 446s [p, tbl, stats] = anova1 (data, [], "off"); 446s assert (p, 0.022661, 1e-6); 446s assert (tbl{2,5}, 2.2969, 1e-4); 446s assert (tbl{2,3}, 9, 0); 446s assert (tbl{4,2}, 0.003903, 1e-6); 446s means = [0.998, 0.9991, 0.9954, 0.9982, 0.9919, 0.9988, 1.0015, 1.0004, 0.9983, 0.9948]; 446s N = 10 * ones (1, 10); 446s assert (stats.means, means, 1e-6); 446s assert (length (stats.gnames), 10, 0); 446s assert (stats.n, N, 0); 446s ***** test 446s y = [54 87 45; 23 98 39; 45 64 51; 54 77 49; 45 89 50; 47 NaN 55]; 446s g = [1 2 3 ; 1 2 3 ; 1 2 3 ; 1 2 3 ; 1 2 3 ; 1 2 3 ]; 446s [p, tbl] = anova1 (y(:), g(:), "off", "equal"); 446s assert (p, 0.00004163, 1e-6); 446s assert (tbl{2,5}, 22.573418, 1e-6); 446s assert (tbl{2,3}, 2, 0); 446s assert (tbl{3,3}, 14, 0); 446s [p, tbl] = anova1 (y(:), g(:), "off", "unequal"); 446s assert (p, 0.00208877, 1e-8); 446s assert (tbl{2,5}, 15.523192, 1e-6); 446s assert (tbl{2,3}, 2, 0); 446s assert (tbl{2,4}, 7.5786897, 1e-6); 446s 2 tests, 2 passed, 0 known failure, 0 skipped 446s [inst/bar3.m] 446s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/bar3.m 446s ***** demo 446s ## Ploting 5 bars in the same series. 446s 446s z = [50; 40; 30; 20; 10]; 446s bar3 (z); 446s ***** demo 446s ## Ploting 5 bars in different groups. 446s 446s z = [50, 40, 30, 20, 10]; 446s bar3 (z); 446s ***** demo 446s ## A 3D bar graph with each series corresponding to a column in z. 446s 446s z = [1, 4, 7; 2, 5, 8; 3, 6, 9; 4, 7, 10]; 446s bar3 (z); 446s ***** demo 446s ## Specify y-axis locations as tick names. y must be a column vector! 446s 446s y = [1950, 1960, 1970, 1980, 1990]'; 446s z = [16, 8, 4, 2, 1]'; 446s bar3 (y, z); 446s ***** demo 446s ## Plot 3 series as a grouped plot without any space between the grouped bars 446s 446s z = [70 50 33 10; 75 55 35 15; 80 60 40 20]; 446s bar3 (z, 1, 'grouped'); 446s ***** demo 446s ## Plot a stacked style 3D bar graph 446s 446s z = [19, 30, 21, 30; 40, 16, 32, 12]; 446s b = bar3 (z, 0.5, 'stacked'); 446s ***** error bar3 ("A") 446s ***** error bar3 ({2,3,4,5}) 446s ***** error ... 446s bar3 ([1,2,3]', ones (2)) 446s ***** error ... 446s bar3 ([1:5], 1.2) 446s ***** error ... 446s bar3 ([1:5]', ones (5), 1.2) 446s ***** error ... 446s bar3 ([1:5]', ones (5), [0.8, 0.7]) 446s ***** error ... 446s bar3 (ones (5), 'width') 446s ***** error ... 446s bar3 (ones (5), 'width', 1.2) 446s ***** error ... 446s bar3 (ones (5), 'width', [0.8, 0.8, 0.8]) 446s ***** error ... 446s bar3 (ones (5), 'color') 446s ***** error ... 446s bar3 (ones (5), 'color', [0.8, 0.8]) 446s ***** error ... 446s bar3 (ones (5), 'color', "brown") 446s ***** error ... 446s bar3 (ones (5), 'color', {"r", "k", "c", "m", "brown"}) 446s ***** error ... 446s bar3 (ones (5), 'xlabel') 446s ***** error ... 446s bar3 (ones (5), 'xlabel', 4) 446s ***** error ... 446s bar3 (ones (5), 'ylabel') 446s ***** error ... 446s bar3 (ones (5), 'ylabel', 4) 446s ***** error bar3 (ones (5), 'this', 4) 446s ***** error ... 446s bar3 (ones (5), 'xlabel', {"A", "B", "C"}) 446s ***** error ... 446s bar3 (ones (5), 'ylabel', {"A", "B", "C"}) 446s 20 tests, 20 passed, 0 known failure, 0 skipped 446s [inst/crossval.m] 446s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/crossval.m 446s ***** test 446s load fisheriris 446s y = meas(:, 1); 446s X = [ones(size(y)) meas(:, 2:4)]; 446s f = @(X1, y1, X2, y2) meansq (y2 - X2*regress(y1, X1)); 446s results0 = crossval (f, X, y); 446s results1 = crossval (f, X, y, 'KFold', 10); 446s folds = 5; 446s results2 = crossval (f, X, y, 'KFold', folds); 446s results3 = crossval (f, X, y, 'Partition', cvpartition (numel (y), 'KFold', folds)); 446s results4 = crossval (f, X, y, 'LeaveOut', 1); 446s mcreps = 2; n_holdout = 20; 446s results5 = crossval (f, X, y, 'HoldOut', n_holdout, 'mcreps', mcreps); 446s 446s ## ensure equal representation of iris species in the training set -- tends 446s ## to slightly reduce cross-validation mean square error 446s results6 = crossval (f, X, y, 'KFold', 5, 'stratify', grp2idx(species)); 446s 446s assert (results0, results1, 2e-15); 446s assert (results2, results3, 5e-17); 446s assert (size(results4), [1 numel(y)]); 446s assert (mean(results4), 0.1018, 1e-4); 446s assert (size(results5), [mcreps 1]); 446s warning: strmatch is obsolete; use strncmp or strcmp instead 446s 1 test, 1 passed, 0 known failure, 0 skipped 446s [inst/Regression/RegressionGAM.m] 446s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/Regression/RegressionGAM.m 446s ***** demo 446s ## Train a RegressionGAM Model for synthetic values 446s f1 = @(x) cos (3 * x); 446s f2 = @(x) x .^ 3; 446s x1 = 2 * rand (50, 1) - 1; 446s x2 = 2 * rand (50, 1) - 1; 446s y = f1(x1) + f2(x2); 446s y = y + y .* 0.2 .* rand (50,1); 446s X = [x1, x2]; 446s a = fitrgam (X, y, "tol", 1e-3) 446s ***** demo 446s ## Declare two different functions 446s f1 = @(x) cos (3 * x); 446s f2 = @(x) x .^ 3; 446s 446s ## Generate 80 samples for f1 and f2 446s x = [-4*pi:0.1*pi:4*pi-0.1*pi]'; 446s X1 = f1 (x); 446s X2 = f2 (x); 446s 446s ## Create a synthetic response by adding noise 446s rand ("seed", 3); 446s Ytrue = X1 + X2; 446s Y = Ytrue + Ytrue .* 0.2 .* rand (80,1); 446s 446s ## Assemble predictor data 446s X = [X1, X2]; 446s 446s ## Train the GAM and test on the same data 446s a = fitrgam (X, Y, "order", [5, 5]); 446s [ypred, ySDsd, yInt] = predict (a, X); 446s 446s ## Plot the results 446s figure 446s [sortedY, indY] = sort (Ytrue); 446s plot (sortedY, "r-"); 446s xlim ([0, 80]); 446s hold on 446s plot (ypred(indY), "g+") 446s plot (yInt(indY,1), "k:") 446s plot (yInt(indY,2), "k:") 446s xlabel ("Predictor samples"); 446s ylabel ("Response"); 446s title ("actual vs predicted values for function f1(x) = cos (3x) "); 446s legend ({"Theoretical Response", "Predicted Response", "Prediction Intervals"}); 446s 446s ## Use 30% Holdout partitioning for training and testing data 446s C = cvpartition (80, "HoldOut", 0.3); 446s [ypred, ySDsd, yInt] = predict (a, X(test(C),:)); 446s 446s ## Plot the results 446s figure 446s [sortedY, indY] = sort (Ytrue(test(C))); 446s plot (sortedY, 'r-'); 446s xlim ([0, sum(test(C))]); 446s hold on 446s plot (ypred(indY), "g+") 446s plot (yInt(indY,1),'k:') 446s plot (yInt(indY,2),'k:') 446s xlabel ("Predictor samples"); 446s ylabel ("Response"); 446s title ("actual vs predicted values for function f1(x) = cos (3x) "); 446s legend ({"Theoretical Response", "Predicted Response", "Prediction Intervals"}); 446s ***** test 446s x = [1, 2, 3; 4, 5, 6; 7, 8, 9; 3, 2, 1]; 446s y = [1; 2; 3; 4]; 446s a = RegressionGAM (x, y); 446s assert ({a.X, a.Y}, {x, y}) 446s assert ({a.BaseModel.Intercept}, {2.5000}) 446s assert ({a.Knots, a.Order, a.DoF}, {[5, 5, 5], [3, 3, 3], [8, 8, 8]}) 446s assert ({a.NumObservations, a.NumPredictors}, {4, 3}) 446s assert ({a.ResponseName, a.PredictorNames}, {"Y", {"x1", "x2", "x3"}}) 446s assert ({a.Formula}, {[]}) 446s ***** test 446s x = [1, 2, 3, 4; 4, 5, 6, 7; 7, 8, 9, 1; 3, 2, 1, 2]; 446s y = [1; 2; 3; 4]; 446s pnames = {"A", "B", "C", "D"}; 446s formula = "Y ~ A + B + C + D + A:C"; 446s intMat = logical ([1,0,0,0;0,1,0,0;0,0,1,0;0,0,0,1;1,0,1,0]); 446s a = RegressionGAM (x, y, "predictors", pnames, "formula", formula); 446s assert ({a.IntMatrix}, {intMat}) 446s assert ({a.ResponseName, a.PredictorNames}, {"Y", pnames}) 446s assert ({a.Formula}, {formula}) 446s ***** error RegressionGAM () 446s ***** error RegressionGAM (ones(10,2)) 446s ***** error ... 446s RegressionGAM (ones(10,2), ones (5,1)) 446s ***** error ... 446s RegressionGAM ([1;2;3;"a";4], ones (5,1)) 446s ***** error ... 446s RegressionGAM (ones(10,2), ones (10,1), "some", "some") 446s ***** error 446s RegressionGAM (ones(10,2), ones (10,1), "formula", {"y~x1+x2"}) 446s ***** error 446s RegressionGAM (ones(10,2), ones (10,1), "formula", [0, 1, 0]) 446s ***** error ... 446s RegressionGAM (ones(10,2), ones (10,1), "formula", "something") 446s ***** error ... 446s RegressionGAM (ones(10,2), ones (10,1), "formula", "something~") 446s ***** error ... 446s RegressionGAM (ones(10,2), ones (10,1), "formula", "something~") 446s ***** error ... 446s RegressionGAM (ones(10,2), ones (10,1), "formula", "something~x1:") 446s ***** error ... 446s RegressionGAM (ones(10,2), ones (10,1), "interactions", "some") 446s ***** error ... 446s RegressionGAM (ones(10,2), ones (10,1), "interactions", -1) 446s ***** error ... 446s RegressionGAM (ones(10,2), ones (10,1), "interactions", [1 2 3 4]) 446s ***** error ... 446s RegressionGAM (ones(10,2), ones (10,1), "interactions", 3) 446s ***** error ... 446s RegressionGAM (ones(10,2), ones (10,1), "formula", "y ~ x1 + x2", "interactions", 1) 446s ***** error ... 446s RegressionGAM (ones(10,2), ones (10,1), "interactions", 1, "formula", "y ~ x1 + x2") 446s ***** error ... 446s RegressionGAM (ones(10,2), ones (10,1), "knots", "a") 446s ***** error ... 446s RegressionGAM (ones(10,2), ones (10,1), "order", 3, "dof", 2, "knots", 5) 446s ***** error ... 446s RegressionGAM (ones(10,2), ones (10,1), "dof", 'a') 446s ***** error ... 446s RegressionGAM (ones(10,2), ones (10,1), "knots", 5, "order", 3, "dof", 2) 446s ***** error ... 446s RegressionGAM (ones(10,2), ones (10,1), "order", 'a') 446s ***** error ... 446s RegressionGAM (ones(10,2), ones (10,1), "knots", 5, "dof", 2, "order", 2) 446s ***** error ... 446s RegressionGAM (ones(10,2), ones (10,1), "tol", -1) 446s ***** error ... 446s RegressionGAM (ones(10,2), ones (10,1), "responsename", -1) 446s ***** error ... 446s RegressionGAM (ones(10,2), ones (10,1), "predictors", -1) 446s ***** error ... 446s RegressionGAM (ones(10,2), ones (10,1), "predictors", ['a','b','c']) 446s ***** error ... 446s RegressionGAM (ones(10,2), ones (10,1), "predictors", {'a','b','c'}) 446s ***** error ... 446s predict (RegressionGAM (ones(10,1), ones(10,1))) 446s ***** error ... 446s predict (RegressionGAM (ones(10,1), ones(10,1)), []) 446s ***** error ... 446s predict (RegressionGAM(ones(10,2), ones(10,1)), 2) 446s ***** error ... 446s predict (RegressionGAM(ones(10,2), ones(10,1)), ones (10,2), "some", "some") 446s ***** error ... 446s predict (RegressionGAM(ones(10,2), ones(10,1)), ones (10,2), "includeinteractions", "some") 446s ***** error ... 446s predict (RegressionGAM(ones(10,2), ones(10,1)), ones (10,2), "includeinteractions", 5) 447s ***** error ... 447s predict (RegressionGAM(ones(10,2), ones(10,1)), ones (10,2), "alpha", 5) 447s ***** error ... 447s predict (RegressionGAM(ones(10,2), ones(10,1)), ones (10,2), "alpha", -1) 447s ***** error ... 447s predict (RegressionGAM(ones(10,2), ones(10,1)), ones (10,2), "alpha", 'a') 447s 39 tests, 39 passed, 0 known failure, 0 skipped 447s [inst/logit.m] 447s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/logit.m 447s ***** test 447s p = [0.01:0.01:0.99]; 447s assert (logit (p), log (p ./ (1-p)), 25*eps); 447s ***** assert (logit ([-1, 0, 0.5, 1, 2]), [NaN, -Inf, 0, +Inf, NaN]) 447s ***** error logit () 447s ***** error logit (1, 2) 447s 4 tests, 4 passed, 0 known failure, 0 skipped 447s [inst/dcov.m] 447s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dcov.m 447s ***** demo 447s base=@(x) (x- min(x))./(max(x)-min(x)); 447s N = 5e2; 447s x = randn (N,1); x = base (x); 447s z = randn (N,1); z = base (z); 447s # Linear relations 447s cy = [1 0.55 0.3 0 -0.3 -0.55 -1]; 447s ly = x .* cy; 447s ly(:,[1:3 5:end]) = base (ly(:,[1:3 5:end])); 447s # Correlated Gaussian 447s cz = 1 - abs (cy); 447s gy = base ( ly + cz.*z); 447s # Shapes 447s sx = repmat (x,1,7); 447s sy = zeros (size (ly)); 447s v = 2 * rand (size(x,1),2) - 1; 447s sx(:,1) = v(:,1); sy(:,1) = cos(2*pi*sx(:,1)) + 0.5*v(:,2).*exp(-sx(:,1).^2/0.5); 447s R =@(d) [cosd(d) sind(d); -sind(d) cosd(d)]; 447s tmp = R(35) * v.'; 447s sx(:,2) = tmp(1,:); sy(:,2) = tmp(2,:); 447s tmp = R(45) * v.'; 447s sx(:,3) = tmp(1,:); sy(:,3) = tmp(2,:); 447s sx(:,4) = v(:,1); sy(:,4) = sx(:,4).^2 + 0.5*v(:,2); 447s sx(:,5) = v(:,1); sy(:,5) = 3*sign(v(:,2)).*(sx(:,5)).^2 + v(:,2); 447s sx(:,6) = cos (2*pi*v(:,1)) + 0.5*(x-0.5); 447s sy(:,6) = sin (2*pi*v(:,1)) + 0.5*(z-0.5); 447s sx(:,7) = x + sign(v(:,1)); sy(:,7) = z + sign(v(:,2)); 447s sy = base (sy); 447s sx = base (sx); 447s # scaled shape 447s sc = 1/3; 447s ssy = (sy-0.5) * sc + 0.5; 447s n = size (ly,2); 447s ym = 1.2; 447s xm = 0.5; 447s fmt={'horizontalalignment','center'}; 447s ff = "% .2f"; 447s figure (1) 447s for i=1:n 447s subplot(4,n,i); 447s plot (x, gy(:,i), '.b'); 447s axis tight 447s axis off 447s text (xm,ym,sprintf (ff, dcov (x,gy(:,i))),fmt{:}) 447s 447s subplot(4,n,i+n); 447s plot (x, ly(:,i), '.b'); 447s axis tight 447s axis off 447s text (xm,ym,sprintf (ff, dcov (x,ly(:,i))),fmt{:}) 447s 447s subplot(4,n,i+2*n); 447s plot (sx(:,i), sy(:,i), '.b'); 447s axis tight 447s axis off 447s text (xm,ym,sprintf (ff, dcov (sx(:,i),sy(:,i))),fmt{:}) 447s v = axis (); 447s 447s subplot(4,n,i+3*n); 447s plot (sx(:,i), ssy(:,i), '.b'); 447s axis (v) 447s axis off 447s text (xm,ym,sprintf (ff, dcov (sx(:,i),ssy(:,i))),fmt{:}) 447s endfor 447s ***** error dcov (randn (30, 5), randn (25,5)) 447s 1 test, 1 passed, 0 known failure, 0 skipped 447s [inst/ecdf.m] 447s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/ecdf.m 447s ***** demo 447s y = exprnd (10, 50, 1); ## random failure times are exponential(10) 447s d = exprnd (20, 50, 1); ## drop-out times are exponential(20) 447s t = min (y, d); ## we observe the minimum of these times 447s censored = (y > d); ## we also observe whether the subject failed 447s 447s ## Calculate and plot the empirical cdf and confidence bounds 447s [f, x, flo, fup] = ecdf (t, "censoring", censored); 447s stairs (x, f); 447s hold on; 447s stairs (x, flo, "r:"); stairs (x, fup, "r:"); 447s 447s ## Superimpose a plot of the known true cdf 447s xx = 0:.1:max (t); yy = 1 - exp (-xx / 10); plot (xx, yy, "g-"); 447s hold off; 447s ***** demo 447s R = wblrnd (100, 2, 100, 1); 447s ecdf (R, "Function", "survivor", "Alpha", 0.01, "Bounds", "on"); 447s hold on 447s x = 1:1:250; 447s wblsurv = 1 - cdf ("weibull", x, 100, 2); 447s plot (x, wblsurv, "g-", "LineWidth", 2) 447s legend ("Empirical survivor function", "Lower confidence bound", ... 447s "Upper confidence bound", "Weibull survivor function", ... 447s "Location", "northeast"); 447s hold off 447s ***** error ecdf (); 447s ***** error ecdf (randi (15,2)); 447s ***** error ecdf ([3,2,4,3+2i,5]); 447s ***** error kstest ([2,3,4,5,6],"tail"); 447s ***** error kstest ([2,3,4,5,6],"tail", "whatever"); 447s ***** error kstest ([2,3,4,5,6],"function", ""); 447s ***** error kstest ([2,3,4,5,6],"badoption", 0.51); 447s ***** error kstest ([2,3,4,5,6],"tail", 0); 447s ***** error kstest ([2,3,4,5,6],"alpha", 0); 447s ***** error kstest ([2,3,4,5,6],"alpha", NaN); 447s ***** error kstest ([NaN,NaN,NaN,NaN,NaN],"tail", "unequal"); 447s ***** error kstest ([2,3,4,5,6],"alpha", 0.05, "CDF", [2,3,4;1,3,4;1,2,1]); 447s ***** test 447s hf = figure ("visible", "off"); 447s unwind_protect 447s x = [2, 3, 4, 3, 5, 4, 6, 5, 8, 3, 7, 8, 9, 0]; 447s [F, x, Flo, Fup] = ecdf (x); 447s F_out = [0; 0.0714; 0.1429; 0.3571; 0.5; 0.6429; 0.7143; 0.7857; 0.9286; 1]; 447s assert (F, F_out, ones (10,1) * 1e-4); 447s x_out = [0 0 2 3 4 5 6 7 8 9]'; 447s assert (x, x_out); 447s Flo_out = [NaN, 0, 0, 0.1061, 0.2381, 0.3919, 0.4776, 0.5708, 0.7937, NaN]'; 447s assert (Flo, Flo_out, ones (10,1) * 1e-4); 447s Fup_out = [NaN, 0.2063, 0.3262, 0.6081, 0.7619, 0.8939, 0.9509, 1, 1, NaN]'; 447s assert (Fup, Fup_out, ones (10,1) * 1e-4); 447s unwind_protect_cleanup 447s close (hf); 447s end_unwind_protect 447s ***** test 447s hf = figure ("visible", "off"); 447s unwind_protect 447s x = [2, 3, 4, 3, 5, 4, 6, 5, 8, 3, 7, 8, 9, 0]; 447s ecdf (x); 447s unwind_protect_cleanup 447s close (hf); 447s end_unwind_protect 447s 14 tests, 14 passed, 0 known failure, 0 skipped 447s [inst/pdist.m] 447s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/pdist.m 447s ***** shared xy, t, eucl, x 447s xy = [0 1; 0 2; 7 6; 5 6]; 447s t = 1e-3; 447s eucl = @(v,m) sqrt(sumsq(repmat(v,rows(m),1)-m,2)); 447s x = [1 2 3; 4 5 6; 7 8 9; 3 2 1]; 447s ***** assert (pdist (xy), [1.000 8.602 7.071 8.062 6.403 2.000], t); 447s ***** assert (pdist (xy, eucl), [1.000 8.602 7.071 8.062 6.403 2.000], t); 447s ***** assert (pdist (xy, "euclidean"), [1.000 8.602 7.071 8.062 6.403 2.000], t); 447s ***** assert (pdist (xy, "seuclidean"), [0.380 2.735 2.363 2.486 2.070 0.561], t); 447s ***** assert (pdist (xy, "mahalanobis"), [1.384 1.967 2.446 2.384 1.535 2.045], t); 447s ***** assert (pdist (xy, "cityblock"), [1.000 12.00 10.00 11.00 9.000 2.000], t); 447s ***** assert (pdist (xy, "minkowski"), [1.000 8.602 7.071 8.062 6.403 2.000], t); 447s ***** assert (pdist (xy, "minkowski", 3), [1.000 7.763 6.299 7.410 5.738 2.000], t); 447s ***** assert (pdist (xy, "cosine"), [0.000 0.349 0.231 0.349 0.231 0.013], t); 447s ***** assert (pdist (xy, "correlation"), [0.000 2.000 0.000 2.000 0.000 2.000], t); 447s ***** assert (pdist (xy, "spearman"), [0.000 2.000 0.000 2.000 0.000 2.000], t); 447s ***** assert (pdist (xy, "hamming"), [0.500 1.000 1.000 1.000 1.000 0.500], t); 447s ***** assert (pdist (xy, "jaccard"), [1.000 1.000 1.000 1.000 1.000 0.500], t); 447s ***** assert (pdist (xy, "chebychev"), [1.000 7.000 5.000 7.000 5.000 2.000], t); 447s ***** assert (pdist (x), [5.1962, 10.3923, 2.8284, 5.1962, 5.9161, 10.7703], 1e-4); 447s ***** assert (pdist (x, "euclidean"), ... 447s [5.1962, 10.3923, 2.8284, 5.1962, 5.9161, 10.7703], 1e-4); 447s ***** assert (pdist (x, eucl), ... 447s [5.1962, 10.3923, 2.8284, 5.1962, 5.9161, 10.7703], 1e-4); 447s ***** assert (pdist (x, "squaredeuclidean"), [27, 108, 8, 27, 35, 116]); 447s ***** assert (pdist (x, "seuclidean"), ... 447s [1.8071, 3.6142, 0.9831, 1.8071, 1.8143, 3.4854], 1e-4); 447s ***** warning ... 447s pdist (x, "mahalanobis"); 447s ***** assert (pdist (x, "cityblock"), [9, 18, 4, 9, 9, 18]); 447s ***** assert (pdist (x, "minkowski"), ... 447s [5.1962, 10.3923, 2.8284, 5.1962, 5.9161, 10.7703], 1e-4); 447s ***** assert (pdist (x, "minkowski", 3), ... 447s [4.3267, 8.6535, 2.5198, 4.3267, 5.3485, 9.2521], 1e-4); 447s ***** assert (pdist (x, "cosine"), ... 447s [0.0254, 0.0406, 0.2857, 0.0018, 0.1472, 0.1173], 1e-4); 447s ***** assert (pdist (x, "correlation"), [0, 0, 2, 0, 2, 2], 1e-14); 447s ***** assert (pdist (x, "spearman"), [0, 0, 2, 0, 2, 2], 1e-14); 447s ***** assert (pdist (x, "hamming"), [1, 1, 2/3, 1, 1, 1]); 447s ***** assert (pdist (x, "jaccard"), [1, 1, 2/3, 1, 1, 1]); 447s ***** assert (pdist (x, "chebychev"), [3, 6, 2, 3, 5, 8]); 447s 29 tests, 29 passed, 0 known failure, 0 skipped 447s [inst/correlation_test.m] 447s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/correlation_test.m 447s ***** error correlation_test (); 447s ***** error correlation_test (1); 447s ***** error ... 447s correlation_test ([1 2 NaN]', [2 3 4]'); 447s ***** error ... 447s correlation_test ([1 2 Inf]', [2 3 4]'); 447s ***** error ... 447s correlation_test ([1 2 3+i]', [2 3 4]'); 447s ***** error ... 447s correlation_test ([1 2 3]', [2 3 NaN]'); 447s ***** error ... 447s correlation_test ([1 2 3]', [2 3 Inf]'); 447s ***** error ... 447s correlation_test ([1 2 3]', [3 4 3+i]'); 448s ***** error ... 448s correlation_test ([1 2 3]', [3 4 4 5]'); 448s ***** error ... 448s correlation_test ([1 2 3]', [2 3 4]', "alpha", 0); 448s ***** error ... 448s correlation_test ([1 2 3]', [2 3 4]', "alpha", 1.2); 448s ***** error ... 448s correlation_test ([1 2 3]', [2 3 4]', "alpha", [.02 .1]); 448s ***** error ... 448s correlation_test ([1 2 3]', [2 3 4]', "alpha", "a"); 448s ***** error ... 448s correlation_test ([1 2 3]', [2 3 4]', "some", 0.05); 448s ***** error ... 448s correlation_test ([1 2 3]', [2 3 4]', "tail", "val"); 448s ***** error ... 448s correlation_test ([1 2 3]', [2 3 4]', "alpha", 0.01, "tail", "val"); 448s ***** error ... 448s correlation_test ([1 2 3]', [2 3 4]', "method", 0.01); 448s ***** error ... 448s correlation_test ([1 2 3]', [2 3 4]', "method", "some"); 448s ***** test 448s x = [6 7 7 9 10 12 13 14 15 17]; 448s y = [19 22 27 25 30 28 30 29 25 32]; 448s [h, pval, stats] = correlation_test (x, y); 448s assert (stats.corrcoef, corr (x', y'), 1e-14); 448s assert (pval, 0.0223, 1e-4); 448s ***** test 448s x = [6 7 7 9 10 12 13 14 15 17]'; 448s y = [19 22 27 25 30 28 30 29 25 32]'; 448s [h, pval, stats] = correlation_test (x, y); 448s assert (stats.corrcoef, corr (x, y), 1e-14); 448s assert (pval, 0.0223, 1e-4); 448s 20 tests, 20 passed, 0 known failure, 0 skipped 448s [inst/isoutlier.m] 448s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/isoutlier.m 448s ***** demo 448s A = [57 59 60 100 59 58 57 58 300 61 62 60 62 58 57]; 448s TF = isoutlier (A, "mean") 448s ***** demo 448s ## Use a moving detection method to detect local outliers in a sine wave 448s 448s x = -2*pi:0.1:2*pi; 448s A = sin(x); 448s A(47) = 0; 448s time = datenum (2023,1,1,0,0,0) + (1/24)*[0:length(x)-1] - 730485; 448s TF = isoutlier (A, "movmedian", 5*(1/24), "SamplePoints", time); 448s plot (time, A) 448s hold on 448s plot (time(TF), A(TF), "x") 448s datetick ('x', 20, 'keepticks') 448s legend ("Original Data", "Outlier Data") 448s ***** demo 448s ## Locate an outlier in a vector of data and visualize the outlier 448s 448s x = 1:10; 448s A = [60 59 49 49 58 100 61 57 48 58]; 448s [TF, L, U, C] = isoutlier (A); 448s plot (x, A); 448s hold on 448s plot (x(TF), A(TF), "x"); 448s xlim ([1,10]); 448s line ([1,10], [L, L], "Linestyle", ":"); 448s text (1.1, L-2, "Lower Threshold"); 448s line ([1,10], [U, U], "Linestyle", ":"); 448s text (1.1, U-2, "Upper Threshold"); 448s line ([1,10], [C, C], "Linestyle", ":"); 448s text (1.1, C-3, "Center Value"); 448s legend ("Original Data", "Outlier Data"); 448s ***** test 448s A = [57 59 60 100 59 58 57 58 300 61 62 60 62 58 57]; 448s assert (isoutlier (A, "mean"), logical([zeros(1,8) 1 zeros(1,6)])) 448s assert (isoutlier (A, "median"), ... 448s logical([zeros(1,3) 1 zeros(1,4) 1 zeros(1,6)])) 448s ***** test 448s A = [57 59 60 100 59 58 57 58 300 61 62 60 62 58 57]; 448s [TF, L, U, C] = isoutlier (A, "mean"); 448s assert (L, -109.2459044922864, 1e-12) 448s assert (U, 264.9792378256198, 1e-12) 448s assert (C, 77.8666666666666, 1e-12) 448s ***** test 448s A = [57 59 60 100 59 58 57 58 300 61 62 60 62 58 57]; 448s [TF, L, U, C] = isoutlier (A, "median"); 448s assert (L, 50.104386688966386, 1e-12) 448s assert (U, 67.895613311033610, 1e-12) 448s assert (C, 59) 448s ***** test 448s A = magic(5) + diag(200*ones(1,5)); 448s T = logical (eye (5)); 448s assert (isoutlier (A, 2), T) 448s ***** test 448s A = [57 59 60 100 59 58 57 58 300 61 62 60 62 58 57]; 448s [TF, L, U, C] = isoutlier (A, "movmedian", 5); 448s l = [54.5522, 52.8283, 54.5522, 54.5522, 54.5522, 53.5522, 53.5522, ... 448s 53.5522, 47.6566, 56.5522, 57.5522, 56.5522, 51.1044, 52.3283, 53.5522]; 448s u = [63.4478, 66.1717, 63.4478, 63.4478, 63.4478, 62.4478, 62.4478, ... 448s 62.4478, 74.3434, 65.4478, 66.4478, 65.4478, 68.8956, 65.6717, 62.4478]; 448s c = [59, 59.5, 59, 59, 59, 58, 58, 58, 61, 61, 62, 61, 60, 59, 58]; 448s assert (L, l, 1e-4) 448s assert (U, u, 1e-4) 448s assert (C, c) 448s ***** test 448s A = [57 59 60 100 59 58 57 58 300 61 62 60 62 58 57]; 448s [TF, L, U, C] = isoutlier (A, "movmedian", 5, "SamplePoints", [1:15]); 448s l = [54.5522, 52.8283, 54.5522, 54.5522, 54.5522, 53.5522, 53.5522, ... 448s 53.5522, 47.6566, 56.5522, 57.5522, 56.5522, 51.1044, 52.3283, 53.5522]; 448s u = [63.4478, 66.1717, 63.4478, 63.4478, 63.4478, 62.4478, 62.4478, ... 448s 62.4478, 74.3434, 65.4478, 66.4478, 65.4478, 68.8956, 65.6717, 62.4478]; 448s c = [59, 59.5, 59, 59, 59, 58, 58, 58, 61, 61, 62, 61, 60, 59, 58]; 448s assert (L, l, 1e-4) 448s assert (U, u, 1e-4) 448s assert (C, c) 448s ***** test 448s A = [57 59 60 100 59 58 57 58 300 61 62 60 62 58 57]; 448s [TF, L, U, C] = isoutlier (A, "movmean", 5); 448s l = [54.0841, 6.8872, 11.5608, 12.1518, 11.0210, 10.0112, -218.2840, ... 448s -217.2375, -215.1239, -213.4890, -211.3264, 55.5800, 52.9589, ... 448s 52.5979, 51.0627]; 448s u = [63.2492, 131.1128, 122.4392, 122.2482, 122.5790, 122.7888, 431.0840, ... 448s 430.8375, 430.3239, 429.8890, 429.3264, 65.6200, 66.6411, 65.9021, ... 448s 66.9373]; 448s c = [58.6667, 69, 67, 67.2, 66.8, 66.4, 106.4, 106.8, 107.6, 108.2, 109, ... 448s 60.6, 59.8, 59.25, 59]; 448s assert (L, l, 1e-4) 448s assert (U, u, 1e-4) 448s assert (C, c, 1e-4) 448s ***** test 448s A = [57 59 60 100 59 58 57 58 300 61 62 60 62 58 57]; 448s [TF, L, U, C] = isoutlier (A, "movmean", 5, "SamplePoints", [1:15]); 448s l = [54.0841, 6.8872, 11.5608, 12.1518, 11.0210, 10.0112, -218.2840, ... 448s -217.2375, -215.1239, -213.4890, -211.3264, 55.5800, 52.9589, ... 448s 52.5979, 51.0627]; 448s u = [63.2492, 131.1128, 122.4392, 122.2482, 122.5790, 122.7888, 431.0840, ... 448s 430.8375, 430.3239, 429.8890, 429.3264, 65.6200, 66.6411, 65.9021, ... 448s 66.9373]; 448s c = [58.6667, 69, 67, 67.2, 66.8, 66.4, 106.4, 106.8, 107.6, 108.2, 109, ... 448s 60.6, 59.8, 59.25, 59]; 448s assert (L, l, 1e-4) 448s assert (U, u, 1e-4) 448s assert (C, c, 1e-4) 448s ***** test 448s A = [57 59 60 100 59 58 57 58 300 61 62 60 62 58 57]; 448s [TF, L, U, C] = isoutlier (A, "gesd"); 448s assert (TF, logical ([0 0 0 1 0 0 0 0 1 0 0 0 0 0 0])) 448s assert (L, 34.235977035439944, 1e-12) 448s assert (U, 89.764022964560060, 1e-12) 448s assert (C, 62) 448s ***** test 448s A = [57 59 60 100 59 58 57 58 300 61 62 60 62 58 57]; 448s [TF, L, U, C] = isoutlier (A, "gesd", "ThresholdFactor", 0.01); 448s assert (TF, logical ([0 0 0 1 0 0 0 0 1 0 0 0 0 0 0])) 448s assert (L, 31.489256770616173, 1e-12) 448s assert (U, 92.510743229383820, 1e-12) 448s assert (C, 62) 448s ***** test 448s A = [57 59 60 100 59 58 57 58 300 61 62 60 62 58 57]; 448s [TF, L, U, C] = isoutlier (A, "gesd", "ThresholdFactor", 5e-10); 448s assert (TF, logical ([0 0 0 0 0 0 0 0 1 0 0 0 0 0 0])) 448s assert (L, 23.976664158788935, 1e-12) 448s assert (U, 100.02333584121110, 1e-12) 448s assert (C, 62) 448s ***** test 448s A = [57 59 60 100 59 58 57 58 300 61 62 60 62 58 57]; 448s [TF, L, U, C] = isoutlier (A, "grubbs"); 448s assert (TF, logical ([0 0 0 1 0 0 0 0 1 0 0 0 0 0 0])) 448s assert (L, 54.642809574646606, 1e-12) 448s assert (U, 63.511036579199555, 1e-12) 448s assert (C, 59.076923076923080, 1e-12) 448s ***** test 448s A = [57 59 60 100 59 58 57 58 300 61 62 60 62 58 57]; 448s [TF, L, U, C] = isoutlier (A, "grubbs", "ThresholdFactor", 0.01); 448s assert (TF, logical ([0 0 0 1 0 0 0 0 1 0 0 0 0 0 0])) 448s assert (L, 54.216083184201850, 1e-12) 448s assert (U, 63.937762969644310, 1e-12) 448s assert (C, 59.076923076923080, 1e-12) 448s ***** test 448s A = [57 59 60 100 59 58 57 58 300 61 62 60 62 58 57]; 448s [TF, L, U, C] = isoutlier (A, "percentiles", [10 90]); 448s assert (TF, logical ([0 0 0 0 0 0 0 0 1 0 0 0 0 0 0])) 448s assert (L, 57) 448s assert (U, 100) 448s assert (C, 78.5) 448s ***** test 448s A = [57 59 60 100 59 58 57 58 300 61 62 60 62 58 57]; 448s [TF, L, U, C] = isoutlier (A, "percentiles", [20 80]); 448s assert (TF, logical ([1 0 0 1 0 0 1 0 1 0 0 0 0 0 1])) 448s assert (L, 57.5) 448s assert (U, 62) 448s assert (C, 59.75) 448s ***** shared A 448s A = [57 59 60 100 59 58 57 58 300 61 62 60 62 58 57]; 448s ***** error ... 448s isoutlier (A, "movmedian", 0); 448s ***** error ... 448s isoutlier (A, "movmedian", []); 448s ***** error ... 448s isoutlier (A, "movmedian", [2 3 4]); 448s ***** error ... 448s isoutlier (A, "movmedian", 1.4); 448s ***** error ... 448s isoutlier (A, "movmedian", [0 1]); 448s ***** error ... 448s isoutlier (A, "movmedian", [2 -1]); 448s ***** error ... 448s isoutlier (A, "movmedian", {2 3}); 448s ***** error ... 448s isoutlier (A, "movmedian", "char"); 448s 448s ***** error ... 448s isoutlier (A, "movmean", 0); 448s ***** error ... 448s isoutlier (A, "movmean", []); 448s ***** error ... 448s isoutlier (A, "movmean", [2 3 4]); 448s ***** error ... 448s isoutlier (A, "movmean", 1.4); 448s ***** error ... 448s isoutlier (A, "movmean", [0 1]); 448s ***** error ... 448s isoutlier (A, "movmean", [2 -1]); 448s ***** error ... 448s isoutlier (A, "movmean", {2 3}); 448s ***** error ... 448s isoutlier (A, "movmean", "char"); 448s 448s ***** error ... 448s isoutlier (A, "percentiles", [-1 90]); 448s ***** error ... 448s isoutlier (A, "percentiles", [10 -90]); 448s ***** error ... 448s isoutlier (A, "percentiles", [90]); 448s ***** error ... 448s isoutlier (A, "percentiles", [90 20]); 448s ***** error ... 448s isoutlier (A, "percentiles", [90 20]); 448s ***** error ... 448s isoutlier (A, "percentiles", [10 20 90]); 448s ***** error ... 448s isoutlier (A, "percentiles", {10 90}); 448s ***** error ... 448s isoutlier (A, "percentiles", "char"); 448s 448s ***** error ... 448s isoutlier (A, "movmean", 5, "SamplePoints", ones(3,15)); 448s ***** error ... 448s isoutlier (A, "movmean", 5, "SamplePoints", 15); 448s ***** error ... 448s isoutlier (A, "movmean", 5, "SamplePoints", [1,1:14]); 448s ***** error ... 448s isoutlier (A, "movmean", 5, "SamplePoints", [2,1,3:15]); 448s ***** error ... 448s isoutlier (A, "movmean", 5, "SamplePoints", [1:14]); 448s 448s ***** error ... 448s isoutlier (A, "movmean", 5, "ThresholdFactor", [1:14]); 448s ***** error ... 448s isoutlier (A, "movmean", 5, "ThresholdFactor", -1); 448s ***** error ... 448s isoutlier (A, "gesd", "ThresholdFactor", 3); 448s ***** error ... 448s isoutlier (A, "grubbs", "ThresholdFactor", 3); 448s 448s ***** error ... 448s isoutlier (A, "movmean", 5, "MaxNumOutliers", [1:14]); 448s ***** error ... 448s isoutlier (A, "movmean", 5, "MaxNumOutliers", -1); 448s ***** error ... 448s isoutlier (A, "movmean", 5, "MaxNumOutliers", 0); 448s ***** error ... 448s isoutlier (A, "movmean", 5, "MaxNumOutliers", 1.5); 448s 448s ***** error ... 448s isoutlier (A, {"movmean"}, 5, "SamplePoints", [1:15]); 448s ***** error isoutlier (A, {1}); 448s ***** error isoutlier (A, true); 448s ***** error isoutlier (A, false); 448s ***** error isoutlier (A, 0); 448s ***** error isoutlier (A, [1 2]); 448s ***** error isoutlier (A, -2); 448s 59 tests, 59 passed, 0 known failure, 0 skipped 448s [inst/multcompare.m] 448s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/multcompare.m 448s ***** demo 448s 448s ## Demonstration using balanced one-way ANOVA from anova1 448s 448s x = ones (50, 4) .* [-2, 0, 1, 5]; 448s randn ("seed", 1); # for reproducibility 448s x = x + normrnd (0, 2, 50, 4); 448s groups = {"A", "B", "C", "D"}; 448s [p, tbl, stats] = anova1 (x, groups, "off"); 448s multcompare (stats); 448s ***** demo 448s 448s ## Demonstration using unbalanced one-way ANOVA example from anovan 448s 448s dv = [ 8.706 10.362 11.552 6.941 10.983 10.092 6.421 14.943 15.931 ... 448s 22.968 18.590 16.567 15.944 21.637 14.492 17.965 18.851 22.891 ... 448s 22.028 16.884 17.252 18.325 25.435 19.141 21.238 22.196 18.038 ... 448s 22.628 31.163 26.053 24.419 32.145 28.966 30.207 29.142 33.212 ... 448s 25.694 ]'; 448s g = [1 1 1 1 1 1 1 1 2 2 2 2 2 3 3 3 3 3 3 3 3 ... 448s 4 4 4 4 4 4 4 5 5 5 5 5 5 5 5 5]'; 448s 448s [P,ATAB, STATS] = anovan (dv, g, "varnames", "score", "display", "off"); 448s 448s [C, M, H, GNAMES] = multcompare (STATS, "dim", 1, "ctype", "holm", ... 448s "ControlGroup", 1, "display", "on") 448s 448s ***** demo 448s 448s ## Demonstration using factorial ANCOVA example from anovan 448s 448s score = [95.6 82.2 97.2 96.4 81.4 83.6 89.4 83.8 83.3 85.7 ... 448s 97.2 78.2 78.9 91.8 86.9 84.1 88.6 89.8 87.3 85.4 ... 448s 81.8 65.8 68.1 70.0 69.9 75.1 72.3 70.9 71.5 72.5 ... 448s 84.9 96.1 94.6 82.5 90.7 87.0 86.8 93.3 87.6 92.4 ... 448s 100. 80.5 92.9 84.0 88.4 91.1 85.7 91.3 92.3 87.9 ... 448s 91.7 88.6 75.8 75.7 75.3 82.4 80.1 86.0 81.8 82.5]'; 448s treatment = {"yes" "yes" "yes" "yes" "yes" "yes" "yes" "yes" "yes" "yes" ... 448s "yes" "yes" "yes" "yes" "yes" "yes" "yes" "yes" "yes" "yes" ... 448s "yes" "yes" "yes" "yes" "yes" "yes" "yes" "yes" "yes" "yes" ... 448s "no" "no" "no" "no" "no" "no" "no" "no" "no" "no" ... 448s "no" "no" "no" "no" "no" "no" "no" "no" "no" "no" ... 448s "no" "no" "no" "no" "no" "no" "no" "no" "no" "no"}'; 448s exercise = {"lo" "lo" "lo" "lo" "lo" "lo" "lo" "lo" "lo" "lo" ... 448s "mid" "mid" "mid" "mid" "mid" "mid" "mid" "mid" "mid" "mid" ... 448s "hi" "hi" "hi" "hi" "hi" "hi" "hi" "hi" "hi" "hi" ... 448s "lo" "lo" "lo" "lo" "lo" "lo" "lo" "lo" "lo" "lo" ... 448s "mid" "mid" "mid" "mid" "mid" "mid" "mid" "mid" "mid" "mid" ... 448s "hi" "hi" "hi" "hi" "hi" "hi" "hi" "hi" "hi" "hi"}'; 448s age = [59 65 70 66 61 65 57 61 58 55 62 61 60 59 55 57 60 63 62 57 ... 448s 58 56 57 59 59 60 55 53 55 58 68 62 61 54 59 63 60 67 60 67 ... 448s 75 54 57 62 65 60 58 61 65 57 56 58 58 58 52 53 60 62 61 61]'; 448s 448s [P, ATAB, STATS] = anovan (score, {treatment, exercise, age}, "model", ... 448s [1 0 0; 0 1 0; 0 0 1; 1 1 0], "continuous", 3, ... 448s "sstype", "h", "display", "off", "contrasts", ... 448s {"simple","poly",""}); 448s 448s [C, M, H, GNAMES] = multcompare (STATS, "dim", [1 2], "ctype", "holm", ... 448s "display", "on") 448s 448s ***** demo 448s 448s ## Demonstration using one-way ANOVA from anovan, with fit by weighted least 448s ## squares to account for heteroskedasticity. 448s 448s g = [1, 1, 1, 1, 1, 1, 1, 1, ... 448s 2, 2, 2, 2, 2, 2, 2, 2, ... 448s 3, 3, 3, 3, 3, 3, 3, 3]'; 448s 448s y = [13, 16, 16, 7, 11, 5, 1, 9, ... 448s 10, 25, 66, 43, 47, 56, 6, 39, ... 448s 11, 39, 26, 35, 25, 14, 24, 17]'; 448s 448s [P,ATAB,STATS] = anovan(y, g, "display", "off"); 448s fitted = STATS.X * STATS.coeffs(:,1); # fitted values 448s b = polyfit (fitted, abs (STATS.resid), 1); 448s v = polyval (b, fitted); # Variance as a function of the fitted values 448s [P,ATAB,STATS] = anovan (y, g, "weights", v.^-1, "display", "off"); 448s [C, M] = multcompare (STATS, "display", "on", "ctype", "mvt") 448s ***** demo 448s 448s ## Demonstration of p-value adjustments to control the false discovery rate 448s ## Data from Westfall (1997) JASA. 92(437):299-306 448s 448s p = [.005708; .023544; .024193; .044895; ... 448s .048805; .221227; .395867; .693051; .775755]; 448s 448s padj = multcompare(p,'ctype','fdr') 448s ***** test 448s 448s ## Tests using unbalanced one-way ANOVA example from anovan and anova1 448s 448s ## Test for anovan - compare pairwise comparisons with matlab for CTYPE "lsd" 448s 448s dv = [ 8.706 10.362 11.552 6.941 10.983 10.092 6.421 14.943 15.931 ... 448s 22.968 18.590 16.567 15.944 21.637 14.492 17.965 18.851 22.891 ... 448s 22.028 16.884 17.252 18.325 25.435 19.141 21.238 22.196 18.038 ... 448s 22.628 31.163 26.053 24.419 32.145 28.966 30.207 29.142 33.212 ... 448s 25.694 ]'; 448s g = [1 1 1 1 1 1 1 1 2 2 2 2 2 3 3 3 3 3 3 3 3 ... 448s 4 4 4 4 4 4 4 5 5 5 5 5 5 5 5 5]'; 448s 448s [P, ATAB, STATS] = anovan (dv, g, "varnames", "score", "display", "off"); 448s [C, M, H, GNAMES] = multcompare (STATS, "dim", 1, "ctype", "lsd", ... 448s "display", "off"); 448s assert (C(1,6), 2.85812420217898e-05, 1e-09); 448s assert (C(2,6), 5.22936741204085e-07, 1e-09); 448s assert (C(3,6), 2.12794763209146e-08, 1e-09); 448s assert (C(4,6), 7.82091664406946e-15, 1e-09); 448s assert (C(5,6), 0.546591417210693, 1e-09); 448s assert (C(6,6), 0.0845897945254446, 1e-09); 448s assert (C(7,6), 9.47436557975328e-08, 1e-09); 448s assert (C(8,6), 0.188873478781067, 1e-09); 448s assert (C(9,6), 4.08974010364197e-08, 1e-09); 448s assert (C(10,6), 4.44427348175241e-06, 1e-09); 448s assert (M(1,1), 10, 1e-09); 448s assert (M(2,1), 18, 1e-09); 448s assert (M(3,1), 19, 1e-09); 448s assert (M(4,1), 21.0001428571429, 1e-09); 448s assert (M(5,1), 29.0001111111111, 1e-09); 448s assert (M(1,2), 1.0177537954095, 1e-09); 448s assert (M(2,2), 1.28736803631001, 1e-09); 448s assert (M(3,2), 1.0177537954095, 1e-09); 448s assert (M(4,2), 1.0880245732889, 1e-09); 448s assert (M(5,2), 0.959547480416536, 1e-09); 448s 448s ## Compare "fdr" adjusted p-values to those obtained using p.adjust in R 448s 448s [C, M, H, GNAMES] = multcompare (STATS, "dim", 1, "ctype", "fdr", ... 448s "display", "off"); 448s assert (C(1,6), 4.08303457454140e-05, 1e-09); 448s assert (C(2,6), 1.04587348240817e-06, 1e-09); 448s assert (C(3,6), 1.06397381604573e-07, 1e-09); 448s assert (C(4,6), 7.82091664406946e-14, 1e-09); 448s assert (C(5,6), 5.46591417210693e-01, 1e-09); 448s assert (C(6,6), 1.05737243156806e-01, 1e-09); 448s assert (C(7,6), 2.36859139493832e-07, 1e-09); 448s assert (C(8,6), 2.09859420867852e-01, 1e-09); 448s assert (C(9,6), 1.36324670121399e-07, 1e-09); 448s assert (C(10,6), 7.40712246958735e-06, 1e-09); 448s 448s ## Compare "hochberg" adjusted p-values to those obtained using p.adjust in R 448s 448s [C, M, H, GNAMES] = multcompare (STATS, "dim", 1, "ctype", "hochberg", ... 448s "display", "off"); 448s assert (C(1,6), 1.14324968087159e-04, 1e-09); 448s assert (C(2,6), 3.13762044722451e-06, 1e-09); 448s assert (C(3,6), 1.91515286888231e-07, 1e-09); 448s assert (C(4,6), 7.82091664406946e-14, 1e-09); 448s assert (C(5,6), 5.46591417210693e-01, 1e-09); 448s assert (C(6,6), 2.53769383576334e-01, 1e-09); 448s assert (C(7,6), 6.63205590582730e-07, 1e-09); 448s assert (C(8,6), 3.77746957562134e-01, 1e-09); 448s assert (C(9,6), 3.27179208291358e-07, 1e-09); 448s assert (C(10,6), 2.22213674087620e-05, 1e-09); 448s 448s ## Compare "holm" adjusted p-values to those obtained using p.adjust in R 448s 448s [C, M, H, GNAMES] = multcompare (STATS, "dim", 1, "ctype", "holm", ... 448s "display", "off"); 448s assert (C(1,6), 1.14324968087159e-04, 1e-09); 448s assert (C(2,6), 3.13762044722451e-06, 1e-09); 448s assert (C(3,6), 1.91515286888231e-07, 1e-09); 448s assert (C(4,6), 7.82091664406946e-14, 1e-09); 448s assert (C(5,6), 5.46591417210693e-01, 1e-09); 448s assert (C(6,6), 2.53769383576334e-01, 1e-09); 448s assert (C(7,6), 6.63205590582730e-07, 1e-09); 448s assert (C(8,6), 3.77746957562134e-01, 1e-09); 448s assert (C(9,6), 3.27179208291358e-07, 1e-09); 448s assert (C(10,6), 2.22213674087620e-05, 1e-09); 448s 448s ## Compare "scheffe" adjusted p-values to those obtained using 'scheffe' in Matlab 448s 448s [C, M, H, GNAMES] = multcompare (STATS, "dim", 1, "ctype", "scheffe", ... 448s "display", "off"); 448s assert (C(1,6), 0.00108105386141085, 1e-09); 448s assert (C(2,6), 2.7779386789517e-05, 1e-09); 448s assert (C(3,6), 1.3599854038198e-06, 1e-09); 448s assert (C(4,6), 7.58830197867751e-13, 1e-09); 448s assert (C(5,6), 0.984039948220281, 1e-09); 448s assert (C(6,6), 0.539077018557706, 1e-09); 448s assert (C(7,6), 5.59475764460574e-06, 1e-09); 448s assert (C(8,6), 0.771173490574105, 1e-09); 448s assert (C(9,6), 2.52838425729905e-06, 1e-09); 448s assert (C(10,6), 0.000200719143889168, 1e-09); 448s 448s ## Compare "bonferroni" adjusted p-values to those obtained using p.adjust in R 448s 448s [C, M, H, GNAMES] = multcompare (STATS, "dim", 1, "ctype", "bonferroni", ... 448s "display", "off"); 448s assert (C(1,6), 2.85812420217898e-04, 1e-09); 448s assert (C(2,6), 5.22936741204085e-06, 1e-09); 448s assert (C(3,6), 2.12794763209146e-07, 1e-09); 448s assert (C(4,6), 7.82091664406946e-14, 1e-09); 448s assert (C(5,6), 1.00000000000000e+00, 1e-09); 448s assert (C(6,6), 8.45897945254446e-01, 1e-09); 448s assert (C(7,6), 9.47436557975328e-07, 1e-09); 448s assert (C(8,6), 1.00000000000000e+00, 1e-09); 448s assert (C(9,6), 4.08974010364197e-07, 1e-09); 448s assert (C(10,6), 4.44427348175241e-05, 1e-09); 448s 448s ## Test for anova1 ("equal")- comparison of results from Matlab 448s 448s [P, ATAB, STATS] = anova1 (dv, g, "off", "equal"); 448s [C, M, H, GNAMES] = multcompare (STATS, "ctype", "lsd", "display", "off"); 448s assert (C(1,6), 2.85812420217898e-05, 1e-09); 448s assert (C(2,6), 5.22936741204085e-07, 1e-09); 448s assert (C(3,6), 2.12794763209146e-08, 1e-09); 448s assert (C(4,6), 7.82091664406946e-15, 1e-09); 448s assert (C(5,6), 0.546591417210693, 1e-09); 448s assert (C(6,6), 0.0845897945254446, 1e-09); 448s assert (C(7,6), 9.47436557975328e-08, 1e-09); 448s assert (C(8,6), 0.188873478781067, 1e-09); 448s assert (C(9,6), 4.08974010364197e-08, 1e-09); 448s assert (C(10,6), 4.44427348175241e-06, 1e-09); 448s assert (M(1,1), 10, 1e-09); 448s assert (M(2,1), 18, 1e-09); 448s assert (M(3,1), 19, 1e-09); 448s assert (M(4,1), 21.0001428571429, 1e-09); 448s assert (M(5,1), 29.0001111111111, 1e-09); 448s assert (M(1,2), 1.0177537954095, 1e-09); 448s assert (M(2,2), 1.28736803631001, 1e-09); 448s assert (M(3,2), 1.0177537954095, 1e-09); 448s assert (M(4,2), 1.0880245732889, 1e-09); 448s assert (M(5,2), 0.959547480416536, 1e-09); 448s 448s ## Test for anova1 ("unequal") - comparison with results from GraphPad Prism 8 448s [P, ATAB, STATS] = anova1 (dv, g, "off", "unequal"); 448s [C, M, H, GNAMES] = multcompare (STATS, "ctype", "lsd", "display", "off"); 448s assert (C(1,6), 0.001247025266382, 1e-09); 448s assert (C(2,6), 0.000018037115146, 1e-09); 448s assert (C(3,6), 0.000002974595187, 1e-09); 448s assert (C(4,6), 0.000000000786046, 1e-09); 448s assert (C(5,6), 0.5693192886650109, 1e-09); 448s assert (C(6,6), 0.110501699029776, 1e-09); 448s assert (C(7,6), 0.000131226488700, 1e-09); 448s assert (C(8,6), 0.1912101409715992, 1e-09); 448s assert (C(9,6), 0.000005385256394, 1e-09); 448s assert (C(10,6), 0.000074089106171, 1e-09); 449s ***** test 449s 449s ## Test for anova2 ("interaction") - comparison with results from Matlab for column effect 449s popcorn = [5.5, 4.5, 3.5; 5.5, 4.5, 4.0; 6.0, 4.0, 3.0; ... 449s 6.5, 5.0, 4.0; 7.0, 5.5, 5.0; 7.0, 5.0, 4.5]; 449s [P, ATAB, STATS] = anova2 (popcorn, 3, "off"); 449s [C, M, H, GNAMES] = multcompare (STATS, "estimate", "column",... 449s "ctype", "lsd", "display", "off"); 449s assert (C(1,6), 1.49311100811177e-05, 1e-09); 449s assert (C(2,6), 2.20506904243535e-07, 1e-09); 449s assert (C(3,6), 0.00449897860490058, 1e-09); 449s assert (M(1,1), 6.25, 1e-09); 449s assert (M(2,1), 4.75, 1e-09); 449s assert (M(3,1), 4, 1e-09); 449s assert (M(1,2), 0.152145154862547, 1e-09); 449s assert (M(2,2), 0.152145154862547, 1e-09); 449s assert (M(3,2), 0.152145154862547, 1e-09); 449s ***** test 449s 449s ## Test for anova2 ("linear") - comparison with results from GraphPad Prism 8 449s words = [10 13 13; 6 8 8; 11 14 14; 22 23 25; 16 18 20; ... 449s 15 17 17; 1 1 4; 12 15 17; 9 12 12; 8 9 12]; 449s [P, ATAB, STATS] = anova2 (words, 1, "off", "linear"); 449s [C, M, H, GNAMES] = multcompare (STATS, "estimate", "column",... 449s "ctype", "lsd", "display", "off"); 449s assert (C(1,6), 0.000020799832702, 1e-09); 449s assert (C(2,6), 0.000000035812410, 1e-09); 449s assert (C(3,6), 0.003038942449215, 1e-09); 449s ***** test 449s 449s ## Test for anova2 ("nested") - comparison with results from GraphPad Prism 8 449s data = [4.5924 7.3809 21.322; -0.5488 9.2085 25.0426; ... 449s 6.1605 13.1147 22.66; 2.3374 15.2654 24.1283; ... 449s 5.1873 12.4188 16.5927; 3.3579 14.3951 10.2129; ... 449s 6.3092 8.5986 9.8934; 3.2831 3.4945 10.0203]; 449s [P, ATAB, STATS] = anova2 (data, 4, "off", "nested"); 449s [C, M, H, GNAMES] = multcompare (STATS, "estimate", "column",... 449s "ctype", "lsd", "display", "off"); 449s assert (C(1,6), 0.261031111511073, 1e-09); 449s assert (C(2,6), 0.065879755907745, 1e-09); 449s assert (C(3,6), 0.241874613529270, 1e-09); 449s ***** shared visibility_setting 449s visibility_setting = get (0, "DefaultFigureVisible"); 449s ***** test 449s set (0, "DefaultFigureVisible", "off"); 449s 449s ## Test for kruskalwallis - comparison with results from MATLAB 449s data = [3,2,4; 5,4,4; 4,2,4; 4,2,4; 4,1,5; ... 449s 4,2,3; 4,3,5; 4,2,4; 5,2,4; 5,3,3]; 449s group = [1:3] .* ones (10,3); 449s [P, ATAB, STATS] = kruskalwallis (data(:), group(:), "off"); 449s C = multcompare (STATS, "ctype", "lsd", "display", "off"); 449s assert (C(1,6), 0.000163089828959986, 1e-09); 449s assert (C(2,6), 0.630298044801257, 1e-09); 449s assert (C(3,6), 0.00100567660695682, 1e-09); 449s C = multcompare (STATS, "ctype", "bonferroni", "display", "off"); 449s assert (C(1,6), 0.000489269486879958, 1e-09); 449s assert (C(2,6), 1, 1e-09); 449s assert (C(3,6), 0.00301702982087047, 1e-09); 449s C = multcompare(STATS, "ctype", "scheffe", "display", "off"); 449s assert (C(1,6), 0.000819054880289573, 1e-09); 449s assert (C(2,6), 0.890628039849261, 1e-09); 449s assert (C(3,6), 0.00447816059021654, 1e-09); 449s set (0, "DefaultFigureVisible", visibility_setting); 449s ***** test 449s set (0, "DefaultFigureVisible", "off"); 449s ## Test for friedman - comparison with results from MATLAB 449s popcorn = [5.5, 4.5, 3.5; 5.5, 4.5, 4.0; 6.0, 4.0, 3.0; ... 449s 6.5, 5.0, 4.0; 7.0, 5.5, 5.0; 7.0, 5.0, 4.5]; 449s [P, ATAB, STATS] = friedman (popcorn, 3, "off"); 449s C = multcompare(STATS, "ctype", "lsd", "display", "off"); 449s assert (C(1,6), 0.227424558028569, 1e-09); 449s assert (C(2,6), 0.0327204848315735, 1e-09); 449s assert (C(3,6), 0.353160353315988, 1e-09); 449s C = multcompare(STATS, "ctype", "bonferroni", "display", "off"); 449s assert (C(1,6), 0.682273674085708, 1e-09); 449s assert (C(2,6), 0.0981614544947206, 1e-09); 449s assert (C(3,6), 1, 1e-09); 449s C = multcompare(STATS, "ctype", "scheffe", "display", "off"); 449s assert (C(1,6), 0.482657360384373, 1e-09); 449s assert (C(2,6), 0.102266573027672, 1e-09); 449s assert (C(3,6), 0.649836502233148, 1e-09); 449s set (0, "DefaultFigureVisible", visibility_setting); 449s ***** test 449s set (0, "DefaultFigureVisible", "off"); 449s ## Test for fitlm - same comparisons as for first anovan example 449s y = [ 8.706 10.362 11.552 6.941 10.983 10.092 6.421 14.943 15.931 ... 449s 22.968 18.590 16.567 15.944 21.637 14.492 17.965 18.851 22.891 ... 449s 22.028 16.884 17.252 18.325 25.435 19.141 21.238 22.196 18.038 ... 449s 22.628 31.163 26.053 24.419 32.145 28.966 30.207 29.142 33.212 ... 449s 25.694 ]'; 449s X = [1 1 1 1 1 1 1 1 2 2 2 2 2 3 3 3 3 3 3 3 3 4 4 4 4 4 4 4 5 5 5 5 5 5 5 5 5]'; 449s [TAB,STATS] = fitlm (X,y,"linear","categorical",1,"display","off",... 449s "contrasts","simple"); 449s [C, M] = multcompare(STATS, "ctype", "lsd", "display", "off"); 449s assert (C(1,6), 2.85812420217898e-05, 1e-09); 449s assert (C(2,6), 5.22936741204085e-07, 1e-09); 449s assert (C(3,6), 2.12794763209146e-08, 1e-09); 449s assert (C(4,6), 7.82091664406946e-15, 1e-09); 449s assert (C(5,6), 0.546591417210693, 1e-09); 449s assert (C(6,6), 0.0845897945254446, 1e-09); 449s assert (C(7,6), 9.47436557975328e-08, 1e-09); 449s assert (C(8,6), 0.188873478781067, 1e-09); 449s assert (C(9,6), 4.08974010364197e-08, 1e-09); 449s assert (C(10,6), 4.44427348175241e-06, 1e-09); 449s assert (M(1,1), 10, 1e-09); 449s assert (M(2,1), 18, 1e-09); 449s assert (M(3,1), 19, 1e-09); 449s assert (M(4,1), 21.0001428571429, 1e-09); 449s assert (M(5,1), 29.0001111111111, 1e-09); 449s assert (M(1,2), 1.0177537954095, 1e-09); 449s assert (M(2,2), 1.28736803631001, 1e-09); 449s assert (M(3,2), 1.0177537954095, 1e-09); 449s assert (M(4,2), 1.0880245732889, 1e-09); 449s assert (M(5,2), 0.959547480416536, 1e-09); 449s set (0, "DefaultFigureVisible", visibility_setting); 449s ***** test 449s ## Test p-value adjustments compared to R stats package function p.adjust 449s ## Data from Westfall (1997) JASA. 92(437):299-306 449s p = [.005708; .023544; .024193; .044895; ... 449s .048805; .221227; .395867; .693051; .775755]; 449s padj = multcompare (p); 449s assert (padj(1), 0.051372, 1e-06); 449s assert (padj(2), 0.188352, 1e-06); 449s assert (padj(3), 0.188352, 1e-06); 449s assert (padj(4), 0.269370, 1e-06); 449s assert (padj(5), 0.269370, 1e-06); 449s assert (padj(6), 0.884908, 1e-06); 449s assert (padj(7), 1.000000, 1e-06); 449s assert (padj(8), 1.000000, 1e-06); 449s assert (padj(9), 1.000000, 1e-06); 449s padj = multcompare(p,'ctype','holm'); 449s assert (padj(1), 0.051372, 1e-06); 449s assert (padj(2), 0.188352, 1e-06); 449s assert (padj(3), 0.188352, 1e-06); 449s assert (padj(4), 0.269370, 1e-06); 449s assert (padj(5), 0.269370, 1e-06); 449s assert (padj(6), 0.884908, 1e-06); 449s assert (padj(7), 1.000000, 1e-06); 449s assert (padj(8), 1.000000, 1e-06); 449s assert (padj(9), 1.000000, 1e-06); 449s padj = multcompare(p,'ctype','hochberg'); 449s assert (padj(1), 0.051372, 1e-06); 449s assert (padj(2), 0.169351, 1e-06); 449s assert (padj(3), 0.169351, 1e-06); 449s assert (padj(4), 0.244025, 1e-06); 449s assert (padj(5), 0.244025, 1e-06); 449s assert (padj(6), 0.775755, 1e-06); 449s assert (padj(7), 0.775755, 1e-06); 449s assert (padj(8), 0.775755, 1e-06); 449s assert (padj(9), 0.775755, 1e-06); 449s padj = multcompare(p,'ctype','fdr'); 449s assert (padj(1), 0.0513720, 1e-07); 449s assert (padj(2), 0.0725790, 1e-07); 449s assert (padj(3), 0.0725790, 1e-07); 449s assert (padj(4), 0.0878490, 1e-07); 449s assert (padj(5), 0.0878490, 1e-07); 449s assert (padj(6), 0.3318405, 1e-07); 449s assert (padj(7), 0.5089719, 1e-07); 449s assert (padj(8), 0.7757550, 1e-07); 449s assert (padj(9), 0.7757550, 1e-07); 449s 8 tests, 8 passed, 0 known failure, 0 skipped 449s [inst/barttest.m] 449s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/barttest.m 449s ***** error barttest () 449s ***** error barttest ([2,NaN;3,4]) 449s ***** error barttest (ones (30, 4), "alpha") 449s ***** error barttest (ones (30, 4), 0) 449s ***** error barttest (ones (30, 4), 1.2) 449s ***** error barttest (ones (30, 4), [0.2, 0.05]) 449s ***** error barttest (ones (30, 1)) 449s ***** error barttest (ones (30, 1), 0.05) 449s ***** test 449s x = [2, 3, 4, 5, 6, 7, 8, 9; 1, 2, 3, 4, 5, 6, 7, 8]'; 449s [ndim, pval, chisq] = barttest (x); 449s assert (ndim, 2); 449s assert (pval, 0); 449s ## assert (chisq, 512.0558, 1e-4); Result differs between octave 6 and 7 ? 449s ***** test 449s x = [0.53767, 0.62702, -0.10224, -0.25485, 1.4193, 1.5237 ; ... 449s 1.8339, 1.6452, -0.24145, -0.23444, 0.29158, 0.1634 ; ... 449s -2.2588, -2.1351, 0.31286, 0.39396, 0.19781, 0.20995 ; ... 449s 0.86217, 1.0835, 0.31286, 0.46499, 1.5877, 1.495 ; ... 449s 0.31877, 0.38454, -0.86488, -0.63839, -0.80447, -0.7536 ; ... 449s -1.3077, -1.1487, -0.030051, -0.017629, 0.69662, 0.60497 ; ... 449s -0.43359, -0.32672, -0.16488, -0.37364, 0.83509, 0.89586 ; ... 449s 0.34262, 0.29639, 0.62771, 0.51672, -0.24372, -0.13698 ; ... 449s 3.5784, 3.5841, 1.0933, 0.93258, 0.21567, 0.455 ; ... 449s 2.7694, 2.6307, 1.1093, 1.4298, -1.1658, -1.1816 ; ... 449s -1.3499, -1.2111, -0.86365, -0.94186, -1.148, -1.4381 ; ... 449s 3.0349, 2.8428, 0.077359, 0.18211, 0.10487, -0.014613; ... 449s 0.7254, 0.56737, -1.2141, -1.2291, 0.72225, 0.90612 ; ... 449s -0.063055,-0.17662, -1.1135, -0.97701, 2.5855, 2.4084 ; ... 449s 0.71474, 0.29225, -0.0068493, -0.11468, -0.66689, -0.52466 ; ... 449s -0.20497, -7.8874e-06, 1.5326, 1.3195, 0.18733, 0.20296 ; ... 449s -0.12414, -0.077029, -0.76967, -0.96262, -0.082494, 0.121 ; ... 449s 1.4897, 1.3683, 0.37138, 0.43653, -1.933, -2.1903 ; ... 449s 1.409, 1.5882, -0.22558, -0.24835, -0.43897, -0.46247 ; ... 449s 1.4172, 1.1616, 1.1174, 1.0785, -1.7947, -1.9471 ]; 449s [ndim, pval, chisq] = barttest (x); 449s assert (ndim, 3); 449s assert (pval, [0; 0; 0; 0.52063; 0.34314], 1e-5); 449s chisq_out = [251.6802; 210.2670; 153.1773; 4.2026; 2.1392]; 449s assert (chisq, chisq_out, 1e-4); 449s 10 tests, 10 passed, 0 known failure, 0 skipped 449s [inst/hotelling_t2test.m] 449s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/hotelling_t2test.m 449s ***** error hotelling_t2test (); 449s ***** error ... 449s hotelling_t2test (1); 449s ***** error ... 449s hotelling_t2test (ones(2,2,2)); 449s ***** error ... 449s hotelling_t2test (ones(20,2), [0, 0], "alpha", 1); 449s ***** error ... 449s hotelling_t2test (ones(20,2), [0, 0], "alpha", -0.2); 449s ***** error ... 449s hotelling_t2test (ones(20,2), [0, 0], "alpha", "a"); 449s ***** error ... 449s hotelling_t2test (ones(20,2), [0, 0], "alpha", [0.01, 0.05]); 449s ***** error ... 449s hotelling_t2test (ones(20,2), [0, 0], "name", 0.01); 449s ***** error ... 449s hotelling_t2test (ones(20,1), [0, 0]); 449s ***** error ... 449s hotelling_t2test (ones(4,5), [0, 0, 0, 0, 0]); 449s ***** error ... 449s hotelling_t2test (ones(20,5), [0, 0, 0, 0]); 449s ***** test 449s randn ("seed", 1); 449s x = randn (50000, 5); 449s [h, pval, stats] = hotelling_t2test (x); 449s assert (h, 0); 449s assert (stats.df1, 5); 449s assert (stats.df2, 49995); 449s ***** test 449s randn ("seed", 1); 449s x = randn (50000, 5); 449s [h, pval, stats] = hotelling_t2test (x, ones (1, 5) * 10); 449s assert (h, 1); 449s assert (stats.df1, 5); 449s assert (stats.df2, 49995); 449s 13 tests, 13 passed, 0 known failure, 0 skipped 449s [inst/cdfplot.m] 449s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/cdfplot.m 449s ***** demo 449s x = randn(100,1); 449s cdfplot (x); 449s ***** test 449s hf = figure ("visible", "off"); 449s unwind_protect 449s x = [2, 4, 3, 2, 4, 3, 2, 5, 6, 4]; 449s [hCDF, stats] = cdfplot (x); 449s assert (stats.min, 2); 449s assert (stats.max, 6); 449s assert (stats.median, 3.5); 449s assert (stats.std, 1.35400640077266, 1e-14); 449s unwind_protect_cleanup 449s close (hf); 449s end_unwind_protect 449s ***** test 449s hf = figure ("visible", "off"); 449s unwind_protect 449s x = randn(100,1); 449s cdfplot (x); 449s unwind_protect_cleanup 449s close (hf); 449s end_unwind_protect 449s ***** error cdfplot (); 449s ***** error cdfplot ([x',x']); 449s ***** error cdfplot ([NaN, NaN, NaN, NaN]); 449s 5 tests, 5 passed, 0 known failure, 0 skipped 449s [inst/silhouette.m] 449s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/silhouette.m 449s ***** demo 449s load fisheriris; 449s X = meas(:,3:4); 449s cidcs = kmeans (X, 3, "Replicates", 5); 449s silhouette (X, cidcs); 449s y_labels(cidcs([1 51 101])) = unique (species); 449s set (gca, "yticklabel", y_labels); 449s title ("Fisher's iris data"); 449s ***** error silhouette (); 450s ***** error silhouette ([1 2; 1 1]); 450s ***** error silhouette ([1 2; 1 1], [1 2 3]'); 450s ***** error silhouette ([1 2; 1 1], [1 2]', "xxx"); 450s 4 tests, 4 passed, 0 known failure, 0 skipped 450s [inst/ttest2.m] 450s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/ttest2.m 450s ***** test 450s a = 1:5; 450s b = 6:10; 450s b(5) = NaN; 450s [h,p,ci,stats] = ttest2 (a,b); 450s assert (h, 1); 450s assert (p, 0.002535996080258229, 1e-14); 450s assert (ci, [-6.822014919225481, -2.17798508077452], 1e-14); 450s assert (stats.tstat, -4.582575694955839, 1e-14); 450s assert (stats.df, 7); 450s assert (stats.sd, 1.4638501094228, 1e-13); 450s ***** error ttest2 ([8:0.1:12], [8:0.1:12], "tail", "invalid"); 450s ***** error ttest2 ([8:0.1:12], [8:0.1:12], "tail", 25); 450s 3 tests, 3 passed, 0 known failure, 0 skipped 450s [inst/fitcnet.m] 450s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/fitcnet.m 450s ***** demo 450s ## Train a Neural Network on the Fisher's Iris data set and display 450s ## a confusion chart with the classification results. 450s 450s load fisheriris 450s Mdl = fitcnet (meas, species); 450s pred_species = resubPredict (Mdl); 450s confusionchart (species, pred_species); 450s ***** error fitcnet () 450s ***** error fitcnet (ones (4,1)) 450s ***** error 450s fitcnet (ones (4,2), ones (4, 1), 'LayerSizes') 450s ***** error 450s fitcnet (ones (4,2), ones (3, 1)) 450s ***** error 450s fitcnet (ones (4,2), ones (3, 1), 'LayerSizes', 2) 450s 5 tests, 5 passed, 0 known failure, 0 skipped 450s [inst/geomean.m] 450s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/geomean.m 450s ***** test 450s x = [0:10]; 450s y = [x;x+5;x+10]; 450s assert (geomean (x), 0); 450s m = [0 9.462942809849169 14.65658770861967]; 450s assert (geomean (y, 2), m', 4e-14); 450s assert (geomean (y, "all"), 0); 450s y(2,4) = NaN; 450s m(2) = 9.623207231679554; 450s assert (geomean (y, 2), [0 NaN m(3)]', 4e-14); 450s assert (geomean (y', "omitnan"), m, 4e-14); 450s z = y + 20; 450s assert (geomean (z, "all"), NaN); 450s assert (geomean (z, "all", "includenan"), NaN); 450s assert (geomean (z, "all", "omitnan"), 29.59298474535024, 4e-14); 450s m = [24.79790781765634 NaN 34.85638839503932]; 450s assert (geomean (z'), m, 4e-14); 450s assert (geomean (z', "includenan"), m, 4e-14); 450s m(2) = 30.02181156156319; 450s assert (geomean (z', "omitnan"), m, 4e-14); 450s assert (geomean (z, 2, "omitnan"), m', 4e-14); 450s ***** test 450s x = repmat ([1:20;6:25], [5 2 6 3]); 450s assert (size (geomean (x, [3 2])), [10 1 1 3]); 450s assert (size (geomean (x, [1 2])), [1 1 6 3]); 450s assert (size (geomean (x, [1 2 4])), [1 1 6]); 450s assert (size (geomean (x, [1 4 3])), [1 40]); 450s assert (size (geomean (x, [1 2 3 4])), [1 1]); 450s ***** test 450s x = repmat ([1:20;6:25], [5 2 6 3]); 450s m = repmat ([8.304361203739333;14.3078118884256], [5 1 1 3]); 450s assert (geomean (x, [3 2]), m, 4e-13); 450s x(2,5,6,3) = NaN; 450s m(2,3) = NaN; 450s assert (geomean (x, [3 2]), m, 4e-13); 450s m(2,3) = 14.3292729579901; 450s assert (geomean (x, [3 2], "omitnan"), m, 4e-13); 450s ***** error geomean ("char") 450s ***** error geomean ([1 -1 3]) 450s ***** error ... 450s geomean (repmat ([1:20;6:25], [5 2 6 3 5]), -1) 450s ***** error ... 450s geomean (repmat ([1:20;6:25], [5 2 6 3 5]), 0) 450s ***** error ... 450s geomean (repmat ([1:20;6:25], [5 2 6 3 5]), [1 1]) 450s 8 tests, 8 passed, 0 known failure, 0 skipped 450s [inst/shadow9/mean.m] 450s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/shadow9/mean.m 450s ***** test 450s x = -10:10; 450s y = x'; 450s z = [y, y+10]; 450s assert (mean (x), 0); 450s assert (mean (y), 0); 450s assert (mean (z), [0, 10]); 450s ***** assert (mean (magic (3), 1), [5, 5, 5]) 450s ***** assert (mean (magic (3), 2), [5; 5; 5]) 450s ***** assert (mean (logical ([1 0 1 1])), 0.75) 450s ***** assert (mean (single ([1 0 1 1])), single (0.75)) 450s ***** assert (mean ([1 2], 3), [1 2]) 450s ***** test 450s in = [1 2 3]; 450s out = 2; 450s assert (mean (in, "default"), mean (in)); 450s assert (mean (in, "default"), out); 450s assert (mean (in, "double"), out); 450s assert (mean (in, "native"), out); 450s ***** test 450s in = single ([1 2 3]); 450s out = 2; 450s assert (mean (in, "default"), mean (in)); 450s assert (mean (in, "default"), single (out)); 450s assert (mean (in, "double"), out); 450s assert (mean (in, "native"), single (out)); 450s ***** test 450s in = logical ([1 0 1]); 450s out = 2/3; 450s assert (mean (in, "default"), mean (in), eps); 450s assert (mean (in, "default"), out, eps); 450s assert (mean (in, "double"), out, eps); 450s assert (mean (in, "native"), out, eps); 450s ***** test 450s in = char ("ab"); 450s out = 97.5; 450s assert (mean (in, "default"), mean (in), eps); 450s assert (mean (in, "default"), out, eps); 450s assert (mean (in, "double"), out, eps); 450s ***** test 450s in = uint8 ([1 2 3]); 450s out = 2; 450s assert (mean (in, "default"), mean (in)); 450s assert (mean (in, "default"), out); 450s assert (mean (in, "double"), out); 450s assert (mean (in, "native"), uint8 (out)); 450s ***** test 450s in = uint8 ([0 1 2 3]); 450s out = 1.5; 450s out_u8 = 2; 450s assert (mean (in, "default"), mean (in), eps); 450s assert (mean (in, "default"), out, eps); 450s assert (mean (in, "double"), out, eps); 450s assert (mean (in, "native"), uint8 (out_u8)); 450s assert (class (mean (in, "native")), "uint8"); 450s ***** test # internal sum exceeding intmax 450s in = uint8 ([3 141 141 255]); 450s out = 135; 450s assert (mean (in, "default"), mean (in)); 450s assert (mean (in, "default"), out); 450s assert (mean (in, "double"), out); 450s assert (mean (in, "native"), uint8 (out)); 450s assert (class (mean (in, "native")), "uint8"); 450s ***** test # fractional answer with internal sum exceeding intmax 450s in = uint8 ([1 141 141 255]); 450s out = 134.5; 450s out_u8 = 135; 450s assert (mean (in, "default"), mean (in)); 450s assert (mean (in, "default"), out); 450s assert (mean (in, "double"), out); 450s assert (mean (in, "native"), uint8 (out_u8)); 450s assert (class (mean (in, "native")), "uint8"); 450s ***** test <54567> # large int64 sum exceeding intmax and double precision limit 450s in_same = uint64 ([intmax("uint64") intmax("uint64")-2]); 450s out_same = intmax ("uint64")-1; 450s in_opp = int64 ([intmin("int64"), intmax("int64")-1]); 450s out_opp = -1; 450s in_neg = int64 ([intmin("int64") intmin("int64")+2]); 450s out_neg = intmin ("int64")+1; 450s 450s ## both positive 450s assert (mean (in_same, "default"), mean (in_same)); 450s assert (mean (in_same, "default"), double (out_same)); 450s assert (mean (in_same, "double"), double (out_same)); 450s assert (mean (in_same, "native"), uint64 (out_same)); 450s assert (class (mean (in_same, "native")), "uint64"); 450s 450s ## opposite signs 450s assert (mean (in_opp, "default"), mean (in_opp)); 450s assert (mean (in_opp, "default"), double (out_opp)); 450s assert (mean (in_opp, "double"), double (out_opp)); 450s assert (mean (in_opp, "native"), int64 (out_opp)); 450s assert (class (mean (in_opp, "native")), "int64"); 450s 450s ## both negative 450s assert (mean (in_neg, "default"), mean (in_neg)); 450s assert (mean (in_neg, "default"), double(out_neg)); 450s assert (mean (in_neg, "double"), double(out_neg)); 450s assert (mean (in_neg, "native"), int64(out_neg)); 450s assert (class (mean (in_neg, "native")), "int64"); 450s ***** test <54567> 450s in = [(intmin('int64')+5), (intmax('int64'))-5]; 450s assert (mean (in, "native"), int64(-1)); 450s assert (class (mean (in, "native")), "int64"); 450s assert (mean (double(in)), double(0) ); 450s assert (mean (in), double(-0.5) ); 450s assert (mean (in, "default"), double(-0.5) ); 450s assert (mean (in, "double"), double(-0.5) ); 450s assert (mean (in, "all", "native"), int64(-1)); 450s assert (mean (in, 2, "native"), int64(-1)); 450s assert (mean (in, [1 2], "native"), int64(-1)); 450s assert (mean (in, [2 3], "native"), int64(-1)); 450s assert (mean ([intmin("int64"), in, intmax("int64")]), double(-0.5)) 450s assert (mean ([in; int64([1 3])], 2, "native"), int64([-1; 2])); 450s ***** test 450s x = [-10:10]; 450s y = [x;x+5;x-5]; 450s assert (mean (x), 0); 450s assert (mean (y, 2), [0, 5, -5]'); 450s assert (mean (y, "all"), 0); 450s y(2,4) = NaN; 450s assert (mean (y', "omitnan"), [0 5.35 -5]); 450s z = y + 20; 450s assert (mean (z, "all"), NaN); 450s assert (mean (z, "all", "includenan"), NaN); 450s assert (mean (z, "all", "omitnan"), 20.03225806451613, 4e-14); 450s m = [20 NaN 15]; 450s assert (mean (z'), m); 450s assert (mean (z', "includenan"), m); 450s m = [20 25.35 15]; 450s assert (mean (z', "omitnan"), m); 450s assert (mean (z, 2, "omitnan"), m'); 450s assert (mean (z, 2, "native", "omitnan"), m'); 450s assert (mean (z, 2, "omitnan", "native"), m'); 450s ***** test 450s assert (mean (true, "all"), 1); 450s assert (mean (false), 0); 450s assert (mean ([true false true]), 2/3, 4e-14); 450s assert (mean ([true false true], 1), [1 0 1]); 450s assert (mean ([true false NaN], 1), [1 0 NaN]); 450s assert (mean ([true false NaN], 2), NaN); 450s assert (mean ([true false NaN], 2, "omitnan"), 0.5); 450s assert (mean ([true false NaN], 2, "omitnan", "native"), 0.5); 450s ***** assert (mean ("abc"), double (98)) 450s ***** assert (mean ("ab"), double (97.5), eps) 450s ***** assert (mean ("abc", "double"), double (98)) 450s ***** assert (mean ("abc", "default"), double (98)) 450s ***** test 450s x = magic (4); 450s x([2, 9:12]) = NaN; 450s assert (mean (x), [NaN 8.5, NaN, 8.5], eps); 450s assert (mean (x,1), [NaN 8.5, NaN, 8.5], eps); 450s assert (mean (x,2), NaN(4,1), eps); 450s assert (mean (x,3), x, eps); 450s assert (mean (x, 'omitnan'), [29/3, 8.5, NaN, 8.5], eps); 450s assert (mean (x, 1, 'omitnan'), [29/3, 8.5, NaN, 8.5], eps); 450s assert (mean (x, 2, 'omitnan'), [31/3; 9.5; 28/3; 19/3], eps); 450s assert (mean (x, 3, 'omitnan'), x, eps); 450s ***** assert (mean ([]), NaN(1,1)) 450s ***** assert (mean (single([])), NaN(1,1,"single")) 450s ***** assert (mean ([], 1), NaN(1,0)) 450s ***** assert (mean ([], 2), NaN(0,1)) 450s ***** assert (mean ([], 3), NaN(0,0)) 450s ***** assert (mean (ones(1,0)), NaN(1,1)) 450s ***** assert (mean (ones(1,0), 1), NaN(1,0)) 450s ***** assert (mean (ones(1,0), 2), NaN(1,1)) 450s ***** assert (mean (ones(1,0), 3), NaN(1,0)) 450s ***** assert (mean (ones(0,1)), NaN(1,1)) 450s ***** assert (mean (ones(0,1), 1), NaN(1,1)) 450s ***** assert (mean (ones(0,1), 2), NaN(0,1)) 450s ***** assert (mean (ones(0,1), 3), NaN(0,1)) 450s ***** assert (mean (ones(0,1,0)), NaN(1,1,0)) 450s ***** assert (mean (ones(0,1,0), 1), NaN(1,1,0)) 450s ***** assert (mean (ones(0,1,0), 2), NaN(0,1,0)) 450s ***** assert (mean (ones(0,1,0), 3), NaN(0,1,1)) 450s ***** assert (mean (ones(0,0,1,0)), NaN(1,0,1,0)) 450s ***** assert (mean (ones(0,0,1,0), 1), NaN(1,0,1,0)) 450s ***** assert (mean (ones(0,0,1,0), 2), NaN(0,1,1,0)) 450s ***** assert (mean (ones(0,0,1,0), 3), NaN(0,0,1,0)) 450s ***** test 450s x = repmat ([1:20;6:25], [5 2 6 3]); 450s assert (size (mean (x, [3 2])), [10 1 1 3]); 450s assert (size (mean (x, [1 2])), [1 1 6 3]); 450s assert (size (mean (x, [1 2 4])), [1 1 6]); 450s assert (size (mean (x, [1 4 3])), [1 40]); 450s assert (size (mean (x, [1 2 3 4])), [1 1]); 450s ***** assert (mean (ones (2,2), 3), ones (2,2)) 450s ***** assert (mean (ones (2,2,2), 99), ones (2,2,2)) 450s ***** assert (mean (magic (3), 3), magic (3)) 450s ***** assert (mean (magic (3), [1 3]), [5, 5, 5]) 450s ***** assert (mean (magic (3), [1 99]), [5, 5, 5]) 450s ***** test 450s x = repmat ([1:20;6:25], [5 2 6 3]); 450s m = repmat ([10.5;15.5], [5 1 1 3]); 450s assert (mean (x, [3 2]), m, 4e-14); 450s x(2,5,6,3) = NaN; 450s m(2,1,1,3) = NaN; 450s assert (mean (x, [3 2]), m, 4e-14); 450s m(2,1,1,3) = 15.52301255230125; 450s assert (mean (x, [3 2], "omitnan"), m, 4e-14); 450s ***** assert (mean ([1 2 3], "aLL"), 2) 450s ***** assert (mean ([1 2 3], "OmitNan"), 2) 450s ***** assert (mean ([1 2 3], "DOUBle"), 2) 450s ***** assert <*63848> (mean (ones (80e6, 1, "single")), 1, eps) 451s ***** assert <*63848> (mean (ones (80e6, 1, "single"), "all"), 1, eps) 451s ***** assert <*63848> (mean (ones (80e6, 1, "single"), 1), 1, eps) 451s ***** assert <*63848> (mean (ones (80e6, 1, "single"), [1 2]), 1, eps) 451s ***** assert <*63848> (mean (ones (80e6, 1, "single"), [1 3]), 1, eps) 452s ***** assert <63848> (mean ([flintmax("double"), ones(1, 2^8-1, "double")]), ... 452s 35184372088833-1/(2^8), eps(35184372088833)) 452s !!!!! known bug: https://octave.org/testfailure/?63848 452s ASSERT errors for: assert (mean ([flintmax("double"), ones(1, 2 ^ 8 - 1, "double")]),35184372088833 - 1 / (2 ^ 8),eps (35184372088833)) 452s 452s Location | Observed | Expected | Reason 452s () 35184372088832 35184372088833 Abs err 1 exceeds tol 0.0078125 by 1 452s ***** error mean () 452s ***** error mean (1, 2, 3) 452s ***** error mean (1, 2, 3, 4) 452s ***** error mean (1, "all", 3) 452s ***** error mean (1, "b") 452s ***** error mean (1, 1, "foo") 453s ***** error mean ("abc", "native") 453s ***** error mean ({1:5}) 453s ***** error mean (1, ones (2,2)) 453s ***** error mean (1, 1.5) 453s ***** error mean (1, 0) 453s ***** error mean (1, []) 453s ***** error mean (1, -1) 453s ***** error mean (1, -1.5) 453s ***** error mean (1, NaN) 453s ***** error mean (1, Inf) 453s ***** error mean (repmat ([1:20;6:25], [5 2]), -1) 453s ***** error mean (repmat ([1:5;5:9], [5 2]), [1 -1]) 453s ***** error mean (1, ones(1,0)) 453s ***** error mean (1, [2 2]) 453s 80 tests, 79 passed, 0 known failure, 1 skipped 453s [inst/shadow9/std.m] 453s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/shadow9/std.m 453s ***** assert (std (13), 0) 453s ***** assert (std (single (13)), single (0)) 453s ***** assert (std ([1,2,3]), 1) 453s ***** assert (std ([1,2,3], 1), sqrt (2/3), eps) 453s ***** assert (std ([1,2,3], [], 1), [0,0,0]) 453s ***** assert (std ([1,2,3], [], 3), [0,0,0]) 453s ***** assert (std (5, 99), 0) 453s ***** assert (std (5, 99, 1), 0) 453s ***** assert (std (5, 99, 2), 0) 453s ***** assert (std ([5 3], [99 99], 2), 1) 453s ***** assert (std ([1:7], [1:7]), sqrt (3)) 453s ***** assert (std ([eye(3)], [1:3]), sqrt ([5/36, 2/9, 1/4]), eps) 453s ***** assert (std (ones (2,2,2), [1:2], 3), [(zeros (2,2))]) 453s ***** assert (std ([1 2; 3 4], 0, 'all'), std ([1:4])) 453s ***** assert (std (reshape ([1:8], 2, 2, 2), 0, [1 3]), sqrt ([17/3 17/3]), eps) 453s ***** assert (std ([1 2 3;1 2 3], [], [1 2]), sqrt (0.8), eps) 453s ***** test 453s x = [-10:10]; 453s y = [x;x+5;x-5]; 453s assert (std (x), sqrt (38.5), 1e-14); 453s assert (std (y, [], 2), sqrt ([38.5; 38.5; 38.5]), 1e-14); 453s assert (std (y, 0, 2), sqrt ([38.5; 38.5; 38.5]), 1e-14); 453s assert (std (y, 1, 2), ones (3,1) * sqrt (36.66666666666666), 1e-14); 453s assert (std (y, "all"), sqrt (54.19354838709678), 1e-14); 453s y(2,4) = NaN; 453s assert (std (y, "all"), NaN); 453s assert (std (y, "all", "includenan"), NaN); 453s assert (std (y, "all", "omitnan"), sqrt (55.01533580116342), 1e-14); 453s assert (std (y, 0, 2, "includenan"), sqrt ([38.5; NaN; 38.5]), 1e-14); 453s assert (std (y, [], 2), sqrt ([38.5; NaN; 38.5]), 1e-14); 453s assert (std (y, [], 2, "omitnan"), ... 453s sqrt ([38.5; 37.81842105263158; 38.5]), 1e-14); 453s ***** assert (std ([4 NaN 6], [1 2 1], "omitnan"), 1, eps) 453s ***** assert (std ([4 5 6], [1 NaN 1], "omitnan"), 1, eps) 453s ***** assert (std (magic(3), [1 NaN 3], "omitnan"), sqrt(3)*[1 2 1], eps) 453s ***** assert (std ([4 NaN 6], [1 2 1], "omitnan", "all"), 1, eps) 453s ***** assert (std ([4 NaN 6], [1 2 1], "all", "omitnan"), 1, eps) 453s ***** assert (std ([4 5 6], [1 NaN 1], "omitnan", "all"), 1, eps) 453s ***** assert (std ([4 NaN 6], [1 2 1], 2, "omitnan"), 1, eps) 453s ***** assert (std ([4 5 6], [1 NaN 1], 2, "omitnan"), 1, eps) 453s ***** assert (std (magic(3), [1 NaN 3], 1, "omitnan"), sqrt(3)*[1 2 1], eps) 453s ***** assert (std (magic(3), [1 NaN 3], 2, "omitnan"), sqrt(3)*[0.5;1;0.5], eps) 453s ***** assert (std (4*[4 5; 6 7; 8 9], [1 3], 2, 'omitnan'), sqrt(3)*[1;1;1], eps) 453s ***** assert (std ([4 NaN; 6 7; 8 9], [1 1 3], 1, 'omitnan'), [1.6 sqrt(3)/2], eps) 453s ***** assert (std (4*[4 NaN; 6 7; 8 9], [1 3], 2, 'omitnan'), sqrt(3)*[0;1;1], eps) 453s ***** assert (std (3*reshape(1:18, [3 3 2]), [1 2 3], 1, 'omitnan'), ... 453s sqrt(5)*ones(1,3,2), eps) 453s ***** assert (std (reshape(1:18, [3 3 2]), [1 2 3], 2, 'omitnan'), ... 453s sqrt(5)*ones(3,1,2), eps) 453s ***** assert (std (3*reshape(1:18, [3 3 2]), ones (3,3,2), [1 2], 'omitnan'), ... 453s sqrt(60)*ones(1,1,2),eps) 453s ***** assert (std (3*reshape(1:18, [3 3 2]), ones (3,3,2), [1 4], 'omitnan'), ... 453s sqrt(6)*ones(1,3,2),eps) 453s ***** assert (std (6*reshape(1:18, [3 3 2]), ones (3,3,2), [1:3], 'omitnan'), ... 453s sqrt(969),eps) 453s ***** test 453s x = reshape(1:18, [3 3 2]); 453s x([2, 14]) = NaN; 453s w = ones (3,3,2); 453s assert (std (16*x, w, [1:3], 'omitnan'), sqrt(6519), eps); 453s ***** test 453s x = reshape(1:18, [3 3 2]); 453s w = ones (3,3,2); 453s w([2, 14]) = NaN; 453s assert (std (16*x, w, [1:3], 'omitnan'), sqrt(6519), eps); 453s ***** assert (std ([1 2 3], "aLl"), 1); 453s ***** assert (std ([1 2 3], "OmitNan"), 1); 453s ***** assert (std ([1 2 3], "IncludeNan"), 1); 453s ***** test 453s x = repmat ([1:20;6:25], [5, 2, 6, 3]); 453s assert (size (std (x, 0, [3 2])), [10, 1, 1, 3]); 453s assert (size (std (x, 1, [1 2])), [1, 1, 6, 3]); 453s assert (size (std (x, [], [1 2 4])), [1, 1, 6]); 453s assert (size (std (x, 0, [1 4 3])), [1, 40]); 453s assert (size (std (x, [], [1 2 3 4])), [1, 1]); 453s ***** assert (std (3*magic(3)), sqrt([63 144 63]), eps) 453s ***** assert (std (3*magic(3), 'omitnan'), sqrt([63 144 63]), eps) 453s ***** assert (std (3*magic(3), 1), sqrt([42 96 42]), eps) 453s ***** assert (std (3*magic(3), 1, 'omitnan'), sqrt([42 96 42]), eps) 453s ***** assert (std (3*magic(3), ones(1,3), 1), sqrt([42 96 42]), eps) 453s ***** assert (std (3*magic(3), ones(1,3), 1, 'omitnan'), sqrt([42 96 42]), eps) 453s ***** assert (std (2*magic(3), [1 1 NaN], 1, 'omitnan'), [5 4 1], eps) 453s ***** assert (std (3*magic(3), ones(3,3)), sqrt([42 96 42]), eps) 453s ***** assert (std (3*magic(3), ones(3,3), 'omitnan'), sqrt([42 96 42]), eps) 453s ***** assert (std (3*magic(3), [1 1 1; 1 1 1; 1 NaN 1], 'omitnan'), ... 453s sqrt([42 36 42]), eps) 453s ***** assert (std (3*magic(3), ones(3,3), 1), sqrt([42 96 42]), eps) 453s ***** assert (std (3*magic(3), ones(3,3), 1, 'omitnan'), sqrt([42 96 42]), eps) 453s ***** assert (std (3*magic(3), [1 1 1; 1 1 1; 1 NaN 1], 1, 'omitnan'), ... 453s sqrt([42 36 42]), eps) 453s ***** assert (std (3*magic(3), ones(3,3), [1 4]), sqrt([42 96 42]), eps) 453s ***** assert (std (3*magic(3), ones(3,3), [1 4], 'omitnan'), sqrt([42 96 42]), eps) 453s ***** assert (std (3*magic(3), [1 1 1; 1 1 1; 1 NaN 1],[1 4],'omitnan'), ... 453s sqrt([42 36 42]), eps) 453s ***** test 453s x = repmat ([1:20;6:25], [5, 2, 6, 3]); 453s v = repmat (sqrt (33.38912133891213), [10, 1, 1, 3]); 453s assert (std (x, 0, [3, 2]), v, 1e-14); 453s v = repmat (sqrt (33.250), [10, 1, 1, 3]); 453s assert (std (x, 1, [3, 2]), v, 1e-14); 453s x(2,5,6,3) = NaN; 453s v(2,1,1,3) = NaN; 453s assert (std (x, 1, [3, 2]), v, 1e-14); 453s v = repmat (sqrt (33.38912133891213), [10 1 1 3]); 453s v(2,1,1,3) = NaN; 453s assert (std (x, [], [3, 2]), v, 1e-14); 453s v(2,1,1,3) = sqrt (33.40177912169048); 453s assert (std (x, [], [3, 2], "omitnan"), v, 1e-14); 453s ***** assert (std (ones (2,2,2), [1:2], 3), [(zeros (2, 2))]) 453s ***** assert (std (magic (3), [1:9], "all"), 2.581988897471611, 1e-14) 453s ***** assert (std (ones (2,2), [], 3), zeros (2,2)) 453s ***** assert (std (ones (2,2,2), [], 99), zeros (2,2,2)) 453s ***** assert (std (magic (3), [], 3), zeros (3,3)) 453s ***** assert (std (magic (3), [], 1), sqrt ([7, 16, 7])) 453s ***** assert (std (magic (3), [], [1 3]), sqrt ([7, 16, 7])) 453s ***** assert (std (magic (3), [], [1 99]), sqrt ([7, 16, 7])) 453s ***** assert (std ([]), NaN) 453s ***** assert (class (var (single ([]))), "single") 453s ***** assert (std ([],[],1), NaN(1,0)) 453s ***** assert (std ([],[],2), NaN(0,1)) 453s ***** assert (std ([],[],3), []) 453s ***** assert (class (var (single ([]), [], 1)), "single") 453s ***** assert (std (ones (1,0)), NaN) 453s ***** assert (std (ones (1,0), [], 1), NaN(1,0)) 453s ***** assert (std (ones (1,0), [], 2), NaN) 453s ***** assert (std (ones (1,0), [], 3), NaN(1,0)) 453s ***** assert (class (var (ones (1, 0, "single"), [], 1)), "single") 453s ***** assert (std (ones (0,1)), NaN) 453s ***** assert (std (ones (0,1), [], 1), NaN) 453s ***** assert (std (ones (0,1), [], 2), NaN(0,1)) 453s ***** assert (std (ones (0,1), [], 3), NaN(0,1)) 453s ***** assert (std (ones (1,3,0,2)), NaN(1,1,0,2)) 453s ***** assert (std (ones (1,3,0,2), [], 1), NaN(1,3,0,2)) 453s ***** assert (std (ones (1,3,0,2), [], 2), NaN(1,1,0,2)) 453s ***** assert (std (ones (1,3,0,2), [], 3), NaN(1,3,1,2)) 453s ***** assert (std (ones (1,3,0,2), [], 4), NaN(1,3,0)) 453s ***** test 453s [~, m] = std ([]); 453s assert (m, NaN); 453s ***** test <*62395> 453s [~, m] = std (13); 453s assert (m, 13); 453s [~, m] = std (single(13)); 453s assert (m, single(13)); 453s [~, m] = std ([1, 2, 3; 3 2 1], []); 453s assert (m, [2 2 2]); 453s [~, m] = std ([1, 2, 3; 3 2 1], [], 1); 453s assert (m, [2 2 2]); 453s [~, m] = std ([1, 2, 3; 3 2 1], [], 2); 453s assert (m, [2 2]'); 453s [~, m] = std ([1, 2, 3; 3 2 1], [], 3); 453s assert (m, [1 2 3; 3 2 1]); 453s ***** test <*62395> 453s [~, m] = std (5,99); 453s assert (m, 5); 453s [~, m] = std ([1:7], [1:7]); 453s assert (m, 5); 453s [~, m] = std ([eye(3)], [1:3]); 453s assert (m, [1/6, 1/3, 0.5], eps); 453s [~, m] = std (ones (2,2,2), [1:2], 3); 453s assert (m, ones (2,2)); 453s [~, m] = std ([1 2; 3 4], 0, 'all'); 453s assert (m, 2.5, eps); 453s [~, m] = std (reshape ([1:8], 2, 2, 2), 0, [1 3]); 453s assert (m, [3.5, 5.5], eps); 453s ***** test 453s [v, m] = std (4 * eye (2), [1, 3]); 453s assert (v, sqrt ([3, 3]), 1e-14); 453s assert (m, [1, 3]); 453s ***** test <*62395> 453s [~, m] = std ([]); 453s assert (m, NaN); 453s ***** test 453s x = repmat ([1:20;6:25], [5, 2, 6, 3]); 453s [~, m] = std (x, 0, [3 2]); 453s assert (m, mean (x, [3 2])); 453s [~, m] = std (x, 0, [1 2]); 453s assert (m, mean (x, [1 2])); 453s [~, m] = std (x, 0, [1 3 4]); 453s assert (m, mean (x, [1 3 4])); 453s ***** test 453s x = repmat ([1:20;6:25], [5, 2, 6, 3]); 453s x(2,5,6,3) = NaN; 453s [~, m] = std (x, 0, [3 2], "omitnan"); 453s assert (m, mean (x, [3 2], "omitnan")); 453s ***** test <*63203> 453s [v, m] = std (Inf); 453s assert (v, NaN); 453s assert (m, Inf); 453s ***** test <*63203> 453s [v, m] = std (NaN); 453s assert (v, NaN); 453s assert (m, NaN); 453s ***** test <*63203> 453s [v, m] = std ([1, Inf, 3]); 453s assert (v, NaN); 453s assert (m, Inf); 453s ***** test <*63203> 453s [v, m] = std ([1, Inf, 3]'); 453s assert (v, NaN); 453s assert (m, Inf); 453s ***** test <*63203> 453s [v, m] = std ([1, NaN, 3]); 453s assert (v, NaN); 453s assert (m, NaN); 453s ***** test <*63203> 453s [v, m] = std ([1, NaN, 3]'); 453s assert (v, NaN); 453s assert (m, NaN); 453s ***** test <*63203> 453s [v, m] = std ([1, Inf, 3], [], 1); 453s assert (v, [0, NaN, 0]); 453s assert (m, [1, Inf, 3]); 453s ***** test <*63203> 453s [v, m] = std ([1, Inf, 3], [], 2); 453s assert (v, NaN); 453s assert (m, Inf); 453s ***** test <*63203> 453s [v, m] = std ([1, Inf, 3], [], 3); 453s assert (v, [0, NaN, 0]); 453s assert (m, [1, Inf, 3]); 453s ***** test <*63203> 453s [v, m] = std ([1, NaN, 3], [], 1); 453s assert (v, [0, NaN, 0]); 453s assert (m, [1, NaN, 3]); 453s ***** test <*63203> 453s [v, m] = std ([1, NaN, 3], [], 2); 453s assert (v, NaN); 453s assert (m, NaN); 453s ***** test <*63203> 453s [v, m] = std ([1, NaN, 3], [], 3); 453s assert (v, [0, NaN, 0]); 453s assert (m, [1, NaN, 3]); 453s ***** test <*63203> 453s [v, m] = std ([1, 2, 3; 3, Inf, 5]); 453s assert (v, sqrt ([2, NaN, 2])); 453s assert (m, [2, Inf, 4]); 453s ***** test <*63203> 453s [v, m] = std ([1, Inf, 3; 3, Inf, 5]); 453s assert (v, sqrt ([2, NaN, 2])); 453s assert (m, [2, Inf, 4]); 453s ***** test <*63203> 453s [v, m] = std ([1, 2, 3; 3, NaN, 5]); 453s assert (v, sqrt ([2, NaN, 2])); 453s assert (m, [2, NaN, 4]); 453s ***** test <*63203> 453s [v, m] = std ([1, NaN, 3; 3, NaN, 5]); 453s assert (v, sqrt ([2, NaN, 2])); 453s assert (m, [2, NaN, 4]); 453s ***** test <*63203> 453s [v, m] = std ([Inf, 2, NaN]); 453s assert (v, NaN); 453s assert (m, NaN); 453s ***** test <*63203> 453s [v, m] = std ([Inf, 2, NaN]'); 453s assert (v, NaN); 453s assert (m, NaN); 453s ***** test <*63203> 453s [v, m] = std ([NaN, 2, Inf]); 453s assert (v, NaN); 453s assert (m, NaN); 453s ***** test <*63203> 453s [v, m] = std ([NaN, 2, Inf]'); 453s assert (v, NaN); 453s assert (m, NaN); 453s ***** test <*63203> 453s [v, m] = std ([Inf, 2, NaN], [], 1); 453s assert (v, [NaN, 0, NaN]); 453s assert (m, [Inf, 2, NaN]); 453s ***** test <*63203> 453s [v, m] = std ([Inf, 2, NaN], [], 2); 453s assert (v, NaN); 453s assert (m, NaN); 453s ***** test <*63203> 453s [v, m] = std ([NaN, 2, Inf], [], 1); 453s assert (v, [NaN, 0, NaN]); 453s assert (m, [NaN, 2, Inf]); 453s ***** test <*63203> 453s [v, m] = std ([NaN, 2, Inf], [], 2); 453s assert (v, NaN); 453s assert (m, NaN); 453s ***** test <*63203> 453s [v, m] = std ([1, 3, NaN; 3, 5, Inf]); 453s assert (v, sqrt ([2, 2, NaN])); 453s assert (m, [2, 4, NaN]); 453s ***** test <*63203> 453s [v, m] = std ([1, 3, Inf; 3, 5, NaN]); 453s assert (v, sqrt ([2, 2, NaN])); 453s assert (m, [2, 4, NaN]); 453s ***** test <*63291> 453s [v, m] = std (2 * eye (2)); 453s assert (v, sqrt ([2, 2])); 453s assert (m, [1, 1]); 453s ***** test <*63291> 453s [v, m] = std (4 * eye (2), [1, 3]); 453s assert (v, sqrt ([3, 3])); 453s assert (m, [1, 3]); 453s ***** test <*63291> 453s [v, m] = std (sparse (2 * eye (2))); 453s assert (full (v), sqrt ([2, 2])); 453s assert (full (m), [1, 1]); 453s ***** test <*63291> 453s [v, m] = std (sparse (4 * eye (2)), [1, 3]); 453s assert (full (v), sqrt ([3, 3])); 453s assert (full (m), [1, 3]); 453s ***** test <*63291> 453s [v, m] = std (sparse (eye (2))); 453s assert (issparse (v)); 453s assert (issparse (m)); 453s ***** test <*63291> 453s [v, m] = std (sparse (eye (2)), [1, 3]); 453s assert (issparse (v)); 453s assert (issparse (m)); 453s ***** error std () 454s ***** error std (1, 2, "omitnan", 3) 454s ***** error std (1, 2, 3, 4) 454s ***** error std (1, 2, 3, 4, 5) 454s ***** error std (1, "foo") 454s ***** error std (1, [], "foo") 454s ***** error std ([1 2 3], 2) 454s ***** error std ([1 2], 2, "all") 454s ***** error std ([1 2],0.5, "all") 454s ***** error std (1, -1) 454s ***** error std (1, [1 -1]) 454s ***** error ... 454s std ([1 2 3], [1 -1 0]) 454s ***** error std ({1:5}) 454s ***** error std ("char") 454s ***** error std (['A'; 'B']) 454s ***** error std (1, [], ones (2,2)) 455s ***** error std (1, 0, 1.5) 455s ***** error std (1, [], 0) 455s ***** error std (1, [], 1.5) 455s ***** error std ([1 2 3], [], [-1 1]) 455s ***** error ... 455s std (repmat ([1:20;6:25], [5 2 6 3]), 0, [1 2 2 2]) 455s ***** error ... 455s std ([1 2], eye (2)) 455s ***** error ... 455s std ([1 2 3 4], [1 2; 3 4]) 455s ***** error ... 455s std ([1 2 3 4], [1 2; 3 4], 1) 455s ***** error ... 455s std ([1 2 3 4], [1 2; 3 4], [2 3]) 455s ***** error ... 455s std (ones (2, 2), [1 2], [1 2]) 455s ***** error ... 455s std ([1 2 3 4; 5 6 7 8], [1 2 1 2 1; 1 2 1 2 1], 1) 455s ***** error ... 455s std (repmat ([1:20;6:25], [5 2 6 3]), repmat ([1:20;6:25], [5 2 3]), [2 3]) 455s ***** error std ([1 2 3; 2 3 4], [1 3 4]) 455s ***** error std ([1 2], [1 2 3]) 455s ***** error std (1, [1 2]) 455s ***** error std ([1 2 3; 2 3 4], [1 3 4], 1) 455s ***** error std ([1 2 3; 2 3 4], [1 3], 2) 455s ***** error std ([1 2], [1 2], 1) 455s ***** error <'all' flag cannot be used with DIM or VECDIM options> ... 455s std (1, [], 1, "all") 455s ***** error ... 455s std ([1 2 3; 2 3 4], [1 3], "all") 455s ***** error ... 455s std (repmat ([1:20;6:25], [5 2 6 3]), repmat ([1:20;6:25], [5 2 3]), "all") 455s 162 tests, 162 passed, 0 known failure, 0 skipped 455s [inst/shadow9/var.m] 455s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/shadow9/var.m 455s ***** assert (var (13), 0) 455s ***** assert (var (single (13)), single (0)) 455s ***** assert (var ([1,2,3]), 1) 455s ***** assert (var ([1,2,3], 1), 2/3, eps) 455s ***** assert (var ([1,2,3], [], 1), [0,0,0]) 455s ***** assert (var ([1,2,3], [], 3), [0,0,0]) 455s ***** assert (var (5, 99), 0) 455s ***** assert (var (5, 99, 1), 0) 455s ***** assert (var (5, 99, 2), 0) 455s ***** assert (var ([5 3], [99 99], 2), 1) 455s ***** assert (var ([1:7], [1:7]), 3) 455s ***** assert (var ([eye(3)], [1:3]), [5/36, 2/9, 1/4], eps) 455s ***** assert (var (ones (2,2,2), [1:2], 3), [(zeros (2,2))]) 455s ***** assert (var ([1 2; 3 4], 0, 'all'), var ([1:4])) 455s ***** assert (var (reshape ([1:8], 2, 2, 2), 0, [1 3]), [17/3 17/3], eps) 455s ***** assert (var ([1 2 3;1 2 3], [], [1 2]), 0.8, eps) 455s ***** test 455s x = [-10:10]; 455s y = [x;x+5;x-5]; 455s assert (var (x), 38.5); 455s assert (var (y, [], 2), [38.5; 38.5; 38.5]); 455s assert (var (y, 0, 2), [38.5; 38.5; 38.5]); 455s assert (var (y, 1, 2), ones (3,1) * 36.66666666666666, 1e-14); 455s assert (var (y, "all"), 54.19354838709678, 1e-14); 455s y(2,4) = NaN; 455s assert (var (y, "all"), NaN); 455s assert (var (y, "all", "includenan"), NaN); 455s assert (var (y, "all", "omitnan"), 55.01533580116342, 1e-14); 455s assert (var (y, 0, 2, "includenan"), [38.5; NaN; 38.5]); 455s assert (var (y, [], 2), [38.5; NaN; 38.5]); 455s assert (var (y, [], 2, "omitnan"), [38.5; 37.81842105263158; 38.5], 1e-14); 455s ***** assert (var ([1 NaN 3], [1 2 3], "omitnan"), 0.75, eps) 455s ***** assert (var ([1 2 3], [1 NaN 3], "omitnan"), 0.75, eps) 455s ***** assert (var (magic(3), [1 NaN 3], "omitnan"), [3 12 3], eps) 455s ***** assert (var ([1 NaN 3], [1 2 3], "omitnan", "all"), 0.75, eps) 455s ***** assert (var ([1 NaN 3], [1 2 3], "all", "omitnan"), 0.75, eps) 455s ***** assert (var ([1 2 3], [1 NaN 3], "omitnan", "all"), 0.75, eps) 455s ***** assert (var ([1 NaN 3], [1 2 3], 2, "omitnan"), 0.75, eps) 455s ***** assert (var ([1 2 3], [1 NaN 3], 2, "omitnan"), 0.75, eps) 455s ***** assert (var (magic(3), [1 NaN 3], 1, "omitnan"), [3 12 3], eps) 455s ***** assert (var (magic(3), [1 NaN 3], 2, "omitnan"), [0.75;3;0.75], eps) 455s ***** assert (var ([4 4; 4 6; 6 6], [1 3], 2, 'omitnan'), [0;0.75;0], eps) 455s ***** assert (var ([4 NaN; 4 6; 6 6], [1 2 3], 1, 'omitnan'), [1 0]) 455s ***** assert (var ([4 NaN; 4 6; 6 6], [1 3], 2, 'omitnan'), [0;0.75;0], eps) 455s ***** assert (var (3*reshape(1:18, [3 3 2]), [1 2 3], 1, 'omitnan'), ones(1,3,2)*5) 455s ***** assert (var (reshape(1:18, [3 3 2]), [1 2 3], 2, 'omitnan'), 5*ones(3,1,2)) 455s ***** assert (var (3*reshape(1:18, [3 3 2]), ones (3,3,2), [1 2], 'omitnan'), ... 455s 60 * ones(1,1,2)) 455s ***** assert (var (3*reshape(1:18, [3 3 2]), ones (3,3,2), [1 4], 'omitnan'), ... 455s 6 * ones(1,3,2)) 455s ***** assert (var (6*reshape(1:18, [3 3 2]), ones (3,3,2), [1:3], 'omitnan'), 969) 455s ***** test 455s x = reshape(1:18, [3 3 2]); 455s x([2, 14]) = NaN; 455s w = ones (3,3,2); 455s assert (var (16*x, w, [1:3], 'omitnan'), 6519); 455s ***** test 455s x = reshape(1:18, [3 3 2]); 455s w = ones (3,3,2); 455s w([2, 14]) = NaN; 455s assert (var (16*x, w, [1:3], 'omitnan'), 6519); 455s ***** assert (var ([1 2 3], "aLl"), 1); 455s ***** assert (var ([1 2 3], "OmitNan"), 1); 455s ***** assert (var ([1 2 3], "IncludeNan"), 1); 455s ***** test 455s x = repmat ([1:20;6:25], [5, 2, 6, 3]); 455s assert (size (var (x, 0, [3 2])), [10, 1, 1, 3]); 455s assert (size (var (x, 1, [1 2])), [1, 1, 6, 3]); 455s assert (size (var (x, [], [1 2 4])), [1, 1, 6]); 455s assert (size (var (x, 0, [1 4 3])), [1, 40]); 455s assert (size (var (x, [], [1 2 3 4])), [1, 1]); 455s ***** assert (var (3*magic(3)), [63 144 63]) 455s ***** assert (var (3*magic(3), 'omitnan'), [63 144 63]) 455s ***** assert (var (3*magic(3), 1), [42 96 42]) 455s ***** assert (var (3*magic(3), 1, 'omitnan'), [42 96 42]) 455s ***** assert (var (3*magic(3), ones(1,3), 1), [42 96 42]) 455s ***** assert (var (3*magic(3), ones(1,3), 1, 'omitnan'), [42 96 42]) 455s ***** assert (var (2*magic(3), [1 1 NaN], 1, 'omitnan'), [25 16 1]) 455s ***** assert (var (3*magic(3), ones(3,3)), [42 96 42]) 455s ***** assert (var (3*magic(3), ones(3,3), 'omitnan'), [42 96 42]) 455s ***** assert (var (3*magic(3), [1 1 1; 1 1 1; 1 NaN 1], 'omitnan'), [42 36 42]) 455s ***** assert (var (3*magic(3), ones(3,3), 1), [42 96 42]) 455s ***** assert (var (3*magic(3), ones(3,3), 1, 'omitnan'), [42 96 42]) 455s ***** assert (var (3*magic(3), [1 1 1; 1 1 1; 1 NaN 1], 1, 'omitnan'), [42 36 42]) 455s ***** assert (var (3*magic(3), ones(3,3), [1 4]), [42 96 42]) 455s ***** assert (var (3*magic(3), ones(3,3), [1 4], 'omitnan'), [42 96 42]) 455s ***** assert (var (3*magic(3), [1 1 1; 1 1 1; 1 NaN 1],[1 4],'omitnan'), [42 36 42]) 455s ***** test 455s x = repmat ([1:20;6:25], [5, 2, 6, 3]); 455s v = repmat (33.38912133891213, [10, 1, 1, 3]); 455s assert (var (x, 0, [3, 2]), v, 1e-14); 455s v = repmat (33.250, [10, 1, 1, 3]); 455s assert (var (x, 1, [3, 2]), v, 1e-14); 455s x(2,5,6,3) = NaN; 455s v(2,1,1,3) = NaN; 455s assert (var (x, 1, [3, 2]), v, 4e-14); 455s v = repmat (33.38912133891213, [10 1 1 3]); 455s v(2,1,1,3) = NaN; 455s assert (var (x, [], [3, 2]), v, 4e-14); 455s v(2,1,1,3) = 33.40177912169048; 455s assert (var (x, [], [3, 2], "omitnan"), v, 4e-14); 455s ***** assert (var (ones (2,2,2), [1:2], 3), [(zeros (2, 2))]) 455s ***** assert (var (magic (3), [1:9], "all"), 6.666666666666667, 1e-14) 455s ***** assert (var (ones (2,2), [], 3), zeros (2,2)) 455s ***** assert (var (ones (2,2,2), [], 99), zeros (2,2,2)) 455s ***** assert (var (magic (3), [], 3), zeros (3,3)) 455s ***** assert (var (magic (3), [], 1), [7, 16, 7]) 455s ***** assert (var (magic (3), [], [1 3]), [7, 16, 7]) 455s ***** assert (var (magic (3), [], [1 99]), [7, 16, 7]) 455s ***** assert (var ([]), NaN) 455s ***** assert (class (var (single ([]))), "single") 455s ***** assert (var ([],[],1), NaN(1,0)) 455s ***** assert (var ([],[],2), NaN(0,1)) 455s ***** assert (var ([],[],3), []) 455s ***** assert (class (var (single ([]), [], 1)), "single") 455s ***** assert (var (ones (1,0)), NaN) 455s ***** assert (var (ones (1,0), [], 1), NaN(1,0)) 455s ***** assert (var (ones (1,0), [], 2), NaN) 455s ***** assert (var (ones (1,0), [], 3), NaN(1,0)) 455s ***** assert (class (var (ones (1, 0, "single"), [], 1)), "single") 455s ***** assert (var (ones (0,1)), NaN) 455s ***** assert (var (ones (0,1), [], 1), NaN) 455s ***** assert (var (ones (0,1), [], 2), NaN(0,1)) 455s ***** assert (var (ones (0,1), [], 3), NaN(0,1)) 455s ***** assert (var (ones (1,3,0,2)), NaN(1,1,0,2)) 455s ***** assert (var (ones (1,3,0,2), [], 1), NaN(1,3,0,2)) 455s ***** assert (var (ones (1,3,0,2), [], 2), NaN(1,1,0,2)) 455s ***** assert (var (ones (1,3,0,2), [], 3), NaN(1,3,1,2)) 455s ***** assert (var (ones (1,3,0,2), [], 4), NaN(1,3,0)) 455s ***** test 455s [~, m] = var ([]); 455s assert (m, NaN); 455s ***** test <*62395> 455s [~, m] = var (13); 455s assert (m, 13); 455s [~, m] = var (single(13)); 455s assert (m, single(13)); 455s [~, m] = var ([1, 2, 3; 3 2 1], []); 455s assert (m, [2 2 2]); 455s [~, m] = var ([1, 2, 3; 3 2 1], [], 1); 455s assert (m, [2 2 2]); 455s [~, m] = var ([1, 2, 3; 3 2 1], [], 2); 455s assert (m, [2 2]'); 455s [~, m] = var ([1, 2, 3; 3 2 1], [], 3); 455s assert (m, [1 2 3; 3 2 1]); 455s ***** test <*62395> 455s [~, m] = var (5,99); 455s assert (m, 5); 455s [~, m] = var ([1:7], [1:7]); 455s assert (m, 5); 455s [~, m] = var ([eye(3)], [1:3]); 455s assert (m, [1/6, 1/3, 0.5], eps); 455s [~, m] = var (ones (2,2,2), [1:2], 3); 455s assert (m, ones (2,2)); 455s [~, m] = var ([1 2; 3 4], 0, 'all'); 455s assert (m, 2.5, eps); 455s [~, m] = var (reshape ([1:8], 2, 2, 2), 0, [1 3]); 455s assert (m, [3.5, 5.5], eps); 455s ***** test 455s [v, m] = var (4 * eye (2), [1, 3]); 455s assert (v, [3, 3]); 455s assert (m, [1, 3]); 455s ***** test <*62395> 455s [~, m] = var ([]); 455s assert (m, NaN); 455s ***** test <*62395> 455s x = repmat ([1:20;6:25], [5, 2, 6, 3]); 455s [~, m] = var (x, 0, [3 2]); 455s assert (m, mean (x, [3 2])); 455s [~, m] = var (x, 0, [1 2]); 455s assert (m, mean (x, [1 2])); 455s [~, m] = var (x, 0, [1 3 4]); 455s assert (m, mean (x, [1 3 4])); 455s ***** test 455s x = repmat ([1:20;6:25], [5, 2, 6, 3]); 455s x(2,5,6,3) = NaN; 455s [~, m] = var (x, 0, [3 2], "omitnan"); 455s assert (m, mean (x, [3 2], "omitnan")); 455s ***** test <*63203> 455s [v, m] = var (Inf); 455s assert (v, NaN); 455s assert (m, Inf); 455s ***** test <*63203> 455s [v, m] = var (NaN); 455s assert (v, NaN); 455s assert (m, NaN); 455s ***** test <*63203> 455s [v, m] = var ([1, Inf, 3]); 455s assert (v, NaN); 455s assert (m, Inf); 455s ***** test <*63203> 455s [v, m] = var ([1, Inf, 3]'); 455s assert (v, NaN); 455s assert (m, Inf); 455s ***** test <*63203> 455s [v, m] = var ([1, NaN, 3]); 455s assert (v, NaN); 455s assert (m, NaN); 455s ***** test <*63203> 455s [v, m] = var ([1, NaN, 3]'); 455s assert (v, NaN); 455s assert (m, NaN); 455s ***** test <*63203> 455s [v, m] = var ([1, Inf, 3], [], 1); 455s assert (v, [0, NaN, 0]); 455s assert (m, [1, Inf, 3]); 455s ***** test <*63203> 455s [v, m] = var ([1, Inf, 3], [], 2); 455s assert (v, NaN); 455s assert (m, Inf); 455s ***** test <*63203> 455s [v, m] = var ([1, Inf, 3], [], 3); 455s assert (v, [0, NaN, 0]); 455s assert (m, [1, Inf, 3]); 455s ***** test <*63203> 455s [v, m] = var ([1, NaN, 3], [], 1); 455s assert (v, [0, NaN, 0]); 455s assert (m, [1, NaN, 3]); 455s ***** test <*63203> 455s [v, m] = var ([1, NaN, 3], [], 2); 455s assert (v, NaN); 455s assert (m, NaN); 455s ***** test <*63203> 455s [v, m] = var ([1, NaN, 3], [], 3); 455s assert (v, [0, NaN, 0]); 455s assert (m, [1, NaN, 3]); 455s ***** test <*63203> 455s [v, m] = var ([1, 2, 3; 3, Inf, 5]); 455s assert (v, [2, NaN, 2]); 455s assert (m, [2, Inf, 4]); 455s ***** test <*63203> 455s [v, m] = var ([1, Inf, 3; 3, Inf, 5]); 455s assert (v, [2, NaN, 2]); 455s assert (m, [2, Inf, 4]); 455s ***** test <*63203> 455s [v, m] = var ([1, 2, 3; 3, NaN, 5]); 455s assert (v, [2, NaN, 2]); 455s assert (m, [2, NaN, 4]); 455s ***** test <*63203> 455s [v, m] = var ([1, NaN, 3; 3, NaN, 5]); 455s assert (v, [2, NaN, 2]); 455s assert (m, [2, NaN, 4]); 455s ***** test <*63203> 455s [v, m] = var ([Inf, 2, NaN]); 455s assert (v, NaN); 455s assert (m, NaN); 455s ***** test <*63203> 455s [v, m] = var ([Inf, 2, NaN]'); 455s assert (v, NaN); 455s assert (m, NaN); 455s ***** test <*63203> 455s [v, m] = var ([NaN, 2, Inf]); 455s assert (v, NaN); 455s assert (m, NaN); 455s ***** test <*63203> 455s [v, m] = var ([NaN, 2, Inf]'); 455s assert (v, NaN); 455s assert (m, NaN); 455s ***** test <*63203> 455s [v, m] = var ([Inf, 2, NaN], [], 1); 455s assert (v, [NaN, 0, NaN]); 455s assert (m, [Inf, 2, NaN]); 455s ***** test <*63203> 455s [v, m] = var ([Inf, 2, NaN], [], 2); 455s assert (v, NaN); 455s assert (m, NaN); 455s ***** test <*63203> 455s [v, m] = var ([NaN, 2, Inf], [], 1); 455s assert (v, [NaN, 0, NaN]); 455s assert (m, [NaN, 2, Inf]); 455s ***** test <*63203> 455s [v, m] = var ([NaN, 2, Inf], [], 2); 455s assert (v, NaN); 455s assert (m, NaN); 455s ***** test <*63203> 455s [v, m] = var ([1, 3, NaN; 3, 5, Inf]); 455s assert (v, [2, 2, NaN]); 455s assert (m, [2, 4, NaN]); 455s ***** test <*63203> 455s [v, m] = var ([1, 3, Inf; 3, 5, NaN]); 455s assert (v, [2, 2, NaN]); 455s assert (m, [2, 4, NaN]); 455s ***** test <*63291> 455s [v, m] = var (2 * eye (2)); 455s assert (v, [2, 2]); 455s assert (m, [1, 1]); 455s ***** test <*63291> 455s [v, m] = var (4 * eye (2), [1, 3]); 455s assert (v, [3, 3]); 455s assert (m, [1, 3]); 455s ***** test <*63291> 455s [v, m] = var (sparse (2 * eye (2))); 455s assert (full (v), [2, 2]); 455s assert (full (m), [1, 1]); 455s ***** test <*63291> 455s [v, m] = var (sparse (4 * eye (2)), [1, 3]); 455s assert (full (v), [3, 3]); 455s assert (full (m), [1, 3]); 455s ***** test<*63291> 455s [v, m] = var (sparse (eye (2))); 455s assert (issparse (v)); 455s assert (issparse (m)); 455s ***** test<*63291> 455s [v, m] = var (sparse (eye (2)), [1, 3]); 455s assert (issparse (v)); 455s assert (issparse (m)); 455s ***** error var () 455s ***** error var (1, 2, "omitnan", 3) 456s ***** error var (1, 2, 3, 4) 456s ***** error var (1, 2, 3, 4, 5) 456s ***** error var (1, "foo") 456s ***** error var (1, [], "foo") 456s ***** error var ([1 2 3], 2) 456s ***** error var ([1 2], 2, "all") 456s ***** error var ([1 2],0.5, "all") 456s ***** error var (1, -1) 456s ***** error var (1, [1 -1]) 456s ***** error ... 456s var ([1 2 3], [1 -1 0]) 456s ***** error var ({1:5}) 456s ***** error var ("char") 456s ***** error var (['A'; 'B']) 456s ***** error var (1, [], ones (2,2)) 456s ***** error var (1, 0, 1.5) 456s ***** error var (1, [], 0) 456s ***** error var (1, [], 1.5) 456s ***** error var ([1 2 3], [], [-1 1]) 456s ***** error ... 456s var (repmat ([1:20;6:25], [5 2 6 3]), 0, [1 2 2 2]) 456s ***** error ... 456s var ([1 2], eye (2)) 456s ***** error ... 456s var ([1 2 3 4], [1 2; 3 4]) 456s ***** error ... 456s var ([1 2 3 4], [1 2; 3 4], 1) 456s ***** error ... 456s var ([1 2 3 4], [1 2; 3 4], [2 3]) 456s ***** error ... 456s var (ones (2, 2), [1 2], [1 2]) 456s ***** error ... 456s var ([1 2 3 4; 5 6 7 8], [1 2 1 2 1; 1 2 1 2 1], 1) 456s ***** error ... 456s var (repmat ([1:20;6:25], [5 2 6 3]), repmat ([1:20;6:25], [5 2 3]), [2 3]) 456s ***** error var ([1 2 3; 2 3 4], [1 3 4]) 456s ***** error var ([1 2], [1 2 3]) 456s ***** error var (1, [1 2]) 456s ***** error var ([1 2 3; 2 3 4], [1 3 4], 1) 456s ***** error var ([1 2 3; 2 3 4], [1 3], 2) 456s ***** error var ([1 2], [1 2], 1) 456s ***** error <'all' flag cannot be used with DIM or VECDIM options> ... 456s var (1, [], 1, "all") 456s ***** error ... 456s var ([1 2 3; 2 3 4], [1 3], "all") 456s ***** error ... 456s var (repmat ([1:20;6:25], [5 2 6 3]), repmat ([1:20;6:25], [5 2 3]), "all") 456s 162 tests, 162 passed, 0 known failure, 0 skipped 456s [inst/shadow9/median.m] 456s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/shadow9/median.m 456s ***** assert (median (1), 1) 456s ***** assert (median ([1,2,3]), 2) 456s ***** assert (median ([1,2,3]'), 2) 456s ***** assert (median (cat(3,3,1,2)), 2) 457s ***** assert (median ([3,1,2]), 2) 457s ***** assert (median ([2,4,6,8]), 5) 457s ***** assert (median ([8,2,6,4]), 5) 457s ***** assert (median (single ([1,2,3])), single (2)) 457s ***** assert (median ([1,2], 3), [1,2]) 457s ***** test 457s x = [1, 2, 3, 4, 5, 6]; 457s x2 = x'; 457s y = [1, 2, 3, 4, 5, 6, 7]; 457s y2 = y'; 457s 457s assert (median (x) == median (x2) && median (x) == 3.5); 457s assert (median (y) == median (y2) && median (y) == 4); 457s assert (median ([x2, 2 * x2]), [3.5, 7]); 457s assert (median ([y2, 3 * y2]), [4, 12]); 457s ***** test 457s in = [1 2 3]; 457s out = 2; 457s assert (median (in, "default"), median (in)); 457s assert (median (in, "default"), out); 457s ***** test 457s in = single ([1 2 3]); 457s out = 2; 457s assert (median (in, "default"), single (median (in))); 457s assert (median (in, "default"), single (out)); 457s assert (median (in, "double"), double (out)); 457s assert (median (in, "native"), single (out)); 457s ***** test 457s in = uint8 ([1 2 3]); 457s out = 2; 457s assert (median (in, "default"), double (median (in))); 457s assert (median (in, "default"), double (out)); 457s assert (median (in, "double"), out); 457s assert (median (in, "native"), uint8 (out)); 457s ***** test 457s in = logical ([1 0 1]); 457s out = 1; 457s assert (median (in, "default"), double (median (in))); 457s assert (median (in, "default"), double (out)); 457s assert (median (in, "double"), double (out)); 457s assert (median (in, "native"), double (out)); 457s ***** test 457s x = repmat ([2 2.1 2.2 2 NaN; 3 1 2 NaN 5; 1 1.1 1.4 5 3], [1, 1, 4]); 457s y = repmat ([2 1.1 2 NaN NaN], [1, 1, 4]); 457s assert (median (x), y); 457s assert (median (x, 1), y); 457s y = repmat ([2 1.1 2 3.5 4], [1, 1, 4]); 457s assert (median (x, "omitnan"), y); 457s assert (median (x, 1, "omitnan"), y); 457s y = repmat ([2.05; 2.5; 1.4], [1, 1, 4]); 457s assert (median (x, 2, "omitnan"), y); 457s y = repmat ([NaN; NaN; 1.4], [1, 1, 4]); 457s assert (median (x, 2), y); 457s assert (median (x, "all"), NaN); 457s assert (median (x, "all", "omitnan"), 2); 457s ***** assert (median (cat (3, 3, 1, NaN, 2), "omitnan"), 2) 457s ***** assert (median (cat (3, 3, 1, NaN, 2), 3, "omitnan"), 2) 457s ***** test 457s assert (median (true, "all"), logical (1)); 457s assert (median (false), logical (0)); 457s assert (median ([true false true]), true); 457s assert (median ([true false true], 2), true); 457s assert (median ([true false true], 1), logical ([1 0 1])); 457s assert (median ([true false NaN], 1), [1 0 NaN]); 457s assert (median ([true false NaN], 2), NaN); 457s assert (median ([true false NaN], 2, "omitnan"), 0.5); 457s assert (median ([true false NaN], 2, "omitnan", "native"), double(0.5)); 457s ***** test 457s x = repmat ([1:20;6:25], [5 2 6 3]); 457s assert (size (median (x, [3 2])), [10 1 1 3]); 457s assert (size (median (x, [1 2])), [1 1 6 3]); 457s assert (size (median (x, [1 2 4])), [1 1 6]); 457s assert (size (median (x, [1 4 3])), [1 40]); 457s assert (size (median (x, [1 2 3 4])), [1 1]); 457s ***** assert (median (ones (2,2), 3), ones (2,2)) 457s ***** assert (median (ones (2,2,2), 99), ones (2,2,2)) 457s ***** assert (median (magic (3), 3), magic (3)) 457s ***** assert (median (magic (3), [1 3]), [4, 5, 6]) 457s ***** assert (median (magic (3), [1 99]), [4, 5, 6]) 457s ***** test 457s x = repmat ([2 2.1 2.2 2 NaN; 3 1 2 NaN 5; 1 1.1 1.4 5 3], [1, 1, 4]); 457s assert (median (x, [3 2]), [NaN NaN 1.4]'); 457s assert (median (x, [3 2], "omitnan"), [2.05 2.5 1.4]'); 457s assert (median (x, [1 3]), [2 1.1 2 NaN NaN]); 457s assert (median (x, [1 3], "omitnan"), [2 1.1 2 3.5 4]); 457s ***** assert (median (NaN), NaN) 457s ***** assert (median (NaN, "omitnan"), NaN) 457s ***** assert (median (NaN (2)), [NaN NaN]) 457s ***** assert (median (NaN (2), "omitnan"), [NaN NaN]) 457s ***** assert (median ([1 NaN 3]), NaN) 457s ***** assert (median ([1 NaN 3], 1), [1 NaN 3]) 457s ***** assert (median ([1 NaN 3], 2), NaN) 457s ***** assert (median ([1 NaN 3]'), NaN) 457s ***** assert (median ([1 NaN 3]', 1), NaN) 457s ***** assert (median ([1 NaN 3]', 2), [1; NaN; 3]) 457s ***** assert (median ([1 NaN 3], "omitnan"), 2) 457s ***** assert (median ([1 NaN 3]', "omitnan"), 2) 457s ***** assert (median ([1 NaN 3], 1, "omitnan"), [1 NaN 3]) 457s ***** assert (median ([1 NaN 3], 2, "omitnan"), 2) 457s ***** assert (median ([1 NaN 3]', 1, "omitnan"), 2) 457s ***** assert (median ([1 NaN 3]', 2, "omitnan"), [1; NaN; 3]) 457s ***** assert (median ([1 2 NaN 3]), NaN) 457s ***** assert (median ([1 2 NaN 3], "omitnan"), 2) 457s ***** assert (median ([1,2,NaN;4,5,6;NaN,8,9]), [NaN, 5, NaN]) 457s ***** assert <*64011> (median ([1,2,NaN;4,5,6;NaN,8,9], "omitnan"), [2.5, 5, 7.5], eps) 457s ***** assert (median ([1 2 ; NaN 4]), [NaN 3]) 457s ***** assert (median ([1 2 ; NaN 4], "omitnan"), [1 3]) 457s ***** assert (median ([1 2 ; NaN 4], 1, "omitnan"), [1 3]) 457s ***** assert (median ([1 2 ; NaN 4], 2, "omitnan"), [1.5; 4], eps) 457s ***** assert (median ([1 2 ; NaN 4], 3, "omitnan"), [1 2 ; NaN 4]) 457s ***** assert (median ([NaN 2 ; NaN 4]), [NaN 3]) 457s ***** assert (median ([NaN 2 ; NaN 4], "omitnan"), [NaN 3]) 457s ***** assert (median (ones (1, 0, 3)), NaN (1, 1, 3)) 457s ***** assert <*65405> (median ([NaN NaN], 1, "omitnan"), [NaN NaN]) 457s ***** assert <*65405> (median ([NaN NaN], 2, "omitnan"), NaN) 457s ***** assert <*65405> (median ([NaN NaN]', 1, "omitnan"), NaN) 457s ***** assert <*65405> (median ([NaN NaN]', 2, "omitnan"), [NaN; NaN]) 457s ***** assert <*65405> (median ([NaN NaN], "omitnan"), NaN) 457s ***** assert <*65405> (median ([NaN NaN]', "omitnan"), NaN) 457s ***** assert <*65405> (median (NaN(1,9), 1, "omitnan"), NaN(1,9)) 457s ***** assert <*65405> (median (NaN(1,9), 2, "omitnan"), NaN) 457s ***** assert <*65405> (median (NaN(1,9), 3, "omitnan"), NaN(1,9)) 457s ***** assert <*65405> (median (NaN(9,1), 1, "omitnan"), NaN) 457s ***** assert <*65405> (median (NaN(9,1), 2, "omitnan"), NaN(9,1)) 457s ***** assert <*65405> (median (NaN(9,1), 3, "omitnan"), NaN(9,1)) 457s ***** assert <*65405> (median (NaN(9,2), 1, "omitnan"), NaN(1,2)) 457s ***** assert <*65405> (median (NaN(9,2), 2, "omitnan"), NaN(9,1)) 457s ***** assert <*65405> (median (NaN(9,2), "omitnan"), NaN(1,2)) 457s ***** assert (median (NaN("single")), NaN("single")) 457s ***** assert (median (NaN("single"), "omitnan"), NaN("single")) 457s ***** assert (median (NaN("single"), "double"), NaN("double")) 457s ***** assert (median (single([1 2 ; NaN 4])), single([NaN 3])) 457s ***** assert (median (single([1 2 ; NaN 4]), "double"), double([NaN 3])) 457s ***** assert (median (single([1 2 ; NaN 4]), "omitnan"), single([1 3])) 457s ***** assert (median (single([1 2 ; NaN 4]), "omitnan", "double"), double([1 3])) 457s ***** assert (median (single([NaN 2 ; NaN 4]), "double"), double([NaN 3])) 457s ***** assert (median (single([NaN 2 ; NaN 4]), "omitnan"), single([NaN 3])) 457s ***** assert (median (single([NaN 2 ; NaN 4]), "omitnan", "double"), double([NaN 3])) 457s ***** test <*64011> 457s x = [magic(3), magic(3)]; 457s x([3, 7, 11, 12, 16, 17]) = NaN; 457s ynan = [NaN, 5, NaN, NaN, 5, NaN]; 457s yomitnan = [5.5, 5, 4.5, 8, 5, 2]; 457s assert (median (x), ynan); 457s assert (median (x, "omitnan"), yomitnan, eps); 457s assert (median (cat (3, x, x)), cat (3, ynan, ynan)); 457s assert (median (cat (3, x, x), "omitnan"), cat (3, yomitnan, yomitnan), eps); 457s ***** assert (median (Inf), Inf) 457s ***** assert (median (-Inf), -Inf) 457s ***** assert (median ([-Inf Inf]), NaN) 457s ***** assert (median ([3 Inf]), Inf) 457s ***** assert (median ([3 4 Inf]), 4) 457s ***** assert (median ([Inf 3 4]), 4) 457s ***** assert (median ([Inf 3 Inf]), Inf) 457s ***** assert (median ([1, 2, Inf]), 2) 457s ***** assert (median ([1, 2, Inf, Inf]), Inf) 457s ***** assert (median ([1, -Inf, Inf, Inf]), Inf) 457s ***** assert (median ([-Inf, -Inf, Inf, Inf]), NaN) 457s ***** assert (median([-Inf, Inf, Inf, Inf]), Inf) 457s ***** assert (median([-Inf, -Inf, -Inf, Inf]), -Inf) 457s ***** assert (median([-Inf, -Inf, -Inf, 2]), -Inf) 457s ***** assert (median([-Inf, -Inf, 1, 2]), -Inf) 457s ***** assert (median ([]), NaN) 457s ***** assert (median (ones(1,0)), NaN) 457s ***** assert (median (ones(0,1)), NaN) 457s ***** assert (median ([], 1), NaN(1,0)) 457s ***** assert (median ([], 2), NaN(0,1)) 457s ***** assert (median ([], 3), NaN(0,0)) 457s ***** assert (median (ones(1,0), 1), NaN(1,0)) 457s ***** assert (median (ones(1,0), 2), NaN(1,1)) 457s ***** assert (median (ones(1,0), 3), NaN(1,0)) 457s ***** assert (median (ones(0,1), 1), NaN(1,1)) 457s ***** assert (median (ones(0,1), 2), NaN(0,1)) 457s ***** assert (median (ones(0,1), 3), NaN(0,1)) 457s ***** assert (median (ones(0,1,0,1), 1), NaN(1,1,0)) 457s ***** assert (median (ones(0,1,0,1), 2), NaN(0,1,0)) 457s ***** assert (median (ones(0,1,0,1), 3), NaN(0,1,1)) 457s ***** assert (median (ones(0,1,0,1), 4), NaN(0,1,0)) 457s ***** assert (median([1 3 3i 2 1i]), 2) 457s ***** assert (median([1 2 4i; 3 2i 4]), [2, 1+1i, 2+2i]) 457s ***** shared a, b, x, y 457s old_state = rand ("state"); 457s restore_state = onCleanup (@() rand ("state", old_state)); 457s rand ("state", 2); 457s a = rand (2,3,4,5); 457s b = rand (3,4,6,5); 457s x = sort (a, 4); 457s y = sort (b, 3); 457s ***** assert <*35679> (median (a, 4), x(:, :, :, 3)) 457s ***** assert <*35679> (median (b, 3), (y(:, :, 3, :) + y(:, :, 4, :))/2) 457s ***** shared ## Clear shared to prevent variable echo for any later test failures 457s ***** test 457s x = ones(15,1,4); 457s x([13,15],1,:) = NaN; 457s assert (median (x, 1, "omitnan"), ones (1,1,4)) 457s ***** assert (median ([true, false]), true) 457s ***** assert (median (logical ([])), false) 457s ***** assert (median (uint8 ([1, 3])), uint8 (2)) 457s ***** assert (median (uint8 ([])), uint8 (NaN)) 457s ***** assert (median (uint8 ([NaN 10])), uint8 (5)) 457s ***** assert (median (int8 ([1, 3, 4])), int8 (3)) 457s ***** assert (median (int8 ([])), int8 (NaN)) 457s ***** assert (median (single ([1, 3, 4])), single (3)) 457s ***** assert (median (single ([1, 3, NaN])), single (NaN)) 457s ***** assert <54567> (median (uint8 ([253, 255])), uint8 (254)) 457s ***** assert <54567> (median (uint8 ([253, 254])), uint8 (254)) 457s ***** assert <54567> (median (int8 ([127, 126, 125, 124; 1 3 5 9])), ... 457s int8 ([64 65 65 67])) 457s ***** assert <54567> (median (int8 ([127, 126, 125, 124; 1 3 5 9]), 2), ... 457s int8 ([126; 4])) 457s ***** assert <54567> (median (int64 ([intmax("int64"), intmax("int64")-2])), ... 457s intmax ("int64") - 1) 457s ***** assert <54567> (median ( ... 457s int64 ([intmax("int64"), intmax("int64")-2; 1 2]), 2), ... 457s int64([intmax("int64") - 1; 2])) 457s ***** assert <54567> (median (uint64 ([intmax("uint64"), intmax("uint64")-2])), ... 457s intmax ("uint64") - 1) 457s ***** assert <54567> (median ( ... 457s uint64 ([intmax("uint64"), intmax("uint64")-2; 1 2]), 2), ... 457s uint64([intmax("uint64") - 1; 2])) 457s ***** assert <54567> (median (... 457s [intmin('int8') intmin('int8')+5 intmax('int8')-5 intmax('int8')]), ... 457s int8(-1)) 457s ***** assert <54567> (median ([int8([1 2 3 4]); ... 457s intmin('int8') intmin('int8')+5 intmax('int8')-5 intmax('int8')], 2), ... 457s int8([3;-1])) 457s ***** assert <54567> (median (... 457s [intmin('int64') intmin('int64')+5 intmax('int64')-5 intmax('int64')]), ... 457s int64(-1)) 457s ***** assert <54567> (median ([int64([1 2 3 4]); ... 457s intmin('int64') intmin('int64')+5 intmax('int64')-5 intmax('int64')], 2), ... 457s int64([3;-1])) 457s ***** assert <54567> (median ([intmax("uint64"), intmax("uint64")-2]), ... 457s intmax("uint64")-1) 457s ***** assert <54567> (median ([intmax("uint64"), intmax("uint64")-2], "default"), ... 457s double(intmax("uint64")-1)) 457s ***** assert <54567> (median ([intmax("uint64"), intmax("uint64")-2], "double"), ... 457s double(intmax("uint64")-1)) 457s ***** assert <54567> (median ([intmax("uint64"), intmax("uint64")-2], "native"), ... 457s intmax("uint64")-1) 457s ***** assert (median ([1 2 3], "aLL"), 2) 457s ***** assert (median ([1 2 3], "OmitNan"), 2) 457s ***** assert (median ([1 2 3], "DOUBle"), 2) 457s ***** error median () 457s ***** error median (1, 2, 3) 457s ***** error median (1, 2, 3, 4) 458s ***** error median (1, "all", 3) 458s ***** error median (1, "b") 458s ***** error median (1, 1, "foo") 458s ***** error <'all' cannot be used with> median (1, 3, "all") 458s ***** error <'all' cannot be used with> median (1, [2 3], "all") 458s ***** error median ({1:5}) 458s ***** error median ("char") 458s ***** error median(1, "double", "native") 458s ***** error median (1, ones (2,2)) 458s ***** error median (1, 1.5) 458s ***** error median (1, 0) 458s ***** error median ([1 2 3], [-1 1]) 458s ***** error median(1, [1 2 2]) 458s 159 tests, 159 passed, 0 known failure, 0 skipped 458s [inst/normalise_distribution.m] 458s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/normalise_distribution.m 458s ***** test 458s v = normalise_distribution ([1 2 3], [], 1); 458s assert (v, [0 0 0]) 458s ***** test 458s v = normalise_distribution ([1 2 3], [], 2); 458s assert (v, norminv ([1 3 5] / 6), 3 * eps) 458s ***** test 458s v = normalise_distribution ([1 2 3]', [], 2); 458s assert (v, [0 0 0]') 458s ***** test 458s v = normalise_distribution ([1 2 3]', [], 1); 458s assert (v, norminv ([1 3 5]' / 6), 3 * eps) 458s ***** test 458s v = normalise_distribution ([1 1 2 2 3 3], [], 2); 458s assert (v, norminv ([3 3 7 7 11 11] / 12), 3 * eps) 458s ***** test 458s v = normalise_distribution ([1 1 2 2 3 3]', [], 1); 458s assert (v, norminv ([3 3 7 7 11 11]' / 12), 3 * eps) 458s ***** test 458s A = randn ( 10 ); 458s N = normalise_distribution (A, @normcdf); 458s assert (A, N, 10000 * eps) 458s ***** test 458s A = exprnd (1, 100); 458s N = normalise_distribution (A, @(x)(expcdf (x, 1))); 458s assert (mean (vec (N)), 0, 0.1) 458s assert (std (vec (N)), 1, 0.1) 458s ***** test 458s A = rand (1000,1); 458s N = normalise_distribution (A, {@(x)(unifcdf (x, 0, 1))}); 458s assert (mean (vec (N)), 0, 0.2) 458s assert (std (vec (N)), 1, 0.1) 458s ***** test 458s A = [rand(1000,1), randn(1000, 1)]; 458s N = normalise_distribution (A, {@(x)(unifcdf (x, 0, 1)), @normcdf}); 458s assert (mean (N), [0, 0], 0.2) 458s assert (std (N), [1, 1], 0.1) 458s ***** test 458s A = [rand(1000,1), randn(1000, 1), exprnd(1, 1000, 1)]'; 458s N = normalise_distribution (A, {@(x)(unifcdf (x, 0, 1)); @normcdf; @(x)(expcdf (x, 1))}, 2); 458s assert (mean (N, 2), [0, 0, 0]', 0.2); 458s assert (std (N, [], 2), [1, 1, 1]', 0.1); 458s ***** xtest 458s A = exprnd (1, 1000, 9); A (300:500, 4:6) = 17; 458s N = normalise_distribution (A); 458s assert (mean (N), [0 0 0 0.38 0.38 0.38 0 0 0], 0.1); 458s assert (var (N), [1 1 1 2.59 2.59 2.59 1 1 1], 0.1); 458s ***** test 458s ***** error normalise_distribution (zeros (3, 4), ... 458s {@(x)(unifcdf (x, 0, 1)); @normcdf; @(x)(expcdf (x,1))}); 458s 14 tests, 14 passed, 0 known failure, 0 skipped 458s [inst/nanmax.m] 458s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/nanmax.m 458s ***** demo 458s ## Find the column maximum values and their indices 458s ## for matrix data with missing values. 458s 458s x = magic (3); 458s x([1, 6:9]) = NaN 458s [y, ind] = nanmax (x) 458s ***** demo 458s ## Find the maximum of all the values in an array, ignoring missing values. 458s ## Create a 2-by-5-by-3 array x with some missing values. 458s 458s x = reshape (1:30, [2, 5, 3]); 458s x([10:12, 25]) = NaN 458s 458s ## Find the maximum of the elements of x. 458s 458s y = nanmax (x, [], 'all') 458s ***** assert (nanmax ([2, 4, NaN, 7]), 7) 458s ***** assert (nanmax ([2, 4, NaN, Inf]), Inf) 458s ***** assert (nanmax ([1, NaN, 3; NaN, 5, 6; 7, 8, NaN]), [7, 8, 6]) 458s ***** assert (nanmax ([1, NaN, 3; NaN, 5, 6; 7, 8, NaN]'), [3, 6, 8]) 458s ***** assert (nanmax (single ([1, NaN, 3; NaN, 5, 6; 7, 8, NaN])), single ([7, 8, 6])) 458s ***** shared x, y 458s x(:,:,1) = [1.77, -0.005, NaN, -2.95; NaN, 0.34, NaN, 0.19]; 458s x(:,:,2) = [1.77, -0.005, NaN, -2.95; NaN, 0.34, NaN, 0.19] + 5; 458s y = x; 458s y(2,3,1) = 0.51; 458s ***** assert (nanmax (x, [], [1, 2])(:), [1.77;6.77]) 458s ***** assert (nanmax (x, [], [1, 3])(:), [6.77;5.34;NaN;5.19]) 458s ***** assert (nanmax (x, [], [2, 3])(:), [6.77;5.34]) 458s ***** assert (nanmax (x, [], [1, 2, 3]), 6.77) 458s ***** assert (nanmax (x, [], 'all'), 6.77) 458s ***** assert (nanmax (y, [], [1, 3])(:), [6.77;5.34;0.51;5.19]) 458s ***** assert (nanmax (x(1,:,1), x(2,:,1)), [1.77, 0.34, NaN, 0.19]) 459s ***** assert (nanmax (x(1,:,2), x(2,:,2)), [6.77, 5.34, NaN, 5.19]) 459s ***** assert (nanmax (y(1,:,1), y(2,:,1)), [1.77, 0.34, 0.51, 0.19]) 459s ***** assert (nanmax (y(1,:,2), y(2,:,2)), [6.77, 5.34, NaN, 5.19]) 459s ***** test 459s xx = repmat ([1:20;6:25], [5 2 6 3]); 459s assert (size (nanmax (xx, [], [3, 2])), [10, 1, 1, 3]); 459s assert (size (nanmax (xx, [], [1, 2])), [1, 1, 6, 3]); 459s assert (size (nanmax (xx, [], [1, 2, 4])), [1, 1, 6]); 459s assert (size (nanmax (xx, [], [1, 4, 3])), [1, 40]); 459s assert (size (nanmax (xx, [], [1, 2, 3, 4])), [1, 1]); 459s ***** assert (nanmax (ones (2), [], 3), ones (2, 2)) 459s ***** assert (nanmax (ones (2, 2, 2), [], 99), ones (2, 2, 2)) 459s ***** assert (nanmax (magic (3), [], 3), magic (3)) 459s ***** assert (nanmax (magic (3), [], [1, 3]), [8, 9, 7]) 459s ***** assert (nanmax (magic (3), [], [1, 99]), [8, 9, 7]) 459s ***** assert (nanmax (ones (2), 3), 3 * ones (2,2)) 459s ***** error ... 459s nanmax (y, [], [1, 1, 2]) 459s ***** error ... 459s [v, idx] = nanmax(x, y, [1 2]) 459s 24 tests, 24 passed, 0 known failure, 0 skipped 459s [inst/dist_fun/nakapdf.m] 459s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/nakapdf.m 459s ***** demo 459s ## Plot various PDFs from the Nakagami distribution 459s x = 0:0.01:3; 459s y1 = nakapdf (x, 0.5, 1); 459s y2 = nakapdf (x, 1, 1); 459s y3 = nakapdf (x, 1, 2); 459s y4 = nakapdf (x, 1, 3); 459s y5 = nakapdf (x, 2, 1); 459s y6 = nakapdf (x, 2, 2); 459s y7 = nakapdf (x, 5, 1); 459s plot (x, y1, "-r", x, y2, "-g", x, y3, "-y", x, y4, "-m", ... 459s x, y5, "-k", x, y6, "-b", x, y7, "-c") 459s grid on 459s xlim ([0, 3]) 459s ylim ([0, 2]) 459s legend ({"μ = 0.5, ω = 1", "μ = 1, ω = 1", "μ = 1, ω = 2", ... 459s "μ = 1, ω = 3", "μ = 2, ω = 1", "μ = 2, ω = 2", ... 459s "μ = 5, ω = 1"}, "location", "northeast") 459s title ("Nakagami PDF") 459s xlabel ("values in x") 459s ylabel ("density") 459s ***** shared x, y 459s x = [-1, 0, 1, 2, Inf]; 459s y = [0, 0, 0.73575888234288467, 0.073262555554936715, 0]; 459s ***** assert (nakapdf (x, ones (1,5), ones (1,5)), y, eps) 459s ***** assert (nakapdf (x, 1, 1), y, eps) 459s ***** assert (nakapdf (x, [1, 1, NaN, 1, 1], 1), [y(1:2), NaN, y(4:5)], eps) 459s ***** assert (nakapdf (x, 1, [1, 1, NaN, 1, 1]), [y(1:2), NaN, y(4:5)], eps) 459s ***** assert (nakapdf ([x, NaN], 1, 1), [y, NaN], eps) 459s ***** assert (nakapdf (single ([x, NaN]), 1, 1), single ([y, NaN])) 459s ***** assert (nakapdf ([x, NaN], single (1), 1), single ([y, NaN])) 459s ***** assert (nakapdf ([x, NaN], 1, single (1)), single ([y, NaN])) 459s ***** error nakapdf () 459s ***** error nakapdf (1) 459s ***** error nakapdf (1, 2) 459s ***** error ... 459s nakapdf (ones (3), ones (2), ones(2)) 459s ***** error ... 459s nakapdf (ones (2), ones (3), ones(2)) 459s ***** error ... 459s nakapdf (ones (2), ones (2), ones(3)) 459s ***** error nakapdf (i, 4, 3) 459s ***** error nakapdf (1, i, 3) 459s ***** error nakapdf (1, 4, i) 459s 17 tests, 17 passed, 0 known failure, 0 skipped 459s [inst/dist_fun/tlscdf.m] 459s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/tlscdf.m 459s ***** demo 459s ## Plot various CDFs from the location-scale Student's T distribution 459s x = -8:0.01:8; 459s p1 = tlscdf (x, 0, 1, 1); 459s p2 = tlscdf (x, 0, 2, 2); 459s p3 = tlscdf (x, 3, 2, 5); 459s p4 = tlscdf (x, -1, 3, Inf); 459s plot (x, p1, "-b", x, p2, "-g", x, p3, "-r", x, p4, "-m") 459s grid on 459s xlim ([-8, 8]) 459s ylim ([0, 1]) 459s legend ({"mu = 0, sigma = 1, nu = 1", "mu = 0, sigma = 2, nu = 2", ... 459s "mu = 3, sigma = 2, nu = 5", 'mu = -1, sigma = 3, nu = \infty'}, ... 459s "location", "northwest") 459s title ("Location-scale Student's T CDF") 459s xlabel ("values in x") 459s ylabel ("probability") 459s ***** shared x,y 459s x = [-Inf 0 1 Inf]; 459s y = [0 1/2 3/4 1]; 459s ***** assert (tlscdf (x, 0, 1, ones (1,4)), y, eps) 459s ***** assert (tlscdf (x, 0, 1, 1), y, eps) 459s ***** assert (tlscdf (x, 0, 1, [0 1 NaN 1]), [NaN 1/2 NaN 1], eps) 459s ***** assert (tlscdf ([x(1:2) NaN x(4)], 0, 1, 1), [y(1:2) NaN y(4)], eps) 459s ***** assert (tlscdf (2, 0, 1, 3, "upper"), 0.0697, 1e-4) 459s ***** assert (tlscdf (205, 0, 1, 5, "upper"), 2.6206e-11, 1e-14) 459s ***** assert (tlscdf ([x, NaN], 0, 1, 1), [y, NaN], eps) 459s ***** assert (tlscdf (single ([x, NaN]), 0, 1, 1), single ([y, NaN]), eps ("single")) 459s ***** assert (tlscdf ([x, NaN], single (0), 1, 1), single ([y, NaN]), eps ("single")) 459s ***** assert (tlscdf ([x, NaN], 0, single (1), 1), single ([y, NaN]), eps ("single")) 459s ***** assert (tlscdf ([x, NaN], 0, 1, single (1)), single ([y, NaN]), eps ("single")) 459s ***** error tlscdf () 459s ***** error tlscdf (1) 459s ***** error tlscdf (1, 2) 459s ***** error tlscdf (1, 2, 3) 459s ***** error tlscdf (1, 2, 3, 4, "uper") 459s ***** error tlscdf (1, 2, 3, 4, 5) 459s ***** error ... 459s tlscdf (ones (3), ones (2), 1, 1) 459s ***** error ... 459s tlscdf (ones (3), 1, ones (2), 1) 459s ***** error ... 459s tlscdf (ones (3), 1, 1, ones (2)) 459s ***** error ... 459s tlscdf (ones (3), ones (2), 1, 1, "upper") 459s ***** error ... 459s tlscdf (ones (3), 1, ones (2), 1, "upper") 459s ***** error ... 459s tlscdf (ones (3), 1, 1, ones (2), "upper") 459s ***** error tlscdf (i, 2, 1, 1) 459s ***** error tlscdf (2, i, 1, 1) 459s ***** error tlscdf (2, 1, i, 1) 459s ***** error tlscdf (2, 1, 1, i) 459s 27 tests, 27 passed, 0 known failure, 0 skipped 459s [inst/dist_fun/gpinv.m] 459s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/gpinv.m 459s ***** demo 459s ## Plot various iCDFs from the generalized Pareto distribution 459s p = 0.001:0.001:0.999; 459s x1 = gpinv (p, 1, 1, 0); 459s x2 = gpinv (p, 5, 1, 0); 459s x3 = gpinv (p, 20, 1, 0); 459s x4 = gpinv (p, 1, 2, 0); 459s x5 = gpinv (p, 5, 2, 0); 459s x6 = gpinv (p, 20, 2, 0); 459s plot (p, x1, "-b", p, x2, "-g", p, x3, "-r", ... 459s p, x4, "-c", p, x5, "-m", p, x6, "-k") 459s grid on 459s ylim ([0, 5]) 459s legend ({"k = 1, σ = 1, θ = 0", "k = 5, σ = 1, θ = 0", ... 459s "k = 20, σ = 1, θ = 0", "k = 1, σ = 2, θ = 0", ... 459s "k = 5, σ = 2, θ = 0", "k = 20, σ = 2, θ = 0"}, ... 459s "location", "southeast") 459s title ("Generalized Pareto iCDF") 459s xlabel ("probability") 459s ylabel ("values in x") 459s ***** shared p, y1, y2, y3 459s p = [-1, 0, 1/2, 1, 2]; 459s y1 = [NaN, 0, 0.6931471805599453, Inf, NaN]; 459s y2 = [NaN, 0, 1, Inf, NaN]; 459s y3 = [NaN, 0, 1/2, 1, NaN]; 459s ***** assert (gpinv (p, zeros (1,5), ones (1,5), zeros (1,5)), y1) 459s ***** assert (gpinv (p, 0, 1, zeros (1,5)), y1) 459s ***** assert (gpinv (p, 0, ones (1,5), 0), y1) 459s ***** assert (gpinv (p, zeros (1,5), 1, 0), y1) 459s ***** assert (gpinv (p, 0, 1, 0), y1) 459s ***** assert (gpinv (p, 0, 1, [0, 0, NaN, 0, 0]), [y1(1:2), NaN, y1(4:5)]) 459s ***** assert (gpinv (p, 0, [1, 1, NaN, 1, 1], 0), [y1(1:2), NaN, y1(4:5)]) 459s ***** assert (gpinv (p, [0, 0, NaN, 0, 0], 1, 0), [y1(1:2), NaN, y1(4:5)]) 459s ***** assert (gpinv ([p(1:2), NaN, p(4:5)], 0, 1, 0), [y1(1:2), NaN, y1(4:5)]) 459s ***** assert (gpinv (p, ones (1,5), ones (1,5), zeros (1,5)), y2) 459s ***** assert (gpinv (p, 1, 1, zeros (1,5)), y2) 459s ***** assert (gpinv (p, 1, ones (1,5), 0), y2) 459s ***** assert (gpinv (p, ones (1,5), 1, 0), y2) 459s ***** assert (gpinv (p, 1, 1, 0), y2) 459s ***** assert (gpinv (p, 1, 1, [0, 0, NaN, 0, 0]), [y2(1:2), NaN, y2(4:5)]) 459s ***** assert (gpinv (p, 1, [1, 1, NaN, 1, 1], 0), [y2(1:2), NaN, y2(4:5)]) 459s ***** assert (gpinv (p, [1, 1, NaN, 1, 1], 1, 0), [y2(1:2), NaN, y2(4:5)]) 459s ***** assert (gpinv ([p(1:2), NaN, p(4:5)], 1, 1, 0), [y2(1:2), NaN, y2(4:5)]) 459s ***** assert (gpinv (p, -ones (1,5), ones (1,5), zeros (1,5)), y3) 459s ***** assert (gpinv (p, -1, 1, zeros (1,5)), y3) 459s ***** assert (gpinv (p, -1, ones (1,5), 0), y3) 459s ***** assert (gpinv (p, -ones (1,5), 1, 0), y3) 459s ***** assert (gpinv (p, -1, 1, 0), y3) 459s ***** assert (gpinv (p, -1, 1, [0, 0, NaN, 0, 0]), [y3(1:2), NaN, y3(4:5)]) 459s ***** assert (gpinv (p, -1, [1, 1, NaN, 1, 1], 0), [y3(1:2), NaN, y3(4:5)]) 459s ***** assert (gpinv (p, -[1, 1, NaN, 1, 1], 1, 0), [y3(1:2), NaN, y3(4:5)]) 459s ***** assert (gpinv ([p(1:2), NaN, p(4:5)], -1, 1, 0), [y3(1:2), NaN, y3(4:5)]) 459s ***** assert (gpinv (single ([p, NaN]), 0, 1, 0), single ([y1, NaN])) 459s ***** assert (gpinv ([p, NaN], 0, 1, single (0)), single ([y1, NaN])) 459s ***** assert (gpinv ([p, NaN], 0, single (1), 0), single ([y1, NaN])) 459s ***** assert (gpinv ([p, NaN], single (0), 1, 0), single ([y1, NaN])) 459s ***** assert (gpinv (single ([p, NaN]), 1, 1, 0), single ([y2, NaN])) 459s ***** assert (gpinv ([p, NaN], 1, 1, single (0)), single ([y2, NaN])) 459s ***** assert (gpinv ([p, NaN], 1, single (1), 0), single ([y2, NaN])) 459s ***** assert (gpinv ([p, NaN], single (1), 1, 0), single ([y2, NaN])) 459s ***** assert (gpinv (single ([p, NaN]), -1, 1, 0), single ([y3, NaN])) 459s ***** assert (gpinv ([p, NaN], -1, 1, single (0)), single ([y3, NaN])) 459s ***** assert (gpinv ([p, NaN], -1, single (1), 0), single ([y3, NaN])) 459s ***** assert (gpinv ([p, NaN], single (-1), 1, 0), single ([y3, NaN])) 459s ***** error gpinv () 459s ***** error gpinv (1) 459s ***** error gpinv (1, 2) 459s ***** error gpinv (1, 2, 3) 459s ***** error ... 459s gpinv (ones (3), ones (2), ones(2), ones(2)) 459s ***** error ... 459s gpinv (ones (2), ones (3), ones(2), ones(2)) 459s ***** error ... 459s gpinv (ones (2), ones (2), ones(3), ones(2)) 459s ***** error ... 459s gpinv (ones (2), ones (2), ones(2), ones(3)) 459s ***** error gpinv (i, 2, 3, 4) 459s ***** error gpinv (1, i, 3, 4) 459s ***** error gpinv (1, 2, i, 4) 459s ***** error gpinv (1, 2, 3, i) 459s 51 tests, 51 passed, 0 known failure, 0 skipped 459s [inst/dist_fun/burrrnd.m] 459s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/burrrnd.m 459s ***** assert (size (burrrnd (1, 1, 1)), [1 1]) 459s ***** assert (size (burrrnd (ones (2,1), 1, 1)), [2, 1]) 459s ***** assert (size (burrrnd (ones (2,2), 1, 1)), [2, 2]) 459s ***** assert (size (burrrnd (1, ones (2,1), 1)), [2, 1]) 459s ***** assert (size (burrrnd (1, ones (2,2), 1)), [2, 2]) 459s ***** assert (size (burrrnd (1, 1, ones (2,1))), [2, 1]) 459s ***** assert (size (burrrnd (1, 1, ones (2,2))), [2, 2]) 459s ***** assert (size (burrrnd (1, 1, 1, 3)), [3, 3]) 459s ***** assert (size (burrrnd (1, 1, 1, [4 1])), [4, 1]) 459s ***** assert (size (burrrnd (1, 1, 1, 4, 1)), [4, 1]) 459s ***** assert (class (burrrnd (1,1,1)), "double") 459s ***** assert (class (burrrnd (single (1),1,1)), "single") 459s ***** assert (class (burrrnd (single ([1 1]),1,1)), "single") 459s ***** assert (class (burrrnd (1,single (1),1)), "single") 459s ***** assert (class (burrrnd (1,single ([1 1]),1)), "single") 459s ***** assert (class (burrrnd (1,1,single (1))), "single") 459s ***** assert (class (burrrnd (1,1,single ([1 1]))), "single") 459s ***** error burrrnd () 459s ***** error burrrnd (1) 459s ***** error burrrnd (1, 2) 459s ***** error ... 459s burrrnd (ones (3), ones (2), ones (2)) 459s ***** error ... 459s burrrnd (ones (2), ones (3), ones (2)) 459s ***** error ... 459s burrrnd (ones (2), ones (2), ones (3)) 459s ***** error burrrnd (i, 2, 3) 459s ***** error burrrnd (1, i, 3) 459s ***** error burrrnd (1, 2, i) 459s ***** error ... 459s burrrnd (1, 2, 3, -1) 459s ***** error ... 459s burrrnd (1, 2, 3, 1.2) 459s ***** error ... 459s burrrnd (1, 2, 3, ones (2)) 459s ***** error ... 459s burrrnd (1, 2, 3, [2 -1 2]) 459s ***** error ... 459s burrrnd (1, 2, 3, [2 0 2.5]) 459s ***** error ... 459s burrrnd (1, 2, 3, 2, -1, 5) 459s ***** error ... 459s burrrnd (1, 2, 3, 2, 1.5, 5) 459s ***** error ... 459s burrrnd (2, ones (2), 2, 3) 459s ***** error ... 459s burrrnd (2, ones (2), 2, [3, 2]) 459s ***** error ... 459s burrrnd (2, ones (2), 2, 3, 2) 459s 36 tests, 36 passed, 0 known failure, 0 skipped 459s [inst/dist_fun/bisapdf.m] 459s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/bisapdf.m 459s ***** demo 459s ## Plot various PDFs from the Birnbaum-Saunders distribution 459s x = 0.01:0.01:4; 459s y1 = bisapdf (x, 1, 0.5); 459s y2 = bisapdf (x, 1, 1); 459s y3 = bisapdf (x, 1, 2); 459s y4 = bisapdf (x, 1, 5); 459s y5 = bisapdf (x, 1, 10); 459s plot (x, y1, "-b", x, y2, "-g", x, y3, "-r", x, y4, "-c", x, y5, "-m") 459s grid on 459s ylim ([0, 1.5]) 459s legend ({"β = 1 ,γ = 0.5", "β = 1, γ = 1", "β = 1, γ = 2", ... 459s "β = 1, γ = 5", "β = 1, γ = 10"}, "location", "northeast") 459s title ("Birnbaum-Saunders PDF") 459s xlabel ("values in x") 459s ylabel ("density") 459s ***** demo 459s ## Plot various PDFs from the Birnbaum-Saunders distribution 459s x = 0.01:0.01:6; 459s y1 = bisapdf (x, 1, 0.3); 459s y2 = bisapdf (x, 2, 0.3); 459s y3 = bisapdf (x, 1, 0.5); 459s y4 = bisapdf (x, 3, 0.5); 459s y5 = bisapdf (x, 5, 0.5); 459s plot (x, y1, "-b", x, y2, "-g", x, y3, "-r", x, y4, "-c", x, y5, "-m") 459s grid on 459s ylim ([0, 1.5]) 459s legend ({"β = 1, γ = 0.3", "β = 2, γ = 0.3", "β = 1, γ = 0.5", ... 459s "β = 3, γ = 0.5", "β = 5, γ = 0.5"}, "location", "northeast") 459s title ("Birnbaum-Saunders CDF") 459s xlabel ("values in x") 459s ylabel ("density") 459s ***** shared x, y 459s x = [-1, 0, 1, 2, Inf]; 459s y = [0, 0, 0.3989422804014327, 0.1647717335503959, 0]; 459s ***** assert (bisapdf (x, ones (1,5), ones (1,5)), y, eps) 459s ***** assert (bisapdf (x, 1, 1), y, eps) 459s ***** assert (bisapdf (x, 1, ones (1,5)), y, eps) 459s ***** assert (bisapdf (x, ones (1,5), 1), y, eps) 459s ***** assert (bisapdf (x, 1, [1, 1, NaN, 1, 1]), [y(1:2), NaN, y(4:5)], eps) 459s ***** assert (bisapdf (x, [1, 1, NaN, 1, 1], 1), [y(1:2), NaN, y(4:5)], eps) 459s ***** assert (bisapdf ([x, NaN], 1, 1), [y, NaN], eps) 459s ***** assert (bisapdf (single ([x, NaN]), 1, 1), single ([y, NaN]), eps ("single")) 459s ***** assert (bisapdf ([x, NaN], 1, single (1)), single ([y, NaN]), eps ("single")) 459s ***** assert (bisapdf ([x, NaN], single (1), 1), single ([y, NaN]), eps ("single")) 459s ***** error bisapdf () 459s ***** error bisapdf (1) 459s ***** error bisapdf (1, 2) 459s ***** error bisapdf (1, 2, 3, 4) 459s ***** error ... 459s bisapdf (ones (3), ones (2), ones(2)) 459s ***** error ... 459s bisapdf (ones (2), ones (3), ones(2)) 459s ***** error ... 459s bisapdf (ones (2), ones (2), ones(3)) 459s ***** error bisapdf (i, 4, 3) 459s ***** error bisapdf (1, i, 3) 459s ***** error bisapdf (1, 4, i) 459s 20 tests, 20 passed, 0 known failure, 0 skipped 459s [inst/dist_fun/unifinv.m] 459s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/unifinv.m 459s ***** demo 459s ## Plot various iCDFs from the continuous uniform distribution 459s p = 0.001:0.001:0.999; 459s x1 = unifinv (p, 2, 5); 459s x2 = unifinv (p, 3, 9); 459s plot (p, x1, "-b", p, x2, "-g") 459s grid on 459s xlim ([0, 1]) 459s ylim ([0, 10]) 459s legend ({"a = 2, b = 5", "a = 3, b = 9"}, "location", "northwest") 459s title ("Continuous uniform iCDF") 459s xlabel ("probability") 459s ylabel ("values in x") 459s ***** shared p 459s p = [-1 0 0.5 1 2]; 459s ***** assert (unifinv (p, ones (1,5), 2*ones (1,5)), [NaN 1 1.5 2 NaN]) 459s ***** assert (unifinv (p, 0, 1), [NaN 1 1.5 2 NaN] - 1) 459s ***** assert (unifinv (p, 1, 2*ones (1,5)), [NaN 1 1.5 2 NaN]) 459s ***** assert (unifinv (p, ones (1,5), 2), [NaN 1 1.5 2 NaN]) 459s ***** assert (unifinv (p, [1 2 NaN 1 1], 2), [NaN NaN NaN 2 NaN]) 459s ***** assert (unifinv (p, 1, 2*[1 0 NaN 1 1]), [NaN NaN NaN 2 NaN]) 459s ***** assert (unifinv ([p(1:2) NaN p(4:5)], 1, 2), [NaN 1 NaN 2 NaN]) 459s ***** assert (unifinv ([p, NaN], 1, 2), [NaN 1 1.5 2 NaN NaN]) 459s ***** assert (unifinv (single ([p, NaN]), 1, 2), single ([NaN 1 1.5 2 NaN NaN])) 459s ***** assert (unifinv ([p, NaN], single (1), 2), single ([NaN 1 1.5 2 NaN NaN])) 459s ***** assert (unifinv ([p, NaN], 1, single (2)), single ([NaN 1 1.5 2 NaN NaN])) 459s ***** error unifinv () 459s ***** error unifinv (1, 2) 459s ***** error ... 459s unifinv (ones (3), ones (2), ones (2)) 459s ***** error ... 459s unifinv (ones (2), ones (3), ones (2)) 459s ***** error ... 459s unifinv (ones (2), ones (2), ones (3)) 459s ***** error unifinv (i, 2, 2) 459s ***** error unifinv (2, i, 2) 459s ***** error unifinv (2, 2, i) 459s 19 tests, 19 passed, 0 known failure, 0 skipped 459s [inst/dist_fun/gppdf.m] 459s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/gppdf.m 459s ***** demo 459s ## Plot various PDFs from the generalized Pareto distribution 459s x = 0:0.001:5; 459s y1 = gppdf (x, 1, 1, 0); 459s y2 = gppdf (x, 5, 1, 0); 459s y3 = gppdf (x, 20, 1, 0); 459s y4 = gppdf (x, 1, 2, 0); 459s y5 = gppdf (x, 5, 2, 0); 459s y6 = gppdf (x, 20, 2, 0); 459s plot (x, y1, "-b", x, y2, "-g", x, y3, "-r", ... 459s x, y4, "-c", x, y5, "-m", x, y6, "-k") 459s grid on 459s xlim ([0, 5]) 459s ylim ([0, 1]) 459s legend ({"k = 1, σ = 1, θ = 0", "k = 5, σ = 1, θ = 0", ... 459s "k = 20, σ = 1, θ = 0", "k = 1, σ = 2, θ = 0", ... 459s "k = 5, σ = 2, θ = 0", "k = 20, σ = 2, θ = 0"}, ... 459s "location", "northeast") 459s title ("Generalized Pareto PDF") 459s xlabel ("values in x") 459s ylabel ("density") 459s ***** shared x, y1, y2, y3 459s x = [-Inf, -1, 0, 1/2, 1, Inf]; 459s y1 = [0, 0, 1, 0.6065306597126334, 0.36787944117144233, 0]; 459s y2 = [0, 0, 1, 4/9, 1/4, 0]; 459s y3 = [0, 0, 1, 1, 1, 0]; 459s ***** assert (gppdf (x, zeros (1,6), ones (1,6), zeros (1,6)), y1, eps) 459s ***** assert (gppdf (x, 0, 1, zeros (1,6)), y1, eps) 459s ***** assert (gppdf (x, 0, ones (1,6), 0), y1, eps) 459s ***** assert (gppdf (x, zeros (1,6), 1, 0), y1, eps) 459s ***** assert (gppdf (x, 0, 1, 0), y1, eps) 459s ***** assert (gppdf (x, 0, 1, [0, 0, 0, NaN, 0, 0]), [y1(1:3), NaN, y1(5:6)]) 459s ***** assert (gppdf (x, 0, [1, 1, 1, NaN, 1, 1], 0), [y1(1:3), NaN, y1(5:6)]) 459s ***** assert (gppdf (x, [0, 0, 0, NaN, 0, 0], 1, 0), [y1(1:3), NaN, y1(5:6)]) 459s ***** assert (gppdf ([x(1:3), NaN, x(5:6)], 0, 1, 0), [y1(1:3), NaN, y1(5:6)]) 459s ***** assert (gppdf (x, ones (1,6), ones (1,6), zeros (1,6)), y2, eps) 459s ***** assert (gppdf (x, 1, 1, zeros (1,6)), y2, eps) 459s ***** assert (gppdf (x, 1, ones (1,6), 0), y2, eps) 459s ***** assert (gppdf (x, ones (1,6), 1, 0), y2, eps) 459s ***** assert (gppdf (x, 1, 1, 0), y2, eps) 459s ***** assert (gppdf (x, 1, 1, [0, 0, 0, NaN, 0, 0]), [y2(1:3), NaN, y2(5:6)]) 459s ***** assert (gppdf (x, 1, [1, 1, 1, NaN, 1, 1], 0), [y2(1:3), NaN, y2(5:6)]) 459s ***** assert (gppdf (x, [1, 1, 1, NaN, 1, 1], 1, 0), [y2(1:3), NaN, y2(5:6)]) 459s ***** assert (gppdf ([x(1:3), NaN, x(5:6)], 1, 1, 0), [y2(1:3), NaN, y2(5:6)]) 459s ***** assert (gppdf (x, -ones (1,6), ones (1,6), zeros (1,6)), y3, eps) 459s ***** assert (gppdf (x, -1, 1, zeros (1,6)), y3, eps) 459s ***** assert (gppdf (x, -1, ones (1,6), 0), y3, eps) 459s ***** assert (gppdf (x, -ones (1,6), 1, 0), y3, eps) 459s ***** assert (gppdf (x, -1, 1, 0), y3, eps) 459s ***** assert (gppdf (x, -1, 1, [0, 0, 0, NaN, 0, 0]), [y3(1:3), NaN, y3(5:6)]) 459s ***** assert (gppdf (x, -1, [1, 1, 1, NaN, 1, 1], 0), [y3(1:3), NaN, y3(5:6)]) 459s ***** assert (gppdf (x, [-1, -1, -1, NaN, -1, -1], 1, 0), [y3(1:3), NaN, y3(5:6)]) 459s ***** assert (gppdf ([x(1:3), NaN, x(5:6)], -1, 1, 0), [y3(1:3), NaN, y3(5:6)]) 459s ***** assert (gppdf (single ([x, NaN]), 0, 1, 0), single ([y1, NaN])) 459s ***** assert (gppdf ([x, NaN], 0, 1, single (0)), single ([y1, NaN])) 459s ***** assert (gppdf ([x, NaN], 0, single (1), 0), single ([y1, NaN])) 459s ***** assert (gppdf ([x, NaN], single (0), 1, 0), single ([y1, NaN])) 459s ***** assert (gppdf (single ([x, NaN]), 1, 1, 0), single ([y2, NaN])) 459s ***** assert (gppdf ([x, NaN], 1, 1, single (0)), single ([y2, NaN])) 459s ***** assert (gppdf ([x, NaN], 1, single (1), 0), single ([y2, NaN])) 459s ***** assert (gppdf ([x, NaN], single (1), 1, 0), single ([y2, NaN])) 459s ***** assert (gppdf (single ([x, NaN]), -1, 1, 0), single ([y3, NaN])) 459s ***** assert (gppdf ([x, NaN], -1, 1, single (0)), single ([y3, NaN])) 459s ***** assert (gppdf ([x, NaN], -1, single (1), 0), single ([y3, NaN])) 459s ***** assert (gppdf ([x, NaN], single (-1), 1, 0), single ([y3, NaN])) 459s ***** error gpcdf () 459s ***** error gpcdf (1) 459s ***** error gpcdf (1, 2) 459s ***** error gpcdf (1, 2, 3) 459s ***** error ... 459s gpcdf (ones (3), ones (2), ones(2), ones(2)) 459s ***** error ... 459s gpcdf (ones (2), ones (3), ones(2), ones(2)) 459s ***** error ... 459s gpcdf (ones (2), ones (2), ones(3), ones(2)) 459s ***** error ... 459s gpcdf (ones (2), ones (2), ones(2), ones(3)) 459s ***** error gpcdf (i, 2, 3, 4) 459s ***** error gpcdf (1, i, 3, 4) 460s ***** error gpcdf (1, 2, i, 4) 460s ***** error gpcdf (1, 2, 3, i) 460s 51 tests, 51 passed, 0 known failure, 0 skipped 460s [inst/dist_fun/nbinpdf.m] 460s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/nbinpdf.m 460s ***** demo 460s ## Plot various PDFs from the negative binomial distribution 460s x = 0:40; 460s y1 = nbinpdf (x, 2, 0.15); 460s y2 = nbinpdf (x, 5, 0.2); 460s y3 = nbinpdf (x, 4, 0.4); 460s y4 = nbinpdf (x, 10, 0.3); 460s plot (x, y1, "*r", x, y2, "*g", x, y3, "*k", x, y4, "*m") 460s grid on 460s xlim ([0, 40]) 460s ylim ([0, 0.12]) 460s legend ({"r = 2, ps = 0.15", "r = 5, ps = 0.2", "r = 4, p = 0.4", ... 460s "r = 10, ps = 0.3"}, "location", "northeast") 460s title ("Negative binomial PDF") 460s xlabel ("values in x (number of failures)") 460s ylabel ("density") 460s ***** shared x, y 460s x = [-1 0 1 2 Inf]; 460s y = [0 1/2 1/4 1/8 NaN]; 460s ***** assert (nbinpdf (x, ones (1,5), 0.5*ones (1,5)), y) 460s ***** assert (nbinpdf (x, 1, 0.5*ones (1,5)), y) 460s ***** assert (nbinpdf (x, ones (1,5), 0.5), y) 460s ***** assert (nbinpdf (x, [0 1 NaN 1.5 Inf], 0.5), [NaN 1/2 NaN 1.875*0.5^1.5/4 NaN], eps) 460s ***** assert (nbinpdf (x, 1, 0.5*[-1 NaN 4 1 1]), [NaN NaN NaN y(4:5)]) 460s ***** assert (nbinpdf ([x, NaN], 1, 0.5), [y, NaN]) 460s ***** assert (nbinpdf (single ([x, NaN]), 1, 0.5), single ([y, NaN])) 460s ***** assert (nbinpdf ([x, NaN], single (1), 0.5), single ([y, NaN])) 460s ***** assert (nbinpdf ([x, NaN], 1, single (0.5)), single ([y, NaN])) 460s ***** error nbinpdf () 460s ***** error nbinpdf (1) 460s ***** error nbinpdf (1, 2) 460s ***** error ... 460s nbinpdf (ones (3), ones (2), ones (2)) 460s ***** error ... 460s nbinpdf (ones (2), ones (3), ones (2)) 460s ***** error ... 460s nbinpdf (ones (2), ones (2), ones (3)) 460s ***** error nbinpdf (i, 2, 2) 460s ***** error nbinpdf (2, i, 2) 460s ***** error nbinpdf (2, 2, i) 460s 18 tests, 18 passed, 0 known failure, 0 skipped 460s [inst/dist_fun/loglinv.m] 460s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/loglinv.m 460s ***** demo 460s ## Plot various iCDFs from the log-logistic distribution 460s p = 0.001:0.001:0.999; 460s x1 = loglinv (p, log (1), 1/0.5); 460s x2 = loglinv (p, log (1), 1); 460s x3 = loglinv (p, log (1), 1/2); 460s x4 = loglinv (p, log (1), 1/4); 460s x5 = loglinv (p, log (1), 1/8); 460s plot (p, x1, "-b", p, x2, "-g", p, x3, "-r", p, x4, "-c", p, x5, "-m") 460s ylim ([0, 20]) 460s grid on 460s legend ({"σ = 2 (β = 0.5)", "σ = 1 (β = 1)", "σ = 0.5 (β = 2)", ... 460s "σ = 0.25 (β = 4)", "σ = 0.125 (β = 8)"}, "location", "northwest") 460s title ("Log-logistic iCDF") 460s xlabel ("probability") 460s ylabel ("x") 460s text (0.03, 12.5, "μ = 0 (α = 1), values of σ (β) as shown in legend") 460s ***** shared p, out1, out2 460s p = [-1, 0, 0.2, 0.5, 0.8, 0.95, 1, 2]; 460s out1 = [NaN, 0, 0.25, 1, 4, 19, Inf, NaN]; 460s out2 = [NaN, 0, 0.0424732, 2.718282, 173.970037, 18644.695061, Inf, NaN]; 460s ***** assert (loglinv (p, 0, 1), out1, 1e-8) 460s ***** assert (loglinv (p, 0, 1), out1, 1e-8) 460s ***** assert (loglinv (p, 1, 3), out2, 1e-6) 460s ***** assert (class (loglinv (single (1), 2, 3)), "single") 460s ***** assert (class (loglinv (1, single (2), 3)), "single") 460s ***** assert (class (loglinv (1, 2, single (3))), "single") 460s ***** error loglinv (1) 460s ***** error loglinv (1, 2) 460s ***** error ... 460s loglinv (1, ones (2), ones (3)) 460s ***** error ... 460s loglinv (ones (2), 1, ones (3)) 460s ***** error ... 460s loglinv (ones (2), ones (3), 1) 460s ***** error loglinv (i, 2, 3) 460s ***** error loglinv (1, i, 3) 460s ***** error loglinv (1, 2, i) 460s 14 tests, 14 passed, 0 known failure, 0 skipped 460s [inst/dist_fun/betainv.m] 460s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/betainv.m 460s ***** demo 460s ## Plot various iCDFs from the Beta distribution 460s p = 0.001:0.001:0.999; 460s x1 = betainv (p, 0.5, 0.5); 460s x2 = betainv (p, 5, 1); 460s x3 = betainv (p, 1, 3); 460s x4 = betainv (p, 2, 2); 460s x5 = betainv (p, 2, 5); 460s plot (p, x1, "-b", p, x2, "-g", p, x3, "-r", p, x4, "-c", p, x5, "-m") 460s grid on 460s legend ({"α = β = 0.5", "α = 5, β = 1", "α = 1, β = 3", ... 460s "α = 2, β = 2", "α = 2, β = 5"}, "location", "southeast") 460s title ("Beta iCDF") 460s xlabel ("probability") 460s ylabel ("values in x") 460s ***** shared p 460s p = [-1 0 0.75 1 2]; 460s ***** assert (betainv (p, ones (1,5), 2*ones (1,5)), [NaN 0 0.5 1 NaN], eps) 460s ***** assert (betainv (p, 1, 2*ones (1,5)), [NaN 0 0.5 1 NaN], eps) 460s ***** assert (betainv (p, ones (1,5), 2), [NaN 0 0.5 1 NaN], eps) 460s ***** assert (betainv (p, [1 0 NaN 1 1], 2), [NaN NaN NaN 1 NaN]) 460s ***** assert (betainv (p, 1, 2*[1 0 NaN 1 1]), [NaN NaN NaN 1 NaN]) 460s ***** assert (betainv ([p(1:2) NaN p(4:5)], 1, 2), [NaN 0 NaN 1 NaN]) 460s ***** assert (betainv ([p, NaN], 1, 2), [NaN 0 0.5 1 NaN NaN], eps) 460s ***** assert (betainv (single ([p, NaN]), 1, 2), single ([NaN 0 0.5 1 NaN NaN])) 460s ***** assert (betainv ([p, NaN], single (1), 2), single ([NaN 0 0.5 1 NaN NaN]), eps("single")) 460s ***** assert (betainv ([p, NaN], 1, single (2)), single ([NaN 0 0.5 1 NaN NaN]), eps("single")) 460s ***** error betainv () 460s ***** error betainv (1) 460s ***** error betainv (1,2) 460s ***** error betainv (1,2,3,4) 460s ***** error ... 460s betainv (ones (3), ones (2), ones (2)) 460s ***** error ... 460s betainv (ones (2), ones (3), ones (2)) 460s ***** error ... 460s betainv (ones (2), ones (2), ones (3)) 460s ***** error betainv (i, 2, 2) 460s ***** error betainv (2, i, 2) 460s ***** error betainv (2, 2, i) 460s 20 tests, 20 passed, 0 known failure, 0 skipped 460s [inst/dist_fun/nakainv.m] 460s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/nakainv.m 460s ***** demo 460s ## Plot various iCDFs from the Nakagami distribution 460s p = 0.001:0.001:0.999; 460s x1 = nakainv (p, 0.5, 1); 460s x2 = nakainv (p, 1, 1); 460s x3 = nakainv (p, 1, 2); 460s x4 = nakainv (p, 1, 3); 460s x5 = nakainv (p, 2, 1); 460s x6 = nakainv (p, 2, 2); 460s x7 = nakainv (p, 5, 1); 460s plot (p, x1, "-r", p, x2, "-g", p, x3, "-y", p, x4, "-m", ... 460s p, x5, "-k", p, x6, "-b", p, x7, "-c") 460s grid on 460s ylim ([0, 3]) 460s legend ({"μ = 0.5, ω = 1", "μ = 1, ω = 1", "μ = 1, ω = 2", ... 460s "μ = 1, ω = 3", "μ = 2, ω = 1", "μ = 2, ω = 2", ... 460s "μ = 5, ω = 1"}, "location", "northwest") 460s title ("Nakagami iCDF") 460s xlabel ("probability") 460s ylabel ("values in x") 460s ***** shared p, y 460s p = [-Inf, -1, 0, 1/2, 1, 2, Inf]; 460s y = [NaN, NaN, 0, 0.83255461115769769, Inf, NaN, NaN]; 460s ***** assert (nakainv (p, ones (1,7), ones (1,7)), y, eps) 460s ***** assert (nakainv (p, 1, 1), y, eps) 460s ***** assert (nakainv (p, [1, 1, 1, NaN, 1, 1, 1], 1), [y(1:3), NaN, y(5:7)], eps) 460s ***** assert (nakainv (p, 1, [1, 1, 1, NaN, 1, 1, 1]), [y(1:3), NaN, y(5:7)], eps) 460s ***** assert (nakainv ([p, NaN], 1, 1), [y, NaN], eps) 460s ***** assert (nakainv (single ([p, NaN]), 1, 1), single ([y, NaN])) 460s ***** assert (nakainv ([p, NaN], single (1), 1), single ([y, NaN])) 460s ***** assert (nakainv ([p, NaN], 1, single (1)), single ([y, NaN])) 460s ***** error nakainv () 460s ***** error nakainv (1) 460s ***** error nakainv (1, 2) 460s ***** error ... 460s nakainv (ones (3), ones (2), ones(2)) 460s ***** error ... 460s nakainv (ones (2), ones (3), ones(2)) 460s ***** error ... 460s nakainv (ones (2), ones (2), ones(3)) 460s ***** error nakainv (i, 4, 3) 460s ***** error nakainv (1, i, 3) 460s ***** error nakainv (1, 4, i) 460s 17 tests, 17 passed, 0 known failure, 0 skipped 460s [inst/dist_fun/gamcdf.m] 460s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/gamcdf.m 460s ***** demo 460s ## Plot various CDFs from the Gamma distribution 460s x = 0:0.01:20; 460s p1 = gamcdf (x, 1, 2); 460s p2 = gamcdf (x, 2, 2); 460s p3 = gamcdf (x, 3, 2); 460s p4 = gamcdf (x, 5, 1); 460s p5 = gamcdf (x, 9, 0.5); 460s p6 = gamcdf (x, 7.5, 1); 460s p7 = gamcdf (x, 0.5, 1); 460s plot (x, p1, "-r", x, p2, "-g", x, p3, "-y", x, p4, "-m", ... 460s x, p5, "-k", x, p6, "-b", x, p7, "-c") 460s grid on 460s legend ({"α = 1, β = 2", "α = 2, β = 2", "α = 3, β = 2", ... 460s "α = 5, β = 1", "α = 9, β = 0.5", "α = 7.5, β = 1", ... 460s "α = 0.5, β = 1"}, "location", "southeast") 460s title ("Gamma CDF") 460s xlabel ("values in x") 460s ylabel ("probability") 460s ***** shared x, y, u 460s x = [-1, 0, 0.5, 1, 2, Inf]; 460s y = [0, gammainc(x(2:end), 1)]; 460s u = [0, NaN, NaN, 1, 0.1353352832366127, 0]; 460s ***** assert (gamcdf (x, ones (1,6), ones (1,6)), y, eps) 460s ***** assert (gamcdf (x, ones (1,6), ones (1,6), []), y, eps) 460s ***** assert (gamcdf (x, 1, ones (1,6)), y, eps) 460s ***** assert (gamcdf (x, ones (1,6), 1), y, eps) 460s ***** assert (gamcdf (x, [0, -Inf, NaN, Inf, 1, 1], 1), [1, NaN, NaN, 0, y(5:6)], eps) 460s ***** assert (gamcdf (x, [0, -Inf, NaN, Inf, 1, 1], 1, "upper"), u, eps) 460s ***** assert (gamcdf (x, 1, [0, -Inf, NaN, Inf, 1, 1]), [NaN, NaN, NaN, 0, y(5:6)], eps) 460s ***** assert (gamcdf ([x(1:2), NaN, x(4:6)], 1, 1), [y(1:2), NaN, y(4:6)], eps) 460s ***** assert (gamcdf ([x, NaN], 1, 1), [y, NaN]) 460s ***** assert (gamcdf (single ([x, NaN]), 1, 1), single ([y, NaN]), eps ("single")) 460s ***** assert (gamcdf ([x, NaN], single (1), 1), single ([y, NaN]), eps ("single")) 460s ***** assert (gamcdf ([x, NaN], 1, single (1)), single ([y, NaN]), eps ("single")) 460s ***** error gamcdf () 460s ***** error gamcdf (1) 460s ***** error gamcdf (1, 2, 3, 4, 5, 6, 7) 460s ***** error gamcdf (1, 2, 3, "uper") 460s ***** error gamcdf (1, 2, 3, 4, 5, "uper") 460s ***** error gamcdf (2, 3, 4, [1, 2]) 460s ***** error ... 460s [p, plo, pup] = gamcdf (1, 2, 3) 460s ***** error ... 460s [p, plo, pup] = gamcdf (1, 2, 3, "upper") 460s ***** error [p, plo, pup] = ... 460s gamcdf (1, 2, 3, [1, 0; 0, 1], 0) 460s ***** error [p, plo, pup] = ... 460s gamcdf (1, 2, 3, [1, 0; 0, 1], 1.22) 460s ***** error [p, plo, pup] = ... 460s gamcdf (1, 2, 3, [1, 0; 0, 1], "alpha", "upper") 460s ***** error ... 460s gamcdf (ones (3), ones (2), ones (2)) 460s ***** error ... 460s gamcdf (ones (2), ones (3), ones (2)) 460s ***** error ... 460s gamcdf (ones (2), ones (2), ones (3)) 460s ***** error gamcdf (i, 2, 2) 460s ***** error gamcdf (2, i, 2) 460s ***** error gamcdf (2, 2, i) 460s ***** error ... 460s [p, plo, pup] = gamcdf (1, 2, 3, [1, 0; 0, -inf], 0.04) 460s 30 tests, 30 passed, 0 known failure, 0 skipped 460s [inst/dist_fun/normrnd.m] 460s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/normrnd.m 460s ***** assert (size (normrnd (1, 1)), [1 1]) 460s ***** assert (size (normrnd (1, ones (2,1))), [2, 1]) 460s ***** assert (size (normrnd (1, ones (2,2))), [2, 2]) 460s ***** assert (size (normrnd (ones (2,1), 1)), [2, 1]) 460s ***** assert (size (normrnd (ones (2,2), 1)), [2, 2]) 460s ***** assert (size (normrnd (1, 1, 3)), [3, 3]) 460s ***** assert (size (normrnd (1, 1, [4, 1])), [4, 1]) 460s ***** assert (size (normrnd (1, 1, 4, 1)), [4, 1]) 460s ***** assert (size (normrnd (1, 1, 4, 1, 5)), [4, 1, 5]) 460s ***** assert (size (normrnd (1, 1, 0, 1)), [0, 1]) 460s ***** assert (size (normrnd (1, 1, 1, 0)), [1, 0]) 460s ***** assert (size (normrnd (1, 1, 1, 2, 0, 5)), [1, 2, 0, 5]) 460s ***** assert (class (normrnd (1, 1)), "double") 460s ***** assert (class (normrnd (1, single (1))), "single") 460s ***** assert (class (normrnd (1, single ([1, 1]))), "single") 460s ***** assert (class (normrnd (single (1), 1)), "single") 460s ***** assert (class (normrnd (single ([1, 1]), 1)), "single") 460s ***** error normrnd () 460s ***** error normrnd (1) 460s ***** error ... 460s normrnd (ones (3), ones (2)) 460s ***** error ... 460s normrnd (ones (2), ones (3)) 460s ***** error normrnd (i, 2, 3) 460s ***** error normrnd (1, i, 3) 460s ***** error ... 460s normrnd (1, 2, -1) 460s ***** error ... 460s normrnd (1, 2, 1.2) 460s ***** error ... 460s normrnd (1, 2, ones (2)) 460s ***** error ... 460s normrnd (1, 2, [2 -1 2]) 460s ***** error ... 460s normrnd (1, 2, [2 0 2.5]) 460s ***** error ... 460s normrnd (1, 2, 2, -1, 5) 460s ***** error ... 460s normrnd (1, 2, 2, 1.5, 5) 460s ***** error ... 460s normrnd (2, ones (2), 3) 460s ***** error ... 460s normrnd (2, ones (2), [3, 2]) 460s ***** error ... 460s normrnd (2, ones (2), 3, 2) 460s 33 tests, 33 passed, 0 known failure, 0 skipped 460s [inst/dist_fun/laplacepdf.m] 460s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/laplacepdf.m 460s ***** demo 460s ## Plot various PDFs from the Laplace distribution 460s x = -10:0.01:10; 460s y1 = laplacepdf (x, 0, 1); 460s y2 = laplacepdf (x, 0, 2); 460s y3 = laplacepdf (x, 0, 4); 460s y4 = laplacepdf (x, -5, 4); 460s plot (x, y1, "-b", x, y2, "-g", x, y3, "-r", x, y4, "-c") 460s grid on 460s xlim ([-10, 10]) 460s ylim ([0, 0.6]) 460s legend ({"μ = 0, β = 1", "μ = 0, β = 2", ... 460s "μ = 0, β = 4", "μ = -5, β = 4"}, "location", "northeast") 460s title ("Laplace PDF") 460s xlabel ("values in x") 460s ylabel ("density") 460s ***** shared x, y 460s x = [-Inf -log(2) 0 log(2) Inf]; 460s y = [0, 1/4, 1/2, 1/4, 0]; 460s ***** assert (laplacepdf ([x, NaN], 0, 1), [y, NaN]) 460s ***** assert (laplacepdf (x, 0, [-2, -1, 0, 1, 2]), [nan(1, 3), 0.25, 0]) 460s ***** assert (laplacepdf (single ([x, NaN]), 0, 1), single ([y, NaN])) 460s ***** assert (laplacepdf ([x, NaN], single (0), 1), single ([y, NaN])) 460s ***** assert (laplacepdf ([x, NaN], 0, single (1)), single ([y, NaN])) 460s ***** error laplacepdf () 460s ***** error laplacepdf (1) 460s ***** error ... 460s laplacepdf (1, 2) 460s ***** error laplacepdf (1, 2, 3, 4) 460s ***** error ... 460s laplacepdf (1, ones (2), ones (3)) 460s ***** error ... 460s laplacepdf (ones (2), 1, ones (3)) 460s ***** error ... 460s laplacepdf (ones (2), ones (3), 1) 460s ***** error laplacepdf (i, 2, 3) 460s ***** error laplacepdf (1, i, 3) 460s ***** error laplacepdf (1, 2, i) 460s 15 tests, 15 passed, 0 known failure, 0 skipped 460s [inst/dist_fun/gumbelinv.m] 460s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/gumbelinv.m 460s ***** demo 460s ## Plot various iCDFs from the Gumbel distribution 460s p = 0.001:0.001:0.999; 460s x1 = gumbelinv (p, 0.5, 2); 460s x2 = gumbelinv (p, 1.0, 2); 460s x3 = gumbelinv (p, 1.5, 3); 460s x4 = gumbelinv (p, 3.0, 4); 460s plot (p, x1, "-b", p, x2, "-g", p, x3, "-r", p, x4, "-c") 460s grid on 460s ylim ([-5, 20]) 460s legend ({"μ = 0.5, β = 2", "μ = 1.0, β = 2", ... 460s "μ = 1.5, β = 3", "μ = 3.0, β = 4"}, "location", "northwest") 460s title ("Gumbel iCDF") 460s xlabel ("probability") 460s ylabel ("values in x") 460s ***** shared p, x 460s p = [0, 0.05, 0.5 0.95]; 460s x = [-Inf, -1.0972, 0.3665, 2.9702]; 460s ***** assert (gumbelinv (p), x, 1e-4) 460s ***** assert (gumbelinv (p, zeros (1,4), ones (1,4)), x, 1e-4) 460s ***** assert (gumbelinv (p, 0, ones (1,4)), x, 1e-4) 460s ***** assert (gumbelinv (p, zeros (1,4), 1), x, 1e-4) 460s ***** assert (gumbelinv (p, [0, -Inf, NaN, Inf], 1), [-Inf, -Inf, NaN, Inf], 1e-4) 460s ***** assert (gumbelinv (p, 0, [Inf, NaN, -1, 0]), [-Inf, NaN, NaN, NaN], 1e-4) 460s ***** assert (gumbelinv ([p(1:2), NaN, p(4)], 0, 1), [x(1:2), NaN, x(4)], 1e-4) 460s ***** assert (gumbelinv ([p, NaN], 0, 1), [x, NaN], 1e-4) 460s ***** assert (gumbelinv (single ([p, NaN]), 0, 1), single ([x, NaN]), 1e-4) 460s ***** assert (gumbelinv ([p, NaN], single (0), 1), single ([x, NaN]), 1e-4) 460s ***** assert (gumbelinv ([p, NaN], 0, single (1)), single ([x, NaN]), 1e-4) 460s p = [0.05, 0.5, 0.95]; 460s x = gumbelinv(p); 460s ***** assert (gumbelcdf(x), p, 1e-4) 460s ***** error gumbelinv () 460s ***** error gumbelinv (1,2,3,4,5,6) 460s ***** error ... 460s gumbelinv (ones (3), ones (2), ones (2)) 460s ***** error ... 460s [p, plo, pup] = gumbelinv (2, 3, 4, [1, 2]) 460s ***** error ... 460s [p, plo, pup] = gumbelinv (1, 2, 3) 460s ***** error [p, plo, pup] = ... 460s gumbelinv (1, 2, 3, [1, 0; 0, 1], 0) 460s ***** error [p, plo, pup] = ... 460s gumbelinv (1, 2, 3, [1, 0; 0, 1], 1.22) 460s ***** error gumbelinv (i, 2, 2) 460s ***** error gumbelinv (2, i, 2) 460s ***** error gumbelinv (2, 2, i) 460s ***** error ... 460s [p, plo, pup] = gumbelinv (1, 2, 3, [-1, 10; -Inf, -Inf], 0.04) 460s 23 tests, 23 passed, 0 known failure, 0 skipped 460s [inst/dist_fun/copulacdf.m] 460s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/copulacdf.m 460s ***** test 460s x = [0.2:0.2:0.6; 0.2:0.2:0.6]; 460s theta = [1; 2]; 460s p = copulacdf ("Clayton", x, theta); 460s expected_p = [0.1395; 0.1767]; 460s assert (p, expected_p, 0.001); 460s ***** test 460s x = [0.2:0.2:0.6; 0.2:0.2:0.6]; 460s p = copulacdf ("Gumbel", x, 2); 460s expected_p = [0.1464; 0.1464]; 460s assert (p, expected_p, 0.001); 460s ***** test 460s x = [0.2:0.2:0.6; 0.2:0.2:0.6]; 460s theta = [1; 2]; 460s p = copulacdf ("Frank", x, theta); 460s expected_p = [0.0699; 0.0930]; 460s assert (p, expected_p, 0.001); 460s ***** test 460s x = [0.2:0.2:0.6; 0.2:0.2:0.6]; 460s theta = [0.3; 0.7]; 460s p = copulacdf ("AMH", x, theta); 460s expected_p = [0.0629; 0.0959]; 460s assert (p, expected_p, 0.001); 460s ***** test 460s x = [0.2:0.2:0.6; 0.2:0.1:0.4]; 460s theta = [0.2, 0.1, 0.1, 0.05]; 460s p = copulacdf ("FGM", x, theta); 460s expected_p = [0.0558; 0.0293]; 460s assert (p, expected_p, 0.001); 460s 5 tests, 5 passed, 0 known failure, 0 skipped 460s [inst/dist_fun/bisainv.m] 460s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/bisainv.m 460s ***** demo 460s ## Plot various iCDFs from the Birnbaum-Saunders distribution 460s p = 0.001:0.001:0.999; 460s x1 = bisainv (p, 1, 0.5); 460s x2 = bisainv (p, 1, 1); 460s x3 = bisainv (p, 1, 2); 460s x4 = bisainv (p, 1, 5); 460s x5 = bisainv (p, 1, 10); 460s plot (p, x1, "-b", p, x2, "-g", p, x3, "-r", p, x4, "-c", p, x5, "-m") 460s grid on 460s ylim ([0, 10]) 460s legend ({"β = 1, γ = 0.5", "β = 1, γ = 1", "β = 1, γ = 2", ... 460s "β = 1, γ = 5", "β = 1, γ = 10"}, "location", "northwest") 460s title ("Birnbaum-Saunders iCDF") 460s xlabel ("probability") 460s ylabel ("values in x") 460s ***** demo 460s ## Plot various iCDFs from the Birnbaum-Saunders distribution 460s p = 0.001:0.001:0.999; 460s x1 = bisainv (p, 1, 0.3); 460s x2 = bisainv (p, 2, 0.3); 460s x3 = bisainv (p, 1, 0.5); 460s x4 = bisainv (p, 3, 0.5); 460s x5 = bisainv (p, 5, 0.5); 460s plot (p, x1, "-b", p, x2, "-g", p, x3, "-r", p, x4, "-c", p, x5, "-m") 460s grid on 460s ylim ([0, 10]) 460s legend ({"β = 1, γ = 0.3", "β = 2, γ = 0.3", "β = 1, γ = 0.5", ... 460s "β = 3, γ = 0.5", "β = 5, γ = 0.5"}, "location", "northwest") 460s title ("Birnbaum-Saunders iCDF") 460s xlabel ("probability") 460s ylabel ("values in x") 460s ***** shared p, y, f 460s f = @(p,b,c) (b * (c * norminv (p) + sqrt (4 + (c * norminv(p))^2))^2) / 4; 460s p = [-1, 0, 1/4, 1/2, 1, 2]; 460s y = [NaN, 0, f(1/4, 1, 1), 1, Inf, NaN]; 460s ***** assert (bisainv (p, ones (1,6), ones (1,6)), y) 460s ***** assert (bisainv (p, 1, ones (1,6)), y) 460s ***** assert (bisainv (p, ones (1,6), 1), y) 460s ***** assert (bisainv (p, 1, 1), y) 460s ***** assert (bisainv (p, 1, [1, 1, 1, NaN, 1, 1]), [y(1:3), NaN, y(5:6)]) 460s ***** assert (bisainv (p, [1, 1, 1, NaN, 1, 1], 1), [y(1:3), NaN, y(5:6)]) 460s ***** assert (bisainv ([p, NaN], 1, 1), [y, NaN]) 460s ***** assert (bisainv (single ([p, NaN]), 1, 1), single ([y, NaN]), eps ("single")) 460s ***** assert (bisainv ([p, NaN], 1, single (1)), single ([y, NaN]), eps ("single")) 460s ***** assert (bisainv ([p, NaN], single (1), 1), single ([y, NaN]), eps ("single")) 460s ***** error bisainv () 460s ***** error bisainv (1) 460s ***** error bisainv (1, 2) 460s ***** error bisainv (1, 2, 3, 4) 460s ***** error ... 460s bisainv (ones (3), ones (2), ones(2)) 460s ***** error ... 460s bisainv (ones (2), ones (3), ones(2)) 460s ***** error ... 460s bisainv (ones (2), ones (2), ones(3)) 460s ***** error bisainv (i, 4, 3) 460s ***** error bisainv (1, i, 3) 460s ***** error bisainv (1, 4, i) 460s 20 tests, 20 passed, 0 known failure, 0 skipped 460s [inst/dist_fun/gevpdf.m] 460s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/gevpdf.m 460s ***** demo 460s ## Plot various PDFs from the generalized extreme value distribution 460s x = -1:0.001:10; 460s y1 = gevpdf (x, 1, 1, 1); 460s y2 = gevpdf (x, 0.5, 1, 1); 460s y3 = gevpdf (x, 1, 1, 5); 460s y4 = gevpdf (x, 1, 2, 5); 460s y5 = gevpdf (x, 1, 5, 5); 460s y6 = gevpdf (x, 1, 0.5, 5); 460s plot (x, y1, "-b", x, y2, "-g", x, y3, "-r", ... 460s x, y4, "-c", x, y5, "-m", x, y6, "-k") 460s grid on 460s xlim ([-1, 10]) 460s ylim ([0, 1.1]) 460s legend ({"k = 1, σ = 1, μ = 1", "k = 0.5, σ = 1, μ = 1", ... 460s "k = 1, σ = 1, μ = 5", "k = 1, σ = 2, μ = 5", ... 460s "k = 1, σ = 5, μ = 5", "k = 1, σ = 0.5, μ = 5"}, ... 460s "location", "northeast") 460s title ("Generalized extreme value PDF") 460s xlabel ("values in x") 460s ylabel ("density") 460s ***** test 460s x = 0:0.5:2.5; 460s sigma = 1:6; 460s k = 1; 460s mu = 0; 460s y = gevpdf (x, k, sigma, mu); 460s expected_y = [0.367879 0.143785 0.088569 0.063898 0.049953 0.040997]; 460s assert (y, expected_y, 0.001); 460s ***** test 460s x = -0.5:0.5:2.5; 460s sigma = 0.5; 460s k = 1; 460s mu = 0; 460s y = gevpdf (x, k, sigma, mu); 460s expected_y = [0 0.735759 0.303265 0.159229 0.097350 0.065498 0.047027]; 460s assert (y, expected_y, 0.001); 460s ***** test # check for continuity for k near 0 460s x = 1; 460s sigma = 0.5; 460s k = -0.03:0.01:0.03; 460s mu = 0; 460s y = gevpdf (x, k, sigma, mu); 460s expected_y = [0.23820 0.23764 0.23704 0.23641 0.23576 0.23508 0.23438]; 460s assert (y, expected_y, 0.001); 460s ***** error gevpdf () 460s ***** error gevpdf (1) 460s ***** error gevpdf (1, 2) 460s ***** error gevpdf (1, 2, 3) 460s ***** error ... 460s gevpdf (ones (3), ones (2), ones(2), ones(2)) 460s ***** error ... 460s gevpdf (ones (2), ones (3), ones(2), ones(2)) 460s ***** error ... 460s gevpdf (ones (2), ones (2), ones(3), ones(2)) 460s ***** error ... 460s gevpdf (ones (2), ones (2), ones(2), ones(3)) 460s ***** error gevpdf (i, 2, 3, 4) 460s ***** error gevpdf (1, i, 3, 4) 460s ***** error gevpdf (1, 2, i, 4) 460s ***** error gevpdf (1, 2, 3, i) 460s 15 tests, 15 passed, 0 known failure, 0 skipped 460s [inst/dist_fun/gevrnd.m] 460s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/gevrnd.m 460s ***** assert(size (gevrnd (1,2,1)), [1, 1]); 460s ***** assert(size (gevrnd (ones(2,1), 2, 1)), [2, 1]); 460s ***** assert(size (gevrnd (ones(2,2), 2, 1)), [2, 2]); 460s ***** assert(size (gevrnd (1, 2*ones(2,1), 1)), [2, 1]); 461s ***** assert(size (gevrnd (1, 2*ones(2,2), 1)), [2, 2]); 461s ***** assert(size (gevrnd (1, 2, 1, 3)), [3, 3]); 461s ***** assert(size (gevrnd (1, 2, 1, [4 1])), [4, 1]); 461s ***** assert(size (gevrnd (1, 2, 1, 4, 1)), [4, 1]); 461s ***** assert (class (gevrnd (1,1,1)), "double") 461s ***** assert (class (gevrnd (single (1),1,1)), "single") 461s ***** assert (class (gevrnd (single ([1 1]),1,1)), "single") 461s ***** assert (class (gevrnd (1,single (1),1)), "single") 461s ***** assert (class (gevrnd (1,single ([1 1]),1)), "single") 461s ***** assert (class (gevrnd (1,1,single (1))), "single") 461s ***** assert (class (gevrnd (1,1,single ([1 1]))), "single") 461s ***** error gevrnd () 461s ***** error gevrnd (1) 461s ***** error gevrnd (1, 2) 461s ***** error ... 461s gevrnd (ones (3), ones (2), ones (2)) 461s ***** error ... 461s gevrnd (ones (2), ones (3), ones (2)) 461s ***** error ... 461s gevrnd (ones (2), ones (2), ones (3)) 461s ***** error gevrnd (i, 2, 3) 461s ***** error gevrnd (1, i, 3) 461s ***** error gevrnd (1, 2, i) 461s ***** error ... 461s gevrnd (1, 2, 3, -1) 461s ***** error ... 461s gevrnd (1, 2, 3, 1.2) 461s ***** error ... 461s gevrnd (1, 2, 3, ones (2)) 461s ***** error ... 461s gevrnd (1, 2, 3, [2 -1 2]) 461s ***** error ... 461s gevrnd (1, 2, 3, [2 0 2.5]) 461s ***** error ... 461s gevrnd (1, 2, 3, 2, -1, 5) 461s ***** error ... 461s gevrnd (1, 2, 3, 2, 1.5, 5) 461s ***** error ... 461s gevrnd (2, ones (2), 2, 3) 461s ***** error ... 461s gevrnd (2, ones (2), 2, [3, 2]) 461s ***** error ... 461s gevrnd (2, ones (2), 2, 3, 2) 461s 34 tests, 34 passed, 0 known failure, 0 skipped 461s [inst/dist_fun/gumbelpdf.m] 461s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/gumbelpdf.m 461s ***** demo 461s ## Plot various PDFs from the Extreme value distribution 461s x = -5:0.001:20; 461s y1 = gumbelpdf (x, 0.5, 2); 461s y2 = gumbelpdf (x, 1.0, 2); 461s y3 = gumbelpdf (x, 1.5, 3); 461s y4 = gumbelpdf (x, 3.0, 4); 461s plot (x, y1, "-b", x, y2, "-g", x, y3, "-r", x, y4, "-c") 461s grid on 461s ylim ([0, 0.2]) 461s legend ({"μ = 0.5, β = 2", "μ = 1.0, β = 2", ... 461s "μ = 1.5, β = 3", "μ = 3.0, β = 4"}, "location", "northeast") 461s title ("Extreme value PDF") 461s xlabel ("values in x") 461s ylabel ("density") 461s ***** shared x, y0, y1 461s x = [-5, 0, 1, 2, 3]; 461s y0 = [0, 0.3679, 0.2547, 0.1182, 0.0474]; 461s y1 = [0, 0.1794, 0.3679, 0.2547, 0.1182]; 461s ***** assert (gumbelpdf (x), y0, 1e-4) 461s ***** assert (gumbelpdf (x, zeros (1,5), ones (1,5)), y0, 1e-4) 461s ***** assert (gumbelpdf (x, ones (1,5), ones (1,5)), y1, 1e-4) 461s ***** error gumbelpdf () 461s ***** error ... 461s gumbelpdf (ones (3), ones (2), ones (2)) 461s ***** error gumbelpdf (i, 2, 2) 461s ***** error gumbelpdf (2, i, 2) 461s ***** error gumbelpdf (2, 2, i) 461s 8 tests, 8 passed, 0 known failure, 0 skipped 461s [inst/dist_fun/loglrnd.m] 461s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/loglrnd.m 461s ***** assert (size (loglrnd (1, 1)), [1 1]) 461s ***** assert (size (loglrnd (1, ones (2,1))), [2, 1]) 461s ***** assert (size (loglrnd (1, ones (2,2))), [2, 2]) 461s ***** assert (size (loglrnd (ones (2,1), 1)), [2, 1]) 461s ***** assert (size (loglrnd (ones (2,2), 1)), [2, 2]) 461s ***** assert (size (loglrnd (1, 1, 3)), [3, 3]) 461s ***** assert (size (loglrnd (1, 1, [4, 1])), [4, 1]) 461s ***** assert (size (loglrnd (1, 1, 4, 1)), [4, 1]) 461s ***** assert (size (loglrnd (1, 1, 4, 1, 5)), [4, 1, 5]) 461s ***** assert (size (loglrnd (1, 1, 0, 1)), [0, 1]) 461s ***** assert (size (loglrnd (1, 1, 1, 0)), [1, 0]) 461s ***** assert (size (loglrnd (1, 1, 1, 2, 0, 5)), [1, 2, 0, 5]) 461s ***** assert (class (loglrnd (1, 1)), "double") 461s ***** assert (class (loglrnd (1, single (1))), "single") 461s ***** assert (class (loglrnd (1, single ([1, 1]))), "single") 461s ***** assert (class (loglrnd (single (1), 1)), "single") 461s ***** assert (class (loglrnd (single ([1, 1]), 1)), "single") 461s ***** error loglrnd () 461s ***** error loglrnd (1) 461s ***** error ... 461s loglrnd (ones (3), ones (2)) 461s ***** error ... 461s loglrnd (ones (2), ones (3)) 461s ***** error loglrnd (i, 2, 3) 461s ***** error loglrnd (1, i, 3) 461s ***** error ... 461s loglrnd (1, 2, -1) 461s ***** error ... 461s loglrnd (1, 2, 1.2) 461s ***** error ... 461s loglrnd (1, 2, ones (2)) 461s ***** error ... 461s loglrnd (1, 2, [2 -1 2]) 461s ***** error ... 461s loglrnd (1, 2, [2 0 2.5]) 461s ***** error ... 461s loglrnd (1, 2, 2, -1, 5) 461s ***** error ... 461s loglrnd (1, 2, 2, 1.5, 5) 461s ***** error ... 461s loglrnd (2, ones (2), 3) 461s ***** error ... 461s loglrnd (2, ones (2), [3, 2]) 461s ***** error ... 461s loglrnd (2, ones (2), 3, 2) 461s 33 tests, 33 passed, 0 known failure, 0 skipped 461s [inst/dist_fun/loglpdf.m] 461s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/loglpdf.m 461s ***** demo 461s ## Plot various PDFs from the log-logistic distribution 461s x = 0.001:0.001:2; 461s y1 = loglpdf (x, log (1), 1/0.5); 461s y2 = loglpdf (x, log (1), 1); 461s y3 = loglpdf (x, log (1), 1/2); 461s y4 = loglpdf (x, log (1), 1/4); 461s y5 = loglpdf (x, log (1), 1/8); 461s plot (x, y1, "-b", x, y2, "-g", x, y3, "-r", x, y4, "-c", x, y5, "-m") 461s grid on 461s ylim ([0,3]) 461s legend ({"σ = 2 (β = 0.5)", "σ = 1 (β = 1)", "σ = 0.5 (β = 2)", ... 461s "σ = 0.25 (β = 4)", "σ = 0.125 (β = 8)"}, "location", "northeast") 461s title ("Log-logistic PDF") 461s xlabel ("values in x") 461s ylabel ("density") 461s text (0.1, 2.8, "μ = 0 (α = 1), values of σ (β) as shown in legend") 461s ***** shared out1, out2 461s out1 = [0, 0, 1, 0.2500, 0.1111, 0.0625, 0.0400, 0.0278, 0]; 461s out2 = [0, 0, 0.0811, 0.0416, 0.0278, 0.0207, 0.0165, 0]; 461s ***** assert (loglpdf ([-1,0,realmin,1:5,Inf], 0, 1), out1, 1e-4) 461s ***** assert (loglpdf ([-1,0,realmin,1:5,Inf], 0, 1), out1, 1e-4) 461s ***** assert (loglpdf ([-1:5,Inf], 1, 3), out2, 1e-4) 461s ***** assert (class (loglpdf (single (1), 2, 3)), "single") 461s ***** assert (class (loglpdf (1, single (2), 3)), "single") 461s ***** assert (class (loglpdf (1, 2, single (3))), "single") 461s ***** error loglpdf (1) 461s ***** error loglpdf (1, 2) 461s ***** error ... 461s loglpdf (1, ones (2), ones (3)) 461s ***** error ... 461s loglpdf (ones (2), 1, ones (3)) 461s ***** error ... 461s loglpdf (ones (2), ones (3), 1) 461s ***** error loglpdf (i, 2, 3) 461s ***** error loglpdf (1, i, 3) 461s ***** error loglpdf (1, 2, i) 461s 14 tests, 14 passed, 0 known failure, 0 skipped 461s [inst/dist_fun/cauchyinv.m] 461s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/cauchyinv.m 461s ***** demo 461s ## Plot various iCDFs from the Cauchy distribution 461s p = 0.001:0.001:0.999; 461s x1 = cauchyinv (p, 0, 0.5); 461s x2 = cauchyinv (p, 0, 1); 461s x3 = cauchyinv (p, 0, 2); 461s x4 = cauchyinv (p, -2, 1); 461s plot (p, x1, "-b", p, x2, "-g", p, x3, "-r", p, x4, "-c") 461s grid on 461s ylim ([-5, 5]) 461s legend ({"x0 = 0, γ = 0.5", "x0 = 0, γ = 1", ... 461s "x0 = 0, γ = 2", "x0 = -2, γ = 1"}, "location", "northwest") 461s title ("Cauchy iCDF") 461s xlabel ("probability") 461s ylabel ("values in x") 461s ***** shared p 461s p = [-1 0 0.5 1 2]; 461s ***** assert (cauchyinv (p, ones (1,5), 2 * ones (1,5)), [NaN -Inf 1 Inf NaN], eps) 461s ***** assert (cauchyinv (p, 1, 2 * ones (1,5)), [NaN -Inf 1 Inf NaN], eps) 461s ***** assert (cauchyinv (p, ones (1,5), 2), [NaN -Inf 1 Inf NaN], eps) 461s ***** assert (cauchyinv (p, [1 -Inf NaN Inf 1], 2), [NaN NaN NaN NaN NaN]) 461s ***** assert (cauchyinv (p, 1, 2 * [1 0 NaN Inf 1]), [NaN NaN NaN NaN NaN]) 461s ***** assert (cauchyinv ([p(1:2) NaN p(4:5)], 1, 2), [NaN -Inf NaN Inf NaN]) 461s ***** assert (cauchyinv ([p, NaN], 1, 2), [NaN -Inf 1 Inf NaN NaN], eps) 461s ***** assert (cauchyinv (single ([p, NaN]), 1, 2), ... 461s single ([NaN -Inf 1 Inf NaN NaN]), eps ("single")) 461s ***** assert (cauchyinv ([p, NaN], single (1), 2), ... 461s single ([NaN -Inf 1 Inf NaN NaN]), eps ("single")) 461s ***** assert (cauchyinv ([p, NaN], 1, single (2)), ... 461s single ([NaN -Inf 1 Inf NaN NaN]), eps ("single")) 461s ***** error cauchyinv () 461s ***** error cauchyinv (1) 461s ***** error ... 461s cauchyinv (1, 2) 461s ***** error cauchyinv (1, 2, 3, 4) 461s ***** error ... 461s cauchyinv (ones (3), ones (2), ones(2)) 461s ***** error ... 461s cauchyinv (ones (2), ones (3), ones(2)) 461s ***** error ... 461s cauchyinv (ones (2), ones (2), ones(3)) 461s ***** error cauchyinv (i, 4, 3) 461s ***** error cauchyinv (1, i, 3) 461s ***** error cauchyinv (1, 4, i) 461s 20 tests, 20 passed, 0 known failure, 0 skipped 461s [inst/dist_fun/mvnrnd.m] 461s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/mvnrnd.m 461s ***** error mvnrnd () 461s ***** error mvnrnd ([2, 3, 4]) 461s ***** error mvnrnd (ones (2, 2, 2), ones (1, 2, 3, 4)) 461s ***** error mvnrnd (ones (1, 3), ones (1, 2, 3, 4)) 461s ***** assert (size (mvnrnd ([2, 3, 4], [2, 2, 2])), [1, 3]) 461s ***** assert (size (mvnrnd ([2, 3, 4], [2, 2, 2], 10)), [10, 3]) 461s 6 tests, 6 passed, 0 known failure, 0 skipped 461s [inst/dist_fun/invginv.m] 461s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/invginv.m 461s ***** demo 461s ## Plot various iCDFs from the inverse Gaussian distribution 461s p = 0.001:0.001:0.999; 461s x1 = invginv (p, 1, 0.2); 461s x2 = invginv (p, 1, 1); 461s x3 = invginv (p, 1, 3); 461s x4 = invginv (p, 3, 0.2); 461s x5 = invginv (p, 3, 1); 461s plot (p, x1, "-b", p, x2, "-g", p, x3, "-r", p, x4, "-c", p, x5, "-y") 461s grid on 461s ylim ([0, 3]) 461s legend ({"μ = 1, σ = 0.2", "μ = 1, σ = 1", "μ = 1, σ = 3", ... 461s "μ = 3, σ = 0.2", "μ = 3, σ = 1"}, "location", "northwest") 461s title ("Inverse Gaussian iCDF") 461s xlabel ("probability") 461s ylabel ("x") 461s ***** shared p, x 461s p = [0, 0.3829, 0.6827, 1]; 461s x = [0, 0.5207, 1.0376, Inf]; 461s ***** assert (invginv (p, 1, 1), x, 1e-4); 461s ***** assert (invginv (p, 1, ones (1,4)), x, 1e-4); 461s ***** assert (invginv (p, 1, [-1, 0, 1, 1]), [NaN, NaN, x(3:4)], 1e-4) 461s ***** assert (invginv (p, [-1, 0, 1, 1], 1), [NaN, NaN, x(3:4)], 1e-4) 461s ***** assert (class (invginv (single ([p, NaN]), 0, 1)), "single") 461s ***** assert (class (invginv ([p, NaN], single (0), 1)), "single") 461s ***** assert (class (invginv ([p, NaN], 0, single (1))), "single") 461s ***** error invginv (1) 461s ***** error invginv (1, 2) 461s ***** error ... 461s invginv (1, ones (2), ones (3)) 461s ***** error ... 461s invginv (ones (2), 1, ones (3)) 461s ***** error ... 461s invginv (ones (2), ones (3), 1) 461s ***** error invginv (i, 2, 3) 461s ***** error invginv (1, i, 3) 461s ***** error invginv (1, 2, i) 461s 15 tests, 15 passed, 0 known failure, 0 skipped 461s [inst/dist_fun/geocdf.m] 461s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/geocdf.m 461s ***** demo 461s ## Plot various CDFs from the geometric distribution 461s x = 0:10; 461s p1 = geocdf (x, 0.2); 461s p2 = geocdf (x, 0.5); 461s p3 = geocdf (x, 0.7); 461s plot (x, p1, "*b", x, p2, "*g", x, p3, "*r") 461s grid on 461s xlim ([0, 10]) 461s legend ({"ps = 0.2", "ps = 0.5", "ps = 0.7"}, "location", "southeast") 461s title ("Geometric CDF") 461s xlabel ("values in x (number of failures)") 461s ylabel ("probability") 461s ***** test 461s p = geocdf ([1, 2, 3, 4], 0.25); 461s assert (p(1), 0.4375000000, 1e-14); 461s assert (p(2), 0.5781250000, 1e-14); 461s assert (p(3), 0.6835937500, 1e-14); 461s assert (p(4), 0.7626953125, 1e-14); 461s ***** test 461s p = geocdf ([1, 2, 3, 4], 0.25, "upper"); 461s assert (p(1), 0.5625000000, 1e-14); 461s assert (p(2), 0.4218750000, 1e-14); 461s assert (p(3), 0.3164062500, 1e-14); 461s assert (p(4), 0.2373046875, 1e-14); 461s ***** shared x, p 461s x = [-1 0 1 Inf]; 461s p = [0 0.5 0.75 1]; 461s ***** assert (geocdf (x, 0.5*ones (1,4)), p) 461s ***** assert (geocdf (x, 0.5), p) 461s ***** assert (geocdf (x, 0.5*[-1 NaN 4 1]), [NaN NaN NaN p(4)]) 461s ***** assert (geocdf ([x(1:2) NaN x(4)], 0.5), [p(1:2) NaN p(4)]) 461s ***** assert (geocdf ([x, NaN], 0.5), [p, NaN]) 461s ***** assert (geocdf (single ([x, NaN]), 0.5), single ([p, NaN])) 461s ***** assert (geocdf ([x, NaN], single (0.5)), single ([p, NaN])) 461s ***** error geocdf () 461s ***** error geocdf (1) 461s ***** error ... 461s geocdf (ones (3), ones (2)) 461s ***** error ... 461s geocdf (ones (2), ones (3)) 461s ***** error geocdf (i, 2) 461s ***** error geocdf (2, i) 461s ***** error geocdf (2, 3, "tail") 461s ***** error geocdf (2, 3, 5) 461s 17 tests, 17 passed, 0 known failure, 0 skipped 461s [inst/dist_fun/bisacdf.m] 461s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/bisacdf.m 461s ***** demo 461s ## Plot various CDFs from the Birnbaum-Saunders distribution 461s x = 0.01:0.01:4; 461s p1 = bisacdf (x, 1, 0.5); 461s p2 = bisacdf (x, 1, 1); 461s p3 = bisacdf (x, 1, 2); 461s p4 = bisacdf (x, 1, 5); 461s p5 = bisacdf (x, 1, 10); 461s plot (x, p1, "-b", x, p2, "-g", x, p3, "-r", x, p4, "-c", x, p5, "-m") 461s grid on 461s legend ({"β = 1, γ = 0.5", "β = 1, γ = 1", "β = 1, γ = 2", ... 461s "β = 1, γ = 5", "β = 1, γ = 10"}, "location", "southeast") 461s title ("Birnbaum-Saunders CDF") 461s xlabel ("values in x") 461s ylabel ("probability") 461s ***** demo 461s ## Plot various CDFs from the Birnbaum-Saunders distribution 461s x = 0.01:0.01:6; 461s p1 = bisacdf (x, 1, 0.3); 461s p2 = bisacdf (x, 2, 0.3); 461s p3 = bisacdf (x, 1, 0.5); 461s p4 = bisacdf (x, 3, 0.5); 461s p5 = bisacdf (x, 5, 0.5); 461s plot (x, p1, "-b", x, p2, "-g", x, p3, "-r", x, p4, "-c", x, p5, "-m") 461s grid on 461s legend ({"β = 1, γ = 0.3", "β = 2, γ = 0.3", "β = 1, γ = 0.5", ... 461s "β = 3, γ = 0.5", "β = 5, γ = 0.5"}, "location", "southeast") 461s title ("Birnbaum-Saunders CDF") 461s xlabel ("values in x") 461s ylabel ("probability") 461s ***** shared x, y 461s x = [-1, 0, 1, 2, Inf]; 461s y = [0, 0, 1/2, 0.76024993890652337, 1]; 461s ***** assert (bisacdf (x, ones (1,5), ones (1,5)), y, eps) 461s ***** assert (bisacdf (x, 1, 1), y, eps) 461s ***** assert (bisacdf (x, 1, ones (1,5)), y, eps) 461s ***** assert (bisacdf (x, ones (1,5), 1), y, eps) 461s ***** assert (bisacdf (x, 1, 1), y, eps) 461s ***** assert (bisacdf (x, 1, [1, 1, NaN, 1, 1]), [y(1:2), NaN, y(4:5)], eps) 461s ***** assert (bisacdf (x, [1, 1, NaN, 1, 1], 1), [y(1:2), NaN, y(4:5)], eps) 461s ***** assert (bisacdf ([x, NaN], 1, 1), [y, NaN], eps) 461s ***** assert (bisacdf (single ([x, NaN]), 1, 1), single ([y, NaN]), eps ("single")) 461s ***** assert (bisacdf ([x, NaN], 1, single (1)), single ([y, NaN]), eps ("single")) 461s ***** assert (bisacdf ([x, NaN], single (1), 1), single ([y, NaN]), eps ("single")) 461s ***** error bisacdf () 461s ***** error bisacdf (1) 461s ***** error bisacdf (1, 2) 461s ***** error ... 461s bisacdf (1, 2, 3, 4, 5) 461s ***** error bisacdf (1, 2, 3, "tail") 461s ***** error bisacdf (1, 2, 3, 4) 461s ***** error ... 461s bisacdf (ones (3), ones (2), ones(2)) 461s ***** error ... 461s bisacdf (ones (2), ones (3), ones(2)) 461s ***** error ... 461s bisacdf (ones (2), ones (2), ones(3)) 461s ***** error bisacdf (i, 4, 3) 461s ***** error bisacdf (1, i, 3) 461s ***** error bisacdf (1, 4, i) 461s 23 tests, 23 passed, 0 known failure, 0 skipped 461s [inst/dist_fun/raylrnd.m] 461s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/raylrnd.m 461s ***** assert (size (raylrnd (2)), [1, 1]) 461s ***** assert (size (raylrnd (ones (2,1))), [2, 1]) 461s ***** assert (size (raylrnd (ones (2,2))), [2, 2]) 461s ***** assert (size (raylrnd (1, 3)), [3, 3]) 461s ***** assert (size (raylrnd (1, [4 1])), [4, 1]) 461s ***** assert (size (raylrnd (1, 4, 1)), [4, 1]) 461s ***** assert (size (raylrnd (1, 4, 1)), [4, 1]) 461s ***** assert (size (raylrnd (1, 4, 1, 5)), [4, 1, 5]) 461s ***** assert (size (raylrnd (1, 0, 1)), [0, 1]) 461s ***** assert (size (raylrnd (1, 1, 0)), [1, 0]) 461s ***** assert (size (raylrnd (1, 1, 2, 0, 5)), [1, 2, 0, 5]) 461s ***** assert (raylrnd (0, 1, 1), NaN) 461s ***** assert (raylrnd ([0, 0, 0], [1, 3]), [NaN, NaN, NaN]) 461s ***** assert (class (raylrnd (2)), "double") 461s ***** assert (class (raylrnd (single (2))), "single") 461s ***** assert (class (raylrnd (single ([2 2]))), "single") 461s ***** error raylrnd () 461s ***** error raylrnd (i) 461s ***** error ... 461s raylrnd (1, -1) 461s ***** error ... 461s raylrnd (1, 1.2) 461s ***** error ... 461s raylrnd (1, ones (2)) 461s ***** error ... 461s raylrnd (1, [2 -1 2]) 461s ***** error ... 461s raylrnd (1, [2 0 2.5]) 461s ***** error ... 461s raylrnd (ones (2), ones (2)) 461s ***** error ... 461s raylrnd (1, 2, -1, 5) 461s ***** error ... 461s raylrnd (1, 2, 1.5, 5) 461s ***** error raylrnd (ones (2,2), 3) 461s ***** error raylrnd (ones (2,2), [3, 2]) 461s ***** error raylrnd (ones (2,2), 2, 3) 461s 29 tests, 29 passed, 0 known failure, 0 skipped 461s [inst/dist_fun/jsucdf.m] 461s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/jsucdf.m 461s ***** error jsucdf () 461s ***** error jsucdf (1, 2, 3, 4) 461s ***** error ... 461s jsucdf (1, ones (2), ones (3)) 461s 3 tests, 3 passed, 0 known failure, 0 skipped 461s [inst/dist_fun/ncfcdf.m] 461s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/ncfcdf.m 461s ***** demo 461s ## Plot various CDFs from the noncentral F distribution 461s x = 0:0.01:5; 461s p1 = ncfcdf (x, 2, 5, 1); 461s p2 = ncfcdf (x, 2, 5, 2); 461s p3 = ncfcdf (x, 5, 10, 1); 461s p4 = ncfcdf (x, 10, 20, 10); 461s plot (x, p1, "-r", x, p2, "-g", x, p3, "-k", x, p4, "-m") 461s grid on 461s xlim ([0, 5]) 461s legend ({"df1 = 2, df2 = 5, λ = 1", "df1 = 2, df2 = 5, λ = 2", ... 461s "df1 = 5, df2 = 10, λ = 1", "df1 = 10, df2 = 20, λ = 10"}, ... 461s "location", "southeast") 461s title ("Noncentral F CDF") 461s xlabel ("values in x") 461s ylabel ("probability") 461s ***** demo 461s ## Compare the noncentral F CDF with LAMBDA = 10 to the F CDF with the 461s ## same number of numerator and denominator degrees of freedom (5, 20) 461s 461s x = 0.01:0.1:10.01; 461s p1 = ncfcdf (x, 5, 20, 10); 461s p2 = fcdf (x, 5, 20); 461s plot (x, p1, "-", x, p2, "-"); 461s grid on 461s xlim ([0, 10]) 461s legend ({"Noncentral F(5,20,10)", "F(5,20)"}, "location", "southeast") 461s title ("Noncentral F vs F CDFs") 461s xlabel ("values in x") 461s ylabel ("probability") 461s ***** test 461s x = -2:0.1:2; 461s p = ncfcdf (x, 10, 1, 3); 461s assert (p([1:21]), zeros (1, 21), 1e-76); 461s assert (p(22), 0.004530737275319753, 1e-14); 461s assert (p(30), 0.255842099135669, 1e-14); 461s assert (p(41), 0.4379890998457305, 1e-14); 462s ***** test 462s p = ncfcdf (12, 10, 3, 2); 462s assert (p, 0.9582287900447416, 1e-14); 462s ***** test 462s p = ncfcdf (2, 3, 2, 1); 462s assert (p, 0.5731985522994989, 1e-14); 462s ***** test 462s p = ncfcdf (2, 3, 2, 1, "upper"); 462s assert (p, 0.4268014477004823, 1e-14); 462s ***** test 462s p = ncfcdf ([3, 6], 3, 2, 5, "upper"); 462s assert (p, [0.530248523596927, 0.3350482341323044], 1e-14); 462s ***** error ncfcdf () 462s ***** error ncfcdf (1) 462s ***** error ncfcdf (1, 2) 462s ***** error ncfcdf (1, 2, 3) 462s ***** error ncfcdf (1, 2, 3, 4, "tail") 462s ***** error ncfcdf (1, 2, 3, 4, 5) 462s ***** error ... 462s ncfcdf (ones (3), ones (2), ones (2), ones (2)) 462s ***** error ... 462s ncfcdf (ones (2), ones (3), ones (2), ones (2)) 462s ***** error ... 462s ncfcdf (ones (2), ones (2), ones (3), ones (2)) 462s ***** error ... 462s ncfcdf (ones (2), ones (2), ones (2), ones (3)) 462s ***** error ncfcdf (i, 2, 2, 2) 462s ***** error ncfcdf (2, i, 2, 2) 462s ***** error ncfcdf (2, 2, i, 2) 462s ***** error ncfcdf (2, 2, 2, i) 462s 19 tests, 19 passed, 0 known failure, 0 skipped 462s [inst/dist_fun/burrcdf.m] 462s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/burrcdf.m 462s ***** demo 462s ## Plot various CDFs from the Burr type XII distribution 462s x = 0.001:0.001:5; 462s p1 = burrcdf (x, 1, 1, 1); 462s p2 = burrcdf (x, 1, 1, 2); 462s p3 = burrcdf (x, 1, 1, 3); 462s p4 = burrcdf (x, 1, 2, 1); 462s p5 = burrcdf (x, 1, 3, 1); 462s p6 = burrcdf (x, 1, 0.5, 2); 462s plot (x, p1, "-b", x, p2, "-g", x, p3, "-r", ... 462s x, p4, "-c", x, p5, "-m", x, p6, "-k") 462s grid on 462s legend ({"λ = 1, c = 1, k = 1", "λ = 1, c = 1, k = 2", ... 462s "λ = 1, c = 1, k = 3", "λ = 1, c = 2, k = 1", ... 462s "λ = 1, c = 3, k = 1", "λ = 1, c = 0.5, k = 2"}, ... 462s "location", "southeast") 462s title ("Burr type XII CDF") 462s xlabel ("values in x") 462s ylabel ("probability") 462s ***** shared x, y 462s x = [-1, 0, 1, 2, Inf]; 462s y = [0, 0, 1/2, 2/3, 1]; 462s ***** assert (burrcdf (x, ones(1,5), ones (1,5), ones (1,5)), y, eps) 462s ***** assert (burrcdf (x, 1, 1, 1), y, eps) 462s ***** assert (burrcdf (x, [1, 1, NaN, 1, 1], 1, 1), [y(1:2), NaN, y(4:5)], eps) 462s ***** assert (burrcdf (x, 1, [1, 1, NaN, 1, 1], 1), [y(1:2), NaN, y(4:5)], eps) 462s ***** assert (burrcdf (x, 1, 1, [1, 1, NaN, 1, 1]), [y(1:2), NaN, y(4:5)], eps) 462s ***** assert (burrcdf ([x, NaN], 1, 1, 1), [y, NaN], eps) 462s ***** assert (burrcdf (single ([x, NaN]), 1, 1, 1), single ([y, NaN]), eps("single")) 462s ***** assert (burrcdf ([x, NaN], single (1), 1, 1), single ([y, NaN]), eps("single")) 462s ***** assert (burrcdf ([x, NaN], 1, single (1), 1), single ([y, NaN]), eps("single")) 462s ***** assert (burrcdf ([x, NaN], 1, 1, single (1)), single ([y, NaN]), eps("single")) 462s ***** error burrcdf () 462s ***** error burrcdf (1) 462s ***** error burrcdf (1, 2) 462s ***** error burrcdf (1, 2, 3) 462s ***** error ... 462s burrcdf (1, 2, 3, 4, 5, 6) 462s ***** error burrcdf (1, 2, 3, 4, "tail") 462s ***** error burrcdf (1, 2, 3, 4, 5) 462s ***** error ... 462s burrcdf (ones (3), ones (2), ones(2), ones(2)) 462s ***** error ... 462s burrcdf (ones (2), ones (3), ones(2), ones(2)) 462s ***** error ... 462s burrcdf (ones (2), ones (2), ones(3), ones(2)) 462s ***** error ... 462s burrcdf (ones (2), ones (2), ones(2), ones(3)) 462s ***** error burrcdf (i, 2, 3, 4) 462s ***** error burrcdf (1, i, 3, 4) 462s ***** error burrcdf (1, 2, i, 4) 462s ***** error burrcdf (1, 2, 3, i) 462s 25 tests, 25 passed, 0 known failure, 0 skipped 462s [inst/dist_fun/hygernd.m] 462s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/hygernd.m 462s ***** assert (size (hygernd (4,2,2)), [1, 1]) 462s ***** assert (size (hygernd (4*ones (2,1), 2,2)), [2, 1]) 462s ***** assert (size (hygernd (4*ones (2,2), 2,2)), [2, 2]) 462s ***** assert (size (hygernd (4, 2*ones (2,1), 2)), [2, 1]) 462s ***** assert (size (hygernd (4, 2*ones (2,2), 2)), [2, 2]) 462s ***** assert (size (hygernd (4, 2, 2*ones (2,1))), [2, 1]) 462s ***** assert (size (hygernd (4, 2, 2*ones (2,2))), [2, 2]) 462s ***** assert (size (hygernd (4, 2, 2, 3)), [3, 3]) 462s ***** assert (size (hygernd (4, 2, 2, [4 1])), [4, 1]) 462s ***** assert (size (hygernd (4, 2, 2, 4, 1)), [4, 1]) 462s ***** assert (class (hygernd (4,2,2)), "double") 462s ***** assert (class (hygernd (single (4),2,2)), "single") 462s ***** assert (class (hygernd (single ([4 4]),2,2)), "single") 462s ***** assert (class (hygernd (4,single (2),2)), "single") 462s ***** assert (class (hygernd (4,single ([2 2]),2)), "single") 462s ***** assert (class (hygernd (4,2,single (2))), "single") 462s ***** assert (class (hygernd (4,2,single ([2 2]))), "single") 462s ***** error hygernd () 462s ***** error hygernd (1) 462s ***** error hygernd (1, 2) 462s ***** error ... 462s hygernd (ones (3), ones (2), ones (2)) 462s ***** error ... 462s hygernd (ones (2), ones (3), ones (2)) 462s ***** error ... 462s hygernd (ones (2), ones (2), ones (3)) 462s ***** error hygernd (i, 2, 3) 462s ***** error hygernd (1, i, 3) 462s ***** error hygernd (1, 2, i) 462s ***** error ... 462s hygernd (1, 2, 3, -1) 462s ***** error ... 462s hygernd (1, 2, 3, 1.2) 462s ***** error ... 462s hygernd (1, 2, 3, ones (2)) 462s ***** error ... 462s hygernd (1, 2, 3, [2 -1 2]) 462s ***** error ... 462s hygernd (1, 2, 3, [2 0 2.5]) 462s ***** error ... 462s hygernd (1, 2, 3, 2, -1, 5) 462s ***** error ... 462s hygernd (1, 2, 3, 2, 1.5, 5) 462s ***** error ... 462s hygernd (2, ones (2), 2, 3) 462s ***** error ... 462s hygernd (2, ones (2), 2, [3, 2]) 462s ***** error ... 462s hygernd (2, ones (2), 2, 3, 2) 462s 36 tests, 36 passed, 0 known failure, 0 skipped 462s [inst/dist_fun/betapdf.m] 462s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/betapdf.m 462s ***** demo 462s ## Plot various PDFs from the Beta distribution 462s x = 0.001:0.001:0.999; 462s y1 = betapdf (x, 0.5, 0.5); 462s y2 = betapdf (x, 5, 1); 462s y3 = betapdf (x, 1, 3); 462s y4 = betapdf (x, 2, 2); 462s y5 = betapdf (x, 2, 5); 462s plot (x, y1, "-b", x, y2, "-g", x, y3, "-r", x, y4, "-c", x, y5, "-m") 462s grid on 462s ylim ([0, 2.5]) 462s legend ({"α = β = 0.5", "α = 5, β = 1", "α = 1, β = 3", ... 462s "α = 2, β = 2", "α = 2, β = 5"}, "location", "north") 462s title ("Beta PDF") 462s xlabel ("values in x") 462s ylabel ("density") 462s ***** shared x, y 462s x = [-1 0 0.5 1 2]; 462s y = [0 2 1 0 0]; 462s ***** assert (betapdf (x, ones (1, 5), 2 * ones (1, 5)), y) 462s ***** assert (betapdf (x, 1, 2 * ones (1, 5)), y) 462s ***** assert (betapdf (x, ones (1, 5), 2), y) 462s ***** assert (betapdf (x, [0 NaN 1 1 1], 2), [NaN NaN y(3:5)]) 462s ***** assert (betapdf (x, 1, 2 * [0 NaN 1 1 1]), [NaN NaN y(3:5)]) 462s ***** assert (betapdf ([x, NaN], 1, 2), [y, NaN]) 462s ***** assert (betapdf (single ([x, NaN]), 1, 2), single ([y, NaN])) 462s ***** assert (betapdf ([x, NaN], single (1), 2), single ([y, NaN])) 462s ***** assert (betapdf ([x, NaN], 1, single (2)), single ([y, NaN])) 462s ***** test 462s x = rand (10,1); 462s y = 1 ./ (pi * sqrt (x .* (1 - x))); 462s assert (betapdf (x, 1/2, 1/2), y, 1e-12); 462s ***** assert (betapdf (0.5, 1000, 1000), 35.678, 1e-3) 462s ***** error betapdf () 462s ***** error betapdf (1) 462s ***** error betapdf (1,2) 462s ***** error betapdf (1,2,3,4) 462s ***** error ... 462s betapdf (ones (3), ones (2), ones (2)) 462s ***** error ... 462s betapdf (ones (2), ones (3), ones (2)) 462s ***** error ... 462s betapdf (ones (2), ones (2), ones (3)) 462s ***** error betapdf (i, 2, 2) 462s ***** error betapdf (2, i, 2) 462s ***** error betapdf (2, 2, i) 462s 21 tests, 21 passed, 0 known failure, 0 skipped 462s [inst/dist_fun/poisscdf.m] 462s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/poisscdf.m 462s ***** demo 462s ## Plot various CDFs from the Poisson distribution 462s x = 0:20; 462s p1 = poisscdf (x, 1); 462s p2 = poisscdf (x, 4); 462s p3 = poisscdf (x, 10); 462s plot (x, p1, "*b", x, p2, "*g", x, p3, "*r") 462s grid on 462s ylim ([0, 1]) 462s legend ({"λ = 1", "λ = 4", "λ = 10"}, "location", "southeast") 462s title ("Poisson CDF") 462s xlabel ("values in x (number of occurences)") 462s ylabel ("probability") 462s ***** shared x, y 462s x = [-1 0 1 2 Inf]; 462s y = [0, gammainc(1, (x(2:4) +1), "upper"), 1]; 462s ***** assert (poisscdf (x, ones (1,5)), y) 462s ***** assert (poisscdf (x, 1), y) 462s ***** assert (poisscdf (x, [1 0 NaN 1 1]), [y(1) 1 NaN y(4:5)]) 462s ***** assert (poisscdf ([x(1:2) NaN Inf x(5)], 1), [y(1:2) NaN 1 y(5)]) 462s ***** assert (poisscdf ([x, NaN], 1), [y, NaN]) 462s ***** assert (poisscdf (single ([x, NaN]), 1), single ([y, NaN]), eps ("single")) 462s ***** assert (poisscdf ([x, NaN], single (1)), single ([y, NaN]), eps ("single")) 462s ***** error poisscdf () 462s ***** error poisscdf (1) 462s ***** error poisscdf (1, 2, 3) 462s ***** error poisscdf (1, 2, "tail") 462s ***** error ... 462s poisscdf (ones (3), ones (2)) 462s ***** error ... 462s poisscdf (ones (2), ones (3)) 462s ***** error poisscdf (i, 2) 462s ***** error poisscdf (2, i) 462s 15 tests, 15 passed, 0 known failure, 0 skipped 462s [inst/dist_fun/wishrnd.m] 462s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/wishrnd.m 462s ***** assert(size (wishrnd (1,2)), [1, 1]); 462s ***** assert(size (wishrnd (1,2,[])), [1, 1]); 462s ***** assert(size (wishrnd (1,2,1)), [1, 1]); 462s ***** assert(size (wishrnd ([],2,1)), [1, 1]); 462s ***** assert(size (wishrnd ([3 1; 1 3], 2.00001, [], 1)), [2, 2]); 462s ***** assert(size (wishrnd (eye(2), 2, [], 3)), [2, 2, 3]); 462s ***** error wishrnd () 462s ***** error wishrnd (1) 462s ***** error wishrnd ([1; 1], 2) 462s 9 tests, 9 passed, 0 known failure, 0 skipped 462s [inst/dist_fun/chi2inv.m] 462s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/chi2inv.m 462s ***** demo 462s ## Plot various iCDFs from the chi-squared distribution 462s p = 0.001:0.001:0.999; 462s x1 = chi2inv (p, 1); 462s x2 = chi2inv (p, 2); 462s x3 = chi2inv (p, 3); 462s x4 = chi2inv (p, 4); 462s x5 = chi2inv (p, 6); 462s x6 = chi2inv (p, 9); 462s plot (p, x1, "-b", p, x2, "-g", p, x3, "-r", ... 462s p, x4, "-c", p, x5, "-m", p, x6, "-y") 462s grid on 462s ylim ([0, 8]) 462s legend ({"df = 1", "df = 2", "df = 3", ... 462s "df = 4", "df = 6", "df = 9"}, "location", "northwest") 462s title ("Chi-squared iCDF") 462s xlabel ("probability") 462s ylabel ("values in x") 462s ***** shared p 462s p = [-1 0 0.3934693402873666 1 2]; 462s ***** assert (chi2inv (p, 2*ones (1,5)), [NaN 0 1 Inf NaN], 5*eps) 462s ***** assert (chi2inv (p, 2), [NaN 0 1 Inf NaN], 5*eps) 462s ***** assert (chi2inv (p, 2*[0 1 NaN 1 1]), [NaN 0 NaN Inf NaN], 5*eps) 462s ***** assert (chi2inv ([p(1:2) NaN p(4:5)], 2), [NaN 0 NaN Inf NaN], 5*eps) 462s ***** assert (chi2inv ([p, NaN], 2), [NaN 0 1 Inf NaN NaN], 5*eps) 462s ***** assert (chi2inv (single ([p, NaN]), 2), single ([NaN 0 1 Inf NaN NaN]), 5*eps ("single")) 462s ***** assert (chi2inv ([p, NaN], single (2)), single ([NaN 0 1 Inf NaN NaN]), 5*eps ("single")) 462s ***** error chi2inv () 462s ***** error chi2inv (1) 462s ***** error chi2inv (1,2,3) 462s ***** error ... 462s chi2inv (ones (3), ones (2)) 462s ***** error ... 462s chi2inv (ones (2), ones (3)) 462s ***** error chi2inv (i, 2) 462s ***** error chi2inv (2, i) 462s 14 tests, 14 passed, 0 known failure, 0 skipped 462s [inst/dist_fun/plrnd.m] 462s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/plrnd.m 462s ***** shared x, Fx 462s x = [0, 1, 3, 4, 7, 10]; 462s Fx = [0, 0.2, 0.5, 0.6, 0.7, 1]; 462s ***** assert (size (plrnd (x, Fx)), [1, 1]) 462s ***** assert (size (plrnd (x, Fx, 3)), [3, 3]) 462s ***** assert (size (plrnd (x, Fx, [4, 1])), [4, 1]) 462s ***** assert (size (plrnd (x, Fx, 4, 1)), [4, 1]) 462s ***** assert (size (plrnd (x, Fx, 4, 1, 5)), [4, 1, 5]) 462s ***** assert (size (plrnd (x, Fx, 0, 1)), [0, 1]) 462s ***** assert (size (plrnd (x, Fx, 1, 0)), [1, 0]) 462s ***** assert (size (plrnd (x, Fx, 1, 2, 0, 5)), [1, 2, 0, 5]) 462s ***** assert (class (plrnd (x, Fx)), "double") 462s ***** assert (class (plrnd (x, single (Fx))), "single") 462s ***** assert (class (plrnd (single (x), Fx)), "single") 462s ***** error plrnd () 462s ***** error plrnd (1) 462s ***** error ... 462s plrnd ([0, 1, 2], [0, 1]) 462s ***** error ... 462s plrnd ([0], [1]) 462s ***** error ... 462s plrnd ([0, 1, 2], [0, 1, 1.5]) 462s ***** error ... 462s plrnd ([0, 1, 2], [0, i, 1]) 462s ***** error ... 462s plrnd ([0, i, 2], [0, 0.5, 1]) 462s ***** error ... 462s plrnd ([0, i, 2], [0, 0.5i, 1]) 462s ***** error ... 462s plrnd (x, Fx, -1) 462s ***** error ... 462s plrnd (x, Fx, 1.2) 463s ***** error ... 463s plrnd (x, Fx, ones (2)) 463s ***** error ... 463s plrnd (x, Fx, [2 -1 2]) 463s ***** error ... 463s plrnd (x, Fx, [2 0 2.5]) 463s ***** error ... 463s plrnd (x, Fx, 2, -1, 5) 463s ***** error ... 463s plrnd (x, Fx, 2, 1.5, 5) 463s 26 tests, 26 passed, 0 known failure, 0 skipped 463s [inst/dist_fun/wienrnd.m] 463s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/wienrnd.m 463s ***** error wienrnd (0) 463s ***** error wienrnd (1, 3, -50) 463s ***** error wienrnd (5, 0) 463s ***** error wienrnd (0.4, 3, 5) 463s ***** error wienrnd ([1 4], 3, 5) 463s 5 tests, 5 passed, 0 known failure, 0 skipped 463s [inst/dist_fun/gumbelrnd.m] 463s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/gumbelrnd.m 463s ***** assert (size (gumbelrnd (1, 1)), [1 1]) 463s ***** assert (size (gumbelrnd (1, ones (2,1))), [2, 1]) 463s ***** assert (size (gumbelrnd (1, ones (2,2))), [2, 2]) 463s ***** assert (size (gumbelrnd (ones (2,1), 1)), [2, 1]) 463s ***** assert (size (gumbelrnd (ones (2,2), 1)), [2, 2]) 463s ***** assert (size (gumbelrnd (1, 1, 3)), [3, 3]) 463s ***** assert (size (gumbelrnd (1, 1, [4, 1])), [4, 1]) 463s ***** assert (size (gumbelrnd (1, 1, 4, 1)), [4, 1]) 463s ***** assert (size (gumbelrnd (1, 1, 4, 1, 5)), [4, 1, 5]) 463s ***** assert (size (gumbelrnd (1, 1, 0, 1)), [0, 1]) 463s ***** assert (size (gumbelrnd (1, 1, 1, 0)), [1, 0]) 463s ***** assert (size (gumbelrnd (1, 1, 1, 2, 0, 5)), [1, 2, 0, 5]) 463s ***** assert (class (gumbelrnd (1, 1)), "double") 463s ***** assert (class (gumbelrnd (1, single (1))), "single") 463s ***** assert (class (gumbelrnd (1, single ([1, 1]))), "single") 463s ***** assert (class (gumbelrnd (single (1), 1)), "single") 463s ***** assert (class (gumbelrnd (single ([1, 1]), 1)), "single") 463s ***** error gumbelrnd () 463s ***** error gumbelrnd (1) 463s ***** error ... 463s gumbelrnd (ones (3), ones (2)) 463s ***** error ... 463s gumbelrnd (ones (2), ones (3)) 463s ***** error gumbelrnd (i, 2, 3) 463s ***** error gumbelrnd (1, i, 3) 463s ***** error ... 463s gumbelrnd (1, 2, -1) 463s ***** error ... 463s gumbelrnd (1, 2, 1.2) 463s ***** error ... 463s gumbelrnd (1, 2, ones (2)) 463s ***** error ... 463s gumbelrnd (1, 2, [2 -1 2]) 463s ***** error ... 463s gumbelrnd (1, 2, [2 0 2.5]) 463s ***** error ... 463s gumbelrnd (1, 2, 2, -1, 5) 463s ***** error ... 463s gumbelrnd (1, 2, 2, 1.5, 5) 463s ***** error ... 463s gumbelrnd (2, ones (2), 3) 463s ***** error ... 463s gumbelrnd (2, ones (2), [3, 2]) 463s ***** error ... 463s gumbelrnd (2, ones (2), 3, 2) 463s 33 tests, 33 passed, 0 known failure, 0 skipped 463s [inst/dist_fun/norminv.m] 463s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/norminv.m 463s ***** demo 463s ## Plot various iCDFs from the normal distribution 463s p = 0.001:0.001:0.999; 463s x1 = norminv (p, 0, 0.5); 463s x2 = norminv (p, 0, 1); 463s x3 = norminv (p, 0, 2); 463s x4 = norminv (p, -2, 0.8); 463s plot (p, x1, "-b", p, x2, "-g", p, x3, "-r", p, x4, "-c") 463s grid on 463s ylim ([-5, 5]) 463s legend ({"μ = 0, σ = 0.5", "μ = 0, σ = 1", ... 463s "μ = 0, σ = 2", "μ = -2, σ = 0.8"}, "location", "northwest") 463s title ("Normal iCDF") 463s xlabel ("probability") 463s ylabel ("values in x") 463s ***** shared p 463s p = [-1 0 0.5 1 2]; 463s ***** assert (norminv (p, ones (1,5), ones (1,5)), [NaN -Inf 1 Inf NaN]) 463s ***** assert (norminv (p, 1, ones (1,5)), [NaN -Inf 1 Inf NaN]) 463s ***** assert (norminv (p, ones (1,5), 1), [NaN -Inf 1 Inf NaN]) 463s ***** assert (norminv (p, [1 -Inf NaN Inf 1], 1), [NaN NaN NaN NaN NaN]) 463s ***** assert (norminv (p, 1, [1 0 NaN Inf 1]), [NaN NaN NaN NaN NaN]) 463s ***** assert (norminv ([p(1:2) NaN p(4:5)], 1, 1), [NaN -Inf NaN Inf NaN]) 463s ***** assert (norminv (p), probit (p)) 463s ***** assert (norminv (0.31254), probit (0.31254)) 463s ***** assert (norminv ([p, NaN], 1, 1), [NaN -Inf 1 Inf NaN NaN]) 463s ***** assert (norminv (single ([p, NaN]), 1, 1), single ([NaN -Inf 1 Inf NaN NaN])) 463s ***** assert (norminv ([p, NaN], single (1), 1), single ([NaN -Inf 1 Inf NaN NaN])) 463s ***** assert (norminv ([p, NaN], 1, single (1)), single ([NaN -Inf 1 Inf NaN NaN])) 463s ***** error norminv () 463s ***** error ... 463s norminv (ones (3), ones (2), ones (2)) 463s ***** error ... 463s norminv (ones (2), ones (3), ones (2)) 463s ***** error ... 463s norminv (ones (2), ones (2), ones (3)) 463s ***** error norminv (i, 2, 2) 463s ***** error norminv (2, i, 2) 463s ***** error norminv (2, 2, i) 463s 19 tests, 19 passed, 0 known failure, 0 skipped 463s [inst/dist_fun/invgpdf.m] 463s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/invgpdf.m 463s ***** demo 463s ## Plot various PDFs from the inverse Gaussian distribution 463s x = 0:0.001:3; 463s y1 = invgpdf (x, 1, 0.2); 463s y2 = invgpdf (x, 1, 1); 463s y3 = invgpdf (x, 1, 3); 463s y4 = invgpdf (x, 3, 0.2); 463s y5 = invgpdf (x, 3, 1); 463s plot (x, y1, "-b", x, y2, "-g", x, y3, "-r", x, y4, "-c", x, y5, "-y") 463s grid on 463s xlim ([0, 3]) 463s ylim ([0, 3]) 463s legend ({"μ = 1, σ = 0.2", "μ = 1, σ = 1", "μ = 1, σ = 3", ... 463s "μ = 3, σ = 0.2", "μ = 3, σ = 1"}, "location", "northeast") 463s title ("Inverse Gaussian PDF") 463s xlabel ("values in x") 463s ylabel ("density") 463s ***** shared x, y 463s x = [-Inf, -1, 0, 1/2, 1, Inf]; 463s y = [0, 0, 0, 0.8788, 0.3989, 0]; 463s ***** assert (invgpdf ([x, NaN], 1, 1), [y, NaN], 1e-4) 463s ***** assert (invgpdf (x, 1, [-2, -1, 0, 1, 1, 1]), [nan(1,3), y([4:6])], 1e-4) 463s ***** assert (class (hncdf (single ([x, NaN]), 1, 1)), "single") 463s ***** assert (class (hncdf ([x, NaN], 1, single (1))), "single") 463s ***** assert (class (hncdf ([x, NaN], single (1), 1)), "single") 463s ***** error invgpdf () 463s ***** error invgpdf (1) 463s ***** error invgpdf (1, 2) 463s ***** error ... 463s invgpdf (1, ones (2), ones (3)) 463s ***** error ... 463s invgpdf (ones (2), 1, ones (3)) 463s ***** error ... 463s invgpdf (ones (2), ones (3), 1) 463s ***** error invgpdf (i, 2, 3) 463s ***** error invgpdf (1, i, 3) 463s ***** error invgpdf (1, 2, i) 463s 14 tests, 14 passed, 0 known failure, 0 skipped 463s [inst/dist_fun/unifrnd.m] 463s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/unifrnd.m 463s ***** assert (size (unifrnd (1, 1)), [1 1]) 463s ***** assert (size (unifrnd (1, ones (2,1))), [2, 1]) 463s ***** assert (size (unifrnd (1, ones (2,2))), [2, 2]) 463s ***** assert (size (unifrnd (ones (2,1), 1)), [2, 1]) 463s ***** assert (size (unifrnd (ones (2,2), 1)), [2, 2]) 463s ***** assert (size (unifrnd (1, 1, 3)), [3, 3]) 463s ***** assert (size (unifrnd (1, 1, [4, 1])), [4, 1]) 463s ***** assert (size (unifrnd (1, 1, 4, 1)), [4, 1]) 463s ***** assert (size (unifrnd (1, 1, 4, 1, 5)), [4, 1, 5]) 463s ***** assert (size (unifrnd (1, 1, 0, 1)), [0, 1]) 463s ***** assert (size (unifrnd (1, 1, 1, 0)), [1, 0]) 463s ***** assert (size (unifrnd (1, 1, 1, 2, 0, 5)), [1, 2, 0, 5]) 463s ***** assert (class (unifrnd (1, 1)), "double") 463s ***** assert (class (unifrnd (1, single (1))), "single") 463s ***** assert (class (unifrnd (1, single ([1, 1]))), "single") 463s ***** assert (class (unifrnd (single (1), 1)), "single") 463s ***** assert (class (unifrnd (single ([1, 1]), 1)), "single") 463s ***** error unifrnd () 463s ***** error unifrnd (1) 463s ***** error ... 463s unifrnd (ones (3), ones (2)) 463s ***** error ... 463s unifrnd (ones (2), ones (3)) 463s ***** error unifrnd (i, 2, 3) 463s ***** error unifrnd (1, i, 3) 463s ***** error ... 463s unifrnd (1, 2, -1) 463s ***** error ... 463s unifrnd (1, 2, 1.2) 463s ***** error ... 463s unifrnd (1, 2, ones (2)) 463s ***** error ... 463s unifrnd (1, 2, [2 -1 2]) 463s ***** error ... 463s unifrnd (1, 2, [2 0 2.5]) 463s ***** error ... 463s unifrnd (1, 2, 2, -1, 5) 463s ***** error ... 463s unifrnd (1, 2, 2, 1.5, 5) 463s ***** error ... 463s unifrnd (2, ones (2), 3) 463s ***** error ... 463s unifrnd (2, ones (2), [3, 2]) 463s ***** error ... 463s unifrnd (2, ones (2), 3, 2) 463s 33 tests, 33 passed, 0 known failure, 0 skipped 463s [inst/dist_fun/vmcdf.m] 463s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/vmcdf.m 463s ***** demo 463s ## Plot various CDFs from the von Mises distribution 463s x1 = [-pi:0.1:pi]; 463s p1 = vmcdf (x1, 0, 0.5); 463s p2 = vmcdf (x1, 0, 1); 463s p3 = vmcdf (x1, 0, 2); 463s p4 = vmcdf (x1, 0, 4); 463s plot (x1, p1, "-r", x1, p2, "-g", x1, p3, "-b", x1, p4, "-c") 463s grid on 463s xlim ([-pi, pi]) 463s legend ({"μ = 0, k = 0.5", "μ = 0, k = 1", ... 463s "μ = 0, k = 2", "μ = 0, k = 4"}, "location", "northwest") 463s title ("Von Mises CDF") 463s xlabel ("values in x") 463s ylabel ("probability") 463s ***** shared x, p0, p1 463s x = [-pi:pi/2:pi]; 463s p0 = [0, 0.10975, 0.5, 0.89025, 1]; 463s p1 = [0, 0.03752, 0.5, 0.99622, 1]; 463s ***** assert (vmcdf (x, 0, 1), p0, 1e-5) 463s ***** assert (vmcdf (x, 0, 1, "upper"), 1 - p0, 1e-5) 463s ***** assert (vmcdf (x, zeros (1,5), ones (1,5)), p0, 1e-5) 463s ***** assert (vmcdf (x, zeros (1,5), ones (1,5), "upper"), 1 - p0, 1e-5) 463s ***** assert (vmcdf (x, 0, [1 2 3 4 5]), p1, 1e-5) 463s ***** assert (vmcdf (x, 0, [1 2 3 4 5], "upper"), 1 - p1, 1e-5) 463s ***** assert (isa (vmcdf (single (pi), 0, 1), "single"), true) 464s ***** assert (isa (vmcdf (pi, single (0), 1), "single"), true) 464s ***** assert (isa (vmcdf (pi, 0, single (1)), "single"), true) 464s ***** error vmcdf () 464s ***** error vmcdf (1) 464s ***** error vmcdf (1, 2) 464s ***** error vmcdf (1, 2, 3, "tail") 464s ***** error vmcdf (1, 2, 3, 4) 464s ***** error ... 464s vmcdf (ones (3), ones (2), ones (2)) 464s ***** error ... 464s vmcdf (ones (2), ones (3), ones (2)) 464s ***** error ... 464s vmcdf (ones (2), ones (2), ones (3)) 464s ***** error vmcdf (i, 2, 2) 464s ***** error vmcdf (2, i, 2) 464s ***** error vmcdf (2, 2, i) 464s 20 tests, 20 passed, 0 known failure, 0 skipped 464s [inst/dist_fun/riceinv.m] 464s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/riceinv.m 464s ***** demo 464s ## Plot various iCDFs from the Rician distribution 464s p = 0.001:0.001:0.999; 464s x1 = riceinv (p, 0, 1); 464s x2 = riceinv (p, 0.5, 1); 464s x3 = riceinv (p, 1, 1); 464s x4 = riceinv (p, 2, 1); 464s x5 = riceinv (p, 4, 1); 464s plot (p, x1, "-b", p, x2, "-g", p, x3, "-r", p, x4, "-m", p, x5, "-k") 464s grid on 464s legend ({"s = 0, σ = 1", "s = 0.5, σ = 1", "s = 1, σ = 1", ... 464s "s = 2, σ = 1", "s = 4, σ = 1"}, "location", "northwest") 464s title ("Rician iCDF") 464s xlabel ("probability") 464s ylabel ("values in x") 464s ***** shared p 464s p = [-1 0 0.75 1 2]; 464s ***** assert (riceinv (p, ones (1,5), 2*ones (1,5)), [NaN 0 3.5354 Inf NaN], 1e-4) 464s ***** assert (riceinv (p, 1, 2*ones (1,5)), [NaN 0 3.5354 Inf NaN], 1e-4) 464s ***** assert (riceinv (p, ones (1,5), 2), [NaN 0 3.5354 Inf NaN], 1e-4) 464s ***** assert (riceinv (p, [1 0 NaN 1 1], 2), [NaN 0 NaN Inf NaN]) 464s ***** assert (riceinv (p, 1, 2*[1 0 NaN 1 1]), [NaN NaN NaN Inf NaN]) 464s ***** assert (riceinv ([p(1:2) NaN p(4:5)], 1, 2), [NaN 0 NaN Inf NaN]) 464s ***** assert (riceinv ([p, NaN], 1, 2), [NaN 0 3.5354 Inf NaN NaN], 1e-4) 464s ***** assert (riceinv (single ([p, NaN]), 1, 2), ... 464s single ([NaN 0 3.5354 Inf NaN NaN]), 1e-4) 464s ***** assert (riceinv ([p, NaN], single (1), 2), ... 464s single ([NaN 0 3.5354 Inf NaN NaN]), 1e-4) 464s ***** assert (riceinv ([p, NaN], 1, single (2)), ... 464s single ([NaN 0 3.5354 Inf NaN NaN]), 1e-4) 464s ***** error riceinv () 464s ***** error riceinv (1) 464s ***** error riceinv (1,2) 464s ***** error riceinv (1,2,3,4) 464s ***** error ... 464s riceinv (ones (3), ones (2), ones (2)) 464s ***** error ... 464s riceinv (ones (2), ones (3), ones (2)) 464s ***** error ... 464s riceinv (ones (2), ones (2), ones (3)) 464s ***** error riceinv (i, 2, 2) 464s ***** error riceinv (2, i, 2) 464s ***** error riceinv (2, 2, i) 464s 20 tests, 20 passed, 0 known failure, 0 skipped 464s [inst/dist_fun/expcdf.m] 464s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/expcdf.m 464s ***** demo 464s ## Plot various CDFs from the exponential distribution 464s x = 0:0.01:5; 464s p1 = expcdf (x, 2/3); 464s p2 = expcdf (x, 1.0); 464s p3 = expcdf (x, 2.0); 464s plot (x, p1, "-b", x, p2, "-g", x, p3, "-r") 464s grid on 464s legend ({"μ = 2/3", "μ = 1", "μ = 2"}, "location", "southeast") 464s title ("Exponential CDF") 464s xlabel ("values in x") 464s ylabel ("probability") 464s ***** shared x, p 464s x = [-1 0 0.5 1 Inf]; 464s p = [0, 1 - exp(-x(2:end)/2)]; 464s ***** assert (expcdf (x, 2 * ones (1, 5)), p, 1e-16) 464s ***** assert (expcdf (x, 2), p, 1e-16) 464s ***** assert (expcdf (x, 2 * [1, 0, NaN, 1, 1]), [0, NaN, NaN, p(4:5)], 1e-16) 464s ***** assert (expcdf ([x, NaN], 2), [p, NaN], 1e-16) 464s ***** assert (expcdf (single ([x, NaN]), 2), single ([p, NaN])) 464s ***** assert (expcdf ([x, NaN], single (2)), single ([p, NaN])) 464s ***** test 464s [p, plo, pup] = expcdf (1, 2, 3); 464s assert (p, 0.39346934028737, 1e-14); 464s assert (plo, 0.08751307220484, 1e-14); 464s assert (pup, 0.93476821257933, 1e-14); 464s ***** test 464s [p, plo, pup] = expcdf (1, 2, 2, 0.1); 464s assert (p, 0.39346934028737, 1e-14); 464s assert (plo, 0.14466318041675, 1e-14); 464s assert (pup, 0.79808291849140, 1e-14); 464s ***** test 464s [p, plo, pup] = expcdf (1, 2, 2, 0.1, "upper"); 464s assert (p, 0.60653065971263, 1e-14); 464s assert (plo, 0.20191708150860, 1e-14); 464s assert (pup, 0.85533681958325, 1e-14); 464s ***** error expcdf () 464s ***** error expcdf (1, 2 ,3 ,4 ,5, 6) 464s ***** error expcdf (1, 2, 3, 4, "uper") 464s ***** error ... 464s expcdf (ones (3), ones (2)) 464s ***** error ... 464s expcdf (2, 3, [1, 2]) 464s ***** error ... 464s [p, plo, pup] = expcdf (1, 2) 464s ***** error [p, plo, pup] = ... 464s expcdf (1, 2, 3, 0) 464s ***** error [p, plo, pup] = ... 464s expcdf (1, 2, 3, 1.22) 464s ***** error [p, plo, pup] = ... 464s expcdf (1, 2, 3, "alpha", "upper") 464s ***** error expcdf (i, 2) 464s ***** error expcdf (2, i) 464s ***** error ... 464s [p, plo, pup] = expcdf (1, 2, -1, 0.04) 464s 21 tests, 21 passed, 0 known failure, 0 skipped 464s [inst/dist_fun/nakarnd.m] 464s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/nakarnd.m 464s ***** assert (size (nakarnd (1, 1)), [1 1]) 464s ***** assert (size (nakarnd (1, ones (2,1))), [2, 1]) 464s ***** assert (size (nakarnd (1, ones (2,2))), [2, 2]) 464s ***** assert (size (nakarnd (ones (2,1), 1)), [2, 1]) 464s ***** assert (size (nakarnd (ones (2,2), 1)), [2, 2]) 464s ***** assert (size (nakarnd (1, 1, 3)), [3, 3]) 464s ***** assert (size (nakarnd (1, 1, [4, 1])), [4, 1]) 464s ***** assert (size (nakarnd (1, 1, 4, 1)), [4, 1]) 465s ***** assert (size (nakarnd (1, 1, 4, 1, 5)), [4, 1, 5]) 465s ***** assert (size (nakarnd (1, 1, 0, 1)), [0, 1]) 465s ***** assert (size (nakarnd (1, 1, 1, 0)), [1, 0]) 465s ***** assert (size (nakarnd (1, 1, 1, 2, 0, 5)), [1, 2, 0, 5]) 465s ***** assert (class (nakarnd (1, 1)), "double") 465s ***** assert (class (nakarnd (1, single (1))), "single") 465s ***** assert (class (nakarnd (1, single ([1, 1]))), "single") 465s ***** assert (class (nakarnd (single (1), 1)), "single") 465s ***** assert (class (nakarnd (single ([1, 1]), 1)), "single") 465s ***** error nakarnd () 465s ***** error nakarnd (1) 465s ***** error ... 465s nakarnd (ones (3), ones (2)) 465s ***** error ... 465s nakarnd (ones (2), ones (3)) 465s ***** error nakarnd (i, 2, 3) 465s ***** error nakarnd (1, i, 3) 465s ***** error ... 465s nakarnd (1, 2, -1) 465s ***** error ... 465s nakarnd (1, 2, 1.2) 465s ***** error ... 465s nakarnd (1, 2, ones (2)) 465s ***** error ... 465s nakarnd (1, 2, [2 -1 2]) 465s ***** error ... 465s nakarnd (1, 2, [2 0 2.5]) 465s ***** error ... 465s nakarnd (1, 2, 2, -1, 5) 465s ***** error ... 465s nakarnd (1, 2, 2, 1.5, 5) 465s ***** error ... 465s nakarnd (2, ones (2), 3) 465s ***** error ... 465s nakarnd (2, ones (2), [3, 2]) 465s ***** error ... 465s nakarnd (2, ones (2), 3, 2) 465s 33 tests, 33 passed, 0 known failure, 0 skipped 465s [inst/dist_fun/poissinv.m] 465s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/poissinv.m 465s ***** demo 465s ## Plot various iCDFs from the Poisson distribution 465s p = 0.001:0.001:0.999; 465s x1 = poissinv (p, 13); 465s x2 = poissinv (p, 4); 465s x3 = poissinv (p, 10); 465s plot (p, x1, "-b", p, x2, "-g", p, x3, "-r") 465s grid on 465s ylim ([0, 20]) 465s legend ({"λ = 1", "λ = 4", "λ = 10"}, "location", "northwest") 465s title ("Poisson iCDF") 465s xlabel ("probability") 465s ylabel ("values in x (number of occurences)") 465s ***** shared p 465s p = [-1 0 0.5 1 2]; 465s ***** assert (poissinv (p, ones (1,5)), [NaN 0 1 Inf NaN]) 465s ***** assert (poissinv (p, 1), [NaN 0 1 Inf NaN]) 465s ***** assert (poissinv (p, [1 0 NaN 1 1]), [NaN NaN NaN Inf NaN]) 465s ***** assert (poissinv ([p(1:2) NaN p(4:5)], 1), [NaN 0 NaN Inf NaN]) 465s ***** assert (poissinv ([p, NaN], 1), [NaN 0 1 Inf NaN NaN]) 465s ***** assert (poissinv (single ([p, NaN]), 1), single ([NaN 0 1 Inf NaN NaN])) 465s ***** assert (poissinv ([p, NaN], single (1)), single ([NaN 0 1 Inf NaN NaN])) 465s ***** error poissinv () 465s ***** error poissinv (1) 465s ***** error ... 465s poissinv (ones (3), ones (2)) 465s ***** error ... 465s poissinv (ones (2), ones (3)) 465s ***** error poissinv (i, 2) 465s ***** error poissinv (2, i) 465s 13 tests, 13 passed, 0 known failure, 0 skipped 465s [inst/dist_fun/mvtrnd.m] 465s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/mvtrnd.m 465s ***** test 465s rho = [1, 0.5; 0.5, 1]; 465s df = 3; 465s n = 10; 465s r = mvtrnd (rho, df, n); 465s assert (size (r), [10, 2]); 465s ***** test 465s rho = [1, 0.5; 0.5, 1]; 465s df = [2; 3]; 465s n = 2; 465s r = mvtrnd (rho, df, 2); 465s assert (size (r), [2, 2]); 465s 2 tests, 2 passed, 0 known failure, 0 skipped 465s [inst/dist_fun/hygepdf.m] 465s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/hygepdf.m 465s ***** demo 465s ## Plot various PDFs from the hypergeometric distribution 465s x = 0:60; 465s y1 = hygepdf (x, 500, 50, 100); 465s y2 = hygepdf (x, 500, 60, 200); 465s y3 = hygepdf (x, 500, 70, 300); 465s plot (x, y1, "*b", x, y2, "*g", x, y3, "*r") 465s grid on 465s xlim ([0, 60]) 465s ylim ([0, 0.18]) 465s legend ({"m = 500, k = 50, μ = 100", "m = 500, k = 60, μ = 200", ... 465s "m = 500, k = 70, μ = 300"}, "location", "northeast") 465s title ("Hypergeometric PDF") 465s xlabel ("values in x (number of successes)") 465s ylabel ("density") 465s ***** shared x, y 465s x = [-1 0 1 2 3]; 465s y = [0 1/6 4/6 1/6 0]; 465s ***** assert (hygepdf (x, 4 * ones (1, 5), 2, 2), y, 3 * eps) 465s ***** assert (hygepdf (x, 4, 2 * ones (1, 5), 2), y, 3 * eps) 465s ***** assert (hygepdf (x, 4, 2, 2 * ones (1, 5)), y, 3 * eps) 465s ***** assert (hygepdf (x, 4 * [1, -1, NaN, 1.1, 1], 2, 2), [0, NaN, NaN, NaN, 0]) 465s ***** assert (hygepdf (x, 4, 2 * [1, -1, NaN, 1.1, 1], 2), [0, NaN, NaN, NaN, 0]) 465s ***** assert (hygepdf (x, 4, 5, 2), [NaN, NaN, NaN, NaN, NaN], 3 * eps) 465s ***** assert (hygepdf (x, 4, 2, 2 * [1, -1, NaN, 1.1, 1]), [0, NaN, NaN, NaN, 0]) 465s ***** assert (hygepdf (x, 4, 2, 5), [NaN, NaN, NaN, NaN, NaN], 3 * eps) 465s ***** assert (hygepdf ([x, NaN], 4, 2, 2), [y, NaN], 3 * eps) 465s ***** assert (hygepdf (single ([x, NaN]), 4, 2, 2), single ([y, NaN]), eps ("single")) 465s ***** assert (hygepdf ([x, NaN], single (4), 2, 2), single ([y, NaN]), eps ("single")) 465s ***** assert (hygepdf ([x, NaN], 4, single (2), 2), single ([y, NaN]), eps ("single")) 465s ***** assert (hygepdf ([x, NaN], 4, 2, single (2)), single ([y, NaN]), eps ("single")) 465s ***** test 465s z = zeros(3,5); 465s z([4,5,6,8,9,12]) = [1, 0.5, 1/6, 0.5, 2/3, 1/6]; 465s assert (hygepdf (x, 4, [0, 1, 2], 2, "vectorexpand"), z, 3 * eps); 465s assert (hygepdf (x, 4, [0, 1, 2]', 2, "vectorexpand"), z, 3 * eps); 465s assert (hygepdf (x', 4, [0, 1, 2], 2, "vectorexpand"), z, 3 * eps); 465s assert (hygepdf (2, 4, [0 ,1, 2], 2, "vectorexpand"), z(:,4), 3 * eps); 465s assert (hygepdf (x, 4, 1, 2, "vectorexpand"), z(2,:), 3 *eps); 465s assert (hygepdf ([NaN, x], 4, [0 1 2]', 2, "vectorexpand"), [NaN(3, 1), z], 3 * eps); 465s ***** error hygepdf () 465s ***** error hygepdf (1) 465s ***** error hygepdf (1,2) 465s ***** error hygepdf (1,2,3) 465s ***** error ... 465s hygepdf (1, ones (3), ones (2), ones (2)) 465s ***** error ... 465s hygepdf (1, ones (2), ones (3), ones (2)) 465s ***** error ... 465s hygepdf (1, ones (2), ones (2), ones (3)) 465s ***** error hygepdf (i, 2, 2, 2) 465s ***** error hygepdf (2, i, 2, 2) 465s ***** error hygepdf (2, 2, i, 2) 465s ***** error hygepdf (2, 2, 2, i) 465s 25 tests, 25 passed, 0 known failure, 0 skipped 465s [inst/dist_fun/wblpdf.m] 465s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/wblpdf.m 465s ***** demo 465s ## Plot various PDFs from the Weibul distribution 465s x = 0:0.001:2.5; 465s y1 = wblpdf (x, 1, 0.5); 465s y2 = wblpdf (x, 1, 1); 465s y3 = wblpdf (x, 1, 1.5); 465s y4 = wblpdf (x, 1, 5); 465s plot (x, y1, "-b", x, y2, "-r", x, y3, "-m", x, y4, "-g") 465s grid on 465s ylim ([0, 2.5]) 465s legend ({"λ = 5, k = 0.5", "λ = 9, k = 1", ... 465s "λ = 6, k = 1.5", "λ = 2, k = 5"}, "location", "northeast") 465s title ("Weibul PDF") 465s xlabel ("values in x") 465s ylabel ("density") 465s ***** shared x,y 465s x = [-1 0 0.5 1 Inf]; 465s y = [0, exp(-x(2:4)), NaN]; 465s ***** assert (wblpdf (x, ones (1,5), ones (1,5)), y) 465s ***** assert (wblpdf (x, 1, ones (1,5)), y) 465s ***** assert (wblpdf (x, ones (1,5), 1), y) 465s ***** assert (wblpdf (x, [0 NaN Inf 1 1], 1), [NaN NaN NaN y(4:5)]) 465s ***** assert (wblpdf (x, 1, [0 NaN Inf 1 1]), [NaN NaN NaN y(4:5)]) 465s ***** assert (wblpdf ([x, NaN], 1, 1), [y, NaN]) 465s ***** assert (wblpdf (single ([x, NaN]), 1, 1), single ([y, NaN])) 465s ***** assert (wblpdf ([x, NaN], single (1), 1), single ([y, NaN])) 465s ***** assert (wblpdf ([x, NaN], 1, single (1)), single ([y, NaN])) 465s ***** error wblpdf () 465s ***** error wblpdf (1,2,3,4) 465s ***** error wblpdf (ones (3), ones (2), ones (2)) 465s ***** error wblpdf (ones (2), ones (3), ones (2)) 465s ***** error wblpdf (ones (2), ones (2), ones (3)) 465s ***** error wblpdf (i, 2, 2) 465s ***** error wblpdf (2, i, 2) 465s ***** error wblpdf (2, 2, i) 465s 17 tests, 17 passed, 0 known failure, 0 skipped 465s [inst/dist_fun/mvtcdfqmc.m] 465s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/mvtcdfqmc.m 465s ***** error mvtcdfqmc (1, 2, 3); 465s ***** error mvtcdfqmc (1, 2, 3, 4, 5, 6, 7, 8); 465s 2 tests, 2 passed, 0 known failure, 0 skipped 465s [inst/dist_fun/unidrnd.m] 465s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/unidrnd.m 465s ***** assert (size (unidrnd (2)), [1, 1]) 465s ***** assert (size (unidrnd (ones (2,1))), [2, 1]) 465s ***** assert (size (unidrnd (ones (2,2))), [2, 2]) 465s ***** assert (size (unidrnd (1, 3)), [3, 3]) 465s ***** assert (size (unidrnd (1, [4 1])), [4, 1]) 465s ***** assert (size (unidrnd (1, 4, 1)), [4, 1]) 465s ***** assert (size (unidrnd (1, 4, 1)), [4, 1]) 465s ***** assert (size (unidrnd (1, 4, 1, 5)), [4, 1, 5]) 465s ***** assert (size (unidrnd (1, 0, 1)), [0, 1]) 465s ***** assert (size (unidrnd (1, 1, 0)), [1, 0]) 465s ***** assert (size (unidrnd (1, 1, 2, 0, 5)), [1, 2, 0, 5]) 465s ***** assert (unidrnd (0, 1, 1), NaN) 465s ***** assert (unidrnd ([0, 0, 0], [1, 3]), [NaN, NaN, NaN]) 465s ***** assert (class (unidrnd (2)), "double") 465s ***** assert (class (unidrnd (single (2))), "single") 465s ***** assert (class (unidrnd (single ([2 2]))), "single") 465s ***** error unidrnd () 465s ***** error unidrnd (i) 465s ***** error ... 465s unidrnd (1, -1) 465s ***** error ... 465s unidrnd (1, 1.2) 465s ***** error ... 465s unidrnd (1, ones (2)) 465s ***** error ... 465s unidrnd (1, [2 -1 2]) 465s ***** error ... 465s unidrnd (1, [2 0 2.5]) 465s ***** error ... 465s unidrnd (ones (2), ones (2)) 465s ***** error ... 465s unidrnd (1, 2, -1, 5) 465s ***** error ... 465s unidrnd (1, 2, 1.5, 5) 465s ***** error unidrnd (ones (2,2), 3) 465s ***** error unidrnd (ones (2,2), [3, 2]) 465s ***** error unidrnd (ones (2,2), 2, 3) 465s 29 tests, 29 passed, 0 known failure, 0 skipped 465s [inst/dist_fun/mnrnd.m] 465s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/mnrnd.m 465s ***** test 465s n = 10; 465s pk = [0.2, 0.5, 0.3]; 465s r = mnrnd (n, pk); 465s assert (size (r), size (pk)); 465s assert (all (r >= 0)); 465s assert (all (round (r) == r)); 465s assert (sum (r) == n); 465s ***** test 465s n = 10 * ones (3, 1); 465s pk = [0.2, 0.5, 0.3]; 465s r = mnrnd (n, pk); 465s assert (size (r), [length(n), length(pk)]); 465s assert (all (r >= 0)); 465s assert (all (round (r) == r)); 465s assert (all (sum (r, 2) == n)); 465s ***** test 465s n = (1:2)'; 465s pk = [0.2, 0.5, 0.3; 0.1, 0.1, 0.8]; 465s r = mnrnd (n, pk); 465s assert (size (r), size (pk)); 465s assert (all (r >= 0)); 465s assert (all (round (r) == r)); 465s assert (all (sum (r, 2) == n)); 465s 3 tests, 3 passed, 0 known failure, 0 skipped 465s [inst/dist_fun/bisarnd.m] 465s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/bisarnd.m 465s ***** assert (size (bisarnd (1, 1)), [1 1]) 465s ***** assert (size (bisarnd (1, ones (2,1))), [2, 1]) 465s ***** assert (size (bisarnd (1, ones (2,2))), [2, 2]) 465s ***** assert (size (bisarnd (ones (2,1), 1)), [2, 1]) 465s ***** assert (size (bisarnd (ones (2,2), 1)), [2, 2]) 465s ***** assert (size (bisarnd (1, 1, 3)), [3, 3]) 465s ***** assert (size (bisarnd (1, 1, [4, 1])), [4, 1]) 465s ***** assert (size (bisarnd (1, 1, 4, 1)), [4, 1]) 465s ***** assert (size (bisarnd (1, 1, 4, 1, 5)), [4, 1, 5]) 465s ***** assert (size (bisarnd (1, 1, 0, 1)), [0, 1]) 465s ***** assert (size (bisarnd (1, 1, 1, 0)), [1, 0]) 465s ***** assert (size (bisarnd (1, 1, 1, 2, 0, 5)), [1, 2, 0, 5]) 465s ***** assert (class (bisarnd (1, 1)), "double") 465s ***** assert (class (bisarnd (1, single (1))), "single") 465s ***** assert (class (bisarnd (1, single ([1, 1]))), "single") 465s ***** assert (class (bisarnd (single (1), 1)), "single") 465s ***** assert (class (bisarnd (single ([1, 1]), 1)), "single") 465s ***** error bisarnd () 465s ***** error bisarnd (1) 465s ***** error ... 465s bisarnd (ones (3), ones (2)) 465s ***** error ... 465s bisarnd (ones (2), ones (3)) 465s ***** error bisarnd (i, 2, 3) 465s ***** error bisarnd (1, i, 3) 465s ***** error ... 465s bisarnd (1, 2, -1) 465s ***** error ... 465s bisarnd (1, 2, 1.2) 465s ***** error ... 465s bisarnd (1, 2, ones (2)) 465s ***** error ... 465s bisarnd (1, 2, [2 -1 2]) 465s ***** error ... 465s bisarnd (1, 2, [2 0 2.5]) 465s ***** error ... 465s bisarnd (1, 2, 2, -1, 5) 465s ***** error ... 465s bisarnd (1, 2, 2, 1.5, 5) 465s ***** error ... 465s bisarnd (2, ones (2), 3) 465s ***** error ... 465s bisarnd (2, ones (2), [3, 2]) 465s ***** error ... 465s bisarnd (2, ones (2), 3, 2) 465s 33 tests, 33 passed, 0 known failure, 0 skipped 465s [inst/dist_fun/lognpdf.m] 465s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/lognpdf.m 465s ***** demo 465s ## Plot various PDFs from the log-normal distribution 465s x = 0:0.01:5; 465s y1 = lognpdf (x, 0, 1); 465s y2 = lognpdf (x, 0, 0.5); 465s y3 = lognpdf (x, 0, 0.25); 465s plot (x, y1, "-b", x, y2, "-g", x, y3, "-r") 465s grid on 465s ylim ([0, 2]) 465s legend ({"μ = 0, σ = 1", "μ = 0, σ = 0.5", "μ = 0, σ = 0.25"}, ... 465s "location", "northeast") 465s title ("Log-normal PDF") 465s xlabel ("values in x") 465s ylabel ("density") 465s ***** shared x, y 465s x = [-1 0 e Inf]; 465s y = [0, 0, 1/(e*sqrt(2*pi)) * exp(-1/2), 0]; 465s ***** assert (lognpdf (x, zeros (1,4), ones (1,4)), y, eps) 465s ***** assert (lognpdf (x, 0, ones (1,4)), y, eps) 465s ***** assert (lognpdf (x, zeros (1,4), 1), y, eps) 465s ***** assert (lognpdf (x, [0 1 NaN 0], 1), [0 0 NaN y(4)], eps) 465s ***** assert (lognpdf (x, 0, [0 NaN Inf 1]), [NaN NaN NaN y(4)], eps) 465s ***** assert (lognpdf ([x, NaN], 0, 1), [y, NaN], eps) 465s ***** assert (lognpdf (single ([x, NaN]), 0, 1), single ([y, NaN]), eps ("single")) 465s ***** assert (lognpdf ([x, NaN], single (0), 1), single ([y, NaN]), eps ("single")) 465s ***** assert (lognpdf ([x, NaN], 0, single (1)), single ([y, NaN]), eps ("single")) 465s ***** error lognpdf () 465s ***** error lognpdf (1,2,3,4) 465s ***** error lognpdf (ones (3), ones (2), ones (2)) 465s ***** error lognpdf (ones (2), ones (3), ones (2)) 465s ***** error lognpdf (ones (2), ones (2), ones (3)) 465s ***** error lognpdf (i, 2, 2) 465s ***** error lognpdf (2, i, 2) 465s ***** error lognpdf (2, 2, i) 465s 17 tests, 17 passed, 0 known failure, 0 skipped 465s [inst/dist_fun/ncx2rnd.m] 465s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/ncx2rnd.m 465s ***** assert (size (ncx2rnd (1, 1)), [1 1]) 465s ***** assert (size (ncx2rnd (1, ones (2,1))), [2, 1]) 465s ***** assert (size (ncx2rnd (1, ones (2,2))), [2, 2]) 465s ***** assert (size (ncx2rnd (ones (2,1), 1)), [2, 1]) 465s ***** assert (size (ncx2rnd (ones (2,2), 1)), [2, 2]) 465s ***** assert (size (ncx2rnd (1, 1, 3)), [3, 3]) 465s ***** assert (size (ncx2rnd (1, 1, [4, 1])), [4, 1]) 465s ***** assert (size (ncx2rnd (1, 1, 4, 1)), [4, 1]) 465s ***** assert (size (ncx2rnd (1, 1, 4, 1, 5)), [4, 1, 5]) 465s ***** assert (size (ncx2rnd (1, 1, 0, 1)), [0, 1]) 465s ***** assert (size (ncx2rnd (1, 1, 1, 0)), [1, 0]) 465s ***** assert (size (ncx2rnd (1, 1, 1, 2, 0, 5)), [1, 2, 0, 5]) 465s ***** assert (class (ncx2rnd (1, 1)), "double") 465s ***** assert (class (ncx2rnd (1, single (1))), "single") 465s ***** assert (class (ncx2rnd (1, single ([1, 1]))), "single") 465s ***** assert (class (ncx2rnd (single (1), 1)), "single") 465s ***** assert (class (ncx2rnd (single ([1, 1]), 1)), "single") 465s ***** error ncx2rnd () 465s ***** error ncx2rnd (1) 465s ***** error ... 465s ncx2rnd (ones (3), ones (2)) 465s ***** error ... 465s ncx2rnd (ones (2), ones (3)) 465s ***** error ncx2rnd (i, 2) 465s ***** error ncx2rnd (1, i) 465s ***** error ... 465s ncx2rnd (1, 2, -1) 465s ***** error ... 465s ncx2rnd (1, 2, 1.2) 465s ***** error ... 465s ncx2rnd (1, 2, ones (2)) 465s ***** error ... 465s ncx2rnd (1, 2, [2 -1 2]) 465s ***** error ... 465s ncx2rnd (1, 2, [2 0 2.5]) 465s ***** error ... 465s ncx2rnd (1, 2, 2, -1, 5) 465s ***** error ... 465s ncx2rnd (1, 2, 2, 1.5, 5) 465s ***** error ... 465s ncx2rnd (2, ones (2), 3) 465s ***** error ... 465s ncx2rnd (2, ones (2), [3, 2]) 465s ***** error ... 465s ncx2rnd (2, ones (2), 3, 2) 465s 33 tests, 33 passed, 0 known failure, 0 skipped 465s [inst/dist_fun/fpdf.m] 465s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/fpdf.m 465s ***** demo 465s ## Plot various PDFs from the F distribution 465s x = 0.01:0.01:4; 465s y1 = fpdf (x, 1, 1); 465s y2 = fpdf (x, 2, 1); 465s y3 = fpdf (x, 5, 2); 465s y4 = fpdf (x, 10, 1); 465s y5 = fpdf (x, 100, 100); 465s plot (x, y1, "-b", x, y2, "-g", x, y3, "-r", x, y4, "-c", x, y5, "-m") 465s grid on 465s ylim ([0, 2.5]) 465s legend ({"df1 = 1, df2 = 2", "df1 = 2, df2 = 1", ... 465s "df1 = 5, df2 = 2", "df1 = 10, df2 = 1", ... 465s "df1 = 100, df2 = 100"}, "location", "northeast") 465s title ("F PDF") 465s xlabel ("values in x") 465s ylabel ("density") 465s ***** shared x, y 465s x = [-1 0 0.5 1 2]; 465s y = [0 0 4/9 1/4 1/9]; 465s ***** assert (fpdf (x, 2*ones (1,5), 2*ones (1,5)), y, eps) 465s ***** assert (fpdf (x, 2, 2*ones (1,5)), y, eps) 465s ***** assert (fpdf (x, 2*ones (1,5), 2), y, eps) 465s ***** assert (fpdf (x, [0 NaN Inf 2 2], 2), [NaN NaN NaN y(4:5)], eps) 465s ***** assert (fpdf (x, 2, [0 NaN Inf 2 2]), [NaN NaN NaN y(4:5)], eps) 465s ***** assert (fpdf ([x, NaN], 2, 2), [y, NaN], eps) 465s ***** test #F (x, 1, df1) == T distribution (sqrt (x), df1) / sqrt (x) 465s rand ("seed", 1234); # for reproducibility 465s xr = rand (10,1); 465s xr = xr(x > 0.1 & x < 0.9); 465s yr = tpdf (sqrt (xr), 2) ./ sqrt (xr); 465s assert (fpdf (xr, 1, 2), yr, 5*eps); 465s ***** assert (fpdf (single ([x, NaN]), 2, 2), single ([y, NaN]), eps ("single")) 465s ***** assert (fpdf ([x, NaN], single (2), 2), single ([y, NaN]), eps ("single")) 465s ***** assert (fpdf ([x, NaN], 2, single (2)), single ([y, NaN]), eps ("single")) 465s ***** error fpdf () 466s ***** error fpdf (1) 466s ***** error fpdf (1,2) 466s ***** error ... 466s fpdf (ones (3), ones (2), ones (2)) 466s ***** error ... 466s fpdf (ones (2), ones (3), ones (2)) 466s ***** error ... 466s fpdf (ones (2), ones (2), ones (3)) 466s ***** error fpdf (i, 2, 2) 466s ***** error fpdf (2, i, 2) 466s ***** error fpdf (2, 2, i) 466s 19 tests, 19 passed, 0 known failure, 0 skipped 466s [inst/dist_fun/copulapdf.m] 466s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/copulapdf.m 466s ***** test 466s x = [0.2:0.2:0.6; 0.2:0.2:0.6]; 466s theta = [1; 2]; 466s y = copulapdf ("Clayton", x, theta); 466s expected_p = [0.9872; 0.7295]; 466s assert (y, expected_p, 0.001); 466s ***** test 466s x = [0.2:0.2:0.6; 0.2:0.2:0.6]; 466s y = copulapdf ("Gumbel", x, 2); 466s expected_p = [0.9468; 0.9468]; 466s assert (y, expected_p, 0.001); 466s ***** test 466s x = [0.2, 0.6; 0.2, 0.6]; 466s theta = [1; 2]; 466s y = copulapdf ("Frank", x, theta); 466s expected_p = [0.9378; 0.8678]; 466s assert (y, expected_p, 0.001); 466s ***** test 466s x = [0.2, 0.6; 0.2, 0.6]; 466s theta = [0.3; 0.7]; 466s y = copulapdf ("AMH", x, theta); 466s expected_p = [0.9540; 0.8577]; 466s assert (y, expected_p, 0.001); 466s 4 tests, 4 passed, 0 known failure, 0 skipped 466s [inst/dist_fun/evpdf.m] 466s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/evpdf.m 466s ***** demo 466s ## Plot various PDFs from the Extreme value distribution 466s x = -10:0.001:10; 466s y1 = evpdf (x, 0.5, 2); 466s y2 = evpdf (x, 1.0, 2); 466s y3 = evpdf (x, 1.5, 3); 466s y4 = evpdf (x, 3.0, 4); 466s plot (x, y1, "-b", x, y2, "-g", x, y3, "-r", x, y4, "-c") 466s grid on 466s ylim ([0, 0.2]) 466s legend ({"μ = 0.5, σ = 2", "μ = 1.0, σ = 2", ... 466s "μ = 1.5, σ = 3", "μ = 3.0, σ = 4"}, "location", "northeast") 466s title ("Extreme value PDF") 466s xlabel ("values in x") 466s ylabel ("density") 466s ***** shared x, y0, y1 466s x = [-5, 0, 1, 2, 3]; 466s y0 = [0.0067, 0.3679, 0.1794, 0.0046, 0]; 466s y1 = [0.0025, 0.2546, 0.3679, 0.1794, 0.0046]; 466s ***** assert (evpdf (x), y0, 1e-4) 466s ***** assert (evpdf (x, zeros (1,5), ones (1,5)), y0, 1e-4) 466s ***** assert (evpdf (x, ones (1,5), ones (1,5)), y1, 1e-4) 466s ***** error evpdf () 466s ***** error ... 466s evpdf (ones (3), ones (2), ones (2)) 466s ***** error evpdf (i, 2, 2) 466s ***** error evpdf (2, i, 2) 466s ***** error evpdf (2, 2, i) 466s 8 tests, 8 passed, 0 known failure, 0 skipped 466s [inst/dist_fun/vmpdf.m] 466s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/vmpdf.m 466s ***** demo 466s ## Plot various PDFs from the von Mises distribution 466s x1 = [-pi:0.1:pi]; 466s y1 = vmpdf (x1, 0, 0.5); 466s y2 = vmpdf (x1, 0, 1); 466s y3 = vmpdf (x1, 0, 2); 466s y4 = vmpdf (x1, 0, 4); 466s plot (x1, y1, "-r", x1, y2, "-g", x1, y3, "-b", x1, y4, "-c") 466s grid on 466s xlim ([-pi, pi]) 466s ylim ([0, 0.8]) 466s legend ({"μ = 0, k = 0.5", "μ = 0, k = 1", ... 466s "μ = 0, k = 2", "μ = 0, k = 4"}, "location", "northwest") 466s title ("Von Mises PDF") 466s xlabel ("values in x") 466s ylabel ("density") 466s ***** shared x, y0, y1 466s x = [-pi:pi/2:pi]; 466s y0 = [0.046245, 0.125708, 0.341710, 0.125708, 0.046245]; 466s y1 = [0.046245, 0.069817, 0.654958, 0.014082, 0.000039]; 466s ***** assert (vmpdf (x, 0, 1), y0, 1e-5) 466s ***** assert (vmpdf (x, zeros (1,5), ones (1,5)), y0, 1e-6) 466s ***** assert (vmpdf (x, 0, [1 2 3 4 5]), y1, 1e-6) 466s ***** assert (isa (vmpdf (single (pi), 0, 1), "single"), true) 466s ***** assert (isa (vmpdf (pi, single (0), 1), "single"), true) 466s ***** assert (isa (vmpdf (pi, 0, single (1)), "single"), true) 466s ***** error vmpdf () 466s ***** error vmpdf (1) 466s ***** error vmpdf (1, 2) 466s ***** error ... 466s vmpdf (ones (3), ones (2), ones (2)) 466s ***** error ... 466s vmpdf (ones (2), ones (3), ones (2)) 466s ***** error ... 466s vmpdf (ones (2), ones (2), ones (3)) 466s ***** error vmpdf (i, 2, 2) 466s ***** error vmpdf (2, i, 2) 466s ***** error vmpdf (2, 2, i) 466s 15 tests, 15 passed, 0 known failure, 0 skipped 466s [inst/dist_fun/hninv.m] 466s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/hninv.m 466s ***** demo 466s ## Plot various iCDFs from the half-normal distribution 466s p = 0.001:0.001:0.999; 466s x1 = hninv (p, 0, 1); 466s x2 = hninv (p, 0, 2); 466s x3 = hninv (p, 0, 3); 466s x4 = hninv (p, 0, 5); 466s plot (p, x1, "-b", p, x2, "-g", p, x3, "-r", p, x4, "-c") 466s grid on 466s ylim ([0, 10]) 466s legend ({"μ = 0, σ = 1", "μ = 0, σ = 2", ... 466s "μ = 0, σ = 3", "μ = 0, σ = 5"}, "location", "northwest") 466s title ("Half-normal iCDF") 466s xlabel ("probability") 466s ylabel ("x") 466s ***** shared p, x 466s p = [0, 0.3829, 0.6827, 1]; 466s x = [0, 1/2, 1, Inf]; 466s ***** assert (hninv (p, 0, 1), x, 1e-4); 466s ***** assert (hninv (p, 5, 1), x + 5, 1e-4); 466s ***** assert (hninv (p, 0, ones (1,4)), x, 1e-4); 466s ***** assert (hninv (p, 0, [-1, 0, 1, 1]), [NaN, NaN, x(3:4)], 1e-4) 466s ***** assert (class (hninv (single ([p, NaN]), 0, 1)), "single") 466s ***** assert (class (hninv ([p, NaN], single (0), 1)), "single") 466s ***** assert (class (hninv ([p, NaN], 0, single (1))), "single") 466s ***** error hninv (1) 466s ***** error hninv (1, 2) 466s ***** error ... 466s hninv (1, ones (2), ones (3)) 466s ***** error ... 466s hninv (ones (2), 1, ones (3)) 466s ***** error ... 466s hninv (ones (2), ones (3), 1) 466s ***** error hninv (i, 2, 3) 466s ***** error hninv (1, i, 3) 466s ***** error hninv (1, 2, i) 466s 15 tests, 15 passed, 0 known failure, 0 skipped 466s [inst/dist_fun/raylinv.m] 466s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/raylinv.m 466s ***** demo 466s ## Plot various iCDFs from the Rayleigh distribution 466s p = 0.001:0.001:0.999; 466s x1 = raylinv (p, 0.5); 466s x2 = raylinv (p, 1); 466s x3 = raylinv (p, 2); 466s x4 = raylinv (p, 3); 466s x5 = raylinv (p, 4); 466s plot (p, x1, "-b", p, x2, "g", p, x3, "-r", p, x4, "-m", p, x5, "-k") 466s grid on 466s ylim ([0, 10]) 466s legend ({"σ = 0,5", "σ = 1", "σ = 2", ... 466s "σ = 3", "σ = 4"}, "location", "northwest") 466s title ("Rayleigh iCDF") 466s xlabel ("probability") 466s ylabel ("values in x") 466s ***** test 466s p = 0:0.1:0.5; 466s sigma = 1:6; 466s x = raylinv (p, sigma); 466s expected_x = [0.0000, 0.9181, 2.0041, 3.3784, 5.0538, 7.0645]; 466s assert (x, expected_x, 0.001); 466s ***** test 466s p = 0:0.1:0.5; 466s x = raylinv (p, 0.5); 466s expected_x = [0.0000, 0.2295, 0.3340, 0.4223, 0.5054, 0.5887]; 466s assert (x, expected_x, 0.001); 466s ***** error raylinv () 466s ***** error raylinv (1) 466s ***** error ... 466s raylinv (ones (3), ones (2)) 466s ***** error ... 466s raylinv (ones (2), ones (3)) 466s ***** error raylinv (i, 2) 466s ***** error raylinv (2, i) 466s 8 tests, 8 passed, 0 known failure, 0 skipped 466s [inst/dist_fun/bvtcdf.m] 466s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/bvtcdf.m 466s ***** test 466s x = [1, 2]; 466s rho = [1, 0.5; 0.5, 1]; 466s df = 4; 466s assert (bvtcdf(x, rho(2), df), mvtcdf(x, rho, df), 1e-14); 466s ***** test 466s x = [3, 2;2, 4;1, 5]; 466s rho = [1, 0.5; 0.5, 1]; 466s df = 4; 466s assert (bvtcdf(x, rho(2), df), mvtcdf(x, rho, df), 1e-14); 466s 2 tests, 2 passed, 0 known failure, 0 skipped 466s [inst/dist_fun/jsupdf.m] 466s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/jsupdf.m 466s ***** error jsupdf () 466s ***** error jsupdf (1, 2, 3, 4) 466s ***** error ... 466s jsupdf (1, ones (2), ones (3)) 466s 3 tests, 3 passed, 0 known failure, 0 skipped 466s [inst/dist_fun/loglcdf.m] 466s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/loglcdf.m 466s ***** demo 466s ## Plot various CDFs from the log-logistic distribution 466s x = 0:0.001:2; 466s p1 = loglcdf (x, log (1), 1/0.5); 466s p2 = loglcdf (x, log (1), 1); 466s p3 = loglcdf (x, log (1), 1/2); 466s p4 = loglcdf (x, log (1), 1/4); 466s p5 = loglcdf (x, log (1), 1/8); 466s plot (x, p1, "-b", x, p2, "-g", x, p3, "-r", x, p4, "-c", x, p5, "-m") 466s legend ({"σ = 2 (β = 0.5)", "σ = 1 (β = 1)", "σ = 0.5 (β = 2)", ... 466s "σ = 0.25 (β = 4)", "σ = 0.125 (β = 8)"}, "location", "northwest") 466s grid on 466s title ("Log-logistic CDF") 466s xlabel ("values in x") 466s ylabel ("probability") 466s text (0.05, 0.64, "μ = 0 (α = 1), values of σ (β) as shown in legend") 466s ***** shared out1, out2 466s out1 = [0, 0.5, 0.66666667, 0.75, 0.8, 0.83333333]; 466s out2 = [0, 0.4174, 0.4745, 0.5082, 0.5321, 0.5506]; 466s ***** assert (loglcdf ([0:5], 0, 1), out1, 1e-8) 466s ***** assert (loglcdf ([0:5], 0, 1, "upper"), 1 - out1, 1e-8) 466s ***** assert (loglcdf ([0:5], 0, 1), out1, 1e-8) 466s ***** assert (loglcdf ([0:5], 0, 1, "upper"), 1 - out1, 1e-8) 466s ***** assert (loglcdf ([0:5], 1, 3), out2, 1e-4) 466s ***** assert (loglcdf ([0:5], 1, 3, "upper"), 1 - out2, 1e-4) 466s ***** assert (class (loglcdf (single (1), 2, 3)), "single") 466s ***** assert (class (loglcdf (1, single (2), 3)), "single") 466s ***** assert (class (loglcdf (1, 2, single (3))), "single") 466s ***** error loglcdf (1) 466s ***** error loglcdf (1, 2) 466s ***** error ... 466s loglcdf (1, 2, 3, 4) 466s ***** error ... 466s loglcdf (1, 2, 3, "uper") 466s ***** error ... 466s loglcdf (1, ones (2), ones (3)) 466s ***** error ... 466s loglcdf (1, ones (2), ones (3), "upper") 466s ***** error ... 466s loglcdf (ones (2), 1, ones (3)) 466s ***** error ... 466s loglcdf (ones (2), 1, ones (3), "upper") 466s ***** error ... 466s loglcdf (ones (2), ones (3), 1) 466s ***** error ... 466s loglcdf (ones (2), ones (3), 1, "upper") 466s ***** error loglcdf (i, 2, 3) 466s ***** error loglcdf (i, 2, 3, "upper") 466s ***** error loglcdf (1, i, 3) 466s ***** error loglcdf (1, i, 3, "upper") 466s ***** error loglcdf (1, 2, i) 466s ***** error loglcdf (1, 2, i, "upper") 466s 25 tests, 25 passed, 0 known failure, 0 skipped 466s [inst/dist_fun/logncdf.m] 466s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/logncdf.m 466s ***** demo 466s ## Plot various CDFs from the log-normal distribution 466s x = 0:0.01:3; 466s p1 = logncdf (x, 0, 1); 466s p2 = logncdf (x, 0, 0.5); 466s p3 = logncdf (x, 0, 0.25); 466s plot (x, p1, "-b", x, p2, "-g", x, p3, "-r") 466s grid on 466s legend ({"μ = 0, σ = 1", "μ = 0, σ = 0.5", "μ = 0, σ = 0.25"}, ... 466s "location", "southeast") 466s title ("Log-normal CDF") 466s xlabel ("values in x") 466s ylabel ("probability") 466s ***** shared x, y 466s x = [-1, 0, 1, e, Inf]; 466s y = [0, 0, 0.5, 1/2+1/2*erf(1/2), 1]; 466s ***** assert (logncdf (x, zeros (1,5), sqrt(2)*ones (1,5)), y, eps) 466s ***** assert (logncdf (x, zeros (1,5), sqrt(2)*ones (1,5), []), y, eps) 466s ***** assert (logncdf (x, 0, sqrt(2)*ones (1,5)), y, eps) 466s ***** assert (logncdf (x, zeros (1,5), sqrt(2)), y, eps) 466s ***** assert (logncdf (x, [0 1 NaN 0 1], sqrt(2)), [0 0 NaN y(4:5)], eps) 466s ***** assert (logncdf (x, 0, sqrt(2)*[0 NaN Inf 1 1]), [NaN NaN y(3:5)], eps) 466s ***** assert (logncdf ([x(1:3) NaN x(5)], 0, sqrt(2)), [y(1:3) NaN y(5)], eps) 466s ***** assert (logncdf ([x, NaN], 0, sqrt(2)), [y, NaN], eps) 466s ***** assert (logncdf (single ([x, NaN]), 0, sqrt(2)), single ([y, NaN]), eps ("single")) 466s ***** assert (logncdf ([x, NaN], single (0), sqrt(2)), single ([y, NaN]), eps ("single")) 466s ***** assert (logncdf ([x, NaN], 0, single (sqrt(2))), single ([y, NaN]), eps ("single")) 466s ***** error logncdf () 466s ***** error logncdf (1,2,3,4,5,6,7) 466s ***** error logncdf (1, 2, 3, 4, "uper") 466s ***** error ... 466s logncdf (ones (3), ones (2), ones (2)) 466s ***** error logncdf (2, 3, 4, [1, 2]) 466s ***** error ... 466s [p, plo, pup] = logncdf (1, 2, 3) 466s ***** error [p, plo, pup] = ... 466s logncdf (1, 2, 3, [1, 0; 0, 1], 0) 466s ***** error [p, plo, pup] = ... 466s logncdf (1, 2, 3, [1, 0; 0, 1], 1.22) 466s ***** error [p, plo, pup] = ... 466s logncdf (1, 2, 3, [1, 0; 0, 1], "alpha", "upper") 466s ***** error logncdf (i, 2, 2) 466s ***** error logncdf (2, i, 2) 466s ***** error logncdf (2, 2, i) 466s ***** error ... 466s [p, plo, pup] =logncdf (1, 2, 3, [1, 0; 0, -inf], 0.04) 466s 24 tests, 24 passed, 0 known failure, 0 skipped 466s [inst/dist_fun/nbinrnd.m] 466s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/nbinrnd.m 466s ***** assert (size (nbinrnd (1, 0.5)), [1 1]) 466s ***** assert (size (nbinrnd (1, 0.5 * ones (2,1))), [2, 1]) 466s ***** assert (size (nbinrnd (1, 0.5 * ones (2,2))), [2, 2]) 466s ***** assert (size (nbinrnd (ones (2,1), 0.5)), [2, 1]) 466s ***** assert (size (nbinrnd (ones (2,2), 0.5)), [2, 2]) 466s ***** assert (size (nbinrnd (1, 0.5, 3)), [3, 3]) 466s ***** assert (size (nbinrnd (1, 0.5, [4, 1])), [4, 1]) 466s ***** assert (size (nbinrnd (1, 0.5, 4, 1)), [4, 1]) 466s ***** assert (size (nbinrnd (1, 0.5, 4, 1, 5)), [4, 1, 5]) 466s ***** assert (size (nbinrnd (1, 0.5, 0, 1)), [0, 1]) 466s ***** assert (size (nbinrnd (1, 0.5, 1, 0)), [1, 0]) 466s ***** assert (size (nbinrnd (1, 0.5, 1, 2, 0, 5)), [1, 2, 0, 5]) 466s ***** assert (class (nbinrnd (1, 0.5)), "double") 466s ***** assert (class (nbinrnd (1, single (0.5))), "single") 466s ***** assert (class (nbinrnd (1, single ([0.5, 0.5]))), "single") 466s ***** assert (class (nbinrnd (single (1), 0.5)), "single") 466s ***** assert (class (nbinrnd (single ([1, 1]), 0.5)), "single") 466s ***** error nbinrnd () 466s ***** error nbinrnd (1) 466s ***** error ... 466s nbinrnd (ones (3), ones (2)) 466s ***** error ... 466s nbinrnd (ones (2), ones (3)) 466s ***** error nbinrnd (i, 2, 3) 466s ***** error nbinrnd (1, i, 3) 466s ***** error ... 466s nbinrnd (1, 2, -1) 466s ***** error ... 466s nbinrnd (1, 2, 1.2) 466s ***** error ... 466s nbinrnd (1, 2, ones (2)) 466s ***** error ... 466s nbinrnd (1, 2, [2 -1 2]) 466s ***** error ... 466s nbinrnd (1, 2, [2 0 2.5]) 466s ***** error ... 466s nbinrnd (1, 2, 2, -1, 5) 466s ***** error ... 466s nbinrnd (1, 2, 2, 1.5, 5) 466s ***** error ... 466s nbinrnd (2, ones (2), 3) 466s ***** error ... 466s nbinrnd (2, ones (2), [3, 2]) 466s ***** error ... 466s nbinrnd (2, ones (2), 3, 2) 466s 33 tests, 33 passed, 0 known failure, 0 skipped 466s [inst/dist_fun/gpcdf.m] 466s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/gpcdf.m 466s ***** demo 466s ## Plot various CDFs from the generalized Pareto distribution 466s x = 0:0.001:5; 466s p1 = gpcdf (x, 1, 1, 0); 466s p2 = gpcdf (x, 5, 1, 0); 466s p3 = gpcdf (x, 20, 1, 0); 466s p4 = gpcdf (x, 1, 2, 0); 466s p5 = gpcdf (x, 5, 2, 0); 466s p6 = gpcdf (x, 20, 2, 0); 466s plot (x, p1, "-b", x, p2, "-g", x, p3, "-r", ... 466s x, p4, "-c", x, p5, "-m", x, p6, "-k") 466s grid on 466s xlim ([0, 5]) 466s legend ({"k = 1, σ = 1, θ = 0", "k = 5, σ = 1, θ = 0", ... 466s "k = 20, σ = 1, θ = 0", "k = 1, σ = 2, θ = 0", ... 466s "k = 5, σ = 2, θ = 0", "k = 20, σ = 2, θ = 0"}, ... 466s "location", "northwest") 466s title ("Generalized Pareto CDF") 466s xlabel ("values in x") 466s ylabel ("probability") 466s ***** shared x, y1, y1u, y2, y2u, y3, y3u 466s x = [-Inf, -1, 0, 1/2, 1, Inf]; 466s y1 = [0, 0, 0, 0.3934693402873666, 0.6321205588285577, 1]; 466s y1u = [1, 1, 1, 0.6065306597126334, 0.3678794411714423, 0]; 466s y2 = [0, 0, 0, 1/3, 1/2, 1]; 466s y2u = [1, 1, 1, 2/3, 1/2, 0]; 466s y3 = [0, 0, 0, 1/2, 1, 1]; 466s y3u = [1, 1, 1, 1/2, 0, 0]; 466s ***** assert (gpcdf (x, zeros (1,6), ones (1,6), zeros (1,6)), y1, eps) 466s ***** assert (gpcdf (x, 0, 1, zeros (1,6)), y1, eps) 466s ***** assert (gpcdf (x, 0, ones (1,6), 0), y1, eps) 466s ***** assert (gpcdf (x, zeros (1,6), 1, 0), y1, eps) 466s ***** assert (gpcdf (x, 0, 1, 0), y1, eps) 466s ***** assert (gpcdf (x, 0, 1, [0, 0, 0, NaN, 0, 0]), [y1(1:3), NaN, y1(5:6)], eps) 466s ***** assert (gpcdf (x, 0, [1, 1, 1, NaN, 1, 1], 0), [y1(1:3), NaN, y1(5:6)], eps) 466s ***** assert (gpcdf (x, [0, 0, 0, NaN, 0, 0], 1, 0), [y1(1:3), NaN, y1(5:6)], eps) 466s ***** assert (gpcdf ([x(1:3), NaN, x(5:6)], 0, 1, 0), [y1(1:3), NaN, y1(5:6)], eps) 466s ***** assert (gpcdf (x, zeros (1,6), ones (1,6), zeros (1,6), "upper"), y1u, eps) 466s ***** assert (gpcdf (x, 0, 1, zeros (1,6), "upper"), y1u, eps) 466s ***** assert (gpcdf (x, 0, ones (1,6), 0, "upper"), y1u, eps) 466s ***** assert (gpcdf (x, zeros (1,6), 1, 0, "upper"), y1u, eps) 466s ***** assert (gpcdf (x, 0, 1, 0, "upper"), y1u, eps) 466s ***** assert (gpcdf (x, ones (1,6), ones (1,6), zeros (1,6)), y2, eps) 466s ***** assert (gpcdf (x, 1, 1, zeros (1,6)), y2, eps) 466s ***** assert (gpcdf (x, 1, ones (1,6), 0), y2, eps) 466s ***** assert (gpcdf (x, ones (1,6), 1, 0), y2, eps) 466s ***** assert (gpcdf (x, 1, 1, 0), y2, eps) 466s ***** assert (gpcdf (x, 1, 1, [0, 0, 0, NaN, 0, 0]), [y2(1:3), NaN, y2(5:6)], eps) 466s ***** assert (gpcdf (x, 1, [1, 1, 1, NaN, 1, 1], 0), [y2(1:3), NaN, y2(5:6)], eps) 466s ***** assert (gpcdf (x, [1, 1, 1, NaN, 1, 1], 1, 0), [y2(1:3), NaN, y2(5:6)], eps) 466s ***** assert (gpcdf ([x(1:3), NaN, x(5:6)], 1, 1, 0), [y2(1:3), NaN, y2(5:6)], eps) 466s ***** assert (gpcdf (x, ones (1,6), ones (1,6), zeros (1,6), "upper"), y2u, eps) 466s ***** assert (gpcdf (x, 1, 1, zeros (1,6), "upper"), y2u, eps) 466s ***** assert (gpcdf (x, 1, ones (1,6), 0, "upper"), y2u, eps) 466s ***** assert (gpcdf (x, ones (1,6), 1, 0, "upper"), y2u, eps) 466s ***** assert (gpcdf (x, 1, 1, 0, "upper"), y2u, eps) 466s ***** assert (gpcdf (x, 1, 1, [0, 0, 0, NaN, 0, 0], "upper"), ... 466s [y2u(1:3), NaN, y2u(5:6)], eps) 466s ***** assert (gpcdf (x, 1, [1, 1, 1, NaN, 1, 1], 0, "upper"), ... 466s [y2u(1:3), NaN, y2u(5:6)], eps) 466s ***** assert (gpcdf (x, [1, 1, 1, NaN, 1, 1], 1, 0, "upper"), ... 466s [y2u(1:3), NaN, y2u(5:6)], eps) 466s ***** assert (gpcdf ([x(1:3), NaN, x(5:6)], 1, 1, 0, "upper"), ... 466s [y2u(1:3), NaN, y2u(5:6)], eps) 466s ***** assert (gpcdf (x, -ones (1,6), ones (1,6), zeros (1,6)), y3, eps) 466s ***** assert (gpcdf (x, -1, 1, zeros (1,6)), y3, eps) 466s ***** assert (gpcdf (x, -1, ones (1,6), 0), y3, eps) 466s ***** assert (gpcdf (x, -ones (1,6), 1, 0), y3, eps) 466s ***** assert (gpcdf (x, -1, 1, 0), y3, eps) 466s ***** assert (gpcdf (x, -1, 1, [0, 0, 0, NaN, 0, 0]), [y3(1:3), NaN, y3(5:6)], eps) 466s ***** assert (gpcdf (x, -1, [1, 1, 1, NaN, 1, 1], 0), [y3(1:3), NaN, y3(5:6)], eps) 466s ***** assert (gpcdf (x, [-1, -1, -1, NaN, -1, -1], 1, 0), [y3(1:3), NaN, y3(5:6)], eps) 466s ***** assert (gpcdf ([x(1:3), NaN, x(5:6)], -1, 1, 0), [y3(1:3), NaN, y3(5:6)], eps) 466s ***** assert (gpcdf (x, -ones (1,6), ones (1,6), zeros (1,6), "upper"), y3u, eps) 466s ***** assert (gpcdf (x, -1, 1, zeros (1,6), "upper"), y3u, eps) 466s ***** assert (gpcdf (x, -1, ones (1,6), 0, "upper"), y3u, eps) 466s ***** assert (gpcdf (x, -ones (1,6), 1, 0, "upper"), y3u, eps) 466s ***** assert (gpcdf (x, -1, 1, 0, "upper"), y3u, eps) 466s ***** assert (gpcdf (x, -1, 1, [0, 0, 0, NaN, 0, 0], "upper"), ... 466s [y3u(1:3), NaN, y3u(5:6)], eps) 466s ***** assert (gpcdf (x, -1, [1, 1, 1, NaN, 1, 1], 0, "upper"), ... 466s [y3u(1:3), NaN, y3u(5:6)], eps) 466s ***** assert (gpcdf (x, [-1, -1, -1, NaN, -1, -1], 1, 0, "upper"), ... 466s [y3u(1:3), NaN, y3u(5:6)], eps) 466s ***** assert (gpcdf ([x(1:3), NaN, x(5:6)], -1, 1, 0, "upper"), ... 466s [y3u(1:3), NaN, y3u(5:6)], eps) 466s ***** assert (gpcdf (single ([x, NaN]), 0, 1, 0), single ([y1, NaN]), eps("single")) 466s ***** assert (gpcdf ([x, NaN], 0, 1, single (0)), single ([y1, NaN]), eps("single")) 466s ***** assert (gpcdf ([x, NaN], 0, single (1), 0), single ([y1, NaN]), eps("single")) 466s ***** assert (gpcdf ([x, NaN], single (0), 1, 0), single ([y1, NaN]), eps("single")) 466s ***** assert (gpcdf (single ([x, NaN]), 1, 1, 0), single ([y2, NaN]), eps("single")) 467s ***** assert (gpcdf ([x, NaN], 1, 1, single (0)), single ([y2, NaN]), eps("single")) 467s ***** assert (gpcdf ([x, NaN], 1, single (1), 0), single ([y2, NaN]), eps("single")) 467s ***** assert (gpcdf ([x, NaN], single (1), 1, 0), single ([y2, NaN]), eps("single")) 467s ***** assert (gpcdf (single ([x, NaN]), -1, 1, 0), single ([y3, NaN]), eps("single")) 467s ***** assert (gpcdf ([x, NaN], -1, 1, single (0)), single ([y3, NaN]), eps("single")) 467s ***** assert (gpcdf ([x, NaN], -1, single (1), 0), single ([y3, NaN]), eps("single")) 467s ***** assert (gpcdf ([x, NaN], single (-1), 1, 0), single ([y3, NaN]), eps("single")) 467s ***** error gpcdf () 467s ***** error gpcdf (1) 467s ***** error gpcdf (1, 2) 467s ***** error gpcdf (1, 2, 3) 467s ***** error gpcdf (1, 2, 3, 4, "tail") 467s ***** error gpcdf (1, 2, 3, 4, 5) 467s ***** error ... 467s gpcdf (ones (3), ones (2), ones(2), ones(2)) 467s ***** error ... 467s gpcdf (ones (2), ones (3), ones(2), ones(2)) 467s ***** error ... 467s gpcdf (ones (2), ones (2), ones(3), ones(2)) 467s ***** error ... 467s gpcdf (ones (2), ones (2), ones(2), ones(3)) 467s ***** error gpcdf (i, 2, 3, 4) 467s ***** error gpcdf (1, i, 3, 4) 467s ***** error gpcdf (1, 2, i, 4) 467s ***** error gpcdf (1, 2, 3, i) 467s 76 tests, 76 passed, 0 known failure, 0 skipped 467s [inst/dist_fun/wblrnd.m] 467s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/wblrnd.m 467s ***** assert (size (wblrnd (1, 1)), [1 1]) 467s ***** assert (size (wblrnd (1, ones (2,1))), [2, 1]) 467s ***** assert (size (wblrnd (1, ones (2,2))), [2, 2]) 467s ***** assert (size (wblrnd (ones (2,1), 1)), [2, 1]) 467s ***** assert (size (wblrnd (ones (2,2), 1)), [2, 2]) 467s ***** assert (size (wblrnd (1, 1, 3)), [3, 3]) 467s ***** assert (size (wblrnd (1, 1, [4, 1])), [4, 1]) 467s ***** assert (size (wblrnd (1, 1, 4, 1)), [4, 1]) 467s ***** assert (size (wblrnd (1, 1, 4, 1, 5)), [4, 1, 5]) 467s ***** assert (size (wblrnd (1, 1, 0, 1)), [0, 1]) 467s ***** assert (size (wblrnd (1, 1, 1, 0)), [1, 0]) 467s ***** assert (size (wblrnd (1, 1, 1, 2, 0, 5)), [1, 2, 0, 5]) 467s ***** assert (class (wblrnd (1, 1)), "double") 467s ***** assert (class (wblrnd (1, single (1))), "single") 467s ***** assert (class (wblrnd (1, single ([1, 1]))), "single") 467s ***** assert (class (wblrnd (single (1), 1)), "single") 467s ***** assert (class (wblrnd (single ([1, 1]), 1)), "single") 467s ***** error wblrnd () 467s ***** error wblrnd (1) 467s ***** error ... 467s wblrnd (ones (3), ones (2)) 467s ***** error ... 467s wblrnd (ones (2), ones (3)) 467s ***** error wblrnd (i, 2, 3) 467s ***** error wblrnd (1, i, 3) 467s ***** error ... 467s wblrnd (1, 2, -1) 467s ***** error ... 467s wblrnd (1, 2, 1.2) 467s ***** error ... 467s wblrnd (1, 2, ones (2)) 467s ***** error ... 467s wblrnd (1, 2, [2 -1 2]) 467s ***** error ... 467s wblrnd (1, 2, [2 0 2.5]) 467s ***** error ... 467s wblrnd (1, 2, 2, -1, 5) 467s ***** error ... 467s wblrnd (1, 2, 2, 1.5, 5) 467s ***** error ... 467s wblrnd (2, ones (2), 3) 467s ***** error ... 467s wblrnd (2, ones (2), [3, 2]) 467s ***** error ... 467s wblrnd (2, ones (2), 3, 2) 467s 33 tests, 33 passed, 0 known failure, 0 skipped 467s [inst/dist_fun/unidinv.m] 467s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/unidinv.m 467s ***** demo 467s ## Plot various iCDFs from the discrete uniform distribution 467s p = 0.001:0.001:0.999; 467s x1 = unidinv (p, 5); 467s x2 = unidinv (p, 9); 467s plot (p, x1, "-b", p, x2, "-g") 467s grid on 467s xlim ([0, 1]) 467s ylim ([0, 10]) 467s legend ({"N = 5", "N = 9"}, "location", "northwest") 467s title ("Discrete uniform iCDF") 467s xlabel ("probability") 467s ylabel ("values in x") 467s ***** shared p 467s p = [-1 0 0.5 1 2]; 467s ***** assert (unidinv (p, 10*ones (1,5)), [NaN NaN 5 10 NaN], eps) 467s ***** assert (unidinv (p, 10), [NaN NaN 5 10 NaN], eps) 467s ***** assert (unidinv (p, 10*[0 1 NaN 1 1]), [NaN NaN NaN 10 NaN], eps) 467s ***** assert (unidinv ([p(1:2) NaN p(4:5)], 10), [NaN NaN NaN 10 NaN], eps) 467s ***** assert (unidinv ([p, NaN], 10), [NaN NaN 5 10 NaN NaN], eps) 467s ***** assert (unidinv (single ([p, NaN]), 10), single ([NaN NaN 5 10 NaN NaN]), eps) 467s ***** assert (unidinv ([p, NaN], single (10)), single ([NaN NaN 5 10 NaN NaN]), eps) 467s ***** error unidinv () 467s ***** error unidinv (1) 467s ***** error ... 467s unidinv (ones (3), ones (2)) 467s ***** error ... 467s unidinv (ones (2), ones (3)) 467s ***** error unidinv (i, 2) 467s ***** error unidinv (2, i) 467s 13 tests, 13 passed, 0 known failure, 0 skipped 467s [inst/dist_fun/betacdf.m] 467s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/betacdf.m 467s ***** demo 467s ## Plot various CDFs from the Beta distribution 467s x = 0:0.005:1; 467s p1 = betacdf (x, 0.5, 0.5); 467s p2 = betacdf (x, 5, 1); 467s p3 = betacdf (x, 1, 3); 467s p4 = betacdf (x, 2, 2); 467s p5 = betacdf (x, 2, 5); 467s plot (x, p1, "-b", x, p2, "-g", x, p3, "-r", x, p4, "-c", x, p5, "-m") 467s grid on 467s legend ({"α = β = 0.5", "α = 5, β = 1", "α = 1, β = 3", ... 467s "α = 2, β = 2", "α = 2, β = 5"}, "location", "northwest") 467s title ("Beta CDF") 467s xlabel ("values in x") 467s ylabel ("probability") 467s ***** shared x, y, x1, x2 467s x = [-1 0 0.5 1 2]; 467s y = [0 0 0.75 1 1]; 467s ***** assert (betacdf (x, ones (1, 5), 2 * ones (1, 5)), y) 467s ***** assert (betacdf (x, 1, 2 * ones (1, 5)), y) 467s ***** assert (betacdf (x, ones (1, 5), 2), y) 467s ***** assert (betacdf (x, [0 1 NaN 1 1], 2), [NaN 0 NaN 1 1]) 467s ***** assert (betacdf (x, 1, 2 * [0 1 NaN 1 1]), [NaN 0 NaN 1 1]) 467s ***** assert (betacdf ([x(1:2) NaN x(4:5)], 1, 2), [y(1:2) NaN y(4:5)]) 467s x1 = [0.1:0.2:0.9]; 467s ***** assert (betacdf (x1, 2, 2), [0.028, 0.216, 0.5, 0.784, 0.972], 1e-14); 467s ***** assert (betacdf (x1, 2, 2, "upper"), 1 - [0.028, 0.216, 0.5, 0.784, 0.972],... 467s 1e-14); 467s x2 = [1, 2, 3]; 467s ***** assert (betacdf (0.5, x2, x2), [0.5, 0.5, 0.5], 1e-14); 467s ***** assert (betacdf ([x, NaN], 1, 2), [y, NaN]) 467s ***** assert (betacdf (single ([x, NaN]), 1, 2), single ([y, NaN])) 467s ***** assert (betacdf ([x, NaN], single (1), 2), single ([y, NaN])) 467s ***** assert (betacdf ([x, NaN], 1, single (2)), single ([y, NaN])) 467s ***** error betacdf () 467s ***** error betacdf (1) 467s ***** error betacdf (1, 2) 467s ***** error betacdf (1, 2, 3, 4, 5) 467s ***** error betacdf (1, 2, 3, "tail") 467s ***** error betacdf (1, 2, 3, 4) 467s ***** error ... 467s betacdf (ones (3), ones (2), ones (2)) 467s ***** error ... 467s betacdf (ones (2), ones (3), ones (2)) 467s ***** error ... 467s betacdf (ones (2), ones (2), ones (3)) 467s ***** error betacdf (i, 2, 2) 467s ***** error betacdf (2, i, 2) 467s ***** error betacdf (2, 2, i) 467s 25 tests, 25 passed, 0 known failure, 0 skipped 467s [inst/dist_fun/iwishpdf.m] 467s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/iwishpdf.m 467s ***** assert(iwishpdf(4, 3, 3.1), 0.04226595, 1E-7); 467s ***** assert(iwishpdf([2 -0.3;-0.3 4], [1 0.3;0.3 1], 4), 1.60166e-05, 1E-10); 467s ***** assert(iwishpdf([6 2 5; 2 10 -5; 5 -5 25], ... 467s [9 5 5; 5 10 -8; 5 -8 22], 5.1), 4.946831e-12, 1E-17); 467s ***** error iwishpdf () 467s ***** error iwishpdf (1, 2) 467s ***** error iwishpdf (1, 2, 0) 467s 6 tests, 6 passed, 0 known failure, 0 skipped 467s [inst/dist_fun/trirnd.m] 467s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/trirnd.m 467s ***** assert (size (trirnd (1, 1.5, 2)), [1, 1]) 467s ***** assert (size (trirnd (1 * ones (2, 1), 1.5, 2)), [2, 1]) 467s ***** assert (size (trirnd (1 * ones (2, 2), 1.5, 2)), [2, 2]) 467s ***** assert (size (trirnd (1, 1.5 * ones (2, 1), 2)), [2, 1]) 467s ***** assert (size (trirnd (1, 1.5 * ones (2, 2), 2)), [2, 2]) 467s ***** assert (size (trirnd (1, 1.5, 2 * ones (2, 1))), [2, 1]) 467s ***** assert (size (trirnd (1, 1.5, 2 * ones (2, 2))), [2, 2]) 467s ***** assert (size (trirnd (1, 1.5, 2, 3)), [3, 3]) 467s ***** assert (size (trirnd (1, 1.5, 2, [4, 1])), [4, 1]) 467s ***** assert (size (trirnd (1, 1.5, 2, 4, 1)), [4, 1]) 467s ***** assert (class (trirnd (1, 1.5, 2)), "double") 467s ***** assert (class (trirnd (single (1), 1.5, 2)), "single") 467s ***** assert (class (trirnd (single ([1, 1]), 1.5, 2)), "single") 467s ***** assert (class (trirnd (1, single (1.5), 2)), "single") 467s ***** assert (class (trirnd (1, single ([1.5, 1.5]), 2)), "single") 467s ***** assert (class (trirnd (1, 1.5, single (1.5))), "single") 467s ***** assert (class (trirnd (1, 1.5, single ([2, 2]))), "single") 467s ***** error trirnd () 467s ***** error trirnd (1) 467s ***** error trirnd (1, 2) 467s ***** error ... 467s trirnd (ones (3), 5 * ones (2), ones (2)) 467s ***** error ... 467s trirnd (ones (2), 5 * ones (3), ones (2)) 467s ***** error ... 467s trirnd (ones (2), 5 * ones (2), ones (3)) 467s ***** error trirnd (i, 5, 3) 467s ***** error trirnd (1, 5+i, 3) 467s ***** error trirnd (1, 5, i) 467s ***** error ... 467s trirnd (1, 5, 3, -1) 467s ***** error ... 467s trirnd (1, 5, 3, 1.2) 467s ***** error ... 467s trirnd (1, 5, 3, ones (2)) 467s ***** error ... 467s trirnd (1, 5, 3, [2 -1 2]) 467s ***** error ... 467s trirnd (1, 5, 3, [2 0 2.5]) 467s ***** error ... 467s trirnd (1, 5, 3, 2, -1, 5) 467s ***** error ... 467s trirnd (1, 5, 3, 2, 1.5, 5) 467s ***** error ... 467s trirnd (2, 5 * ones (2), 2, 3) 467s ***** error ... 467s trirnd (2, 5 * ones (2), 2, [3, 2]) 467s ***** error ... 467s trirnd (2, 5 * ones (2), 2, 3, 2) 467s 36 tests, 36 passed, 0 known failure, 0 skipped 467s [inst/dist_fun/iwishrnd.m] 467s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/iwishrnd.m 467s ***** assert(size (iwishrnd (1,2,1)), [1, 1]); 467s ***** assert(size (iwishrnd ([],2,1)), [1, 1]); 467s ***** assert(size (iwishrnd ([3 1; 1 3], 2.00001, [], 1)), [2, 2]); 467s ***** assert(size (iwishrnd (eye(2), 2, [], 3)), [2, 2, 3]); 467s ***** error iwishrnd () 468s ***** error iwishrnd (1) 468s ***** error iwishrnd ([-3 1; 1 3],1) 468s ***** error iwishrnd ([1; 1],1) 468s 8 tests, 8 passed, 0 known failure, 0 skipped 468s [inst/dist_fun/gprnd.m] 468s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/gprnd.m 468s ***** assert (size (gprnd (0, 1, 0)), [1, 1]) 468s ***** assert (size (gprnd (0, 1, zeros (2,1))), [2, 1]) 468s ***** assert (size (gprnd (0, 1, zeros (2,2))), [2, 2]) 468s ***** assert (size (gprnd (0, ones (2,1), 0)), [2, 1]) 468s ***** assert (size (gprnd (0, ones (2,2), 0)), [2, 2]) 468s ***** assert (size (gprnd (zeros (2,1), 1, 0)), [2, 1]) 468s ***** assert (size (gprnd (zeros (2,2), 1, 0)), [2, 2]) 468s ***** assert (size (gprnd (0, 1, 0, 3)), [3, 3]) 468s ***** assert (size (gprnd (0, 1, 0, [4 1])), [4, 1]) 468s ***** assert (size (gprnd (0, 1, 0, 4, 1)), [4, 1]) 468s ***** assert (size (gprnd (1,1,0)), [1, 1]) 468s ***** assert (size (gprnd (1, 1, zeros (2,1))), [2, 1]) 468s ***** assert (size (gprnd (1, 1, zeros (2,2))), [2, 2]) 468s ***** assert (size (gprnd (1, ones (2,1), 0)), [2, 1]) 468s ***** assert (size (gprnd (1, ones (2,2), 0)), [2, 2]) 468s ***** assert (size (gprnd (ones (2,1), 1, 0)), [2, 1]) 468s ***** assert (size (gprnd (ones (2,2), 1, 0)), [2, 2]) 468s ***** assert (size (gprnd (1, 1, 0, 3)), [3, 3]) 468s ***** assert (size (gprnd (1, 1, 0, [4 1])), [4, 1]) 468s ***** assert (size (gprnd (1, 1, 0, 4, 1)), [4, 1]) 468s ***** assert (size (gprnd (-1, 1, 0)), [1, 1]) 468s ***** assert (size (gprnd (-1, 1, zeros (2,1))), [2, 1]) 468s ***** assert (size (gprnd (1, -1, zeros (2,2))), [2, 2]) 468s ***** assert (size (gprnd (-1, ones (2,1), 0)), [2, 1]) 468s ***** assert (size (gprnd (-1, ones (2,2), 0)), [2, 2]) 468s ***** assert (size (gprnd (-ones (2,1), 1, 0)), [2, 1]) 468s ***** assert (size (gprnd (-ones (2,2), 1, 0)), [2, 2]) 468s ***** assert (size (gprnd (-1, 1, 0, 3)), [3, 3]) 468s ***** assert (size (gprnd (-1, 1, 0, [4, 1])), [4, 1]) 468s ***** assert (size (gprnd (-1, 1, 0, 4, 1)), [4, 1]) 468s ***** assert (class (gprnd (0, 1, 0)), "double") 468s ***** assert (class (gprnd (0, 1, single (0))), "single") 468s ***** assert (class (gprnd (0, 1, single ([0, 0]))), "single") 468s ***** assert (class (gprnd (0, single (1),0)), "single") 468s ***** assert (class (gprnd (0, single ([1, 1]),0)), "single") 468s ***** assert (class (gprnd (single (0), 1, 0)), "single") 468s ***** assert (class (gprnd (single ([0, 0]), 1, 0)), "single") 468s ***** error gprnd () 468s ***** error gprnd (1) 468s ***** error gprnd (1, 2) 468s ***** error ... 468s gprnd (ones (3), ones (2), ones (2)) 468s ***** error ... 468s gprnd (ones (2), ones (3), ones (2)) 468s ***** error ... 468s gprnd (ones (2), ones (2), ones (3)) 468s ***** error gprnd (i, 2, 3) 468s ***** error gprnd (1, i, 3) 468s ***** error gprnd (1, 2, i) 468s ***** error ... 468s gprnd (1, 2, 3, -1) 468s ***** error ... 468s gprnd (1, 2, 3, 1.2) 468s ***** error ... 468s gprnd (1, 2, 3, ones (2)) 468s ***** error ... 468s gprnd (1, 2, 3, [2 -1 2]) 468s ***** error ... 468s gprnd (1, 2, 3, [2 0 2.5]) 468s ***** error ... 468s gprnd (1, 2, 3, 2, -1, 5) 468s ***** error ... 468s gprnd (1, 2, 3, 2, 1.5, 5) 468s ***** error ... 468s gprnd (2, ones (2), 2, 3) 468s ***** error ... 468s gprnd (2, ones (2), 2, [3, 2]) 468s ***** error ... 468s gprnd (2, ones (2), 2, 3, 2) 468s 56 tests, 56 passed, 0 known failure, 0 skipped 468s [inst/dist_fun/finv.m] 468s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/finv.m 468s ***** demo 468s ## Plot various iCDFs from the F distribution 468s p = 0.001:0.001:0.999; 468s x1 = finv (p, 1, 1); 468s x2 = finv (p, 2, 1); 468s x3 = finv (p, 5, 2); 468s x4 = finv (p, 10, 1); 468s x5 = finv (p, 100, 100); 468s plot (p, x1, "-b", p, x2, "-g", p, x3, "-r", p, x4, "-c", p, x5, "-m") 468s grid on 468s ylim ([0, 4]) 468s legend ({"df1 = 1, df2 = 2", "df1 = 2, df2 = 1", ... 468s "df1 = 5, df2 = 2", "df1 = 10, df2 = 1", ... 468s "df1 = 100, df2 = 100"}, "location", "northwest") 468s title ("F iCDF") 468s xlabel ("probability") 468s ylabel ("values in x") 468s ***** shared p 468s p = [-1 0 0.5 1 2]; 468s ***** assert (finv (p, 2*ones (1,5), 2*ones (1,5)), [NaN 0 1 Inf NaN]) 468s ***** assert (finv (p, 2, 2*ones (1,5)), [NaN 0 1 Inf NaN]) 468s ***** assert (finv (p, 2*ones (1,5), 2), [NaN 0 1 Inf NaN]) 468s ***** assert (finv (p, [2 -Inf NaN Inf 2], 2), [NaN NaN NaN NaN NaN]) 468s ***** assert (finv (p, 2, [2 -Inf NaN Inf 2]), [NaN NaN NaN NaN NaN]) 468s ***** assert (finv ([p(1:2) NaN p(4:5)], 2, 2), [NaN 0 NaN Inf NaN]) 468s ***** assert (finv (0.025, 10, 1e6), 0.3247, 1e-4) 468s ***** assert (finv (0.025, 10, 1e7), 0.3247, 1e-4) 468s ***** assert (finv (0.025, 10, 1e10), 0.3247, 1e-4) 468s ***** assert (finv (0.025, 10, 1e255), 0.3247, 1e-4) 468s ***** assert (finv (0.025, 10, Inf), 0.3247, 1e-4) 468s ***** assert (finv ([p, NaN], 2, 2), [NaN 0 1 Inf NaN NaN]) 468s ***** assert (finv (single ([p, NaN]), 2, 2), single ([NaN 0 1 Inf NaN NaN])) 468s ***** assert (finv ([p, NaN], single (2), 2), single ([NaN 0 1 Inf NaN NaN])) 468s ***** assert (finv ([p, NaN], 2, single (2)), single ([NaN 0 1 Inf NaN NaN])) 468s ***** error finv () 468s ***** error finv (1) 468s ***** error finv (1,2) 468s ***** error ... 468s finv (ones (3), ones (2), ones (2)) 468s ***** error ... 468s finv (ones (2), ones (3), ones (2)) 468s ***** error ... 468s finv (ones (2), ones (2), ones (3)) 468s ***** error finv (i, 2, 2) 468s ***** error finv (2, i, 2) 468s ***** error finv (2, 2, i) 468s 24 tests, 24 passed, 0 known failure, 0 skipped 468s [inst/dist_fun/laplacecdf.m] 468s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/laplacecdf.m 468s ***** demo 468s ## Plot various CDFs from the Laplace distribution 468s x = -10:0.01:10; 468s p1 = laplacecdf (x, 0, 1); 468s p2 = laplacecdf (x, 0, 2); 468s p3 = laplacecdf (x, 0, 4); 468s p4 = laplacecdf (x, -5, 4); 468s plot (x, p1, "-b", x, p2, "-g", x, p3, "-r", x, p4, "-c") 468s grid on 468s xlim ([-10, 10]) 468s legend ({"μ = 0, β = 1", "μ = 0, β = 2", ... 468s "μ = 0, β = 4", "μ = -5, β = 4"}, "location", "southeast") 468s title ("Laplace CDF") 468s xlabel ("values in x") 468s ylabel ("probability") 468s ***** shared x, y 468s x = [-Inf, -log(2), 0, log(2), Inf]; 468s y = [0, 1/4, 1/2, 3/4, 1]; 468s ***** assert (laplacecdf ([x, NaN], 0, 1), [y, NaN]) 468s ***** assert (laplacecdf (x, 0, [-2, -1, 0, 1, 2]), [nan(1, 3), 0.75, 1]) 468s ***** assert (laplacecdf (single ([x, NaN]), 0, 1), single ([y, NaN]), eps ("single")) 468s ***** assert (laplacecdf ([x, NaN], single (0), 1), single ([y, NaN]), eps ("single")) 468s ***** assert (laplacecdf ([x, NaN], 0, single (1)), single ([y, NaN]), eps ("single")) 468s ***** error laplacecdf () 468s ***** error laplacecdf (1) 468s ***** error ... 468s laplacecdf (1, 2) 468s ***** error ... 468s laplacecdf (1, 2, 3, 4, 5) 468s ***** error laplacecdf (1, 2, 3, "tail") 468s ***** error laplacecdf (1, 2, 3, 4) 468s ***** error ... 468s laplacecdf (ones (3), ones (2), ones (2)) 468s ***** error ... 468s laplacecdf (ones (2), ones (3), ones (2)) 468s ***** error ... 468s laplacecdf (ones (2), ones (2), ones (3)) 468s ***** error laplacecdf (i, 2, 2) 468s ***** error laplacecdf (2, i, 2) 468s ***** error laplacecdf (2, 2, i) 468s 17 tests, 17 passed, 0 known failure, 0 skipped 468s [inst/dist_fun/mvncdf.m] 468s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/mvncdf.m 468s ***** demo 468s mu = [1, -1]; 468s Sigma = [0.9, 0.4; 0.4, 0.3]; 468s [X1, X2] = meshgrid (linspace (-1, 3, 25)', linspace (-3, 1, 25)'); 468s X = [X1(:), X2(:)]; 468s p = mvncdf (X, mu, Sigma); 468s Z = reshape (p, 25, 25); 468s surf (X1, X2, Z); 468s title ("Bivariate Normal Distribution"); 468s ylabel "X1" 468s xlabel "X2" 468s ***** demo 468s mu = [0, 0]; 468s Sigma = [0.25, 0.3; 0.3, 1]; 468s p = mvncdf ([0 0], [1 1], mu, Sigma); 468s x1 = -3:.2:3; 468s x2 = -3:.2:3; 468s [X1, X2] = meshgrid (x1, x2); 468s X = [X1(:), X2(:)]; 468s p = mvnpdf (X, mu, Sigma); 468s p = reshape (p, length (x2), length (x1)); 468s contour (x1, x2, p, [0.0001, 0.001, 0.01, 0.05, 0.15, 0.25, 0.35]); 468s xlabel ("x"); 468s ylabel ("p"); 468s title ("Probability over Rectangular Region"); 468s line ([0, 0, 1, 1, 0], [1, 0, 0, 1, 1], "Linestyle", "--", "Color", "k"); 468s ***** test 468s fD = (-2:2)'; 468s X = repmat (fD, 1, 4); 468s p = mvncdf (X); 468s assert (p, [0; 0.0006; 0.0625; 0.5011; 0.9121], ones (5, 1) * 1e-4); 468s ***** test 468s mu = [1, -1]; 468s Sigma = [0.9, 0.4; 0.4, 0.3]; 468s [X1,X2] = meshgrid (linspace (-1, 3, 25)', linspace (-3, 1, 25)'); 468s X = [X1(:), X2(:)]; 468s p = mvncdf (X, mu, Sigma); 468s p_out = [0.00011878988774500, 0.00034404112322371, ... 468s 0.00087682502191813, 0.00195221905058185, ... 468s 0.00378235566873474, 0.00638175749734415, ... 468s 0.00943764224329656, 0.01239164888125426, ... 468s 0.01472750274376648, 0.01623228313374828]'; 468s assert (p([1:10]), p_out, 1e-16); 468s ***** test 468s mu = [1, -1]; 468s Sigma = [0.9, 0.4; 0.4, 0.3]; 468s [X1,X2] = meshgrid (linspace (-1, 3, 25)', linspace (-3, 1, 25)'); 468s X = [X1(:), X2(:)]; 468s p = mvncdf (X, mu, Sigma); 468s p_out = [0.8180695783608276, 0.8854485749482751, ... 468s 0.9308108777385832, 0.9579855743025508, ... 468s 0.9722897881414742, 0.9788150170059926, ... 468s 0.9813597788804785, 0.9821977956568989, ... 468s 0.9824283794464095, 0.9824809345614861]'; 468s assert (p([616:625]), p_out, 3e-16); 468s ***** test 468s mu = [0, 0]; 468s Sigma = [0.25, 0.3; 0.3, 1]; 468s [p, err] = mvncdf ([0, 0], [1, 1], mu, Sigma); 468s assert (p, 0.2097424404755626, 1e-16); 468s assert (err, 1e-08); 468s ***** test 468s x = [1 2]; 468s mu = [0.5 1.5]; 468s sigma = [1.0, 0.5; 0.5, 1.0]; 468s p = mvncdf (x, mu, sigma); 468s assert (p, 0.546244443857090, 1e-15); 468s ***** test 468s x = [1 2]; 468s mu = [0.5 1.5]; 468s sigma = [1.0, 0.5; 0.5, 1.0]; 468s a = [-inf 0]; 468s p = mvncdf (a, x, mu, sigma); 468s assert (p, 0.482672935215631, 1e-15); 468s ***** error p = mvncdf (randn (25,26), [], eye (26)); 468s ***** error p = mvncdf (randn (25,8), [], eye (9)); 468s ***** error p = mvncdf (randn (25,4), randn (25,5), [], eye (4)); 468s ***** error p = mvncdf (randn (25,4), randn (25,4), [2, 3; 2, 3], eye (4)); 468s ***** error p = mvncdf (randn (25,4), randn (25,4), ones (1, 5), eye (4)); 468s ***** error p = mvncdf ([-inf, 0], [1, 2], [0.5, 1.5], [1.0, 0.5; 0.5, 1.0], option) 468s 12 tests, 12 passed, 0 known failure, 0 skipped 468s [inst/dist_fun/wishpdf.m] 468s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/wishpdf.m 468s ***** assert(wishpdf(4, 3, 3.1), 0.07702496, 1E-7); 468s ***** assert(wishpdf([2 -0.3;-0.3 4], [1 0.3;0.3 1], 4), 0.004529741, 1E-7); 468s ***** assert(wishpdf([6 2 5; 2 10 -5; 5 -5 25], [9 5 5; 5 10 -8; 5 -8 22], 5.1), 4.474865e-10, 1E-15); 468s ***** error wishpdf () 468s ***** error wishpdf (1, 2) 469s ***** error wishpdf (1, 2, 0) 469s ***** error wishpdf (1, 2) 469s 7 tests, 7 passed, 0 known failure, 0 skipped 469s [inst/dist_fun/normpdf.m] 469s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/normpdf.m 469s ***** demo 469s ## Plot various PDFs from the normal distribution 469s x = -5:0.01:5; 469s y1 = normpdf (x, 0, 0.5); 469s y2 = normpdf (x, 0, 1); 469s y3 = normpdf (x, 0, 2); 469s y4 = normpdf (x, -2, 0.8); 469s plot (x, y1, "-b", x, y2, "-g", x, y3, "-r", x, y4, "-c") 469s grid on 469s xlim ([-5, 5]) 469s ylim ([0, 0.9]) 469s legend ({"μ = 0, σ = 0.5", "μ = 0, σ = 1", ... 469s "μ = 0, σ = 2", "μ = -2, σ = 0.8"}, "location", "northeast") 469s title ("Normal PDF") 469s xlabel ("values in x") 469s ylabel ("density") 469s ***** shared x, y 469s x = [-Inf, 1, 2, Inf]; 469s y = 1 / sqrt (2 * pi) * exp (-(x - 1) .^ 2 / 2); 469s ***** assert (normpdf (x, ones (1,4), ones (1,4)), y, eps) 469s ***** assert (normpdf (x, 1, ones (1,4)), y, eps) 469s ***** assert (normpdf (x, ones (1,4), 1), y, eps) 469s ***** assert (normpdf (x, [0 -Inf NaN Inf], 1), [y(1) NaN NaN NaN], eps) 469s ***** assert (normpdf (x, 1, [Inf NaN -1 0]), [NaN NaN NaN NaN], eps) 469s ***** assert (normpdf ([x, NaN], 1, 1), [y, NaN], eps) 469s ***** assert (normpdf (single ([x, NaN]), 1, 1), single ([y, NaN]), eps ("single")) 469s ***** assert (normpdf ([x, NaN], single (1), 1), single ([y, NaN]), eps ("single")) 469s ***** assert (normpdf ([x, NaN], 1, single (1)), single ([y, NaN]), eps ("single")) 469s ***** error normpdf () 469s ***** error ... 469s normpdf (ones (3), ones (2), ones (2)) 469s ***** error ... 469s normpdf (ones (2), ones (3), ones (2)) 469s ***** error ... 469s normpdf (ones (2), ones (2), ones (3)) 469s ***** error normpdf (i, 2, 2) 469s ***** error normpdf (2, i, 2) 469s ***** error normpdf (2, 2, i) 469s 16 tests, 16 passed, 0 known failure, 0 skipped 469s [inst/dist_fun/fcdf.m] 469s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/fcdf.m 469s ***** demo 469s ## Plot various CDFs from the F distribution 469s x = 0.01:0.01:4; 469s p1 = fcdf (x, 1, 2); 469s p2 = fcdf (x, 2, 1); 469s p3 = fcdf (x, 5, 2); 469s p4 = fcdf (x, 10, 1); 469s p5 = fcdf (x, 100, 100); 469s plot (x, p1, "-b", x, p2, "-g", x, p3, "-r", x, p4, "-c", x, p5, "-m") 469s grid on 469s legend ({"df1 = 1, df2 = 2", "df1 = 2, df2 = 1", ... 469s "df1 = 5, df2 = 2", "df1 = 10, df2 = 1", ... 469s "df1 = 100, df2 = 100"}, "location", "southeast") 469s title ("F CDF") 469s xlabel ("values in x") 469s ylabel ("probability") 469s ***** shared x, y 469s x = [-1, 0, 0.5, 1, 2, Inf]; 469s y = [0, 0, 1/3, 1/2, 2/3, 1]; 469s ***** assert (fcdf (x, 2*ones (1,6), 2*ones (1,6)), y, eps) 469s ***** assert (fcdf (x, 2, 2*ones (1,6)), y, eps) 469s ***** assert (fcdf (x, 2*ones (1,6), 2), y, eps) 469s ***** assert (fcdf (x, [0 NaN Inf 2 2 2], 2), [NaN NaN 0.1353352832366127 y(4:6)], eps) 469s ***** assert (fcdf (x, 2, [0 NaN Inf 2 2 2]), [NaN NaN 0.3934693402873666 y(4:6)], eps) 469s ***** assert (fcdf ([x(1:2) NaN x(4:6)], 2, 2), [y(1:2) NaN y(4:6)], eps) 469s ***** assert (fcdf ([x, NaN], 2, 2), [y, NaN], eps) 469s ***** assert (fcdf (single ([x, NaN]), 2, 2), single ([y, NaN]), eps ("single")) 469s ***** assert (fcdf ([x, NaN], single (2), 2), single ([y, NaN]), eps ("single")) 469s ***** assert (fcdf ([x, NaN], 2, single (2)), single ([y, NaN]), eps ("single")) 469s ***** error fcdf () 469s ***** error fcdf (1) 469s ***** error fcdf (1, 2) 469s ***** error fcdf (1, 2, 3, 4) 469s ***** error fcdf (1, 2, 3, "tail") 469s ***** error ... 469s fcdf (ones (3), ones (2), ones (2)) 469s ***** error ... 469s fcdf (ones (2), ones (3), ones (2)) 469s ***** error ... 469s fcdf (ones (2), ones (2), ones (3)) 469s ***** error fcdf (i, 2, 2) 469s ***** error fcdf (2, i, 2) 469s ***** error fcdf (2, 2, i) 469s 21 tests, 21 passed, 0 known failure, 0 skipped 469s [inst/dist_fun/logipdf.m] 469s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/logipdf.m 469s ***** demo 469s ## Plot various PDFs from the logistic distribution 469s x = -5:0.01:20; 469s y1 = logipdf (x, 5, 2); 469s y2 = logipdf (x, 9, 3); 469s y3 = logipdf (x, 9, 4); 469s y4 = logipdf (x, 6, 2); 469s y5 = logipdf (x, 2, 1); 469s plot (x, y1, "-b", x, y2, "-g", x, y3, "-r", x, y4, "-c", x, y5, "-m") 469s grid on 469s ylim ([0, 0.3]) 469s legend ({"μ = 5, σ = 2", "μ = 9, σ = 3", "μ = 9, σ = 4", ... 469s "μ = 6, σ = 2", "μ = 2, σ = 1"}, "location", "northeast") 469s title ("Logistic PDF") 469s xlabel ("values in x") 469s ylabel ("density") 469s ***** shared x, y 469s x = [-Inf -log(4) 0 log(4) Inf]; 469s y = [0, 0.16, 1/4, 0.16, 0]; 469s ***** assert (logipdf ([x, NaN], 0, 1), [y, NaN], eps) 469s ***** assert (logipdf (x, 0, [-2, -1, 0, 1, 2]), [nan(1, 3), y([4:5])], eps) 469s ***** assert (logipdf (single ([x, NaN]), 0, 1), single ([y, NaN]), eps ("single")) 469s ***** assert (logipdf ([x, NaN], single (0), 1), single ([y, NaN]), eps ("single")) 469s ***** assert (logipdf ([x, NaN], 0, single (1)), single ([y, NaN]), eps ("single")) 469s ***** error logipdf () 469s ***** error logipdf (1) 469s ***** error ... 469s logipdf (1, 2) 469s ***** error ... 469s logipdf (1, ones (2), ones (3)) 469s ***** error ... 469s logipdf (ones (2), 1, ones (3)) 469s ***** error ... 469s logipdf (ones (2), ones (3), 1) 469s ***** error logipdf (i, 2, 3) 469s ***** error logipdf (1, i, 3) 469s ***** error logipdf (1, 2, i) 469s 14 tests, 14 passed, 0 known failure, 0 skipped 469s [inst/dist_fun/tricdf.m] 469s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/tricdf.m 469s ***** demo 469s ## Plot various CDFs from the triangular distribution 469s x = 0.001:0.001:10; 469s p1 = tricdf (x, 3, 4, 6); 469s p2 = tricdf (x, 1, 2, 5); 469s p3 = tricdf (x, 2, 3, 9); 469s p4 = tricdf (x, 2, 5, 9); 469s plot (x, p1, "-b", x, p2, "-g", x, p3, "-r", x, p4, "-c") 469s grid on 469s xlim ([0, 10]) 469s legend ({"a = 3, b = 4, c = 6", "a = 1, b = 2, c = 5", ... 469s "a = 2, b = 3, c = 9", "a = 2, b = 5, c = 9"}, ... 469s "location", "southeast") 469s title ("Triangular CDF") 469s xlabel ("values in x") 469s ylabel ("probability") 469s ***** shared x, y 469s x = [-1, 0, 0.1, 0.5, 0.9, 1, 2] + 1; 469s y = [0, 0, 0.02, 0.5, 0.98, 1 1]; 469s ***** assert (tricdf (x, ones (1,7), 1.5 * ones (1, 7), 2 * ones (1, 7)), y, eps) 469s ***** assert (tricdf (x, 1 * ones (1, 7), 1.5, 2), y, eps) 469s ***** assert (tricdf (x, 1 * ones (1, 7), 1.5, 2, "upper"), 1 - y, eps) 469s ***** assert (tricdf (x, 1, 1.5, 2 * ones (1, 7)), y, eps) 469s ***** assert (tricdf (x, 1, 1.5 * ones (1, 7), 2), y, eps) 469s ***** assert (tricdf (x, 1, 1.5, 2), y, eps) 469s ***** assert (tricdf (x, [1, 1, NaN, 1, 1, 1, 1], 1.5, 2), ... 469s [y(1:2), NaN, y(4:7)], eps) 469s ***** assert (tricdf (x, 1, 1.5, 2*[1, 1, NaN, 1, 1, 1, 1]), ... 469s [y(1:2), NaN, y(4:7)], eps) 469s ***** assert (tricdf (x, 1, 1.5, 2*[1, 1, NaN, 1, 1, 1, 1]), ... 469s [y(1:2), NaN, y(4:7)], eps) 469s ***** assert (tricdf ([x, NaN], 1, 1.5, 2), [y, NaN], eps) 469s ***** assert (tricdf (single ([x, NaN]), 1, 1.5, 2), ... 469s single ([y, NaN]), eps("single")) 469s ***** assert (tricdf ([x, NaN], single (1), 1.5, 2), ... 469s single ([y, NaN]), eps("single")) 469s ***** assert (tricdf ([x, NaN], 1, single (1.5), 2), ... 469s single ([y, NaN]), eps("single")) 469s ***** assert (tricdf ([x, NaN], 1, 1.5, single (2)), ... 469s single ([y, NaN]), eps("single")) 469s ***** error tricdf () 469s ***** error tricdf (1) 469s ***** error tricdf (1, 2) 469s ***** error tricdf (1, 2, 3) 469s ***** error ... 469s tricdf (1, 2, 3, 4, 5, 6) 469s ***** error tricdf (1, 2, 3, 4, "tail") 469s ***** error tricdf (1, 2, 3, 4, 5) 469s ***** error ... 469s tricdf (ones (3), ones (2), ones(2), ones(2)) 469s ***** error ... 469s tricdf (ones (2), ones (3), ones(2), ones(2)) 469s ***** error ... 469s tricdf (ones (2), ones (2), ones(3), ones(2)) 469s ***** error ... 469s tricdf (ones (2), ones (2), ones(2), ones(3)) 469s ***** error tricdf (i, 2, 3, 4) 469s ***** error tricdf (1, i, 3, 4) 469s ***** error tricdf (1, 2, i, 4) 469s ***** error tricdf (1, 2, 3, i) 469s 29 tests, 29 passed, 0 known failure, 0 skipped 469s [inst/dist_fun/ncx2pdf.m] 469s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/ncx2pdf.m 469s ***** demo 469s ## Plot various PDFs from the noncentral chi-squared distribution 469s x = 0:0.1:10; 469s y1 = ncx2pdf (x, 2, 1); 469s y2 = ncx2pdf (x, 2, 2); 469s y3 = ncx2pdf (x, 2, 3); 469s y4 = ncx2pdf (x, 4, 1); 469s y5 = ncx2pdf (x, 4, 2); 469s y6 = ncx2pdf (x, 4, 3); 469s plot (x, y1, "-r", x, y2, "-g", x, y3, "-k", ... 469s x, y4, "-m", x, y5, "-c", x, y6, "-y") 469s grid on 469s xlim ([0, 10]) 469s ylim ([0, 0.32]) 469s legend ({"df = 2, λ = 1", "df = 2, λ = 2", ... 469s "df = 2, λ = 3", "df = 4, λ = 1", ... 469s "df = 4, λ = 2", "df = 4, λ = 3"}, "location", "northeast") 469s title ("Noncentral chi-squared PDF") 469s xlabel ("values in x") 469s ylabel ("density") 469s ***** demo 469s ## Compare the noncentral chi-squared PDF with LAMBDA = 2 to the 469s ## chi-squared PDF with the same number of degrees of freedom (4). 469s 469s x = 0:0.1:10; 469s y1 = ncx2pdf (x, 4, 2); 469s y2 = chi2pdf (x, 4); 469s plot (x, y1, "-", x, y2, "-"); 469s grid on 469s xlim ([0, 10]) 469s ylim ([0, 0.32]) 469s legend ({"Noncentral T(10,1)", "T(10)"}, "location", "northwest") 469s title ("Noncentral chi-squared vs chi-squared PDFs") 469s xlabel ("values in x") 469s ylabel ("density") 469s ***** shared x1, df, d1 469s x1 = [-Inf, 2, NaN, 4, Inf]; 469s df = [2, 0, -1, 1, 4]; 469s d1 = [1, NaN, 3, -1, 2]; 469s ***** assert (ncx2pdf (x1, df, d1), [0, NaN, NaN, NaN, 0]); 469s ***** assert (ncx2pdf (x1, df, 1), [0, 0.07093996461786045, NaN, ... 469s 0.06160064323277038, 0], 1e-14); 469s ***** assert (ncx2pdf (x1, df, 3), [0, 0.1208364909271113, NaN, ... 469s 0.09631299762429098, 0], 1e-14); 469s ***** assert (ncx2pdf (x1, df, 2), [0, 0.1076346446244688, NaN, ... 469s 0.08430464047296625, 0], 1e-14); 469s ***** assert (ncx2pdf (x1, 2, d1), [0, NaN, NaN, NaN, 0]); 469s ***** assert (ncx2pdf (2, df, d1), [0.1747201674611283, NaN, NaN, ... 469s NaN, 0.1076346446244688], 1e-14); 469s ***** assert (ncx2pdf (4, df, d1), [0.09355987820265799, NaN, NaN, ... 469s NaN, 0.1192317192431485], 1e-14); 469s ***** error ncx2pdf () 469s ***** error ncx2pdf (1) 469s ***** error ncx2pdf (1, 2) 469s ***** error ... 469s ncx2pdf (ones (3), ones (2), ones (2)) 469s ***** error ... 469s ncx2pdf (ones (2), ones (3), ones (2)) 469s ***** error ... 469s ncx2pdf (ones (2), ones (2), ones (3)) 469s ***** error ncx2pdf (i, 2, 2) 469s ***** error ncx2pdf (2, i, 2) 469s ***** error ncx2pdf (2, 2, i) 469s 16 tests, 16 passed, 0 known failure, 0 skipped 469s [inst/dist_fun/hncdf.m] 469s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/hncdf.m 469s ***** demo 469s ## Plot various CDFs from the half-normal distribution 469s x = 0:0.001:10; 469s p1 = hncdf (x, 0, 1); 469s p2 = hncdf (x, 0, 2); 469s p3 = hncdf (x, 0, 3); 469s p4 = hncdf (x, 0, 5); 469s plot (x, p1, "-b", x, p2, "-g", x, p3, "-r", x, p4, "-c") 469s grid on 469s xlim ([0, 10]) 469s legend ({"μ = 0, σ = 1", "μ = 0, σ = 2", ... 469s "μ = 0, σ = 3", "μ = 0, σ = 5"}, "location", "southeast") 469s title ("Half-normal CDF") 469s xlabel ("values in x") 469s ylabel ("probability") 469s ***** demo 469s ## Plot half-normal against normal cumulative distribution function 469s x = -5:0.001:5; 469s p1 = hncdf (x, 0, 1); 469s p2 = normcdf (x); 469s plot (x, p1, "-b", x, p2, "-g") 469s grid on 469s xlim ([-5, 5]) 469s legend ({"half-normal with μ = 0, σ = 1", ... 469s "standart normal (μ = 0, σ = 1)"}, "location", "southeast") 469s title ("Half-normal against standard normal CDF") 469s xlabel ("values in x") 469s ylabel ("probability") 469s ***** shared x, p1, p1u, y2, y2u, y3, y3u 469s x = [-Inf, -1, 0, 1/2, 1, Inf]; 469s p1 = [0, 0, 0, 0.3829, 0.6827, 1]; 469s p1u = [1, 1, 1, 0.6171, 0.3173, 0]; 469s ***** assert (hncdf (x, zeros (1,6), ones (1,6)), p1, 1e-4) 469s ***** assert (hncdf (x, 0, 1), p1, 1e-4) 469s ***** assert (hncdf (x, 0, ones (1,6)), p1, 1e-4) 469s ***** assert (hncdf (x, zeros (1,6), 1), p1, 1e-4) 469s ***** assert (hncdf (x, 0, [1, 1, 1, NaN, 1, 1]), [p1(1:3), NaN, p1(5:6)], 1e-4) 469s ***** assert (hncdf (x, [0, 0, 0, NaN, 0, 0], 1), [p1(1:3), NaN, p1(5:6)], 1e-4) 469s ***** assert (hncdf ([x(1:3), NaN, x(5:6)], 0, 1), [p1(1:3), NaN, p1(5:6)], 1e-4) 469s ***** assert (hncdf (x, zeros (1,6), ones (1,6), "upper"), p1u, 1e-4) 469s ***** assert (hncdf (x, 0, 1, "upper"), p1u, 1e-4) 469s ***** assert (hncdf (x, 0, ones (1,6), "upper"), p1u, 1e-4) 469s ***** assert (hncdf (x, zeros (1,6), 1, "upper"), p1u, 1e-4) 469s ***** assert (class (hncdf (single ([x, NaN]), 0, 1)), "single") 469s ***** assert (class (hncdf ([x, NaN], 0, single (1))), "single") 469s ***** assert (class (hncdf ([x, NaN], single (0), 1)), "single") 469s ***** error hncdf () 469s ***** error hncdf (1) 469s ***** error hncdf (1, 2) 469s ***** error hncdf (1, 2, 3, "tail") 469s ***** error hncdf (1, 2, 3, 5) 469s ***** error ... 469s hncdf (ones (3), ones (2), ones(2)) 469s ***** error ... 469s hncdf (ones (2), ones (3), ones(2)) 469s ***** error ... 469s hncdf (ones (2), ones (2), ones(3)) 469s ***** error hncdf (i, 2, 3) 469s ***** error hncdf (1, i, 3) 469s ***** error hncdf (1, 2, i) 469s 25 tests, 25 passed, 0 known failure, 0 skipped 469s [inst/dist_fun/triinv.m] 469s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/triinv.m 469s ***** demo 469s ## Plot various iCDFs from the triangular distribution 469s p = 0.001:0.001:0.999; 469s x1 = triinv (p, 3, 6, 4); 469s x2 = triinv (p, 1, 5, 2); 469s x3 = triinv (p, 2, 9, 3); 469s x4 = triinv (p, 2, 9, 5); 469s plot (p, x1, "-b", p, x2, "-g", p, x3, "-r", p, x4, "-c") 469s grid on 469s ylim ([0, 10]) 469s legend ({"a = 3, b = 6, c = 4", "a = 1, b = 5, c = 2", ... 469s "a = 2, b = 9, c = 3", "a = 2, b = 9, c = 5"}, ... 469s "location", "northwest") 469s title ("Triangular CDF") 469s xlabel ("probability") 469s ylabel ("values in x") 469s ***** shared p, y 469s p = [-1, 0, 0.02, 0.5, 0.98, 1, 2]; 469s y = [NaN, 0, 0.1, 0.5, 0.9, 1, NaN] + 1; 469s ***** assert (triinv (p, ones (1, 7), 1.5 * ones (1, 7), 2 * ones (1, 7)), y, eps) 469s ***** assert (triinv (p, 1 * ones (1, 7), 1.5, 2), y, eps) 469s ***** assert (triinv (p, 1, 1.5, 2 * ones (1, 7)), y, eps) 469s ***** assert (triinv (p, 1, 1.5*ones (1,7), 2), y, eps) 469s ***** assert (triinv (p, 1, 1.5, 2), y, eps) 469s ***** assert (triinv (p, [1, 1, NaN, 1, 1, 1, 1], 1.5, 2), [y(1:2), NaN, y(4:7)], eps) 469s ***** assert (triinv (p, 1, 1.5 * [1, 1, NaN, 1, 1, 1, 1], 2), [y(1:2), NaN, y(4:7)], eps) 469s ***** assert (triinv (p, 1, 1.5, 2 * [1, 1, NaN, 1, 1, 1, 1]), [y(1:2), NaN, y(4:7)], eps) 469s ***** assert (triinv ([p, NaN], 1, 1.5, 2), [y, NaN], eps) 469s ***** assert (triinv (single ([p, NaN]), 1, 1.5, 2), single ([y, NaN]), eps('single')) 469s ***** assert (triinv ([p, NaN], single (1), 1.5, 2), single ([y, NaN]), eps('single')) 469s ***** assert (triinv ([p, NaN], 1, single (1.5), 2), single ([y, NaN]), eps('single')) 469s ***** assert (triinv ([p, NaN], 1, 1.5, single (2)), single ([y, NaN]), eps('single')) 469s ***** error triinv () 469s ***** error triinv (1) 469s ***** error triinv (1, 2) 469s ***** error triinv (1, 2, 3) 469s ***** error ... 469s triinv (1, 2, 3, 4, 5) 469s ***** error ... 469s triinv (ones (3), ones (2), ones(2), ones(2)) 469s ***** error ... 469s triinv (ones (2), ones (3), ones(2), ones(2)) 469s ***** error ... 469s triinv (ones (2), ones (2), ones(3), ones(2)) 469s ***** error ... 469s triinv (ones (2), ones (2), ones(2), ones(3)) 469s ***** error triinv (i, 2, 3, 4) 469s ***** error triinv (1, i, 3, 4) 469s ***** error triinv (1, 2, i, 4) 469s ***** error triinv (1, 2, 3, i) 469s 26 tests, 26 passed, 0 known failure, 0 skipped 469s [inst/dist_fun/nctrnd.m] 469s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/nctrnd.m 469s ***** assert (size (nctrnd (1, 1)), [1 1]) 469s ***** assert (size (nctrnd (1, ones (2,1))), [2, 1]) 469s ***** assert (size (nctrnd (1, ones (2,2))), [2, 2]) 469s ***** assert (size (nctrnd (ones (2,1), 1)), [2, 1]) 469s ***** assert (size (nctrnd (ones (2,2), 1)), [2, 2]) 469s ***** assert (size (nctrnd (1, 1, 3)), [3, 3]) 469s ***** assert (size (nctrnd (1, 1, [4, 1])), [4, 1]) 469s ***** assert (size (nctrnd (1, 1, 4, 1)), [4, 1]) 470s ***** assert (size (nctrnd (1, 1, 4, 1, 5)), [4, 1, 5]) 470s ***** assert (size (nctrnd (1, 1, 0, 1)), [0, 1]) 470s ***** assert (size (nctrnd (1, 1, 1, 0)), [1, 0]) 470s ***** assert (size (nctrnd (1, 1, 1, 2, 0, 5)), [1, 2, 0, 5]) 470s ***** assert (class (nctrnd (1, 1)), "double") 470s ***** assert (class (nctrnd (1, single (1))), "single") 470s ***** assert (class (nctrnd (1, single ([1, 1]))), "single") 470s ***** assert (class (nctrnd (single (1), 1)), "single") 470s ***** assert (class (nctrnd (single ([1, 1]), 1)), "single") 470s ***** error nctrnd () 470s ***** error nctrnd (1) 470s ***** error ... 470s nctrnd (ones (3), ones (2)) 470s ***** error ... 470s nctrnd (ones (2), ones (3)) 470s ***** error nctrnd (i, 2) 470s ***** error nctrnd (1, i) 470s ***** error ... 470s nctrnd (1, 2, -1) 470s ***** error ... 470s nctrnd (1, 2, 1.2) 470s ***** error ... 470s nctrnd (1, 2, ones (2)) 470s ***** error ... 470s nctrnd (1, 2, [2 -1 2]) 470s ***** error ... 470s nctrnd (1, 2, [2 0 2.5]) 470s ***** error ... 470s nctrnd (1, 2, 2, -1, 5) 470s ***** error ... 470s nctrnd (1, 2, 2, 1.5, 5) 470s ***** error ... 470s nctrnd (2, ones (2), 3) 470s ***** error ... 470s nctrnd (2, ones (2), [3, 2]) 470s ***** error ... 470s nctrnd (2, ones (2), 3, 2) 470s 33 tests, 33 passed, 0 known failure, 0 skipped 470s [inst/dist_fun/exprnd.m] 470s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/exprnd.m 470s ***** assert (size (exprnd (2)), [1, 1]) 470s ***** assert (size (exprnd (ones (2,1))), [2, 1]) 470s ***** assert (size (exprnd (ones (2,2))), [2, 2]) 470s ***** assert (size (exprnd (1, 3)), [3, 3]) 470s ***** assert (size (exprnd (1, [4 1])), [4, 1]) 470s ***** assert (size (exprnd (1, 4, 1)), [4, 1]) 470s ***** assert (size (exprnd (1, 4, 1)), [4, 1]) 470s ***** assert (size (exprnd (1, 4, 1, 5)), [4, 1, 5]) 470s ***** assert (size (exprnd (1, 0, 1)), [0, 1]) 470s ***** assert (size (exprnd (1, 1, 0)), [1, 0]) 470s ***** assert (size (exprnd (1, 1, 2, 0, 5)), [1, 2, 0, 5]) 470s ***** assert (class (exprnd (2)), "double") 470s ***** assert (class (exprnd (single (2))), "single") 470s ***** assert (class (exprnd (single ([2 2]))), "single") 470s ***** error exprnd () 470s ***** error exprnd (i) 470s ***** error ... 470s exprnd (1, -1) 470s ***** error ... 470s exprnd (1, 1.2) 470s ***** error ... 470s exprnd (1, ones (2)) 470s ***** error ... 470s exprnd (1, [2 -1 2]) 470s ***** error ... 470s exprnd (1, [2 0 2.5]) 470s ***** error ... 470s exprnd (ones (2), ones (2)) 470s ***** error ... 470s exprnd (1, 2, -1, 5) 470s ***** error ... 470s exprnd (1, 2, 1.5, 5) 470s ***** error exprnd (ones (2,2), 3) 470s ***** error exprnd (ones (2,2), [3, 2]) 470s ***** error exprnd (ones (2,2), 2, 3) 470s 27 tests, 27 passed, 0 known failure, 0 skipped 470s [inst/dist_fun/logirnd.m] 470s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/logirnd.m 470s ***** assert (size (logirnd (1, 1)), [1 1]) 470s ***** assert (size (logirnd (1, ones (2,1))), [2, 1]) 470s ***** assert (size (logirnd (1, ones (2,2))), [2, 2]) 470s ***** assert (size (logirnd (ones (2,1), 1)), [2, 1]) 470s ***** assert (size (logirnd (ones (2,2), 1)), [2, 2]) 470s ***** assert (size (logirnd (1, 1, 3)), [3, 3]) 470s ***** assert (size (logirnd (1, 1, [4, 1])), [4, 1]) 470s ***** assert (size (logirnd (1, 1, 4, 1)), [4, 1]) 470s ***** assert (size (logirnd (1, 1, 4, 1, 5)), [4, 1, 5]) 470s ***** assert (size (logirnd (1, 1, 0, 1)), [0, 1]) 470s ***** assert (size (logirnd (1, 1, 1, 0)), [1, 0]) 470s ***** assert (size (logirnd (1, 1, 1, 2, 0, 5)), [1, 2, 0, 5]) 470s ***** assert (class (logirnd (1, 1)), "double") 470s ***** assert (class (logirnd (1, single (1))), "single") 470s ***** assert (class (logirnd (1, single ([1, 1]))), "single") 470s ***** assert (class (logirnd (single (1), 1)), "single") 470s ***** assert (class (logirnd (single ([1, 1]), 1)), "single") 470s ***** error logirnd () 470s ***** error logirnd (1) 470s ***** error ... 470s logirnd (ones (3), ones (2)) 470s ***** error ... 470s logirnd (ones (2), ones (3)) 470s ***** error logirnd (i, 2, 3) 470s ***** error logirnd (1, i, 3) 470s ***** error ... 470s logirnd (1, 2, -1) 470s ***** error ... 470s logirnd (1, 2, 1.2) 470s ***** error ... 470s logirnd (1, 2, ones (2)) 470s ***** error ... 470s logirnd (1, 2, [2 -1 2]) 470s ***** error ... 470s logirnd (1, 2, [2 0 2.5]) 470s ***** error ... 470s logirnd (1, 2, 2, -1, 5) 470s ***** error ... 470s logirnd (1, 2, 2, 1.5, 5) 470s ***** error ... 470s logirnd (2, ones (2), 3) 470s ***** error ... 470s logirnd (2, ones (2), [3, 2]) 470s ***** error ... 470s logirnd (2, ones (2), 3, 2) 470s 33 tests, 33 passed, 0 known failure, 0 skipped 470s [inst/dist_fun/tpdf.m] 470s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/tpdf.m 470s ***** demo 470s ## Plot various PDFs from the Student's T distribution 470s x = -5:0.01:5; 470s y1 = tpdf (x, 1); 470s y2 = tpdf (x, 2); 470s y3 = tpdf (x, 5); 470s y4 = tpdf (x, Inf); 470s plot (x, y1, "-b", x, y2, "-g", x, y3, "-r", x, y4, "-m") 470s grid on 470s xlim ([-5, 5]) 470s ylim ([0, 0.41]) 470s legend ({"df = 1", "df = 2", ... 470s "df = 5", 'df = \infty'}, "location", "northeast") 470s title ("Student's T PDF") 470s xlabel ("values in x") 470s ylabel ("density") 470s ***** test 470s x = rand (10,1); 470s y = 1./(pi * (1 + x.^2)); 470s assert (tpdf (x, 1), y, 5*eps); 470s ***** shared x, y 470s x = [-Inf 0 0.5 1 Inf]; 470s y = 1./(pi * (1 + x.^2)); 470s ***** assert (tpdf (x, ones (1,5)), y, eps) 470s ***** assert (tpdf (x, 1), y, eps) 470s ***** assert (tpdf (x, [0 NaN 1 1 1]), [NaN NaN y(3:5)], eps) 470s ***** assert (tpdf (x, Inf), normpdf (x)) 470s ***** assert (tpdf ([x, NaN], 1), [y, NaN], eps) 470s ***** assert (tpdf (single ([x, NaN]), 1), single ([y, NaN]), eps ("single")) 470s ***** assert (tpdf ([x, NaN], single (1)), single ([y, NaN]), eps ("single")) 470s ***** error tpdf () 470s ***** error tpdf (1) 470s ***** error ... 470s tpdf (ones (3), ones (2)) 470s ***** error ... 470s tpdf (ones (2), ones (3)) 470s ***** error tpdf (i, 2) 470s ***** error tpdf (2, i) 470s 14 tests, 14 passed, 0 known failure, 0 skipped 470s [inst/dist_fun/bvncdf.m] 470s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/bvncdf.m 470s ***** demo 470s mu = [1, -1]; 470s sigma = [0.9, 0.4; 0.4, 0.3]; 470s [X1, X2] = meshgrid (linspace (-1, 3, 25)', linspace (-3, 1, 25)'); 470s x = [X1(:), X2(:)]; 470s p = bvncdf (x, mu, sigma); 470s Z = reshape (p, 25, 25); 470s surf (X1, X2, Z); 470s title ("Bivariate Normal Distribution"); 470s ylabel "X1" 470s xlabel "X2" 470s ***** test 470s mu = [1, -1]; 470s sigma = [0.9, 0.4; 0.4, 0.3]; 470s [X1,X2] = meshgrid (linspace (-1, 3, 25)', linspace (-3, 1, 25)'); 470s x = [X1(:), X2(:)]; 470s p = bvncdf (x, mu, sigma); 470s p_out = [0.00011878988774500, 0.00034404112322371, ... 470s 0.00087682502191813, 0.00195221905058185, ... 470s 0.00378235566873474, 0.00638175749734415, ... 470s 0.00943764224329656, 0.01239164888125426, ... 470s 0.01472750274376648, 0.01623228313374828]'; 470s assert (p([1:10]), p_out, 1e-16); 470s ***** test 470s mu = [1, -1]; 470s sigma = [0.9, 0.4; 0.4, 0.3]; 470s [X1,X2] = meshgrid (linspace (-1, 3, 25)', linspace (-3, 1, 25)'); 470s x = [X1(:), X2(:)]; 470s p = bvncdf (x, mu, sigma); 470s p_out = [0.8180695783608276, 0.8854485749482751, ... 470s 0.9308108777385832, 0.9579855743025508, ... 470s 0.9722897881414742, 0.9788150170059926, ... 470s 0.9813597788804785, 0.9821977956568989, ... 470s 0.9824283794464095, 0.9824809345614861]'; 470s assert (p([616:625]), p_out, 3e-16); 470s ***** error bvncdf (randn (25,3), [], [1, 1; 1, 1]); 470s ***** error bvncdf (randn (25,2), [], [1, 1; 1, 1]); 470s ***** error bvncdf (randn (25,2), [], ones (3, 2)); 470s 5 tests, 5 passed, 0 known failure, 0 skipped 470s [inst/dist_fun/cauchycdf.m] 470s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/cauchycdf.m 470s ***** demo 470s ## Plot various CDFs from the Cauchy distribution 470s x = -5:0.01:5; 470s p1 = cauchycdf (x, 0, 0.5); 470s p2 = cauchycdf (x, 0, 1); 470s p3 = cauchycdf (x, 0, 2); 470s p4 = cauchycdf (x, -2, 1); 470s plot (x, p1, "-b", x, p2, "-g", x, p3, "-r", x, p4, "-c") 470s grid on 470s xlim ([-5, 5]) 470s legend ({"x0 = 0, γ = 0.5", "x0 = 0, γ = 1", ... 470s "x0 = 0, γ = 2", "x0 = -2, γ = 1"}, "location", "southeast") 470s title ("Cauchy CDF") 470s xlabel ("values in x") 470s ylabel ("probability") 470s ***** shared x, y 470s x = [-1 0 0.5 1 2]; 470s y = 1/pi * atan ((x-1) / 2) + 1/2; 470s ***** assert (cauchycdf (x, ones (1,5), 2*ones (1,5)), y) 470s ***** assert (cauchycdf (x, 1, 2*ones (1,5)), y) 470s ***** assert (cauchycdf (x, ones (1,5), 2), y) 470s ***** assert (cauchycdf (x, [-Inf 1 NaN 1 Inf], 2), [NaN y(2) NaN y(4) NaN]) 470s ***** assert (cauchycdf (x, 1, 2*[0 1 NaN 1 Inf]), [NaN y(2) NaN y(4) NaN]) 470s ***** assert (cauchycdf ([x(1:2) NaN x(4:5)], 1, 2), [y(1:2) NaN y(4:5)]) 470s ***** assert (cauchycdf ([x, NaN], 1, 2), [y, NaN]) 470s ***** assert (cauchycdf (single ([x, NaN]), 1, 2), single ([y, NaN]), eps ("single")) 470s ***** assert (cauchycdf ([x, NaN], single (1), 2), single ([y, NaN]), eps ("single")) 470s ***** assert (cauchycdf ([x, NaN], 1, single (2)), single ([y, NaN]), eps ("single")) 470s ***** error cauchycdf () 470s ***** error cauchycdf (1) 470s ***** error ... 470s cauchycdf (1, 2) 470s ***** error ... 470s cauchycdf (1, 2, 3, 4, 5) 470s ***** error cauchycdf (1, 2, 3, "tail") 470s ***** error cauchycdf (1, 2, 3, 4) 470s ***** error ... 470s cauchycdf (ones (3), ones (2), ones (2)) 470s ***** error ... 470s cauchycdf (ones (2), ones (3), ones (2)) 470s ***** error ... 470s cauchycdf (ones (2), ones (2), ones (3)) 470s ***** error cauchycdf (i, 2, 2) 470s ***** error cauchycdf (2, i, 2) 470s ***** error cauchycdf (2, 2, i) 470s 22 tests, 22 passed, 0 known failure, 0 skipped 470s [inst/dist_fun/poissrnd.m] 470s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/poissrnd.m 470s ***** assert (size (poissrnd (2)), [1, 1]) 470s ***** assert (size (poissrnd (ones (2,1))), [2, 1]) 470s ***** assert (size (poissrnd (ones (2,2))), [2, 2]) 470s ***** assert (size (poissrnd (1, 3)), [3, 3]) 470s ***** assert (size (poissrnd (1, [4 1])), [4, 1]) 470s ***** assert (size (poissrnd (1, 4, 1)), [4, 1]) 470s ***** assert (size (poissrnd (1, 4, 1)), [4, 1]) 470s ***** assert (size (poissrnd (1, 4, 1, 5)), [4, 1, 5]) 470s ***** assert (size (poissrnd (1, 0, 1)), [0, 1]) 470s ***** assert (size (poissrnd (1, 1, 0)), [1, 0]) 470s ***** assert (size (poissrnd (1, 1, 2, 0, 5)), [1, 2, 0, 5]) 470s ***** assert (poissrnd (0, 1, 1), 0) 470s ***** assert (poissrnd ([0, 0, 0], [1, 3]), [0 0 0]) 470s ***** assert (class (poissrnd (2)), "double") 470s ***** assert (class (poissrnd (single (2))), "single") 470s ***** assert (class (poissrnd (single ([2 2]))), "single") 470s ***** error poissrnd () 470s ***** error poissrnd (i) 470s ***** error ... 470s poissrnd (1, -1) 470s ***** error ... 470s poissrnd (1, 1.2) 470s ***** error ... 470s poissrnd (1, ones (2)) 470s ***** error ... 470s poissrnd (1, [2 -1 2]) 470s ***** error ... 470s poissrnd (1, [2 0 2.5]) 470s ***** error ... 470s poissrnd (ones (2), ones (2)) 470s ***** error ... 470s poissrnd (1, 2, -1, 5) 470s ***** error ... 470s poissrnd (1, 2, 1.5, 5) 470s ***** error poissrnd (ones (2,2), 3) 470s ***** error poissrnd (ones (2,2), [3, 2]) 470s ***** error poissrnd (ones (2,2), 2, 3) 470s 29 tests, 29 passed, 0 known failure, 0 skipped 470s [inst/dist_fun/evcdf.m] 470s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/evcdf.m 470s ***** demo 470s ## Plot various CDFs from the extreme value distribution 470s x = -10:0.01:10; 470s p1 = evcdf (x, 0.5, 2); 470s p2 = evcdf (x, 1.0, 2); 470s p3 = evcdf (x, 1.5, 3); 470s p4 = evcdf (x, 3.0, 4); 470s plot (x, p1, "-b", x, p2, "-g", x, p3, "-r", x, p4, "-c") 470s grid on 470s legend ({"μ = 0.5, σ = 2", "μ = 1.0, σ = 2", ... 470s "μ = 1.5, σ = 3", "μ = 3.0, σ = 4"}, "location", "southeast") 470s title ("Extreme value CDF") 470s xlabel ("values in x") 470s ylabel ("probability") 470s ***** shared x, y 470s x = [-Inf, 1, 2, Inf]; 470s y = [0, 0.6321, 0.9340, 1]; 470s ***** assert (evcdf (x, ones (1,4), ones (1,4)), y, 1e-4) 470s ***** assert (evcdf (x, 1, ones (1,4)), y, 1e-4) 470s ***** assert (evcdf (x, ones (1,4), 1), y, 1e-4) 470s ***** assert (evcdf (x, [0, -Inf, NaN, Inf], 1), [0, 1, NaN, NaN], 1e-4) 470s ***** assert (evcdf (x, 1, [Inf, NaN, -1, 0]), [NaN, NaN, NaN, NaN], 1e-4) 470s ***** assert (evcdf ([x(1:2), NaN, x(4)], 1, 1), [y(1:2), NaN, y(4)], 1e-4) 470s ***** assert (evcdf (x, "upper"), [1, 0.0660, 0.0006, 0], 1e-4) 470s ***** assert (evcdf ([x, NaN], 1, 1), [y, NaN], 1e-4) 470s ***** assert (evcdf (single ([x, NaN]), 1, 1), single ([y, NaN]), 1e-4) 470s ***** assert (evcdf ([x, NaN], single (1), 1), single ([y, NaN]), 1e-4) 470s ***** assert (evcdf ([x, NaN], 1, single (1)), single ([y, NaN]), 1e-4) 470s ***** error evcdf () 470s ***** error evcdf (1,2,3,4,5,6,7) 470s ***** error evcdf (1, 2, 3, 4, "uper") 470s ***** error ... 470s evcdf (ones (3), ones (2), ones (2)) 470s ***** error evcdf (2, 3, 4, [1, 2]) 470s ***** error ... 470s [p, plo, pup] = evcdf (1, 2, 3) 470s ***** error [p, plo, pup] = ... 470s evcdf (1, 2, 3, [1, 0; 0, 1], 0) 470s ***** error [p, plo, pup] = ... 470s evcdf (1, 2, 3, [1, 0; 0, 1], 1.22) 470s ***** error [p, plo, pup] = ... 470s evcdf (1, 2, 3, [1, 0; 0, 1], "alpha", "upper") 470s ***** error evcdf (i, 2, 2) 470s ***** error evcdf (2, i, 2) 470s ***** error evcdf (2, 2, i) 470s ***** error ... 470s [p, plo, pup] = evcdf (1, 2, 3, [1, 0; 0, -inf], 0.04) 470s 24 tests, 24 passed, 0 known failure, 0 skipped 470s [inst/dist_fun/hnrnd.m] 470s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/hnrnd.m 470s ***** assert (size (hnrnd (1, 1, 1)), [1, 1]) 470s ***** assert (size (hnrnd (1, 1, 2)), [2, 2]) 470s ***** assert (size (hnrnd (1, 1, [2, 1])), [2, 1]) 470s ***** assert (size (hnrnd (1, zeros (2, 2))), [2, 2]) 470s ***** assert (size (hnrnd (1, ones (2, 1))), [2, 1]) 470s ***** assert (size (hnrnd (1, ones (2, 2))), [2, 2]) 470s ***** assert (size (hnrnd (ones (2, 1), 1)), [2, 1]) 470s ***** assert (size (hnrnd (ones (2, 2), 1)), [2, 2]) 470s ***** assert (size (hnrnd (1, 1, 3)), [3, 3]) 470s ***** assert (size (hnrnd (1, 1, [4 1])), [4, 1]) 470s ***** assert (size (hnrnd (1, 1, 4, 1)), [4, 1]) 470s ***** test 470s r = hnrnd (1, [1, 0, -1]); 470s assert (r([2:3]), [NaN, NaN]) 470s ***** assert (class (hnrnd (1, 0)), "double") 470s ***** assert (class (hnrnd (1, single (0))), "single") 470s ***** assert (class (hnrnd (1, single ([0 0]))), "single") 470s ***** assert (class (hnrnd (1, single (1))), "single") 470s ***** assert (class (hnrnd (1, single ([1 1]))), "single") 470s ***** assert (class (hnrnd (single (1), 1)), "single") 470s ***** assert (class (hnrnd (single ([1 1]), 1)), "single") 470s ***** error hnrnd () 470s ***** error hnrnd (1) 470s ***** error ... 470s hnrnd (ones (3), ones (2)) 470s ***** error ... 470s hnrnd (ones (2), ones (3)) 470s ***** error hnrnd (i, 2, 3) 470s ***** error hnrnd (1, i, 3) 470s ***** error ... 470s hnrnd (1, 2, -1) 470s ***** error ... 470s hnrnd (1, 2, 1.2) 470s ***** error ... 470s hnrnd (1, 2, ones (2)) 470s ***** error ... 470s hnrnd (1, 2, [2 -1 2]) 470s ***** error ... 470s hnrnd (1, 2, [2 0 2.5]) 470s ***** error ... 470s hnrnd (1, 2, 2, -1, 5) 470s ***** error ... 470s hnrnd (1, 2, 2, 1.5, 5) 470s ***** error ... 470s hnrnd (2, ones (2), 3) 470s ***** error ... 470s hnrnd (2, ones (2), [3, 2]) 470s ***** error ... 470s hnrnd (2, ones (2), 3, 2) 470s 35 tests, 35 passed, 0 known failure, 0 skipped 470s [inst/dist_fun/ncfrnd.m] 470s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/ncfrnd.m 470s ***** assert (size (ncfrnd (1, 1, 1)), [1 1]) 470s ***** assert (size (ncfrnd (1, ones (2,1), 1)), [2, 1]) 470s ***** assert (size (ncfrnd (1, ones (2,2), 1)), [2, 2]) 470s ***** assert (size (ncfrnd (ones (2,1), 1, 1)), [2, 1]) 470s ***** assert (size (ncfrnd (ones (2,2), 1, 1)), [2, 2]) 470s ***** assert (size (ncfrnd (1, 1, 1, 3)), [3, 3]) 470s ***** assert (size (ncfrnd (1, 1, 1, [4, 1])), [4, 1]) 470s ***** assert (size (ncfrnd (1, 1, 1, 4, 1)), [4, 1]) 470s ***** assert (size (ncfrnd (1, 1, 1, 4, 1, 5)), [4, 1, 5]) 470s ***** assert (size (ncfrnd (1, 1, 1, 0, 1)), [0, 1]) 470s ***** assert (size (ncfrnd (1, 1, 1, 1, 0)), [1, 0]) 470s ***** assert (size (ncfrnd (1, 1, 1, 1, 2, 0, 5)), [1, 2, 0, 5]) 470s ***** assert (class (ncfrnd (1, 1, 1)), "double") 470s ***** assert (class (ncfrnd (1, single (1), 1)), "single") 470s ***** assert (class (ncfrnd (1, 1, single (1))), "single") 470s ***** assert (class (ncfrnd (1, single ([1, 1]), 1)), "single") 470s ***** assert (class (ncfrnd (1, 1, single ([1, 1]))), "single") 470s ***** assert (class (ncfrnd (single (1), 1, 1)), "single") 470s ***** assert (class (ncfrnd (single ([1, 1]), 1, 1)), "single") 470s ***** error ncfrnd () 470s ***** error ncfrnd (1) 470s ***** error ncfrnd (1, 2) 470s ***** error ... 470s ncfrnd (ones (3), ones (2), ones (2)) 470s ***** error ... 470s ncfrnd (ones (2), ones (3), ones (2)) 470s ***** error ... 470s ncfrnd (ones (2), ones (2), ones (3)) 470s ***** error ncfrnd (i, 2, 3) 470s ***** error ncfrnd (1, i, 3) 470s ***** error ncfrnd (1, 2, i) 470s ***** error ... 470s ncfrnd (1, 2, 3, -1) 470s ***** error ... 470s ncfrnd (1, 2, 3, 1.2) 470s ***** error ... 470s ncfrnd (1, 2, 3, ones (2)) 470s ***** error ... 470s ncfrnd (1, 2, 3, [2 -1 2]) 470s ***** error ... 470s ncfrnd (1, 2, 3, [2 0 2.5]) 470s ***** error ... 470s ncfrnd (1, 2, 3, 2, -1, 5) 470s ***** error ... 470s ncfrnd (1, 2, 3, 2, 1.5, 5) 470s ***** error ... 470s ncfrnd (2, ones (2), 2, 3) 470s ***** error ... 470s ncfrnd (2, ones (2), 2, [3, 2]) 470s ***** error ... 470s ncfrnd (2, ones (2), 2, 3, 2) 470s 38 tests, 38 passed, 0 known failure, 0 skipped 470s [inst/dist_fun/ricernd.m] 470s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/ricernd.m 470s ***** assert (size (ricernd (2, 1/2)), [1, 1]) 470s ***** assert (size (ricernd (2 * ones (2, 1), 1/2)), [2, 1]) 470s ***** assert (size (ricernd (2 * ones (2, 2), 1/2)), [2, 2]) 470s ***** assert (size (ricernd (2, 1/2 * ones (2, 1))), [2, 1]) 470s ***** assert (size (ricernd (1, 1/2 * ones (2, 2))), [2, 2]) 470s ***** assert (size (ricernd (ones (2, 1), 1)), [2, 1]) 470s ***** assert (size (ricernd (ones (2, 2), 1)), [2, 2]) 470s ***** assert (size (ricernd (2, 1/2, 3)), [3, 3]) 470s ***** assert (size (ricernd (1, 1, [4, 1])), [4, 1]) 470s ***** assert (size (ricernd (1, 1, 4, 1)), [4, 1]) 471s ***** assert (size (ricernd (1, 1, 4, 1, 5)), [4, 1, 5]) 471s ***** assert (size (ricernd (1, 1, 0, 1)), [0, 1]) 471s ***** assert (size (ricernd (1, 1, 1, 0)), [1, 0]) 471s ***** assert (size (ricernd (1, 1, 1, 2, 0, 5)), [1, 2, 0, 5]) 471s ***** assert (class (ricernd (1, 1)), "double") 471s ***** assert (class (ricernd (1, single (0))), "single") 471s ***** assert (class (ricernd (1, single ([0, 0]))), "single") 471s ***** assert (class (ricernd (1, single (1), 2)), "single") 471s ***** assert (class (ricernd (1, single ([1, 1]), 1, 2)), "single") 471s ***** assert (class (ricernd (single (1), 1, 2)), "single") 471s ***** assert (class (ricernd (single ([1, 1]), 1, 1, 2)), "single") 471s ***** error ricernd () 471s ***** error ricernd (1) 471s ***** error ... 471s ricernd (ones (3), ones (2)) 471s ***** error ... 471s ricernd (ones (2), ones (3)) 471s ***** error ricernd (i, 2) 471s ***** error ricernd (1, i) 471s ***** error ... 471s ricernd (1, 1/2, -1) 471s ***** error ... 471s ricernd (1, 1/2, 1.2) 471s ***** error ... 471s ricernd (1, 1/2, ones (2)) 471s ***** error ... 471s ricernd (1, 1/2, [2 -1 2]) 471s ***** error ... 471s ricernd (1, 1/2, [2 0 2.5]) 471s ***** error ... 471s ricernd (1, 1/2, 2, -1, 5) 471s ***** error ... 471s ricernd (1, 1/2, 2, 1.5, 5) 471s ***** error ... 471s ricernd (2, 1/2 * ones (2), 3) 471s ***** error ... 471s ricernd (2, 1/2 * ones (2), [3, 2]) 471s ***** error ... 471s ricernd (2, 1/2 * ones (2), 3, 2) 471s ***** error ... 471s ricernd (2 * ones (2), 1/2, 3) 471s ***** error ... 471s ricernd (2 * ones (2), 1/2, [3, 2]) 471s ***** error ... 471s ricernd (2 * ones (2), 1/2, 3, 2) 471s 40 tests, 40 passed, 0 known failure, 0 skipped 471s [inst/dist_fun/frnd.m] 471s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/frnd.m 471s ***** assert (size (frnd (1, 1)), [1 1]) 471s ***** assert (size (frnd (1, ones (2,1))), [2, 1]) 471s ***** assert (size (frnd (1, ones (2,2))), [2, 2]) 471s ***** assert (size (frnd (ones (2,1), 1)), [2, 1]) 471s ***** assert (size (frnd (ones (2,2), 1)), [2, 2]) 471s ***** assert (size (frnd (1, 1, 3)), [3, 3]) 471s ***** assert (size (frnd (1, 1, [4, 1])), [4, 1]) 471s ***** assert (size (frnd (1, 1, 4, 1)), [4, 1]) 471s ***** assert (size (frnd (1, 1, 4, 1, 5)), [4, 1, 5]) 471s ***** assert (size (frnd (1, 1, 0, 1)), [0, 1]) 471s ***** assert (size (frnd (1, 1, 1, 0)), [1, 0]) 471s ***** assert (size (frnd (1, 1, 1, 2, 0, 5)), [1, 2, 0, 5]) 471s ***** assert (class (frnd (1, 1)), "double") 471s ***** assert (class (frnd (1, single (1))), "single") 471s ***** assert (class (frnd (1, single ([1, 1]))), "single") 471s ***** assert (class (frnd (single (1), 1)), "single") 471s ***** assert (class (frnd (single ([1, 1]), 1)), "single") 471s ***** error frnd () 471s ***** error frnd (1) 471s ***** error ... 471s frnd (ones (3), ones (2)) 471s ***** error ... 471s frnd (ones (2), ones (3)) 471s ***** error frnd (i, 2, 3) 471s ***** error frnd (1, i, 3) 471s ***** error ... 471s frnd (1, 2, -1) 471s ***** error ... 471s frnd (1, 2, 1.2) 471s ***** error ... 471s frnd (1, 2, ones (2)) 471s ***** error ... 471s frnd (1, 2, [2 -1 2]) 471s ***** error ... 471s frnd (1, 2, [2 0 2.5]) 471s ***** error ... 471s frnd (1, 2, 2, -1, 5) 471s ***** error ... 471s frnd (1, 2, 2, 1.5, 5) 471s ***** error ... 471s frnd (2, ones (2), 3) 471s ***** error ... 471s frnd (2, ones (2), [3, 2]) 471s ***** error ... 471s frnd (2, ones (2), 3, 2) 471s 33 tests, 33 passed, 0 known failure, 0 skipped 471s [inst/dist_fun/nakacdf.m] 471s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/nakacdf.m 471s ***** demo 471s ## Plot various CDFs from the Nakagami distribution 471s x = 0:0.01:3; 471s p1 = nakacdf (x, 0.5, 1); 471s p2 = nakacdf (x, 1, 1); 471s p3 = nakacdf (x, 1, 2); 471s p4 = nakacdf (x, 1, 3); 471s p5 = nakacdf (x, 2, 1); 471s p6 = nakacdf (x, 2, 2); 471s p7 = nakacdf (x, 5, 1); 471s plot (x, p1, "-r", x, p2, "-g", x, p3, "-y", x, p4, "-m", ... 471s x, p5, "-k", x, p6, "-b", x, p7, "-c") 471s grid on 471s xlim ([0, 3]) 471s legend ({"μ = 0.5, ω = 1", "μ = 1, ω = 1", "μ = 1, ω = 2", ... 471s "μ = 1, ω = 3", "μ = 2, ω = 1", "μ = 2, ω = 2", ... 471s "μ = 5, ω = 1"}, "location", "southeast") 471s title ("Nakagami CDF") 471s xlabel ("values in x") 471s ylabel ("probability") 471s ***** shared x, y 471s x = [-1, 0, 1, 2, Inf]; 471s y = [0, 0, 0.63212055882855778, 0.98168436111126578, 1]; 471s ***** assert (nakacdf (x, ones (1,5), ones (1,5)), y, eps) 471s ***** assert (nakacdf (x, 1, 1), y, eps) 471s ***** assert (nakacdf (x, [1, 1, NaN, 1, 1], 1), [y(1:2), NaN, y(4:5)]) 471s ***** assert (nakacdf (x, 1, [1, 1, NaN, 1, 1]), [y(1:2), NaN, y(4:5)]) 471s ***** assert (nakacdf ([x, NaN], 1, 1), [y, NaN], eps) 471s ***** assert (nakacdf (single ([x, NaN]), 1, 1), single ([y, NaN]), eps("single")) 471s ***** assert (nakacdf ([x, NaN], single (1), 1), single ([y, NaN]), eps("single")) 471s ***** assert (nakacdf ([x, NaN], 1, single (1)), single ([y, NaN]), eps("single")) 471s ***** error nakacdf () 471s ***** error nakacdf (1) 471s ***** error nakacdf (1, 2) 471s ***** error nakacdf (1, 2, 3, "tail") 471s ***** error nakacdf (1, 2, 3, 4) 471s ***** error ... 471s nakacdf (ones (3), ones (2), ones (2)) 471s ***** error ... 471s nakacdf (ones (2), ones (3), ones (2)) 471s ***** error ... 471s nakacdf (ones (2), ones (2), ones (3)) 471s ***** error nakacdf (i, 2, 2) 471s ***** error nakacdf (2, i, 2) 471s ***** error nakacdf (2, 2, i) 471s 19 tests, 19 passed, 0 known failure, 0 skipped 471s [inst/dist_fun/mvnpdf.m] 471s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/mvnpdf.m 471s ***** demo 471s mu = [1, -1]; 471s sigma = [0.9, 0.4; 0.4, 0.3]; 471s [X1, X2] = meshgrid (linspace (-1, 3, 25)', linspace (-3, 1, 25)'); 471s x = [X1(:), X2(:)]; 471s p = mvnpdf (x, mu, sigma); 471s surf (X1, X2, reshape (p, 25, 25)); 471s ***** error y = mvnpdf (); 471s ***** error y = mvnpdf ([]); 471s ***** error y = mvnpdf (ones (3,3,3)); 471s ***** error ... 471s y = mvnpdf (ones (10, 2), [4, 2, 3]); 471s ***** error ... 471s y = mvnpdf (ones (10, 2), [4, 2; 3, 2]); 471s ***** error ... 471s y = mvnpdf (ones (10, 2), ones (3, 3, 3)); 471s ***** shared x, mu, sigma 471s x = [1, 2, 5, 4, 6]; 471s mu = [2, 0, -1, 1, 4]; 471s sigma = [2, 2, 2, 2, 2]; 471s ***** assert (mvnpdf (x), 1.579343404440977e-20, 1e-30); 471s ***** assert (mvnpdf (x, mu), 1.899325144348102e-14, 1e-25); 471s ***** assert (mvnpdf (x, mu, sigma), 2.449062307156273e-09, 1e-20); 471s 9 tests, 9 passed, 0 known failure, 0 skipped 471s [inst/dist_fun/normcdf.m] 471s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/normcdf.m 471s ***** demo 471s ## Plot various CDFs from the normal distribution 471s x = -5:0.01:5; 471s p1 = normcdf (x, 0, 0.5); 471s p2 = normcdf (x, 0, 1); 471s p3 = normcdf (x, 0, 2); 471s p4 = normcdf (x, -2, 0.8); 471s plot (x, p1, "-b", x, p2, "-g", x, p3, "-r", x, p4, "-c") 471s grid on 471s xlim ([-5, 5]) 471s legend ({"μ = 0, σ = 0.5", "μ = 0, σ = 1", ... 471s "μ = 0, σ = 2", "μ = -2, σ = 0.8"}, "location", "southeast") 471s title ("Normal CDF") 471s xlabel ("values in x") 471s ylabel ("probability") 471s ***** shared x, y 471s x = [-Inf 1 2 Inf]; 471s y = [0, 0.5, 1/2*(1+erf(1/sqrt(2))), 1]; 471s ***** assert (normcdf (x, ones (1,4), ones (1,4)), y) 471s ***** assert (normcdf (x, 1, ones (1,4)), y) 471s ***** assert (normcdf (x, ones (1,4), 1), y) 471s ***** assert (normcdf (x, [0, -Inf, NaN, Inf], 1), [0, 1, NaN, NaN]) 471s ***** assert (normcdf (x, 1, [Inf, NaN, -1, 0]), [NaN, NaN, NaN, 1]) 471s ***** assert (normcdf ([x(1:2), NaN, x(4)], 1, 1), [y(1:2), NaN, y(4)]) 471s ***** assert (normcdf (x, "upper"), [1, 0.1587, 0.0228, 0], 1e-4) 471s ***** assert (normcdf ([x, NaN], 1, 1), [y, NaN]) 471s ***** assert (normcdf (single ([x, NaN]), 1, 1), single ([y, NaN]), eps ("single")) 471s ***** assert (normcdf ([x, NaN], single (1), 1), single ([y, NaN]), eps ("single")) 471s ***** assert (normcdf ([x, NaN], 1, single (1)), single ([y, NaN]), eps ("single")) 471s ***** error normcdf () 471s ***** error normcdf (1,2,3,4,5,6,7) 471s ***** error normcdf (1, 2, 3, 4, "uper") 471s ***** error ... 471s normcdf (ones (3), ones (2), ones (2)) 471s ***** error normcdf (2, 3, 4, [1, 2]) 471s ***** error ... 471s [p, plo, pup] = normcdf (1, 2, 3) 471s ***** error [p, plo, pup] = ... 471s normcdf (1, 2, 3, [1, 0; 0, 1], 0) 471s ***** error [p, plo, pup] = ... 471s normcdf (1, 2, 3, [1, 0; 0, 1], 1.22) 471s ***** error [p, plo, pup] = ... 471s normcdf (1, 2, 3, [1, 0; 0, 1], "alpha", "upper") 471s ***** error normcdf (i, 2, 2) 471s ***** error normcdf (2, i, 2) 471s ***** error normcdf (2, 2, i) 471s ***** error ... 471s [p, plo, pup] =normcdf (1, 2, 3, [1, 0; 0, -inf], 0.04) 471s 24 tests, 24 passed, 0 known failure, 0 skipped 471s [inst/dist_fun/evrnd.m] 471s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/evrnd.m 471s ***** assert (size (evrnd (1, 1)), [1 1]) 471s ***** assert (size (evrnd (1, ones (2,1))), [2, 1]) 471s ***** assert (size (evrnd (1, ones (2,2))), [2, 2]) 471s ***** assert (size (evrnd (ones (2,1), 1)), [2, 1]) 471s ***** assert (size (evrnd (ones (2,2), 1)), [2, 2]) 471s ***** assert (size (evrnd (1, 1, 3)), [3, 3]) 471s ***** assert (size (evrnd (1, 1, [4, 1])), [4, 1]) 471s ***** assert (size (evrnd (1, 1, 4, 1)), [4, 1]) 471s ***** assert (size (evrnd (1, 1, 4, 1, 5)), [4, 1, 5]) 471s ***** assert (size (evrnd (1, 1, 0, 1)), [0, 1]) 471s ***** assert (size (evrnd (1, 1, 1, 0)), [1, 0]) 471s ***** assert (size (evrnd (1, 1, 1, 2, 0, 5)), [1, 2, 0, 5]) 471s ***** assert (class (evrnd (1, 1)), "double") 471s ***** assert (class (evrnd (1, single (1))), "single") 471s ***** assert (class (evrnd (1, single ([1, 1]))), "single") 471s ***** assert (class (evrnd (single (1), 1)), "single") 471s ***** assert (class (evrnd (single ([1, 1]), 1)), "single") 471s ***** error evrnd () 471s ***** error evrnd (1) 471s ***** error ... 471s evrnd (ones (3), ones (2)) 471s ***** error ... 471s evrnd (ones (2), ones (3)) 471s ***** error evrnd (i, 2, 3) 471s ***** error evrnd (1, i, 3) 471s ***** error ... 471s evrnd (1, 2, -1) 471s ***** error ... 471s evrnd (1, 2, 1.2) 471s ***** error ... 471s evrnd (1, 2, ones (2)) 471s ***** error ... 471s evrnd (1, 2, [2 -1 2]) 471s ***** error ... 471s evrnd (1, 2, [2 0 2.5]) 471s ***** error ... 471s evrnd (1, 2, 2, -1, 5) 471s ***** error ... 471s evrnd (1, 2, 2, 1.5, 5) 471s ***** error ... 471s evrnd (2, ones (2), 3) 471s ***** error ... 471s evrnd (2, ones (2), [3, 2]) 471s ***** error ... 471s evrnd (2, ones (2), 3, 2) 471s 33 tests, 33 passed, 0 known failure, 0 skipped 471s [inst/dist_fun/evinv.m] 471s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/evinv.m 471s ***** demo 471s ## Plot various iCDFs from the extreme value distribution 471s p = 0.001:0.001:0.999; 471s x1 = evinv (p, 0.5, 2); 471s x2 = evinv (p, 1.0, 2); 471s x3 = evinv (p, 1.5, 3); 471s x4 = evinv (p, 3.0, 4); 471s plot (p, x1, "-b", p, x2, "-g", p, x3, "-r", p, x4, "-c") 471s grid on 471s ylim ([-10, 10]) 471s legend ({"μ = 0.5, σ = 2", "μ = 1.0, σ = 2", ... 471s "μ = 1.5, σ = 3", "μ = 3.0, σ = 4"}, "location", "northwest") 471s title ("Extreme value iCDF") 471s xlabel ("probability") 471s ylabel ("values in x") 471s ***** shared p, x 471s p = [0, 0.05, 0.5 0.95]; 471s x = [-Inf, -2.9702, -0.3665, 1.0972]; 471s ***** assert (evinv (p), x, 1e-4) 471s ***** assert (evinv (p, zeros (1,4), ones (1,4)), x, 1e-4) 471s ***** assert (evinv (p, 0, ones (1,4)), x, 1e-4) 471s ***** assert (evinv (p, zeros (1,4), 1), x, 1e-4) 471s ***** assert (evinv (p, [0, -Inf, NaN, Inf], 1), [-Inf, -Inf, NaN, Inf], 1e-4) 471s ***** assert (evinv (p, 0, [Inf, NaN, -1, 0]), [-Inf, NaN, NaN, NaN], 1e-4) 471s ***** assert (evinv ([p(1:2), NaN, p(4)], 0, 1), [x(1:2), NaN, x(4)], 1e-4) 471s ***** assert (evinv ([p, NaN], 0, 1), [x, NaN], 1e-4) 471s ***** assert (evinv (single ([p, NaN]), 0, 1), single ([x, NaN]), 1e-4) 471s ***** assert (evinv ([p, NaN], single (0), 1), single ([x, NaN]), 1e-4) 471s ***** assert (evinv ([p, NaN], 0, single (1)), single ([x, NaN]), 1e-4) 471s ***** error evinv () 471s ***** error evinv (1,2,3,4,5,6) 471s ***** error ... 471s evinv (ones (3), ones (2), ones (2)) 471s ***** error ... 471s [p, plo, pup] = evinv (2, 3, 4, [1, 2]) 471s ***** error ... 471s [p, plo, pup] = evinv (1, 2, 3) 471s ***** error [p, plo, pup] = ... 471s evinv (1, 2, 3, [1, 0; 0, 1], 0) 471s ***** error [p, plo, pup] = ... 471s evinv (1, 2, 3, [1, 0; 0, 1], 1.22) 471s ***** error evinv (i, 2, 2) 471s ***** error evinv (2, i, 2) 471s ***** error evinv (2, 2, i) 471s ***** error ... 471s [p, plo, pup] = evinv (1, 2, 3, [-1, -10; -Inf, -Inf], 0.04) 471s 22 tests, 22 passed, 0 known failure, 0 skipped 471s [inst/dist_fun/unifpdf.m] 471s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/unifpdf.m 471s ***** demo 471s ## Plot various PDFs from the continuous uniform distribution 471s x = 0:0.001:10; 471s y1 = unifpdf (x, 2, 5); 471s y2 = unifpdf (x, 3, 9); 471s plot (x, y1, "-b", x, y2, "-g") 471s grid on 471s xlim ([0, 10]) 471s ylim ([0, 0.4]) 471s legend ({"a = 2, b = 5", "a = 3, b = 9"}, "location", "northeast") 471s title ("Continuous uniform PDF") 471s xlabel ("values in x") 471s ylabel ("density") 471s ***** shared x, y 471s x = [-1 0 0.5 1 2] + 1; 471s y = [0 1 1 1 0]; 471s ***** assert (unifpdf (x, ones (1,5), 2*ones (1,5)), y) 471s ***** assert (unifpdf (x, 1, 2*ones (1,5)), y) 471s ***** assert (unifpdf (x, ones (1,5), 2), y) 471s ***** assert (unifpdf (x, [2 NaN 1 1 1], 2), [NaN NaN y(3:5)]) 471s ***** assert (unifpdf (x, 1, 2*[0 NaN 1 1 1]), [NaN NaN y(3:5)]) 471s ***** assert (unifpdf ([x, NaN], 1, 2), [y, NaN]) 471s ***** assert (unifpdf (x, 0, 1), [1 1 0 0 0]) 471s ***** assert (unifpdf (single ([x, NaN]), 1, 2), single ([y, NaN])) 471s ***** assert (unifpdf (single ([x, NaN]), single (1), 2), single ([y, NaN])) 471s ***** assert (unifpdf ([x, NaN], 1, single (2)), single ([y, NaN])) 471s ***** error unifpdf () 471s ***** error unifpdf (1) 471s ***** error unifpdf (1, 2) 471s ***** error ... 471s unifpdf (ones (3), ones (2), ones (2)) 471s ***** error ... 471s unifpdf (ones (2), ones (3), ones (2)) 471s ***** error ... 471s unifpdf (ones (2), ones (2), ones (3)) 471s ***** error unifpdf (i, 2, 2) 471s ***** error unifpdf (2, i, 2) 471s ***** error unifpdf (2, 2, i) 471s 19 tests, 19 passed, 0 known failure, 0 skipped 471s [inst/dist_fun/vminv.m] 471s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/vminv.m 471s ***** demo 471s ## Plot various iCDFs from the von Mises distribution 471s p1 = [0,0.005,0.01:0.01:0.1,0.15,0.2:0.1:0.8,0.85,0.9:0.01:0.99,0.995,1]; 471s x1 = vminv (p1, 0, 0.5); 471s x2 = vminv (p1, 0, 1); 471s x3 = vminv (p1, 0, 2); 471s x4 = vminv (p1, 0, 4); 471s plot (p1, x1, "-r", p1, x2, "-g", p1, x3, "-b", p1, x4, "-c") 471s grid on 471s ylim ([-pi, pi]) 471s legend ({"μ = 0, k = 0.5", "μ = 0, k = 1", ... 471s "μ = 0, k = 2", "μ = 0, k = 4"}, "location", "northwest") 471s title ("Von Mises iCDF") 471s xlabel ("probability") 471s ylabel ("values in x") 471s ***** shared x, p0, p1 471s x = [-pi:pi/2:pi]; 471s p0 = [0, 0.10975, 0.5, 0.89025, 1]; 471s p1 = [0, 0.03752, 0.5, 0.99622, 1]; 471s ***** assert (vminv (p0, 0, 1), x, 5e-5) 472s ***** assert (vminv (p0, zeros (1,5), ones (1,5)), x, 5e-5) 472s ***** assert (vminv (p1, 0, [1 2 3 4 5]), x, [5e-5, 5e-4, 5e-5, 5e-4, 5e-5]) 473s ***** error vminv () 473s ***** error vminv (1) 473s ***** error vminv (1, 2) 473s ***** error ... 473s vminv (ones (3), ones (2), ones (2)) 473s ***** error ... 473s vminv (ones (2), ones (3), ones (2)) 473s ***** error ... 473s vminv (ones (2), ones (2), ones (3)) 473s ***** error vminv (i, 2, 2) 473s ***** error vminv (2, i, 2) 473s ***** error vminv (2, 2, i) 473s 12 tests, 12 passed, 0 known failure, 0 skipped 473s [inst/dist_fun/gampdf.m] 473s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/gampdf.m 473s ***** demo 473s ## Plot various PDFs from the Gamma distribution 473s x = 0:0.01:20; 473s y1 = gampdf (x, 1, 2); 473s y2 = gampdf (x, 2, 2); 473s y3 = gampdf (x, 3, 2); 473s y4 = gampdf (x, 5, 1); 473s y5 = gampdf (x, 9, 0.5); 473s y6 = gampdf (x, 7.5, 1); 473s y7 = gampdf (x, 0.5, 1); 473s plot (x, y1, "-r", x, y2, "-g", x, y3, "-y", x, y4, "-m", ... 473s x, y5, "-k", x, y6, "-b", x, y7, "-c") 473s grid on 473s ylim ([0,0.5]) 473s legend ({"α = 1, β = 2", "α = 2, β = 2", "α = 3, β = 2", ... 473s "α = 5, β = 1", "α = 9, β = 0.5", "α = 7.5, β = 1", ... 473s "α = 0.5, β = 1"}, "location", "northeast") 473s title ("Gamma PDF") 473s xlabel ("values in x") 473s ylabel ("density") 473s ***** shared x, y 473s x = [-1 0 0.5 1 Inf]; 473s y = [0 exp(-x(2:end))]; 473s ***** assert (gampdf (x, ones (1,5), ones (1,5)), y) 473s ***** assert (gampdf (x, 1, ones (1,5)), y) 473s ***** assert (gampdf (x, ones (1,5), 1), y) 473s ***** assert (gampdf (x, [0 -Inf NaN Inf 1], 1), [NaN NaN NaN NaN y(5)]) 473s ***** assert (gampdf (x, 1, [0 -Inf NaN Inf 1]), [NaN NaN NaN 0 y(5)]) 473s ***** assert (gampdf ([x, NaN], 1, 1), [y, NaN]) 473s ***** assert (gampdf (single ([x, NaN]), 1, 1), single ([y, NaN])) 473s ***** assert (gampdf ([x, NaN], single (1), 1), single ([y, NaN])) 473s ***** assert (gampdf ([x, NaN], 1, single (1)), single ([y, NaN])) 473s ***** error gampdf () 473s ***** error gampdf (1) 473s ***** error gampdf (1,2) 473s ***** error ... 473s gampdf (ones (3), ones (2), ones (2)) 473s ***** error ... 473s gampdf (ones (2), ones (3), ones (2)) 473s ***** error ... 473s gampdf (ones (2), ones (2), ones (3)) 473s ***** error gampdf (i, 2, 2) 473s ***** error gampdf (2, i, 2) 473s ***** error gampdf (2, 2, i) 473s 18 tests, 18 passed, 0 known failure, 0 skipped 473s [inst/dist_fun/vmrnd.m] 473s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/vmrnd.m 473s ***** assert (size (vmrnd (1, 1)), [1 1]) 473s ***** assert (size (vmrnd (1, ones (2,1))), [2, 1]) 473s ***** assert (size (vmrnd (1, ones (2,2))), [2, 2]) 473s ***** assert (size (vmrnd (ones (2,1), 1)), [2, 1]) 473s ***** assert (size (vmrnd (ones (2,2), 1)), [2, 2]) 473s ***** assert (size (vmrnd (1, 1, 3)), [3, 3]) 473s ***** assert (size (vmrnd (1, 1, [4, 1])), [4, 1]) 473s ***** assert (size (vmrnd (1, 1, 4, 1)), [4, 1]) 473s ***** assert (size (vmrnd (1, 1, 4, 1, 5)), [4, 1, 5]) 473s ***** assert (size (vmrnd (1, 1, 0, 1)), [0, 1]) 473s ***** assert (size (vmrnd (1, 1, 1, 0)), [1, 0]) 473s ***** assert (size (vmrnd (1, 1, 1, 2, 0, 5)), [1, 2, 0, 5]) 473s ***** assert (class (vmrnd (1, 1)), "double") 473s ***** assert (class (vmrnd (1, single (1))), "single") 473s ***** assert (class (vmrnd (1, single ([1, 1]))), "single") 473s ***** assert (class (vmrnd (single (1), 1)), "single") 473s ***** assert (class (vmrnd (single ([1, 1]), 1)), "single") 473s ***** error vmrnd () 473s ***** error vmrnd (1) 473s ***** error ... 473s vmrnd (ones (3), ones (2)) 473s ***** error ... 473s vmrnd (ones (2), ones (3)) 473s ***** error vmrnd (i, 2, 3) 473s ***** error vmrnd (1, i, 3) 473s ***** error ... 473s vmrnd (1, 2, -1) 473s ***** error ... 473s vmrnd (1, 2, 1.2) 473s ***** error ... 473s vmrnd (1, 2, ones (2)) 473s ***** error ... 473s vmrnd (1, 2, [2 -1 2]) 473s ***** error ... 473s vmrnd (1, 2, [2 0 2.5]) 473s ***** error ... 473s vmrnd (1, 2, 2, -1, 5) 473s ***** error ... 473s vmrnd (1, 2, 2, 1.5, 5) 473s ***** error ... 473s vmrnd (2, ones (2), 3) 473s ***** error ... 473s vmrnd (2, ones (2), [3, 2]) 473s ***** error ... 473s vmrnd (2, ones (2), 3, 2) 473s 33 tests, 33 passed, 0 known failure, 0 skipped 473s [inst/dist_fun/gevcdf.m] 473s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/gevcdf.m 473s ***** demo 473s ## Plot various CDFs from the generalized extreme value distribution 473s x = -1:0.001:10; 473s p1 = gevcdf (x, 1, 1, 1); 473s p2 = gevcdf (x, 0.5, 1, 1); 473s p3 = gevcdf (x, 1, 1, 5); 473s p4 = gevcdf (x, 1, 2, 5); 473s p5 = gevcdf (x, 1, 5, 5); 473s p6 = gevcdf (x, 1, 0.5, 5); 473s plot (x, p1, "-b", x, p2, "-g", x, p3, "-r", ... 473s x, p4, "-c", x, p5, "-m", x, p6, "-k") 473s grid on 473s xlim ([-1, 10]) 473s legend ({"k = 1, σ = 1, μ = 1", "k = 0.5, σ = 1, μ = 1", ... 473s "k = 1, σ = 1, μ = 5", "k = 1, σ = 2, μ = 5", ... 473s "k = 1, σ = 5, μ = 5", "k = 1, σ = 0.5, μ = 5"}, ... 473s "location", "southeast") 473s title ("Generalized extreme value CDF") 473s xlabel ("values in x") 473s ylabel ("probability") 473s ***** test 473s x = 0:0.5:2.5; 473s sigma = 1:6; 473s k = 1; 473s mu = 0; 473s p = gevcdf (x, k, sigma, mu); 473s expected_p = [0.36788, 0.44933, 0.47237, 0.48323, 0.48954, 0.49367]; 473s assert (p, expected_p, 0.001); 473s ***** test 473s x = -0.5:0.5:2.5; 473s sigma = 0.5; 473s k = 1; 473s mu = 0; 473s p = gevcdf (x, k, sigma, mu); 473s expected_p = [0, 0.36788, 0.60653, 0.71653, 0.77880, 0.81873, 0.84648]; 473s assert (p, expected_p, 0.001); 473s ***** test # check for continuity for k near 0 473s x = 1; 473s sigma = 0.5; 473s k = -0.03:0.01:0.03; 473s mu = 0; 473s p = gevcdf (x, k, sigma, mu); 473s expected_p = [0.88062, 0.87820, 0.87580, 0.87342, 0.87107, 0.86874, 0.86643]; 473s assert (p, expected_p, 0.001); 473s ***** error gevcdf () 473s ***** error gevcdf (1) 473s ***** error gevcdf (1, 2) 473s ***** error gevcdf (1, 2, 3) 473s ***** error ... 473s gevcdf (1, 2, 3, 4, 5, 6) 473s ***** error gevcdf (1, 2, 3, 4, "tail") 473s ***** error gevcdf (1, 2, 3, 4, 5) 473s ***** error ... 473s gevcdf (ones (3), ones (2), ones(2), ones(2)) 473s ***** error ... 473s gevcdf (ones (2), ones (3), ones(2), ones(2)) 473s ***** error ... 473s gevcdf (ones (2), ones (2), ones(3), ones(2)) 473s ***** error ... 473s gevcdf (ones (2), ones (2), ones(2), ones(3)) 473s ***** error gevcdf (i, 2, 3, 4) 473s ***** error gevcdf (1, i, 3, 4) 473s ***** error gevcdf (1, 2, i, 4) 473s ***** error gevcdf (1, 2, 3, i) 473s 18 tests, 18 passed, 0 known failure, 0 skipped 473s [inst/dist_fun/raylpdf.m] 473s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/raylpdf.m 473s ***** demo 473s ## Plot various PDFs from the Rayleigh distribution 473s x = 0:0.01:10; 473s y1 = raylpdf (x, 0.5); 473s y2 = raylpdf (x, 1); 473s y3 = raylpdf (x, 2); 473s y4 = raylpdf (x, 3); 473s y5 = raylpdf (x, 4); 473s plot (x, y1, "-b", x, y2, "g", x, y3, "-r", x, y4, "-m", x, y5, "-k") 473s grid on 473s ylim ([0, 1.25]) 473s legend ({"σ = 0,5", "σ = 1", "σ = 2", ... 473s "σ = 3", "σ = 4"}, "location", "northeast") 473s title ("Rayleigh PDF") 473s xlabel ("values in x") 473s ylabel ("density") 473s ***** test 473s x = 0:0.5:2.5; 473s sigma = 1:6; 473s y = raylpdf (x, sigma); 473s expected_y = [0.0000, 0.1212, 0.1051, 0.0874, 0.0738, 0.0637]; 473s assert (y, expected_y, 0.001); 473s ***** test 473s x = 0:0.5:2.5; 473s y = raylpdf (x, 0.5); 473s expected_y = [0.0000, 1.2131, 0.5413, 0.0667, 0.0027, 0.0000]; 473s assert (y, expected_y, 0.001); 473s ***** error raylpdf () 473s ***** error raylpdf (1) 473s ***** error ... 473s raylpdf (ones (3), ones (2)) 473s ***** error ... 473s raylpdf (ones (2), ones (3)) 473s ***** error raylpdf (i, 2) 473s ***** error raylpdf (2, i) 473s 8 tests, 8 passed, 0 known failure, 0 skipped 473s [inst/dist_fun/unifcdf.m] 473s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/unifcdf.m 473s ***** demo 473s ## Plot various CDFs from the continuous uniform distribution 473s x = 0:0.1:10; 473s p1 = unifcdf (x, 2, 5); 473s p2 = unifcdf (x, 3, 9); 473s plot (x, p1, "-b", x, p2, "-g") 473s grid on 473s xlim ([0, 10]) 473s ylim ([0, 1]) 473s legend ({"a = 2, b = 5", "a = 3, b = 9"}, "location", "southeast") 473s title ("Continuous uniform CDF") 473s xlabel ("values in x") 473s ylabel ("probability") 473s ***** shared x, y 473s x = [-1 0 0.5 1 2] + 1; 473s y = [0 0 0.5 1 1]; 473s ***** assert (unifcdf (x, ones (1,5), 2*ones (1,5)), y) 473s ***** assert (unifcdf (x, ones (1,5), 2*ones (1,5), "upper"), 1 - y) 473s ***** assert (unifcdf (x, 1, 2*ones (1,5)), y) 473s ***** assert (unifcdf (x, 1, 2*ones (1,5), "upper"), 1 - y) 473s ***** assert (unifcdf (x, ones (1,5), 2), y) 473s ***** assert (unifcdf (x, ones (1,5), 2, "upper"), 1 - y) 473s ***** assert (unifcdf (x, [2 1 NaN 1 1], 2), [NaN 0 NaN 1 1]) 473s ***** assert (unifcdf (x, [2 1 NaN 1 1], 2, "upper"), 1 - [NaN 0 NaN 1 1]) 473s ***** assert (unifcdf (x, 1, 2*[0 1 NaN 1 1]), [NaN 0 NaN 1 1]) 473s ***** assert (unifcdf (x, 1, 2*[0 1 NaN 1 1], "upper"), 1 - [NaN 0 NaN 1 1]) 473s ***** assert (unifcdf ([x(1:2) NaN x(4:5)], 1, 2), [y(1:2) NaN y(4:5)]) 473s ***** assert (unifcdf ([x(1:2) NaN x(4:5)], 1, 2, "upper"), 1 - [y(1:2) NaN y(4:5)]) 473s ***** assert (unifcdf ([x, NaN], 1, 2), [y, NaN]) 473s ***** assert (unifcdf (single ([x, NaN]), 1, 2), single ([y, NaN])) 473s ***** assert (unifcdf ([x, NaN], single (1), 2), single ([y, NaN])) 473s ***** assert (unifcdf ([x, NaN], 1, single (2)), single ([y, NaN])) 473s ***** error unifcdf () 473s ***** error unifcdf (1) 473s ***** error unifcdf (1, 2) 473s ***** error unifcdf (1, 2, 3, 4) 473s ***** error unifcdf (1, 2, 3, "tail") 473s ***** error ... 473s unifcdf (ones (3), ones (2), ones (2)) 474s ***** error ... 474s unifcdf (ones (2), ones (3), ones (2)) 474s ***** error ... 474s unifcdf (ones (2), ones (2), ones (3)) 474s ***** error unifcdf (i, 2, 2) 474s ***** error unifcdf (2, i, 2) 474s ***** error unifcdf (2, 2, i) 474s 27 tests, 27 passed, 0 known failure, 0 skipped 474s [inst/dist_fun/hygecdf.m] 474s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/hygecdf.m 474s ***** demo 474s ## Plot various CDFs from the hypergeometric distribution 474s x = 0:60; 474s p1 = hygecdf (x, 500, 50, 100); 474s p2 = hygecdf (x, 500, 60, 200); 474s p3 = hygecdf (x, 500, 70, 300); 474s plot (x, p1, "*b", x, p2, "*g", x, p3, "*r") 474s grid on 474s xlim ([0, 60]) 474s legend ({"m = 500, k = 50, n = 100", "m = 500, k = 60, n = 200", ... 474s "m = 500, k = 70, n = 300"}, "location", "southeast") 474s title ("Hypergeometric CDF") 474s xlabel ("values in x (number of successes)") 474s ylabel ("probability") 474s ***** shared x, y 474s x = [-1 0 1 2 3]; 474s y = [0 1/6 5/6 1 1]; 474s ***** assert (hygecdf (x, 4*ones (1,5), 2, 2), y, 5*eps) 474s ***** assert (hygecdf (x, 4, 2*ones (1,5), 2), y, 5*eps) 474s ***** assert (hygecdf (x, 4, 2, 2*ones (1,5)), y, 5*eps) 474s ***** assert (hygecdf (x, 4*[1 -1 NaN 1.1 1], 2, 2), [y(1) NaN NaN NaN y(5)], 5*eps) 474s ***** assert (hygecdf (x, 4*[1 -1 NaN 1.1 1], 2, 2, "upper"), ... 474s [y(5) NaN NaN NaN y(1)], 5*eps) 474s ***** assert (hygecdf (x, 4, 2*[1 -1 NaN 1.1 1], 2), [y(1) NaN NaN NaN y(5)], 5*eps) 474s ***** assert (hygecdf (x, 4, 2*[1 -1 NaN 1.1 1], 2, "upper"), ... 474s [y(5) NaN NaN NaN y(1)], 5*eps) 474s ***** assert (hygecdf (x, 4, 5, 2), [NaN NaN NaN NaN NaN]) 474s ***** assert (hygecdf (x, 4, 2, 2*[1 -1 NaN 1.1 1]), [y(1) NaN NaN NaN y(5)], 5*eps) 474s ***** assert (hygecdf (x, 4, 2, 2*[1 -1 NaN 1.1 1], "upper"), ... 474s [y(5) NaN NaN NaN y(1)], 5*eps) 474s ***** assert (hygecdf (x, 4, 2, 5), [NaN NaN NaN NaN NaN]) 474s ***** assert (hygecdf ([x(1:2) NaN x(4:5)], 4, 2, 2), [y(1:2) NaN y(4:5)], 5*eps) 474s ***** test 474s p = hygecdf (x, 10, [1 2 3 4 5], 2, "upper"); 474s assert (p, [1, 34/90, 2/30, 0, 0], 10*eps); 474s ***** test 474s p = hygecdf (2*x, 10, [1 2 3 4 5], 2, "upper"); 474s assert (p, [1, 34/90, 0, 0, 0], 10*eps); 474s ***** assert (hygecdf ([x, NaN], 4, 2, 2), [y, NaN], 5*eps) 474s ***** assert (hygecdf (single ([x, NaN]), 4, 2, 2), single ([y, NaN]), ... 474s eps ("single")) 474s ***** assert (hygecdf ([x, NaN], single (4), 2, 2), single ([y, NaN]), ... 474s eps ("single")) 474s ***** assert (hygecdf ([x, NaN], 4, single (2), 2), single ([y, NaN]), ... 474s eps ("single")) 474s ***** assert (hygecdf ([x, NaN], 4, 2, single (2)), single ([y, NaN]), ... 474s eps ("single")) 474s ***** error hygecdf () 474s ***** error hygecdf (1) 474s ***** error hygecdf (1,2) 474s ***** error hygecdf (1,2,3) 474s ***** error hygecdf (1,2,3,4,5) 474s ***** error hygecdf (1,2,3,4,"uper") 474s ***** error ... 474s hygecdf (ones (2), ones (3), 1, 1) 474s ***** error ... 474s hygecdf (1, ones (2), ones (3), 1) 474s ***** error ... 474s hygecdf (1, 1, ones (2), ones (3)) 474s ***** error hygecdf (i, 2, 2, 2) 474s ***** error hygecdf (2, i, 2, 2) 474s ***** error hygecdf (2, 2, i, 2) 474s ***** error hygecdf (2, 2, 2, i) 474s 32 tests, 32 passed, 0 known failure, 0 skipped 474s [inst/dist_fun/mvtpdf.m] 474s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/mvtpdf.m 474s ***** demo 474s ## Compute the pdf of a multivariate t distribution with correlation 474s ## parameters rho = [1 .4; .4 1] and 2 degrees of freedom. 474s 474s rho = [1, 0.4; 0.4, 1]; 474s df = 2; 474s [X1, X2] = meshgrid (linspace (-2, 2, 25)', linspace (-2, 2, 25)'); 474s X = [X1(:), X2(:)]; 474s y = mvtpdf (X, rho, df); 474s surf (X1, X2, reshape (y, 25, 25)); 474s title ("Bivariate Student's t probability density function"); 474s ***** assert (mvtpdf ([0 0], eye(2), 1), 0.1591549, 1E-7) 474s ***** assert (mvtpdf ([1 0], [1 0.5; 0.5 1], 2), 0.06615947, 1E-7) 474s ***** assert (mvtpdf ([1 0.4 0; 1.2 0.5 0.5; 1.4 0.6 1], ... 474s [1 0.5 0.3; 0.5 1 0.6; 0.3 0.6 1], [5 6 7]), ... 474s [0.04713313 0.03722421 0.02069011]', 1E-7) 474s 3 tests, 3 passed, 0 known failure, 0 skipped 474s [inst/dist_fun/nctinv.m] 474s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/nctinv.m 474s ***** demo 474s ## Plot various iCDFs from the noncentral T distribution 474s p = 0.001:0.001:0.999; 474s x1 = nctinv (p, 1, 0); 474s x2 = nctinv (p, 4, 0); 474s x3 = nctinv (p, 1, 2); 474s x4 = nctinv (p, 4, 2); 474s plot (p, x1, "-r", p, x2, "-g", p, x3, "-k", p, x4, "-m") 474s grid on 474s ylim ([-5, 5]) 474s legend ({"df = 1, μ = 0", "df = 4, μ = 0", ... 474s "df = 1, μ = 2", "df = 4, μ = 2"}, "location", "northwest") 474s title ("Noncentral T iCDF") 474s xlabel ("probability") 474s ylabel ("values in x") 474s ***** demo 474s ## Compare the noncentral T iCDF with MU = 1 to the T iCDF 474s ## with the same number of degrees of freedom (10). 474s 474s p = 0.001:0.001:0.999; 474s x1 = nctinv (p, 10, 1); 474s x2 = tinv (p, 10); 474s plot (p, x1, "-", p, x2, "-"); 474s grid on 474s ylim ([-5, 5]) 474s legend ({"Noncentral T(10,1)", "T(10)"}, "location", "northwest") 474s title ("Noncentral T vs T quantile functions") 474s xlabel ("probability") 474s ylabel ("values in x") 474s ***** test 474s x = [-Inf,-0.3347,0.1756,0.5209,0.8279,1.1424,1.5021,1.9633,2.6571,4.0845,Inf]; 474s assert (nctinv ([0:0.1:1], 2, 1), x, 1e-4); 475s ***** test 475s x = [-Inf,1.5756,2.0827,2.5343,3.0043,3.5406,4.2050,5.1128,6.5510,9.6442,Inf]; 475s assert (nctinv ([0:0.1:1], 2, 3), x, 1e-4); 476s ***** test 476s x = [-Inf,2.2167,2.9567,3.7276,4.6464,5.8455,7.5619,10.3327,15.7569,31.8159,Inf]; 476s assert (nctinv ([0:0.1:1], 1, 4), x, 1e-4); 477s ***** test 477s x = [1.7791 1.9368 2.0239 2.0801 2.1195 2.1489]; 477s assert (nctinv (0.05, [1, 2, 3, 4, 5, 6], 4), x, 1e-4); 478s ***** test 478s x = [-0.7755, 0.3670, 1.2554, 2.0239, 2.7348, 3.4154]; 478s assert (nctinv (0.05, 3, [1, 2, 3, 4, 5, 6]), x, 1e-4); 480s ***** test 480s x = [-0.7183, 0.3624, 1.2878, 2.1195, -3.5413, 3.6430]; 480s assert (nctinv (0.05, 5, [1, 2, 3, 4, -1, 6]), x, 1e-4); 483s ***** test 483s assert (nctinv (0.996, 5, 8), 30.02610554063658, 2e-11); 486s ***** error nctinv () 486s ***** error nctinv (1) 486s ***** error nctinv (1, 2) 486s ***** error ... 486s nctinv (ones (3), ones (2), ones (2)) 486s ***** error ... 486s nctinv (ones (2), ones (3), ones (2)) 486s ***** error ... 486s nctinv (ones (2), ones (2), ones (3)) 486s ***** error nctinv (i, 2, 2) 486s ***** error nctinv (2, i, 2) 486s ***** error nctinv (2, 2, i) 486s 16 tests, 16 passed, 0 known failure, 0 skipped 486s [inst/dist_fun/poisspdf.m] 486s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/poisspdf.m 486s ***** demo 486s ## Plot various PDFs from the Poisson distribution 486s x = 0:20; 486s y1 = poisspdf (x, 1); 486s y2 = poisspdf (x, 4); 486s y3 = poisspdf (x, 10); 486s plot (x, y1, "*b", x, y2, "*g", x, y3, "*r") 486s grid on 486s ylim ([0, 0.4]) 486s legend ({"λ = 1", "λ = 4", "λ = 10"}, "location", "northeast") 486s title ("Poisson PDF") 486s xlabel ("values in x (number of occurences)") 486s ylabel ("density") 486s ***** shared x, y 486s x = [-1 0 1 2 Inf]; 486s y = [0, exp(-1)*[1 1 0.5], 0]; 486s ***** assert (poisspdf (x, ones (1,5)), y, eps) 486s ***** assert (poisspdf (x, 1), y, eps) 486s ***** assert (poisspdf (x, [1 0 NaN 1 1]), [y(1) NaN NaN y(4:5)], eps) 486s ***** assert (poisspdf ([x, NaN], 1), [y, NaN], eps) 486s ***** assert (poisspdf (single ([x, NaN]), 1), single ([y, NaN]), eps ("single")) 486s ***** assert (poisspdf ([x, NaN], single (1)), single ([y, NaN]), eps ("single")) 486s ***** error poisspdf () 486s ***** error poisspdf (1) 486s ***** error ... 486s poisspdf (ones (3), ones (2)) 486s ***** error ... 486s poisspdf (ones (2), ones (3)) 486s ***** error poisspdf (i, 2) 486s ***** error poisspdf (2, i) 486s 12 tests, 12 passed, 0 known failure, 0 skipped 486s [inst/dist_fun/mvtcdf.m] 486s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/mvtcdf.m 486s ***** demo 486s ## Compute the cdf of a multivariate Student's t distribution with 486s ## correlation parameters rho = [1, 0.4; 0.4, 1] and 2 degrees of freedom. 486s 486s rho = [1, 0.4; 0.4, 1]; 486s df = 2; 486s [X1, X2] = meshgrid (linspace (-2, 2, 25)', linspace (-2, 2, 25)'); 486s X = [X1(:), X2(:)]; 486s p = mvtcdf (X, rho, df); 486s surf (X1, X2, reshape (p, 25, 25)); 486s title ("Bivariate Student's t cummulative distribution function"); 486s ***** test 486s x = [1, 2]; 486s rho = [1, 0.5; 0.5, 1]; 486s df = 4; 486s a = [-1, 0]; 486s assert (mvtcdf(a, x, rho, df), 0.294196905339283, 1e-14); 486s ***** test 486s x = [1, 2;2, 4;1, 5]; 486s rho = [1, 0.5; 0.5, 1]; 486s df = 4; 486s p =[0.790285178602166; 0.938703291727784; 0.81222737321336]; 486s assert (mvtcdf(x, rho, df), p, 1e-14); 486s ***** test 486s x = [1, 2, 2, 4, 1, 5]; 486s rho = eye (6); 486s rho(rho == 0) = 0.5; 486s df = 4; 486s assert (mvtcdf(x, rho, df), 0.6874, 1e-4); 515s ***** error mvtcdf (1) 515s ***** error mvtcdf (1, 2) 515s ***** error ... 515s mvtcdf (1, [2, 3; 3, 2], 1) 515s ***** error ... 515s mvtcdf ([2, 3, 4], ones (2), 1) 515s ***** error ... 515s mvtcdf ([1, 2, 3], [2, 3], ones (2), 1) 515s ***** error ... 515s mvtcdf ([2, 3], ones (2), [1, 2, 3]) 515s ***** error ... 515s mvtcdf ([2, 3], [1, 0.5; 0.5, 1], [1, 2, 3]) 515s 10 tests, 10 passed, 0 known failure, 0 skipped 515s [inst/dist_fun/unidcdf.m] 515s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/unidcdf.m 515s ***** demo 515s ## Plot various CDFs from the discrete uniform distribution 515s x = 0:10; 515s p1 = unidcdf (x, 5); 515s p2 = unidcdf (x, 9); 515s plot (x, p1, "*b", x, p2, "*g") 515s grid on 515s xlim ([0, 10]) 515s ylim ([0, 1]) 515s legend ({"N = 5", "N = 9"}, "location", "southeast") 515s title ("Discrete uniform CDF") 515s xlabel ("values in x") 515s ylabel ("probability") 515s ***** shared x, y 515s x = [0 1 2.5 10 11]; 515s y = [0, 0.1 0.2 1.0 1.0]; 515s ***** assert (unidcdf (x, 10*ones (1,5)), y) 515s ***** assert (unidcdf (x, 10*ones (1,5), "upper"), 1 - y) 515s ***** assert (unidcdf (x, 10), y) 515s ***** assert (unidcdf (x, 10, "upper"), 1 - y) 515s ***** assert (unidcdf (x, 10*[0 1 NaN 1 1]), [NaN 0.1 NaN y(4:5)]) 515s ***** assert (unidcdf ([x(1:2) NaN Inf x(5)], 10), [y(1:2) NaN 1 y(5)]) 515s ***** assert (unidcdf ([x, NaN], 10), [y, NaN]) 515s ***** assert (unidcdf (single ([x, NaN]), 10), single ([y, NaN])) 515s ***** assert (unidcdf ([x, NaN], single (10)), single ([y, NaN])) 515s ***** error unidcdf () 515s ***** error unidcdf (1) 515s ***** error unidcdf (1, 2, 3) 515s ***** error unidcdf (1, 2, "tail") 515s ***** error ... 515s unidcdf (ones (3), ones (2)) 515s ***** error ... 515s unidcdf (ones (2), ones (3)) 515s ***** error unidcdf (i, 2) 515s ***** error unidcdf (2, i) 515s 17 tests, 17 passed, 0 known failure, 0 skipped 515s [inst/dist_fun/invgrnd.m] 515s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/invgrnd.m 515s ***** assert (size (invgrnd (1, 1, 1)), [1, 1]) 515s ***** assert (size (invgrnd (1, 1, 2)), [2, 2]) 515s ***** assert (size (invgrnd (1, 1, [2, 1])), [2, 1]) 515s ***** assert (size (invgrnd (1, zeros (2, 2))), [2, 2]) 515s ***** assert (size (invgrnd (1, ones (2, 1))), [2, 1]) 515s ***** assert (size (invgrnd (1, ones (2, 2))), [2, 2]) 515s ***** assert (size (invgrnd (ones (2, 1), 1)), [2, 1]) 515s ***** assert (size (invgrnd (ones (2, 2), 1)), [2, 2]) 515s ***** assert (size (invgrnd (1, 1, 3)), [3, 3]) 515s ***** assert (size (invgrnd (1, 1, [4 1])), [4, 1]) 515s ***** assert (size (invgrnd (1, 1, 4, 1)), [4, 1]) 515s ***** test 515s r = invgrnd (1, [1, 0, -1]); 515s assert (r([2:3]), [NaN, NaN]) 515s ***** assert (class (invgrnd (1, 0)), "double") 515s ***** assert (class (invgrnd (1, single (0))), "single") 515s ***** assert (class (invgrnd (1, single ([0 0]))), "single") 515s ***** assert (class (invgrnd (1, single (1))), "single") 515s ***** assert (class (invgrnd (1, single ([1 1]))), "single") 515s ***** assert (class (invgrnd (single (1), 1)), "single") 515s ***** assert (class (invgrnd (single ([1 1]), 1)), "single") 515s ***** error invgrnd () 515s ***** error invgrnd (1) 515s ***** error ... 515s invgrnd (ones (3), ones (2)) 515s ***** error ... 515s invgrnd (ones (2), ones (3)) 515s ***** error invgrnd (i, 2, 3) 515s ***** error invgrnd (1, i, 3) 515s ***** error ... 515s invgrnd (1, 2, -1) 515s ***** error ... 515s invgrnd (1, 2, 1.2) 515s ***** error ... 515s invgrnd (1, 2, ones (2)) 515s ***** error ... 515s invgrnd (1, 2, [2 -1 2]) 515s ***** error ... 515s invgrnd (1, 2, [2 0 2.5]) 515s ***** error ... 515s invgrnd (1, 2, 2, -1, 5) 515s ***** error ... 515s invgrnd (1, 2, 2, 1.5, 5) 515s ***** error ... 515s invgrnd (2, ones (2), 3) 515s ***** error ... 515s invgrnd (2, ones (2), [3, 2]) 515s ***** error ... 515s invgrnd (2, ones (2), 3, 2) 515s 35 tests, 35 passed, 0 known failure, 0 skipped 515s [inst/dist_fun/nbincdf.m] 515s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/nbincdf.m 515s ***** demo 515s ## Plot various CDFs from the negative binomial distribution 515s x = 0:50; 515s p1 = nbincdf (x, 2, 0.15); 515s p2 = nbincdf (x, 5, 0.2); 515s p3 = nbincdf (x, 4, 0.4); 515s p4 = nbincdf (x, 10, 0.3); 515s plot (x, p1, "*r", x, p2, "*g", x, p3, "*k", x, p4, "*m") 515s grid on 515s xlim ([0, 40]) 515s legend ({"r = 2, ps = 0.15", "r = 5, ps = 0.2", "r = 4, p = 0.4", ... 515s "r = 10, ps = 0.3"}, "location", "southeast") 515s title ("Negative binomial CDF") 515s xlabel ("values in x (number of failures)") 515s ylabel ("probability") 515s ***** shared x, y 515s x = [-1 0 1 2 Inf]; 515s y = [0 1/2 3/4 7/8 1]; 515s ***** assert (nbincdf (x, ones (1,5), 0.5*ones (1,5)), y) 515s ***** assert (nbincdf (x, 1, 0.5*ones (1,5)), y) 515s ***** assert (nbincdf (x, ones (1,5), 0.5), y) 515s ***** assert (nbincdf (x, ones (1,5), 0.5, "upper"), 1 - y, eps) 515s ***** assert (nbincdf ([x(1:3) 0 x(5)], [0 1 NaN 1.5 Inf], 0.5), ... 515s [NaN 1/2 NaN nbinpdf(0,1.5,0.5) NaN], eps) 515s ***** assert (nbincdf (x, 1, 0.5*[-1 NaN 4 1 1]), [NaN NaN NaN y(4:5)]) 515s ***** assert (nbincdf ([x(1:2) NaN x(4:5)], 1, 0.5), [y(1:2) NaN y(4:5)]) 515s ***** assert (nbincdf ([x, NaN], 1, 0.5), [y, NaN]) 515s ***** assert (nbincdf (single ([x, NaN]), 1, 0.5), single ([y, NaN])) 515s ***** assert (nbincdf ([x, NaN], single (1), 0.5), single ([y, NaN])) 515s ***** assert (nbincdf ([x, NaN], 1, single (0.5)), single ([y, NaN])) 515s ***** error nbincdf () 515s ***** error nbincdf (1) 515s ***** error nbincdf (1, 2) 515s ***** error nbincdf (1, 2, 3, 4) 515s ***** error nbincdf (1, 2, 3, "some") 515s ***** error ... 515s nbincdf (ones (3), ones (2), ones (2)) 515s ***** error ... 515s nbincdf (ones (2), ones (3), ones (2)) 515s ***** error ... 515s nbincdf (ones (2), ones (2), ones (3)) 515s ***** error nbincdf (i, 2, 2) 515s ***** error nbincdf (2, i, 2) 515s ***** error nbincdf (2, 2, i) 515s 22 tests, 22 passed, 0 known failure, 0 skipped 515s [inst/dist_fun/binoinv.m] 515s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/binoinv.m 515s ***** demo 515s ## Plot various iCDFs from the binomial distribution 515s p = 0.001:0.001:0.999; 515s x1 = binoinv (p, 20, 0.5); 515s x2 = binoinv (p, 20, 0.7); 515s x3 = binoinv (p, 40, 0.5); 515s plot (p, x1, "-b", p, x2, "-g", p, x3, "-r") 515s grid on 515s legend ({"n = 20, ps = 0.5", "n = 20, ps = 0.7", ... 515s "n = 40, ps = 0.5"}, "location", "southeast") 515s title ("Binomial iCDF") 515s xlabel ("probability") 515s ylabel ("values in x (number of successes)") 515s ***** shared p 515s p = [-1 0 0.5 1 2]; 515s ***** assert (binoinv (p, 2*ones (1,5), 0.5*ones (1,5)), [NaN 0 1 2 NaN]) 515s ***** assert (binoinv (p, 2, 0.5*ones (1,5)), [NaN 0 1 2 NaN]) 515s ***** assert (binoinv (p, 2*ones (1,5), 0.5), [NaN 0 1 2 NaN]) 515s ***** assert (binoinv (p, 2*[0 -1 NaN 1.1 1], 0.5), [NaN NaN NaN NaN NaN]) 515s ***** assert (binoinv (p, 2, 0.5*[0 -1 NaN 3 1]), [NaN NaN NaN NaN NaN]) 515s ***** assert (binoinv ([p(1:2) NaN p(4:5)], 2, 0.5), [NaN 0 NaN 2 NaN]) 515s ***** assert (binoinv ([p, NaN], 2, 0.5), [NaN 0 1 2 NaN NaN]) 515s ***** assert (binoinv (single ([p, NaN]), 2, 0.5), single ([NaN 0 1 2 NaN NaN])) 515s ***** assert (binoinv ([p, NaN], single (2), 0.5), single ([NaN 0 1 2 NaN NaN])) 515s ***** assert (binoinv ([p, NaN], 2, single (0.5)), single ([NaN 0 1 2 NaN NaN])) 515s ***** shared x, tol 515s x = magic (3) + 1; 515s tol = 1; 515s ***** assert (binoinv (binocdf (1:10, 11, 0.1), 11, 0.1), 1:10, tol) 515s ***** assert (binoinv (binocdf (1:10, 2*(1:10), 0.1), 2*(1:10), 0.1), 1:10, tol) 515s ***** assert (binoinv (binocdf (x, 2*x, 1./x), 2*x, 1./x), x, tol) 515s ***** error binoinv () 515s ***** error binoinv (1) 515s ***** error binoinv (1,2) 515s ***** error binoinv (1,2,3,4) 515s ***** error ... 515s binoinv (ones (3), ones (2), ones (2)) 515s ***** error ... 515s binoinv (ones (2), ones (3), ones (2)) 515s ***** error ... 515s binoinv (ones (2), ones (2), ones (3)) 515s ***** error binoinv (i, 2, 2) 515s ***** error binoinv (2, i, 2) 515s ***** error binoinv (2, 2, i) 515s 23 tests, 23 passed, 0 known failure, 0 skipped 515s [inst/dist_fun/wblcdf.m] 515s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/wblcdf.m 515s ***** demo 515s ## Plot various CDFs from the Weibull distribution 515s x = 0:0.001:2.5; 515s p1 = wblcdf (x, 1, 0.5); 515s p2 = wblcdf (x, 1, 1); 515s p3 = wblcdf (x, 1, 1.5); 515s p4 = wblcdf (x, 1, 5); 515s plot (x, p1, "-b", x, p2, "-r", x, p3, "-m", x, p4, "-g") 515s grid on 515s legend ({"λ = 1, k = 0.5", "λ = 1, k = 1", ... 515s "λ = 1, k = 1.5", "λ = 1, k = 5"}, "location", "southeast") 515s title ("Weibull CDF") 515s xlabel ("values in x") 515s ylabel ("probability") 515s ***** shared x, y 515s x = [-1 0 0.5 1 Inf]; 515s y = [0, 1-exp(-x(2:4)), 1]; 515s ***** assert (wblcdf (x, ones (1,5), ones (1,5)), y, 1e-16) 515s ***** assert (wblcdf (x, ones (1,5), ones (1,5), "upper"), 1 - y) 515s ***** assert (wblcdf (x, "upper"), 1 - y) 515s ***** assert (wblcdf (x, 1, ones (1,5)), y, 1e-16) 515s ***** assert (wblcdf (x, ones (1,5), 1), y, 1e-16) 515s ***** assert (wblcdf (x, [0 1 NaN Inf 1], 1), [NaN 0 NaN 0 1]) 515s ***** assert (wblcdf (x, [0 1 NaN Inf 1], 1, "upper"), 1 - [NaN 0 NaN 0 1]) 515s ***** assert (wblcdf (x, 1, [0 1 NaN Inf 1]), [NaN 0 NaN y(4:5)]) 515s ***** assert (wblcdf (x, 1, [0 1 NaN Inf 1], "upper"), 1 - [NaN 0 NaN y(4:5)]) 515s ***** assert (wblcdf ([x(1:2) NaN x(4:5)], 1, 1), [y(1:2) NaN y(4:5)]) 515s ***** assert (wblcdf ([x(1:2) NaN x(4:5)], 1, 1, "upper"), 1 - [y(1:2) NaN y(4:5)]) 515s ***** assert (wblcdf ([x, NaN], 1, 1), [y, NaN], 1e-16) 515s ***** assert (wblcdf (single ([x, NaN]), 1, 1), single ([y, NaN])) 515s ***** assert (wblcdf ([x, NaN], single (1), 1), single ([y, NaN])) 515s ***** assert (wblcdf ([x, NaN], 1, single (1)), single ([y, NaN])) 515s ***** error wblcdf () 515s ***** error wblcdf (1,2,3,4,5,6,7) 515s ***** error wblcdf (1, 2, 3, 4, "uper") 515s ***** error ... 515s wblcdf (ones (3), ones (2), ones (2)) 515s ***** error wblcdf (2, 3, 4, [1, 2]) 515s ***** error ... 515s [p, plo, pup] = wblcdf (1, 2, 3) 515s ***** error [p, plo, pup] = ... 515s wblcdf (1, 2, 3, [1, 0; 0, 1], 0) 515s ***** error [p, plo, pup] = ... 515s wblcdf (1, 2, 3, [1, 0; 0, 1], 1.22) 515s ***** error [p, plo, pup] = ... 515s wblcdf (1, 2, 3, [1, 0; 0, 1], "alpha", "upper") 515s ***** error wblcdf (i, 2, 2) 515s ***** error wblcdf (2, i, 2) 515s ***** error wblcdf (2, 2, i) 515s ***** error ... 515s [p, plo, pup] =wblcdf (1, 2, 3, [1, 0; 0, -inf], 0.04) 515s 28 tests, 28 passed, 0 known failure, 0 skipped 515s [inst/dist_fun/gaminv.m] 515s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/gaminv.m 515s ***** demo 515s ## Plot various iCDFs from the Gamma distribution 515s p = 0.001:0.001:0.999; 515s x1 = gaminv (p, 1, 2); 515s x2 = gaminv (p, 2, 2); 515s x3 = gaminv (p, 3, 2); 515s x4 = gaminv (p, 5, 1); 515s x5 = gaminv (p, 9, 0.5); 515s x6 = gaminv (p, 7.5, 1); 515s x7 = gaminv (p, 0.5, 1); 515s plot (p, x1, "-r", p, x2, "-g", p, x3, "-y", p, x4, "-m", ... 515s p, x5, "-k", p, x6, "-b", p, x7, "-c") 515s ylim ([0, 20]) 515s grid on 515s legend ({"α = 1, β = 2", "α = 2, β = 2", "α = 3, β = 2", ... 515s "α = 5, β = 1", "α = 9, β = 0.5", "α = 7.5, β = 1", ... 515s "α = 0.5, β = 1"}, "location", "northwest") 515s title ("Gamma iCDF") 515s xlabel ("probability") 515s ylabel ("x") 515s ***** shared p 515s p = [-1 0 0.63212055882855778 1 2]; 515s ***** assert (gaminv (p, ones (1,5), ones (1,5)), [NaN 0 1 Inf NaN], eps) 515s ***** assert (gaminv (p, 1, ones (1,5)), [NaN 0 1 Inf NaN], eps) 515s ***** assert (gaminv (p, ones (1,5), 1), [NaN 0 1 Inf NaN], eps) 515s ***** assert (gaminv (p, [1 -Inf NaN Inf 1], 1), [NaN NaN NaN NaN NaN]) 515s ***** assert (gaminv (p, 1, [1 -Inf NaN Inf 1]), [NaN NaN NaN NaN NaN]) 515s ***** assert (gaminv ([p(1:2) NaN p(4:5)], 1, 1), [NaN 0 NaN Inf NaN]) 515s ***** assert (gaminv ([p(1:2) NaN p(4:5)], 1, 1), [NaN 0 NaN Inf NaN]) 516s ***** assert (gaminv (1e-16, 1, 1), 1e-16, eps) 516s ***** assert (gaminv (1e-16, 1, 2), 2e-16, eps) 516s ***** assert (gaminv (1e-20, 3, 5), 1.957434012161815e-06, eps) 516s ***** assert (gaminv (1e-15, 1, 1), 1e-15, eps) 516s ***** assert (gaminv (1e-35, 1, 1), 1e-35, eps) 516s ***** assert (gaminv ([p, NaN], 1, 1), [NaN 0 1 Inf NaN NaN], eps) 516s ***** assert (gaminv (single ([p, NaN]), 1, 1), single ([NaN 0 1 Inf NaN NaN]), ... 516s eps ("single")) 516s ***** assert (gaminv ([p, NaN], single (1), 1), single ([NaN 0 1 Inf NaN NaN]), ... 516s eps ("single")) 516s ***** assert (gaminv ([p, NaN], 1, single (1)), single ([NaN 0 1 Inf NaN NaN]), ... 516s eps ("single")) 516s ***** error gaminv () 516s ***** error gaminv (1) 516s ***** error gaminv (1,2) 516s ***** error ... 516s gaminv (ones (3), ones (2), ones (2)) 516s ***** error ... 516s gaminv (ones (2), ones (3), ones (2)) 516s ***** error ... 516s gaminv (ones (2), ones (2), ones (3)) 516s ***** error gaminv (i, 2, 2) 516s ***** error gaminv (2, i, 2) 516s ***** error gaminv (2, 2, i) 516s 25 tests, 25 passed, 0 known failure, 0 skipped 516s [inst/dist_fun/laplaceinv.m] 516s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/laplaceinv.m 516s ***** demo 516s ## Plot various iCDFs from the Laplace distribution 516s p = 0.001:0.001:0.999; 516s x1 = cauchyinv (p, 0, 1); 516s x2 = cauchyinv (p, 0, 2); 516s x3 = cauchyinv (p, 0, 4); 516s x4 = cauchyinv (p, -5, 4); 516s plot (p, x1, "-b", p, x2, "-g", p, x3, "-r", p, x4, "-c") 516s grid on 516s ylim ([-10, 10]) 516s legend ({"μ = 0, β = 1", "μ = 0, β = 2", ... 516s "μ = 0, β = 4", "μ = -5, β = 4"}, "location", "northwest") 516s title ("Laplace iCDF") 516s xlabel ("probability") 516s ylabel ("values in x") 516s ***** shared p, x 516s p = [-1 0 0.5 1 2]; 516s x = [NaN, -Inf, 0, Inf, NaN]; 516s ***** assert (laplaceinv (p, 0, 1), x) 516s ***** assert (laplaceinv (p, 0, [-2, -1, 0, 1, 2]), [nan(1, 3), Inf, NaN]) 516s ***** assert (laplaceinv ([p, NaN], 0, 1), [x, NaN]) 516s ***** assert (laplaceinv (single ([p, NaN]), 0, 1), single ([x, NaN])) 516s ***** assert (laplaceinv ([p, NaN], single (0), 1), single ([x, NaN])) 516s ***** assert (laplaceinv ([p, NaN], 0, single (1)), single ([x, NaN])) 516s ***** error laplaceinv () 516s ***** error laplaceinv (1) 516s ***** error ... 516s laplaceinv (1, 2) 516s ***** error laplaceinv (1, 2, 3, 4) 516s ***** error ... 516s laplaceinv (1, ones (2), ones (3)) 516s ***** error ... 516s laplaceinv (ones (2), 1, ones (3)) 516s ***** error ... 516s laplaceinv (ones (2), ones (3), 1) 516s ***** error laplaceinv (i, 2, 3) 516s ***** error laplaceinv (1, i, 3) 516s ***** error laplaceinv (1, 2, i) 516s 16 tests, 16 passed, 0 known failure, 0 skipped 516s [inst/dist_fun/betarnd.m] 516s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/betarnd.m 516s ***** assert (size (betarnd (2, 1/2)), [1 1]) 516s ***** assert (size (betarnd (2 * ones (2, 1), 1/2)), [2, 1]) 516s ***** assert (size (betarnd (2 * ones (2, 2), 1/2)), [2, 2]) 516s ***** assert (size (betarnd (2, 1/2 * ones (2, 1))), [2, 1]) 516s ***** assert (size (betarnd (1, 1/2 * ones (2, 2))), [2, 2]) 516s ***** assert (size (betarnd (ones (2, 1), 1)), [2, 1]) 516s ***** assert (size (betarnd (ones (2, 2), 1)), [2, 2]) 516s ***** assert (size (betarnd (2, 1/2, 3)), [3, 3]) 516s ***** assert (size (betarnd (1, 1, [4, 1])), [4, 1]) 516s ***** assert (size (betarnd (1, 1, 4, 1)), [4, 1]) 516s ***** assert (size (betarnd (1, 1, 4, 1, 5)), [4, 1, 5]) 516s ***** assert (size (betarnd (1, 1, 0, 1)), [0, 1]) 516s ***** assert (size (betarnd (1, 1, 1, 0)), [1, 0]) 516s ***** assert (size (betarnd (1, 1, 1, 2, 0, 5)), [1, 2, 0, 5]) 516s ***** assert (class (betarnd (1, 1)), "double") 516s ***** assert (class (betarnd (1, single (0))), "single") 516s ***** assert (class (betarnd (1, single ([0, 0]))), "single") 516s ***** assert (class (betarnd (1, single (1), 2)), "single") 516s ***** assert (class (betarnd (1, single ([1, 1]), 1, 2)), "single") 516s ***** assert (class (betarnd (single (1), 1, 2)), "single") 516s ***** assert (class (betarnd (single ([1, 1]), 1, 1, 2)), "single") 516s ***** error betarnd () 516s ***** error betarnd (1) 516s ***** error ... 516s betarnd (ones (3), ones (2)) 516s ***** error ... 516s betarnd (ones (2), ones (3)) 516s ***** error betarnd (i, 2) 516s ***** error betarnd (1, i) 516s ***** error ... 516s betarnd (1, 1/2, -1) 516s ***** error ... 516s betarnd (1, 1/2, 1.2) 516s ***** error ... 516s betarnd (1, 1/2, ones (2)) 516s ***** error ... 516s betarnd (1, 1/2, [2 -1 2]) 516s ***** error ... 516s betarnd (1, 1/2, [2 0 2.5]) 516s ***** error ... 516s betarnd (1, 1/2, 2, -1, 5) 516s ***** error ... 516s betarnd (1, 1/2, 2, 1.5, 5) 516s ***** error ... 516s betarnd (2, 1/2 * ones (2), 3) 516s ***** error ... 516s betarnd (2, 1/2 * ones (2), [3, 2]) 516s ***** error ... 516s betarnd (2, 1/2 * ones (2), 3, 2) 516s ***** error ... 516s betarnd (2 * ones (2), 1/2, 3) 516s ***** error ... 516s betarnd (2 * ones (2), 1/2, [3, 2]) 516s ***** error ... 516s betarnd (2 * ones (2), 1/2, 3, 2) 516s 40 tests, 40 passed, 0 known failure, 0 skipped 516s [inst/dist_fun/logicdf.m] 516s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/logicdf.m 516s ***** demo 516s ## Plot various CDFs from the logistic distribution 516s x = -5:0.01:20; 516s p1 = logicdf (x, 5, 2); 516s p2 = logicdf (x, 9, 3); 516s p3 = logicdf (x, 9, 4); 516s p4 = logicdf (x, 6, 2); 516s p5 = logicdf (x, 2, 1); 516s plot (x, p1, "-b", x, p2, "-g", x, p3, "-r", x, p4, "-c", x, p5, "-m") 516s grid on 516s legend ({"μ = 5, σ = 2", "μ = 9, σ = 3", "μ = 9, σ = 4", ... 516s "μ = 6, σ = 2", "μ = 2, σ = 1"}, "location", "southeast") 516s title ("Logistic CDF") 516s xlabel ("values in x") 516s ylabel ("probability") 516s ***** shared x, y 516s x = [-Inf -log(3) 0 log(3) Inf]; 516s y = [0, 1/4, 1/2, 3/4, 1]; 516s ***** assert (logicdf ([x, NaN], 0, 1), [y, NaN], eps) 516s ***** assert (logicdf (x, 0, [-2, -1, 0, 1, 2]), [nan(1, 3), 0.75, 1]) 516s ***** assert (logicdf (single ([x, NaN]), 0, 1), single ([y, NaN]), eps ("single")) 516s ***** assert (logicdf ([x, NaN], single (0), 1), single ([y, NaN]), eps ("single")) 516s ***** assert (logicdf ([x, NaN], 0, single (1)), single ([y, NaN]), eps ("single")) 516s ***** error logicdf () 516s ***** error logicdf (1) 516s ***** error ... 516s logicdf (1, 2) 516s ***** error logicdf (1, 2, 3, "tail") 516s ***** error logicdf (1, 2, 3, 4) 516s ***** error ... 516s logicdf (1, ones (2), ones (3)) 516s ***** error ... 516s logicdf (ones (2), 1, ones (3)) 516s ***** error ... 516s logicdf (ones (2), ones (3), 1) 516s ***** error logicdf (i, 2, 3) 516s ***** error logicdf (1, i, 3) 516s ***** error logicdf (1, 2, i) 516s 16 tests, 16 passed, 0 known failure, 0 skipped 516s [inst/dist_fun/geopdf.m] 516s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/geopdf.m 516s ***** demo 516s ## Plot various PDFs from the geometric distribution 516s x = 0:10; 516s y1 = geopdf (x, 0.2); 516s y2 = geopdf (x, 0.5); 516s y3 = geopdf (x, 0.7); 516s plot (x, y1, "*b", x, y2, "*g", x, y3, "*r") 516s grid on 516s ylim ([0, 0.8]) 516s legend ({"ps = 0.2", "ps = 0.5", "ps = 0.7"}, "location", "northeast") 516s title ("Geometric PDF") 516s xlabel ("values in x (number of failures)") 516s ylabel ("density") 516s ***** shared x, y 516s x = [-1 0 1 Inf]; 516s y = [0, 1/2, 1/4, NaN]; 516s ***** assert (geopdf (x, 0.5*ones (1,4)), y) 516s ***** assert (geopdf (x, 0.5), y) 516s ***** assert (geopdf (x, 0.5*[-1 NaN 4 1]), [NaN NaN NaN y(4)]) 516s ***** assert (geopdf ([x, NaN], 0.5), [y, NaN]) 516s ***** assert (geopdf (single ([x, NaN]), 0.5), single ([y, NaN]), 5*eps ("single")) 516s ***** assert (geopdf ([x, NaN], single (0.5)), single ([y, NaN]), 5*eps ("single")) 516s ***** error geopdf () 516s ***** error geopdf (1) 516s ***** error geopdf (1,2,3) 516s ***** error geopdf (ones (3), ones (2)) 516s ***** error geopdf (ones (2), ones (3)) 516s ***** error geopdf (i, 2) 516s ***** error geopdf (2, i) 516s 13 tests, 13 passed, 0 known failure, 0 skipped 516s [inst/dist_fun/tcdf.m] 516s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/tcdf.m 516s ***** demo 516s ## Plot various CDFs from the Student's T distribution 516s x = -5:0.01:5; 516s p1 = tcdf (x, 1); 516s p2 = tcdf (x, 2); 516s p3 = tcdf (x, 5); 516s p4 = tcdf (x, Inf); 516s plot (x, p1, "-b", x, p2, "-g", x, p3, "-r", x, p4, "-m") 516s grid on 516s xlim ([-5, 5]) 516s ylim ([0, 1]) 516s legend ({"df = 1", "df = 2", ... 516s "df = 5", 'df = \infty'}, "location", "southeast") 516s title ("Student's T CDF") 516s xlabel ("values in x") 516s ylabel ("probability") 516s ***** shared x,y 516s x = [-Inf 0 1 Inf]; 516s y = [0 1/2 3/4 1]; 516s ***** assert (tcdf (x, ones (1,4)), y, eps) 516s ***** assert (tcdf (x, 1), y, eps) 516s ***** assert (tcdf (x, [0 1 NaN 1]), [NaN 1/2 NaN 1], eps) 516s ***** assert (tcdf ([x(1:2) NaN x(4)], 1), [y(1:2) NaN y(4)], eps) 516s ***** assert (tcdf (2, 3, "upper"), 0.0697, 1e-4) 516s ***** assert (tcdf (205, 5, "upper"), 2.6206e-11, 1e-14) 516s ***** assert (tcdf ([x, NaN], 1), [y, NaN], eps) 516s ***** assert (tcdf (single ([x, NaN]), 1), single ([y, NaN]), eps ("single")) 516s ***** assert (tcdf ([x, NaN], single (1)), single ([y, NaN]), eps ("single")) 516s ***** error tcdf () 516s ***** error tcdf (1) 516s ***** error tcdf (1, 2, "uper") 516s ***** error tcdf (1, 2, 3) 516s ***** error ... 516s tcdf (ones (3), ones (2)) 516s ***** error ... 516s tcdf (ones (3), ones (2)) 516s ***** error ... 516s tcdf (ones (3), ones (2), "upper") 516s ***** error tcdf (i, 2) 516s ***** error tcdf (2, i) 516s ***** shared tol_rel 516s tol_rel = 10 * eps; 516s ***** assert (tcdf (10^(-10), 2.5), 0.50000000003618087, -tol_rel) 516s ***** assert (tcdf (10^(-11), 2.5), 0.50000000000361809, -tol_rel) 516s ***** assert (tcdf (10^(-12), 2.5), 0.50000000000036181, -tol_rel) 516s ***** assert (tcdf (10^(-13), 2.5), 0.50000000000003618, -tol_rel) 516s ***** assert (tcdf (10^(-14), 2.5), 0.50000000000000362, -tol_rel) 516s ***** assert (tcdf (10^(-15), 2.5), 0.50000000000000036, -tol_rel) 516s ***** assert (tcdf (10^(-16), 2.5), 0.50000000000000004, -tol_rel) 516s ***** assert (tcdf (-10^1, 2.5), 2.2207478836537124e-03, -tol_rel) 516s ***** assert (tcdf (-10^2, 2.5), 7.1916492116661878e-06, -tol_rel) 516s ***** assert (tcdf (-10^3, 2.5), 2.2747463948307452e-08, -tol_rel) 516s ***** assert (tcdf (-10^4, 2.5), 7.1933970159922115e-11, -tol_rel) 516s ***** assert (tcdf (-10^5, 2.5), 2.2747519231756221e-13, -tol_rel) 516s 30 tests, 30 passed, 0 known failure, 0 skipped 516s [inst/dist_fun/burrinv.m] 516s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/burrinv.m 516s ***** demo 516s ## Plot various iCDFs from the Burr type XII distribution 516s p = 0.001:0.001:0.999; 516s x1 = burrinv (p, 1, 1, 1); 516s x2 = burrinv (p, 1, 1, 2); 516s x3 = burrinv (p, 1, 1, 3); 516s x4 = burrinv (p, 1, 2, 1); 516s x5 = burrinv (p, 1, 3, 1); 516s x6 = burrinv (p, 1, 0.5, 2); 516s plot (p, x1, "-b", p, x2, "-g", p, x3, "-r", ... 516s p, x4, "-c", p, x5, "-m", p, x6, "-k") 516s grid on 516s ylim ([0, 5]) 516s legend ({"λ = 1, c = 1, k = 1", "λ = 1, c = 1, k = 2", ... 516s "λ = 1, c = 1, k = 3", "λ = 1, c = 2, k = 1", ... 516s "λ = 1, c = 3, k = 1", "λ = 1, c = 0.5, k = 2"}, ... 516s "location", "northwest") 516s title ("Burr type XII iCDF") 516s xlabel ("probability") 516s ylabel ("values in x") 516s ***** shared p, y 516s p = [-Inf, -1, 0, 1/2, 1, 2, Inf]; 516s y = [NaN, NaN, 0, 1 , Inf, NaN, NaN]; 516s ***** assert (burrinv (p, ones (1,7), ones (1,7), ones(1,7)), y, eps) 516s ***** assert (burrinv (p, 1, 1, 1), y, eps) 516s ***** assert (burrinv (p, [1, 1, 1, NaN, 1, 1, 1], 1, 1), [y(1:3), NaN, y(5:7)], eps) 516s ***** assert (burrinv (p, 1, [1, 1, 1, NaN, 1, 1, 1], 1), [y(1:3), NaN, y(5:7)], eps) 516s ***** assert (burrinv (p, 1, 1, [1, 1, 1, NaN, 1, 1, 1]), [y(1:3), NaN, y(5:7)], eps) 516s ***** assert (burrinv ([p, NaN], 1, 1, 1), [y, NaN], eps) 516s ***** assert (burrinv (single ([p, NaN]), 1, 1, 1), single ([y, NaN]), eps("single")) 516s ***** assert (burrinv ([p, NaN], single (1), 1, 1), single ([y, NaN]), eps("single")) 516s ***** assert (burrinv ([p, NaN], 1, single (1), 1), single ([y, NaN]), eps("single")) 516s ***** assert (burrinv ([p, NaN], 1, 1, single (1)), single ([y, NaN]), eps("single")) 516s ***** error burrinv () 516s ***** error burrinv (1) 516s ***** error burrinv (1, 2) 516s ***** error burrinv (1, 2, 3) 516s ***** error ... 516s burrinv (1, 2, 3, 4, 5) 516s ***** error ... 516s burrinv (ones (3), ones (2), ones(2), ones(2)) 516s ***** error ... 516s burrinv (ones (2), ones (3), ones(2), ones(2)) 516s ***** error ... 516s burrinv (ones (2), ones (2), ones(3), ones(2)) 516s ***** error ... 516s burrinv (ones (2), ones (2), ones(2), ones(3)) 516s ***** error burrinv (i, 2, 3, 4) 516s ***** error burrinv (1, i, 3, 4) 516s ***** error burrinv (1, 2, i, 4) 516s ***** error burrinv (1, 2, 3, i) 516s 23 tests, 23 passed, 0 known failure, 0 skipped 516s [inst/dist_fun/chi2rnd.m] 516s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/chi2rnd.m 516s ***** assert (size (chi2rnd (2)), [1, 1]) 516s ***** assert (size (chi2rnd (ones (2,1))), [2, 1]) 516s ***** assert (size (chi2rnd (ones (2,2))), [2, 2]) 516s ***** assert (size (chi2rnd (1, 3)), [3, 3]) 516s ***** assert (size (chi2rnd (1, [4 1])), [4, 1]) 516s ***** assert (size (chi2rnd (1, 4, 1)), [4, 1]) 516s ***** assert (size (chi2rnd (1, 4, 1)), [4, 1]) 516s ***** assert (size (chi2rnd (1, 4, 1, 5)), [4, 1, 5]) 516s ***** assert (size (chi2rnd (1, 0, 1)), [0, 1]) 516s ***** assert (size (chi2rnd (1, 1, 0)), [1, 0]) 516s ***** assert (size (chi2rnd (1, 1, 2, 0, 5)), [1, 2, 0, 5]) 516s ***** assert (class (chi2rnd (2)), "double") 516s ***** assert (class (chi2rnd (single (2))), "single") 516s ***** assert (class (chi2rnd (single ([2 2]))), "single") 516s ***** error chi2rnd () 516s ***** error chi2rnd (i) 516s ***** error ... 516s chi2rnd (1, -1) 516s ***** error ... 516s chi2rnd (1, 1.2) 516s ***** error ... 516s chi2rnd (1, ones (2)) 516s ***** error ... 516s chi2rnd (1, [2 -1 2]) 516s ***** error ... 516s chi2rnd (1, [2 0 2.5]) 516s ***** error ... 516s chi2rnd (ones (2), ones (2)) 516s ***** error ... 516s chi2rnd (1, 2, -1, 5) 516s ***** error ... 516s chi2rnd (1, 2, 1.5, 5) 516s ***** error chi2rnd (ones (2,2), 3) 516s ***** error chi2rnd (ones (2,2), [3, 2]) 516s ***** error chi2rnd (ones (2,2), 2, 3) 516s 27 tests, 27 passed, 0 known failure, 0 skipped 516s [inst/dist_fun/tlsrnd.m] 516s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/tlsrnd.m 516s ***** assert (size (tlsrnd (1, 2, 3)), [1, 1]) 516s ***** assert (size (tlsrnd (ones (2,1), 2, 3)), [2, 1]) 516s ***** assert (size (tlsrnd (ones (2,2), 2, 3)), [2, 2]) 516s ***** assert (size (tlsrnd (1, 2, 3, 3)), [3, 3]) 516s ***** assert (size (tlsrnd (1, 2, 3, [4 1])), [4, 1]) 516s ***** assert (size (tlsrnd (1, 2, 3, 4, 1)), [4, 1]) 516s ***** assert (size (tlsrnd (1, 2, 3, 4, 1)), [4, 1]) 516s ***** assert (size (tlsrnd (1, 2, 3, 4, 1, 5)), [4, 1, 5]) 516s ***** assert (size (tlsrnd (1, 2, 3, 0, 1)), [0, 1]) 516s ***** assert (size (tlsrnd (1, 2, 3, 1, 0)), [1, 0]) 516s ***** assert (size (tlsrnd (1, 2, 3, 1, 2, 0, 5)), [1, 2, 0, 5]) 516s ***** assert (tlsrnd (1, 2, 0, 1, 1), NaN) 516s ***** assert (tlsrnd (1, 2, [0, 0, 0], [1, 3]), [NaN, NaN, NaN]) 516s ***** assert (class (tlsrnd (1, 2, 3)), "double") 516s ***** assert (class (tlsrnd (single (1), 2, 3)), "single") 516s ***** assert (class (tlsrnd (single ([1, 1]), 2, 3)), "single") 516s ***** assert (class (tlsrnd (1, single (2), 3)), "single") 516s ***** assert (class (tlsrnd (1, single ([2, 2]), 3)), "single") 516s ***** assert (class (tlsrnd (1, 2, single (3))), "single") 516s ***** assert (class (tlsrnd (1, 2, single ([3, 3]))), "single") 516s ***** error tlsrnd () 516s ***** error tlsrnd (1) 516s ***** error tlsrnd (1, 2) 516s ***** error ... 516s tlsrnd (ones (3), ones (2), 1) 516s ***** error ... 516s tlsrnd (ones (2), 1, ones (3)) 516s ***** error ... 516s tlsrnd (1, ones (2), ones (3)) 516s ***** error tlsrnd (i, 2, 3) 516s ***** error tlsrnd (1, i, 3) 516s ***** error tlsrnd (1, 2, i) 516s ***** error ... 516s tlsrnd (1, 2, 3, -1) 516s ***** error ... 516s tlsrnd (1, 2, 3, 1.2) 516s ***** error ... 516s tlsrnd (1, 2, 3, ones (2)) 516s ***** error ... 516s tlsrnd (1, 2, 3, [2 -1 2]) 516s ***** error ... 516s tlsrnd (1, 2, 3, [2 0 2.5]) 516s ***** error ... 516s tlsrnd (ones (2), 2, 3, ones (2)) 516s ***** error ... 516s tlsrnd (1, 2, 3, 2, -1, 5) 516s ***** error ... 516s tlsrnd (1, 2, 3, 2, 1.5, 5) 516s ***** error ... 516s tlsrnd (ones (2,2), 2, 3, 3) 516s ***** error ... 516s tlsrnd (1, ones (2,2), 3, 3) 516s ***** error ... 516s tlsrnd (1, 2, ones (2,2), 3) 516s ***** error ... 516s tlsrnd (1, 2, ones (2,2), [3, 3]) 516s ***** error ... 516s tlsrnd (1, 2, ones (2,2), 2, 3) 516s 42 tests, 42 passed, 0 known failure, 0 skipped 516s [inst/dist_fun/ncfpdf.m] 516s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/ncfpdf.m 516s ***** demo 516s ## Plot various PDFs from the noncentral F distribution 516s x = 0:0.01:5; 516s y1 = ncfpdf (x, 2, 5, 1); 516s y2 = ncfpdf (x, 2, 5, 2); 516s y3 = ncfpdf (x, 5, 10, 1); 516s y4 = ncfpdf (x, 10, 20, 10); 516s plot (x, y1, "-r", x, y2, "-g", x, y3, "-k", x, y4, "-m") 516s grid on 516s xlim ([0, 5]) 516s ylim ([0, 0.8]) 516s legend ({"df1 = 2, df2 = 5, λ = 1", "df1 = 2, df2 = 5, λ = 2", ... 516s "df1 = 5, df2 = 10, λ = 1", "df1 = 10, df2 = 20, λ = 10"}, ... 516s "location", "northeast") 516s title ("Noncentral F PDF") 516s xlabel ("values in x") 516s ylabel ("density") 516s ***** demo 516s ## Compare the noncentral F PDF with LAMBDA = 10 to the F PDF with the 516s ## same number of numerator and denominator degrees of freedom (5, 20) 516s 516s x = 0.01:0.1:10.01; 516s y1 = ncfpdf (x, 5, 20, 10); 516s y2 = fpdf (x, 5, 20); 516s plot (x, y1, "-", x, y2, "-"); 516s grid on 516s xlim ([0, 10]) 516s ylim ([0, 0.8]) 516s legend ({"Noncentral F(5,20,10)", "F(5,20)"}, "location", "northeast") 516s title ("Noncentral F vs F PDFs") 516s xlabel ("values in x") 516s ylabel ("density") 516s ***** shared x1, df1, df2, lambda 516s x1 = [-Inf, 2, NaN, 4, Inf]; 516s df1 = [2, 0, -1, 1, 4]; 516s df2 = [2, 4, 5, 6, 8]; 516s lambda = [1, NaN, 3, -1, 2]; 516s ***** assert (ncfpdf (x1, df1, df2, lambda), [0, NaN, NaN, NaN, NaN]); 517s ***** assert (ncfpdf (x1, df1, df2, 1), [0, NaN, NaN, ... 517s 0.05607937264237208, NaN], 1e-14); 517s ***** assert (ncfpdf (x1, df1, df2, 3), [0, NaN, NaN, ... 517s 0.080125760971946518, NaN], 1e-14); 517s ***** assert (ncfpdf (x1, df1, df2, 2), [0, NaN, NaN, ... 517s 0.0715902008258656, NaN], 1e-14); 517s ***** assert (ncfpdf (x1, 3, 5, lambda), [0, NaN, NaN, NaN, NaN]); 517s ***** assert (ncfpdf (2, df1, df2, lambda), [0.1254046999837947, NaN, NaN, ... 517s NaN, 0.2152571783045893], 1e-14); 517s ***** assert (ncfpdf (4, df1, df2, lambda), [0.05067089541001374, NaN, NaN, ... 517s NaN, 0.05560846335398539], 1e-14); 517s ***** error ncfpdf () 517s ***** error ncfpdf (1) 517s ***** error ncfpdf (1, 2) 517s ***** error ncfpdf (1, 2, 3) 517s ***** error ... 517s ncfpdf (ones (3), ones (2), ones (2), ones (2)) 517s ***** error ... 517s ncfpdf (ones (2), ones (3), ones (2), ones (2)) 517s ***** error ... 517s ncfpdf (ones (2), ones (2), ones (3), ones (2)) 517s ***** error ... 517s ncfpdf (ones (2), ones (2), ones (2), ones (3)) 517s ***** error ncfpdf (i, 2, 2, 2) 517s ***** error ncfpdf (2, i, 2, 2) 517s ***** error ncfpdf (2, 2, i, 2) 517s ***** error ncfpdf (2, 2, 2, i) 517s 19 tests, 19 passed, 0 known failure, 0 skipped 517s [inst/dist_fun/gumbelcdf.m] 517s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/gumbelcdf.m 517s ***** demo 517s ## Plot various CDFs from the Gumbel distribution 517s x = -5:0.01:20; 517s p1 = gumbelcdf (x, 0.5, 2); 517s p2 = gumbelcdf (x, 1.0, 2); 517s p3 = gumbelcdf (x, 1.5, 3); 517s p4 = gumbelcdf (x, 3.0, 4); 517s plot (x, p1, "-b", x, p2, "-g", x, p3, "-r", x, p4, "-c") 517s grid on 517s legend ({"μ = 0.5, β = 2", "μ = 1.0, β = 2", ... 517s "μ = 1.5, β = 3", "μ = 3.0, β = 4"}, "location", "southeast") 517s title ("Gumbel CDF") 517s xlabel ("values in x") 517s ylabel ("probability") 517s ***** shared x, y 517s x = [-Inf, 1, 2, Inf]; 517s y = [0, 0.3679, 0.6922, 1]; 517s ***** assert (gumbelcdf (x, ones (1,4), ones (1,4)), y, 1e-4) 517s ***** assert (gumbelcdf (x, 1, ones (1,4)), y, 1e-4) 517s ***** assert (gumbelcdf (x, ones (1,4), 1), y, 1e-4) 517s ***** assert (gumbelcdf (x, [0, -Inf, NaN, Inf], 1), [0, 1, NaN, NaN], 1e-4) 517s ***** assert (gumbelcdf (x, 1, [Inf, NaN, -1, 0]), [NaN, NaN, NaN, NaN], 1e-4) 517s ***** assert (gumbelcdf ([x(1:2), NaN, x(4)], 1, 1), [y(1:2), NaN, y(4)], 1e-4) 517s ***** assert (gumbelcdf (x, "upper"), [1, 0.3078, 0.1266, 0], 1e-4) 517s ***** assert (gumbelcdf ([x, NaN], 1, 1), [y, NaN], 1e-4) 517s ***** assert (gumbelcdf (single ([x, NaN]), 1, 1), single ([y, NaN]), 1e-4) 517s ***** assert (gumbelcdf ([x, NaN], single (1), 1), single ([y, NaN]), 1e-4) 517s ***** assert (gumbelcdf ([x, NaN], 1, single (1)), single ([y, NaN]), 1e-4) 517s ***** error gumbelcdf () 517s ***** error gumbelcdf (1,2,3,4,5,6,7) 517s ***** error gumbelcdf (1, 2, 3, 4, "uper") 517s ***** error ... 517s gumbelcdf (ones (3), ones (2), ones (2)) 517s ***** error gumbelcdf (2, 3, 4, [1, 2]) 517s ***** error ... 517s [p, plo, pup] = gumbelcdf (1, 2, 3) 517s ***** error [p, plo, pup] = ... 517s gumbelcdf (1, 2, 3, [1, 0; 0, 1], 0) 517s ***** error [p, plo, pup] = ... 517s gumbelcdf (1, 2, 3, [1, 0; 0, 1], 1.22) 517s ***** error [p, plo, pup] = ... 517s gumbelcdf (1, 2, 3, [1, 0; 0, 1], "alpha", "upper") 517s ***** error gumbelcdf (i, 2, 2) 517s ***** error gumbelcdf (2, i, 2) 517s ***** error gumbelcdf (2, 2, i) 517s ***** error ... 517s [p, plo, pup] = gumbelcdf (1, 2, 3, [1, 0; 0, -inf], 0.04) 517s 24 tests, 24 passed, 0 known failure, 0 skipped 517s [inst/dist_fun/nctpdf.m] 517s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/nctpdf.m 517s ***** demo 517s ## Plot various PDFs from the noncentral T distribution 517s x = -5:0.01:10; 517s y1 = nctpdf (x, 1, 0); 517s y2 = nctpdf (x, 4, 0); 517s y3 = nctpdf (x, 1, 2); 517s y4 = nctpdf (x, 4, 2); 517s plot (x, y1, "-r", x, y2, "-g", x, y3, "-k", x, y4, "-m") 517s grid on 517s xlim ([-5, 10]) 517s ylim ([0, 0.4]) 517s legend ({"df = 1, μ = 0", "df = 4, μ = 0", ... 517s "df = 1, μ = 2", "df = 4, μ = 2"}, "location", "northeast") 517s title ("Noncentral T PDF") 517s xlabel ("values in x") 517s ylabel ("density") 517s ***** demo 517s ## Compare the noncentral T PDF with MU = 1 to the T PDF 517s ## with the same number of degrees of freedom (10). 517s 517s x = -5:0.1:5; 517s y1 = nctpdf (x, 10, 1); 517s y2 = tpdf (x, 10); 517s plot (x, y1, "-", x, y2, "-"); 517s grid on 517s xlim ([-5, 5]) 517s ylim ([0, 0.4]) 517s legend ({"Noncentral χ^2(4,2)", "χ^2(4)"}, "location", "northwest") 517s title ("Noncentral T vs T PDFs") 517s xlabel ("values in x") 517s ylabel ("density") 517s ***** shared x1, df, mu 517s x1 = [-Inf, 2, NaN, 4, Inf]; 517s df = [2, 0, -1, 1, 4]; 517s mu = [1, NaN, 3, -1, 2]; 517s ***** assert (nctpdf (x1, df, mu), [0, NaN, NaN, 0.00401787561306999, 0], 1e-14); 517s ***** assert (nctpdf (x1, df, 1), [0, NaN, NaN, 0.0482312135423008, 0], 1e-14); 517s ***** assert (nctpdf (x1, df, 3), [0, NaN, NaN, 0.1048493126401585, 0], 1e-14); 517s ***** assert (nctpdf (x1, df, 2), [0, NaN, NaN, 0.08137377919890307, 0], 1e-14); 517s ***** assert (nctpdf (x1, 3, mu), [0, NaN, NaN, 0.001185305171654381, 0], 1e-14); 517s ***** assert (nctpdf (2, df, mu), [0.1791097459405861, NaN, NaN, ... 517s 0.0146500727180389, 0.3082302682110299], 1e-14); 517s ***** assert (nctpdf (4, df, mu), [0.04467929612254971, NaN, NaN, ... 517s 0.00401787561306999, 0.0972086534042828], 1e-14); 517s ***** error nctpdf () 517s ***** error nctpdf (1) 517s ***** error nctpdf (1, 2) 517s ***** error ... 517s nctpdf (ones (3), ones (2), ones (2)) 517s ***** error ... 517s nctpdf (ones (2), ones (3), ones (2)) 517s ***** error ... 517s nctpdf (ones (2), ones (2), ones (3)) 517s ***** error nctpdf (i, 2, 2) 517s ***** error nctpdf (2, i, 2) 517s ***** error nctpdf (2, 2, i) 517s 16 tests, 16 passed, 0 known failure, 0 skipped 517s [inst/dist_fun/cauchypdf.m] 517s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/cauchypdf.m 517s ***** demo 517s ## Plot various PDFs from the Cauchy distribution 517s x = -5:0.01:5; 517s y1 = cauchypdf (x, 0, 0.5); 517s y2 = cauchypdf (x, 0, 1); 517s y3 = cauchypdf (x, 0, 2); 517s y4 = cauchypdf (x, -2, 1); 517s plot (x, y1, "-b", x, y2, "-g", x, y3, "-r", x, y4, "-c") 517s grid on 517s xlim ([-5, 5]) 517s ylim ([0, 0.7]) 517s legend ({"x0 = 0, γ = 0.5", "x0 = 0, γ = 1", ... 517s "x0 = 0, γ = 2", "x0 = -2, γ = 1"}, "location", "northeast") 517s title ("Cauchy PDF") 517s xlabel ("values in x") 517s ylabel ("density") 517s ***** shared x, y 517s x = [-1 0 0.5 1 2]; 517s y = 1/pi * ( 2 ./ ((x-1).^2 + 2^2) ); 517s ***** assert (cauchypdf (x, ones (1,5), 2*ones (1,5)), y) 517s ***** assert (cauchypdf (x, 1, 2*ones (1,5)), y) 517s ***** assert (cauchypdf (x, ones (1,5), 2), y) 517s ***** assert (cauchypdf (x, [-Inf 1 NaN 1 Inf], 2), [NaN y(2) NaN y(4) NaN]) 517s ***** assert (cauchypdf (x, 1, 2*[0 1 NaN 1 Inf]), [NaN y(2) NaN y(4) NaN]) 517s ***** assert (cauchypdf ([x, NaN], 1, 2), [y, NaN]) 517s ***** assert (cauchypdf (single ([x, NaN]), 1, 2), single ([y, NaN]), eps ("single")) 517s ***** assert (cauchypdf ([x, NaN], single (1), 2), single ([y, NaN]), eps ("single")) 517s ***** assert (cauchypdf ([x, NaN], 1, single (2)), single ([y, NaN]), eps ("single")) 517s ***** test 517s x = rand (10, 1); 517s assert (cauchypdf (x, 0, 1), tpdf (x, 1), eps); 517s ***** error cauchypdf () 517s ***** error cauchypdf (1) 517s ***** error ... 517s cauchypdf (1, 2) 517s ***** error cauchypdf (1, 2, 3, 4) 517s ***** error ... 517s cauchypdf (ones (3), ones (2), ones(2)) 517s ***** error ... 517s cauchypdf (ones (2), ones (3), ones(2)) 517s ***** error ... 517s cauchypdf (ones (2), ones (2), ones(3)) 517s ***** error cauchypdf (i, 4, 3) 517s ***** error cauchypdf (1, i, 3) 517s ***** error cauchypdf (1, 4, i) 517s 20 tests, 20 passed, 0 known failure, 0 skipped 517s [inst/dist_fun/burrpdf.m] 518s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/burrpdf.m 518s ***** demo 518s ## Plot various PDFs from the Burr type XII distribution 518s x = 0.001:0.001:3; 518s y1 = burrpdf (x, 1, 1, 1); 518s y2 = burrpdf (x, 1, 1, 2); 518s y3 = burrpdf (x, 1, 1, 3); 518s y4 = burrpdf (x, 1, 2, 1); 518s y5 = burrpdf (x, 1, 3, 1); 518s y6 = burrpdf (x, 1, 0.5, 2); 518s plot (x, y1, "-b", x, y2, "-g", x, y3, "-r", ... 518s x, y4, "-c", x, y5, "-m", x, y6, "-k") 518s grid on 518s ylim ([0, 2]) 518s legend ({"λ = 1, c = 1, k = 1", "λ = 1, c = 1, k = 2", ... 518s "λ = 1, c = 1, k = 3", "λ = 1, c = 2, k = 1", ... 518s "λ = 1, c = 3, k = 1", "λ = 1, c = 0.5, k = 2"}, ... 518s "location", "northeast") 518s title ("Burr type XII PDF") 518s xlabel ("values in x") 518s ylabel ("density") 518s ***** shared x, y 518s x = [-1, 0, 1, 2, Inf]; 518s y = [0, 1, 1/4, 1/9, 0]; 518s ***** assert (burrpdf (x, ones(1,5), ones (1,5), ones (1,5)), y) 518s ***** assert (burrpdf (x, 1, 1, 1), y) 518s ***** assert (burrpdf (x, [1, 1, NaN, 1, 1], 1, 1), [y(1:2), NaN, y(4:5)]) 518s ***** assert (burrpdf (x, 1, [1, 1, NaN, 1, 1], 1), [y(1:2), NaN, y(4:5)]) 518s ***** assert (burrpdf (x, 1, 1, [1, 1, NaN, 1, 1]), [y(1:2), NaN, y(4:5)]) 518s ***** assert (burrpdf ([x, NaN], 1, 1, 1), [y, NaN]) 518s ***** assert (burrpdf (single ([x, NaN]), 1, 1, 1), single ([y, NaN])) 518s ***** assert (burrpdf ([x, NaN], single (1), 1, 1), single ([y, NaN])) 518s ***** assert (burrpdf ([x, NaN], 1, single (1), 1), single ([y, NaN])) 518s ***** assert (burrpdf ([x, NaN], 1, 1, single (1)), single ([y, NaN])) 518s ***** error burrpdf () 518s ***** error burrpdf (1) 518s ***** error burrpdf (1, 2) 518s ***** error burrpdf (1, 2, 3) 518s ***** error ... 518s burrpdf (1, 2, 3, 4, 5) 518s ***** error ... 518s burrpdf (ones (3), ones (2), ones(2), ones(2)) 518s ***** error ... 518s burrpdf (ones (2), ones (3), ones(2), ones(2)) 518s ***** error ... 518s burrpdf (ones (2), ones (2), ones(3), ones(2)) 518s ***** error ... 518s burrpdf (ones (2), ones (2), ones(2), ones(3)) 518s ***** error burrpdf (i, 2, 3, 4) 518s ***** error burrpdf (1, i, 3, 4) 518s ***** error burrpdf (1, 2, i, 4) 518s ***** error burrpdf (1, 2, 3, i) 518s 23 tests, 23 passed, 0 known failure, 0 skipped 518s [inst/dist_fun/plcdf.m] 518s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/plcdf.m 518s ***** demo 518s ## Plot various CDFs from the Piecewise linear distribution 518s data = 0:0.01:10; 518s x1 = [0, 1, 3, 4, 7, 10]; 518s Fx1 = [0, 0.2, 0.5, 0.6, 0.7, 1]; 518s x2 = [0, 2, 5, 6, 7, 8]; 518s Fx2 = [0, 0.1, 0.3, 0.6, 0.9, 1]; 518s p1 = plcdf (data, x1, Fx1); 518s p2 = plcdf (data, x2, Fx2); 518s plot (data, p1, "-b", data, p2, "g") 518s grid on 518s ylim ([0, 1]) 518s xlim ([0, 10]) 518s legend ({"x1, Fx1", "x2, Fx2"}, "location", "southeast") 518s title ("Piecewise linear CDF") 518s xlabel ("values in data") 518s ylabel ("probability") 518s ***** test 518s data = 0:0.2:1; 518s p = plcdf (data, [0, 1], [0, 1]); 518s assert (p, data); 518s ***** test 518s data = 0:0.2:1; 518s p = plcdf (data, [0, 2], [0, 1]); 518s assert (p, 0.5 * data); 518s ***** test 518s data = 0:0.2:1; 518s p = plcdf (data, [0, 1], [0, 0.5]); 518s assert (p, 0.5 * data); 518s ***** test 518s data = 0:0.2:1; 518s p = plcdf (data, [0, 0.5], [0, 1]); 518s assert (p, [0, 0.4, 0.8, 1, 1, 1]); 518s ***** test 518s data = 0:0.2:1; 518s p = plcdf (data, [0, 1], [0, 1], "upper"); 518s assert (p, 1 - data); 518s ***** error plcdf () 518s ***** error plcdf (1) 518s ***** error plcdf (1, 2) 518s ***** error plcdf (1, 2, 3, "uper") 518s ***** error plcdf (1, 2, 3, 4) 518s ***** error ... 518s plcdf (1, [0, 1, 2], [0, 1]) 518s ***** error ... 518s plcdf (1, [0], [1]) 518s ***** error ... 518s plcdf (1, [0, 1, 2], [0, 1, 1.5]) 518s ***** error ... 518s plcdf (1, [0, 1, 2], [0, i, 1]) 518s ***** error ... 518s plcdf (i, [0, 1, 2], [0, 0.5, 1]) 518s ***** error ... 518s plcdf (1, [0, i, 2], [0, 0.5, 1]) 518s ***** error ... 518s plcdf (1, [0, 1, 2], [0, 0.5i, 1]) 518s 17 tests, 17 passed, 0 known failure, 0 skipped 518s [inst/dist_fun/hygeinv.m] 518s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/hygeinv.m 518s ***** demo 518s ## Plot various iCDFs from the hypergeometric distribution 518s p = 0.001:0.001:0.999; 518s x1 = hygeinv (p, 500, 50, 100); 518s x2 = hygeinv (p, 500, 60, 200); 518s x3 = hygeinv (p, 500, 70, 300); 518s plot (p, x1, "-b", p, x2, "-g", p, x3, "-r") 518s grid on 518s ylim ([0, 60]) 518s legend ({"m = 500, k = 50, n = 100", "m = 500, k = 60, n = 200", ... 518s "m = 500, k = 70, n = 300"}, "location", "northwest") 518s title ("Hypergeometric iCDF") 518s xlabel ("probability") 518s ylabel ("values in p (number of successes)") 518s ***** shared p 518s p = [-1 0 0.5 1 2]; 518s ***** assert (hygeinv (p, 4*ones (1,5), 2*ones (1,5), 2*ones (1,5)), [NaN 0 1 2 NaN]) 518s ***** assert (hygeinv (p, 4*ones (1,5), 2, 2), [NaN 0 1 2 NaN]) 518s ***** assert (hygeinv (p, 4, 2*ones (1,5), 2), [NaN 0 1 2 NaN]) 518s ***** assert (hygeinv (p, 4, 2, 2*ones (1,5)), [NaN 0 1 2 NaN]) 518s ***** assert (hygeinv (p, 4*[1 -1 NaN 1.1 1], 2, 2), [NaN NaN NaN NaN NaN]) 518s ***** assert (hygeinv (p, 4, 2*[1 -1 NaN 1.1 1], 2), [NaN NaN NaN NaN NaN]) 518s ***** assert (hygeinv (p, 4, 5, 2), [NaN NaN NaN NaN NaN]) 518s ***** assert (hygeinv (p, 4, 2, 2*[1 -1 NaN 1.1 1]), [NaN NaN NaN NaN NaN]) 518s ***** assert (hygeinv (p, 4, 2, 5), [NaN NaN NaN NaN NaN]) 518s ***** assert (hygeinv ([p(1:2) NaN p(4:5)], 4, 2, 2), [NaN 0 NaN 2 NaN]) 518s ***** assert (hygeinv ([p, NaN], 4, 2, 2), [NaN 0 1 2 NaN NaN]) 518s ***** assert (hygeinv (single ([p, NaN]), 4, 2, 2), single ([NaN 0 1 2 NaN NaN])) 518s ***** assert (hygeinv ([p, NaN], single (4), 2, 2), single ([NaN 0 1 2 NaN NaN])) 518s ***** assert (hygeinv ([p, NaN], 4, single (2), 2), single ([NaN 0 1 2 NaN NaN])) 518s ***** assert (hygeinv ([p, NaN], 4, 2, single (2)), single ([NaN 0 1 2 NaN NaN])) 518s ***** error hygeinv () 518s ***** error hygeinv (1) 518s ***** error hygeinv (1,2) 518s ***** error hygeinv (1,2,3) 518s ***** error ... 518s hygeinv (ones (2), ones (3), 1, 1) 518s ***** error ... 518s hygeinv (1, ones (2), ones (3), 1) 518s ***** error ... 518s hygeinv (1, 1, ones (2), ones (3)) 518s ***** error hygeinv (i, 2, 2, 2) 518s ***** error hygeinv (2, i, 2, 2) 518s ***** error hygeinv (2, 2, i, 2) 518s ***** error hygeinv (2, 2, 2, i) 518s 26 tests, 26 passed, 0 known failure, 0 skipped 518s [inst/dist_fun/tlspdf.m] 518s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/tlspdf.m 518s ***** demo 518s ## Plot various PDFs from the Student's T distribution 518s x = -8:0.01:8; 518s y1 = tlspdf (x, 0, 1, 1); 518s y2 = tlspdf (x, 0, 2, 2); 518s y3 = tlspdf (x, 3, 2, 5); 518s y4 = tlspdf (x, -1, 3, Inf); 518s plot (x, y1, "-b", x, y2, "-g", x, y3, "-r", x, y4, "-m") 518s grid on 518s xlim ([-8, 8]) 518s ylim ([0, 0.41]) 518s legend ({"mu = 0, sigma = 1, nu = 1", "mu = 0, sigma = 2, nu = 2", ... 518s "mu = 3, sigma = 2, nu = 5", 'mu = -1, sigma = 3, nu = \infty'}, ... 518s "location", "northwest") 518s title ("Location-scale Student's T PDF") 518s xlabel ("values in x") 518s ylabel ("density") 518s ***** test 518s x = rand (10,1); 518s y = 1./(pi * (1 + x.^2)); 518s assert (tlspdf (x, 0, 1, 1), y, 5*eps); 518s assert (tlspdf (x+5, 5, 1, 1), y, 5*eps); 518s assert (tlspdf (x.*2, 0, 2, 1), y./2, 5*eps); 518s ***** shared x, y 518s x = [-Inf 0 0.5 1 Inf]; 518s y = 1./(pi * (1 + x.^2)); 518s ***** assert (tlspdf (x, 0, 1, ones (1,5)), y, eps) 518s ***** assert (tlspdf (x, 0, 1, 1), y, eps) 518s ***** assert (tlspdf (x, 0, 1, [0 NaN 1 1 1]), [NaN NaN y(3:5)], eps) 518s ***** assert (tlspdf (x, 0, 1, Inf), normpdf (x)) 518s ***** assert (class (tlspdf ([x, NaN], 1, 1, 1)), "double") 518s ***** assert (class (tlspdf (single ([x, NaN]), 1, 1, 1)), "single") 518s ***** assert (class (tlspdf ([x, NaN], single (1), 1, 1)), "single") 518s ***** assert (class (tlspdf ([x, NaN], 1, single (1), 1)), "single") 518s ***** assert (class (tlspdf ([x, NaN], 1, 1, single (1))), "single") 518s ***** error tlspdf () 518s ***** error tlspdf (1) 518s ***** error tlspdf (1, 2) 518s ***** error tlspdf (1, 2, 3) 518s ***** error ... 518s tlspdf (ones (3), ones (2), 1, 1) 518s ***** error ... 518s tlspdf (ones (2), 1, ones (3), 1) 518s ***** error ... 518s tlspdf (ones (2), 1, 1, ones (3)) 518s ***** error tlspdf (i, 2, 1, 1) 518s ***** error tlspdf (2, i, 1, 1) 518s ***** error tlspdf (2, 1, i, 1) 518s ***** error tlspdf (2, 1, 1, i) 518s 21 tests, 21 passed, 0 known failure, 0 skipped 518s [inst/dist_fun/binocdf.m] 518s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/binocdf.m 518s ***** demo 518s ## Plot various CDFs from the binomial distribution 518s x = 0:40; 518s p1 = binocdf (x, 20, 0.5); 518s p2 = binocdf (x, 20, 0.7); 518s p3 = binocdf (x, 40, 0.5); 518s plot (x, p1, "*b", x, p2, "*g", x, p3, "*r") 518s grid on 518s legend ({"n = 20, ps = 0.5", "n = 20, ps = 0.7", ... 518s "n = 40, ps = 0.5"}, "location", "southeast") 518s title ("Binomial CDF") 518s xlabel ("values in x (number of successes)") 518s ylabel ("probability") 518s ***** shared x, p, p1 518s x = [-1 0 1 2 3]; 518s p = [0 1/4 3/4 1 1]; 518s p1 = 1 - p; 518s ***** assert (binocdf (x, 2 * ones (1, 5), 0.5 * ones (1, 5)), p, eps) 518s ***** assert (binocdf (x, 2, 0.5 * ones (1, 5)), p, eps) 518s ***** assert (binocdf (x, 2 * ones (1, 5), 0.5), p, eps) 518s ***** assert (binocdf (x, 2 * [0 -1 NaN 1.1 1], 0.5), [0 NaN NaN NaN 1]) 518s ***** assert (binocdf (x, 2, 0.5 * [0 -1 NaN 3 1]), [0 NaN NaN NaN 1]) 518s ***** assert (binocdf ([x(1:2) NaN x(4:5)], 2, 0.5), [p(1:2) NaN p(4:5)], eps) 518s ***** assert (binocdf (99, 100, 0.1, "upper"), 1e-100, 1e-112); 518s ***** assert (binocdf (x, 2 * ones (1, 5), 0.5*ones (1,5), "upper"), p1, eps) 518s ***** assert (binocdf (x, 2, 0.5 * ones (1, 5), "upper"), p1, eps) 518s ***** assert (binocdf (x, 2 * ones (1, 5), 0.5, "upper"), p1, eps) 518s ***** assert (binocdf (x, 2 * [0 -1 NaN 1.1 1], 0.5, "upper"), [1 NaN NaN NaN 0]) 518s ***** assert (binocdf (x, 2, 0.5 * [0 -1 NaN 3 1], "upper"), [1 NaN NaN NaN 0]) 518s ***** assert (binocdf ([x(1:2) NaN x(4:5)], 2, 0.5, "upper"), [p1(1:2) NaN p1(4:5)]) 518s ***** assert (binocdf ([x, NaN], 2, 0.5), [p, NaN], eps) 518s ***** assert (binocdf (single ([x, NaN]), 2, 0.5), single ([p, NaN])) 518s ***** assert (binocdf ([x, NaN], single (2), 0.5), single ([p, NaN])) 518s ***** assert (binocdf ([x, NaN], 2, single (0.5)), single ([p, NaN])) 518s ***** error binocdf () 518s ***** error binocdf (1) 518s ***** error binocdf (1, 2) 518s ***** error binocdf (1, 2, 3, 4, 5) 518s ***** error binocdf (1, 2, 3, "tail") 518s ***** error binocdf (1, 2, 3, 4) 518s ***** error ... 518s binocdf (ones (3), ones (2), ones (2)) 518s ***** error ... 518s binocdf (ones (2), ones (3), ones (2)) 518s ***** error ... 518s binocdf (ones (2), ones (2), ones (3)) 518s ***** error binocdf (i, 2, 2) 518s ***** error binocdf (2, i, 2) 518s ***** error binocdf (2, 2, i) 518s 29 tests, 29 passed, 0 known failure, 0 skipped 518s [inst/dist_fun/ncx2inv.m] 518s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/ncx2inv.m 518s ***** demo 518s ## Plot various iCDFs from the noncentral chi-squared distribution 518s p = 0.001:0.001:0.999; 518s x1 = ncx2inv (p, 2, 1); 518s x2 = ncx2inv (p, 2, 2); 518s x3 = ncx2inv (p, 2, 3); 518s x4 = ncx2inv (p, 4, 1); 518s x5 = ncx2inv (p, 4, 2); 518s x6 = ncx2inv (p, 4, 3); 518s plot (p, x1, "-r", p, x2, "-g", p, x3, "-k", ... 518s p, x4, "-m", p, x5, "-c", p, x6, "-y") 518s grid on 518s ylim ([0, 10]) 518s legend ({"df = 2, λ = 1", "df = 2, λ = 2", ... 518s "df = 2, λ = 3", "df = 4, λ = 1", ... 518s "df = 4, λ = 2", "df = 4, λ = 3"}, "location", "northwest") 518s title ("Noncentral chi-squared iCDF") 518s xlabel ("probability") 518s ylabel ("values in x") 518s ***** demo 518s ## Compare the noncentral chi-squared CDF with LAMBDA = 2 to the 518s ## chi-squared CDF with the same number of degrees of freedom (4). 518s 518s p = 0.001:0.001:0.999; 518s x1 = ncx2inv (p, 4, 2); 518s x2 = chi2inv (p, 4); 518s plot (p, x1, "-", p, x2, "-"); 518s grid on 518s ylim ([0, 10]) 518s legend ({"Noncentral χ^2(4,2)", "χ^2(4)"}, "location", "northwest") 518s title ("Noncentral chi-squared vs chi-squared quantile functions") 518s xlabel ("probability") 518s ylabel ("values in x") 518s ***** test 518s x = [0,0.3443,0.7226,1.1440,1.6220,2.1770,2.8436,3.6854,4.8447,6.7701,Inf]; 518s assert (ncx2inv ([0:0.1:1], 2, 1), x, 1e-4); 518s ***** test 518s x = [0,0.8295,1.6001,2.3708,3.1785,4.0598,5.0644,6.2765,7.8763,10.4199,Inf]; 518s assert (ncx2inv ([0:0.1:1], 2, 3), x, 1e-4); 518s ***** test 518s x = [0,0.5417,1.3483,2.1796,3.0516,4.0003,5.0777,6.3726,8.0748,10.7686,Inf]; 518s assert (ncx2inv ([0:0.1:1], 1, 4), x, 1e-4); 519s ***** test 519s x = [0.1808, 0.6456, 1.1842, 1.7650, 2.3760, 3.0105]; 519s assert (ncx2inv (0.05, [1, 2, 3, 4, 5, 6], 4), x, 1e-4); 519s ***** test 519s x = [0.4887, 0.6699, 0.9012, 1.1842, 1.5164, 1.8927]; 519s assert (ncx2inv (0.05, 3, [1, 2, 3, 4, 5, 6]), x, 1e-4); 520s ***** test 520s x = [1.3941, 1.6824, 2.0103, 2.3760, NaN, 3.2087]; 520s assert (ncx2inv (0.05, 5, [1, 2, 3, 4, -1, 6]), x, 1e-4); 520s ***** test 520s assert (ncx2inv (0.996, 5, 8), 35.51298862765576, 3e-13); 521s ***** error ncx2inv () 521s ***** error ncx2inv (1) 521s ***** error ncx2inv (1, 2) 521s ***** error ... 521s ncx2inv (ones (3), ones (2), ones (2)) 521s ***** error ... 521s ncx2inv (ones (2), ones (3), ones (2)) 521s ***** error ... 521s ncx2inv (ones (2), ones (2), ones (3)) 521s ***** error ncx2inv (i, 2, 2) 521s ***** error ncx2inv (2, i, 2) 521s ***** error ncx2inv (2, 2, i) 521s 16 tests, 16 passed, 0 known failure, 0 skipped 521s [inst/dist_fun/trnd.m] 521s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/trnd.m 521s ***** assert (size (trnd (2)), [1, 1]) 521s ***** assert (size (trnd (ones (2,1))), [2, 1]) 521s ***** assert (size (trnd (ones (2,2))), [2, 2]) 521s ***** assert (size (trnd (1, 3)), [3, 3]) 521s ***** assert (size (trnd (1, [4 1])), [4, 1]) 521s ***** assert (size (trnd (1, 4, 1)), [4, 1]) 521s ***** assert (size (trnd (1, 4, 1)), [4, 1]) 521s ***** assert (size (trnd (1, 4, 1, 5)), [4, 1, 5]) 521s ***** assert (size (trnd (1, 0, 1)), [0, 1]) 521s ***** assert (size (trnd (1, 1, 0)), [1, 0]) 521s ***** assert (size (trnd (1, 1, 2, 0, 5)), [1, 2, 0, 5]) 521s ***** assert (trnd (0, 1, 1), NaN) 521s ***** assert (trnd ([0, 0, 0], [1, 3]), [NaN, NaN, NaN]) 521s ***** assert (class (trnd (2)), "double") 521s ***** assert (class (trnd (single (2))), "single") 521s ***** assert (class (trnd (single ([2 2]))), "single") 521s ***** error trnd () 521s ***** error trnd (i) 521s ***** error ... 521s trnd (1, -1) 521s ***** error ... 521s trnd (1, 1.2) 521s ***** error ... 521s trnd (1, ones (2)) 521s ***** error ... 521s trnd (1, [2 -1 2]) 521s ***** error ... 521s trnd (1, [2 0 2.5]) 521s ***** error ... 521s trnd (ones (2), ones (2)) 521s ***** error ... 521s trnd (1, 2, -1, 5) 521s ***** error ... 521s trnd (1, 2, 1.5, 5) 521s ***** error trnd (ones (2,2), 3) 521s ***** error trnd (ones (2,2), [3, 2]) 521s ***** error trnd (ones (2,2), 2, 3) 521s 29 tests, 29 passed, 0 known failure, 0 skipped 521s [inst/dist_fun/nbininv.m] 521s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/nbininv.m 521s ***** demo 521s ## Plot various iCDFs from the negative binomial distribution 521s p = 0.001:0.001:0.999; 521s x1 = nbininv (p, 2, 0.15); 521s x2 = nbininv (p, 5, 0.2); 521s x3 = nbininv (p, 4, 0.4); 521s x4 = nbininv (p, 10, 0.3); 521s plot (p, x1, "-r", p, x2, "-g", p, x3, "-k", p, x4, "-m") 521s grid on 521s ylim ([0, 40]) 521s legend ({"r = 2, ps = 0.15", "r = 5, ps = 0.2", "r = 4, p = 0.4", ... 521s "r = 10, ps = 0.3"}, "location", "northwest") 521s title ("Negative binomial iCDF") 521s xlabel ("probability") 521s ylabel ("values in x (number of failures)") 521s ***** shared p 521s p = [-1 0 3/4 1 2]; 521s ***** assert (nbininv (p, ones (1,5), 0.5*ones (1,5)), [NaN 0 1 Inf NaN]) 521s ***** assert (nbininv (p, 1, 0.5*ones (1,5)), [NaN 0 1 Inf NaN]) 521s ***** assert (nbininv (p, ones (1,5), 0.5), [NaN 0 1 Inf NaN]) 521s ***** assert (nbininv (p, [1 0 NaN Inf 1], 0.5), [NaN NaN NaN NaN NaN]) 521s ***** assert (nbininv (p, [1 0 1.5 Inf 1], 0.5), [NaN NaN 2 NaN NaN]) 521s ***** assert (nbininv (p, 1, 0.5*[1 -Inf NaN Inf 1]), [NaN NaN NaN NaN NaN]) 521s ***** assert (nbininv ([p(1:2) NaN p(4:5)], 1, 0.5), [NaN 0 NaN Inf NaN]) 521s ***** assert (nbininv ([p, NaN], 1, 0.5), [NaN 0 1 Inf NaN NaN]) 521s ***** assert (nbininv (single ([p, NaN]), 1, 0.5), single ([NaN 0 1 Inf NaN NaN])) 521s ***** assert (nbininv ([p, NaN], single (1), 0.5), single ([NaN 0 1 Inf NaN NaN])) 521s ***** assert (nbininv ([p, NaN], 1, single (0.5)), single ([NaN 0 1 Inf NaN NaN])) 521s ***** shared y, tol 521s y = magic (3) + 1; 521s tol = 1; 521s ***** assert (nbininv (nbincdf (1:10, 3, 0.1), 3, 0.1), 1:10, tol) 521s ***** assert (nbininv (nbincdf (1:10, 3./(1:10), 0.1), 3./(1:10), 0.1), 1:10, tol) 521s ***** assert (nbininv (nbincdf (y, 3./y, 1./y), 3./y, 1./y), y, tol) 521s ***** error nbininv () 521s ***** error nbininv (1) 521s ***** error nbininv (1, 2) 521s ***** error ... 521s nbininv (ones (3), ones (2), ones (2)) 521s ***** error ... 521s nbininv (ones (2), ones (3), ones (2)) 521s ***** error ... 521s nbininv (ones (2), ones (2), ones (3)) 521s ***** error nbininv (i, 2, 2) 521s ***** error nbininv (2, i, 2) 521s ***** error nbininv (2, 2, i) 521s 23 tests, 23 passed, 0 known failure, 0 skipped 521s [inst/dist_fun/ricecdf.m] 521s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/ricecdf.m 521s ***** demo 521s ## Plot various CDFs from the Rician distribution 521s x = 0:0.01:10; 521s p1 = ricecdf (x, 0, 1); 521s p2 = ricecdf (x, 0.5, 1); 521s p3 = ricecdf (x, 1, 1); 521s p4 = ricecdf (x, 2, 1); 521s p5 = ricecdf (x, 4, 1); 521s plot (x, p1, "-b", x, p2, "g", x, p3, "-r", x, p4, "-m", x, p5, "-k") 521s grid on 521s ylim ([0, 1]) 521s xlim ([0, 8]) 521s legend ({"s = 0, σ = 1", "s = 0.5, σ = 1", "s = 1, σ = 1", ... 521s "s = 2, σ = 1", "s = 4, σ = 1"}, "location", "southeast") 521s title ("Rician CDF") 521s xlabel ("values in x") 521s ylabel ("probability") 521s ***** demo 521s ## Plot various CDFs from the Rician distribution 521s x = 0:0.01:10; 521s p1 = ricecdf (x, 0, 0.5); 521s p2 = ricecdf (x, 0, 2); 521s p3 = ricecdf (x, 0, 3); 521s p4 = ricecdf (x, 2, 2); 521s p5 = ricecdf (x, 4, 2); 521s plot (x, p1, "-b", x, p2, "g", x, p3, "-r", x, p4, "-m", x, p5, "-k") 521s grid on 521s ylim ([0, 1]) 521s xlim ([0, 8]) 521s legend ({"ν = 0, σ = 0.5", "ν = 0, σ = 2", "ν = 0, σ = 3", ... 521s "ν = 2, σ = 2", "ν = 4, σ = 2"}, "location", "southeast") 521s title ("Rician CDF") 521s xlabel ("values in x") 521s ylabel ("probability") 521s ***** test 521s x = 0:0.5:2.5; 521s s = 1:6; 521s p = ricecdf (x, s, 1); 521s expected_p = [0.0000, 0.0179, 0.0108, 0.0034, 0.0008, 0.0001]; 521s assert (p, expected_p, 0.001); 521s ***** test 521s x = 0:0.5:2.5; 521s sigma = 1:6; 521s p = ricecdf (x, 1, sigma); 521s expected_p = [0.0000, 0.0272, 0.0512, 0.0659, 0.0754, 0.0820]; 521s assert (p, expected_p, 0.001); 521s ***** test 521s x = 0:0.5:2.5; 521s p = ricecdf (x, 0, 1); 521s expected_p = [0.0000, 0.1175, 0.3935, 0.6753, 0.8647, 0.9561]; 521s assert (p, expected_p, 0.001); 521s ***** test 521s x = 0:0.5:2.5; 521s p = ricecdf (x, 1, 1); 521s expected_p = [0.0000, 0.0735, 0.2671, 0.5120, 0.7310, 0.8791]; 521s assert (p, expected_p, 0.001); 521s ***** shared x, p 521s x = [-1, 0, 1, 2, Inf]; 521s p = [0, 0, 0.26712019620318, 0.73098793996409, 1]; 521s ***** assert (ricecdf (x, 1, 1), p, 1e-14) 521s ***** assert (ricecdf (x, 1, 1, "upper"), 1 - p, 1e-14) 521s ***** error ricecdf () 521s ***** error ricecdf (1) 521s ***** error ricecdf (1, 2) 521s ***** error ricecdf (1, 2, 3, "uper") 521s ***** error ricecdf (1, 2, 3, 4) 521s ***** error ... 521s ricecdf (ones (3), ones (2), ones (2)) 521s ***** error ... 521s ricecdf (ones (2), ones (3), ones (2)) 521s ***** error ... 521s ricecdf (ones (2), ones (2), ones (3)) 521s ***** error ricecdf (i, 2, 3) 521s ***** error ricecdf (2, i, 3) 521s ***** error ricecdf (2, 2, i) 521s 17 tests, 17 passed, 0 known failure, 0 skipped 521s [inst/dist_fun/invgcdf.m] 521s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/invgcdf.m 521s ***** demo 521s ## Plot various CDFs from the inverse Gaussian distribution 521s x = 0:0.001:3; 521s p1 = invgcdf (x, 1, 0.2); 521s p2 = invgcdf (x, 1, 1); 521s p3 = invgcdf (x, 1, 3); 521s p4 = invgcdf (x, 3, 0.2); 521s p5 = invgcdf (x, 3, 1); 521s plot (x, p1, "-b", x, p2, "-g", x, p3, "-r", x, p4, "-c", x, p5, "-y") 521s grid on 521s xlim ([0, 3]) 521s legend ({"μ = 1, σ = 0.2", "μ = 1, σ = 1", "μ = 1, σ = 3", ... 521s "μ = 3, σ = 0.2", "μ = 3, σ = 1"}, "location", "southeast") 521s title ("Inverse Gaussian CDF") 521s xlabel ("values in x") 521s ylabel ("probability") 521s ***** shared x, p1, p1u, y2, y2u, y3, y3u 521s x = [-Inf, -1, 0, 1/2, 1, Inf]; 521s p1 = [0, 0, 0, 0.3650, 0.6681, 1]; 521s p1u = [1, 1, 1, 0.6350, 0.3319, 0]; 521s ***** assert (invgcdf (x, ones (1,6), ones (1,6)), p1, 1e-4) 521s ***** assert (invgcdf (x, 1, 1), p1, 1e-4) 521s ***** assert (invgcdf (x, 1, ones (1,6)), p1, 1e-4) 521s ***** assert (invgcdf (x, ones (1,6), 1), p1, 1e-4) 521s ***** assert (invgcdf (x, 1, [1, 1, 1, NaN, 1, 1]), [p1(1:3), NaN, p1(5:6)], 1e-4) 521s ***** assert (invgcdf (x, [1, 1, 1, NaN, 1, 1], 1), [p1(1:3), NaN, p1(5:6)], 1e-4) 521s ***** assert (invgcdf ([x(1:3), NaN, x(5:6)], 1, 1), [p1(1:3), NaN, p1(5:6)], 1e-4) 521s ***** assert (invgcdf (x, ones (1,6), ones (1,6), "upper"), p1u, 1e-4) 521s ***** assert (invgcdf (x, 1, 1, "upper"), p1u, 1e-4) 521s ***** assert (invgcdf (x, 1, ones (1,6), "upper"), p1u, 1e-4) 521s ***** assert (invgcdf (x, ones (1,6), 1, "upper"), p1u, 1e-4) 521s ***** assert (class (invgcdf (single ([x, NaN]), 1, 1)), "single") 521s ***** assert (class (invgcdf ([x, NaN], 1, single (1))), "single") 521s ***** assert (class (invgcdf ([x, NaN], single (1), 1)), "single") 521s ***** error invgcdf () 521s ***** error invgcdf (1) 521s ***** error invgcdf (1, 2) 521s ***** error invgcdf (1, 2, 3, "tail") 521s ***** error invgcdf (1, 2, 3, 5) 521s ***** error ... 521s invgcdf (ones (3), ones (2), ones(2)) 521s ***** error ... 521s invgcdf (ones (2), ones (3), ones(2)) 521s ***** error ... 521s invgcdf (ones (2), ones (2), ones(3)) 521s ***** error invgcdf (i, 2, 3) 521s ***** error invgcdf (1, i, 3) 521s ***** error invgcdf (1, 2, i) 521s 25 tests, 25 passed, 0 known failure, 0 skipped 521s [inst/dist_fun/gamrnd.m] 521s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/gamrnd.m 521s ***** assert (size (gamrnd (1, 1)), [1 1]) 521s ***** assert (size (gamrnd (1, ones (2,1))), [2, 1]) 521s ***** assert (size (gamrnd (1, ones (2,2))), [2, 2]) 521s ***** assert (size (gamrnd (ones (2,1), 1)), [2, 1]) 521s ***** assert (size (gamrnd (ones (2,2), 1)), [2, 2]) 521s ***** assert (size (gamrnd (1, 1, 3)), [3, 3]) 521s ***** assert (size (gamrnd (1, 1, [4, 1])), [4, 1]) 521s ***** assert (size (gamrnd (1, 1, 4, 1)), [4, 1]) 521s ***** assert (size (gamrnd (1, 1, 4, 1, 5)), [4, 1, 5]) 521s ***** assert (size (gamrnd (1, 1, 0, 1)), [0, 1]) 521s ***** assert (size (gamrnd (1, 1, 1, 0)), [1, 0]) 521s ***** assert (size (gamrnd (1, 1, 1, 2, 0, 5)), [1, 2, 0, 5]) 521s ***** assert (class (gamrnd (1, 1)), "double") 521s ***** assert (class (gamrnd (1, single (1))), "single") 521s ***** assert (class (gamrnd (1, single ([1, 1]))), "single") 521s ***** assert (class (gamrnd (single (1), 1)), "single") 521s ***** assert (class (gamrnd (single ([1, 1]), 1)), "single") 521s ***** error gamrnd () 521s ***** error gamrnd (1) 521s ***** error ... 521s gamrnd (ones (3), ones (2)) 521s ***** error ... 521s gamrnd (ones (2), ones (3)) 521s ***** error gamrnd (i, 2, 3) 521s ***** error gamrnd (1, i, 3) 521s ***** error ... 521s gamrnd (1, 2, -1) 521s ***** error ... 521s gamrnd (1, 2, 1.2) 521s ***** error ... 521s gamrnd (1, 2, ones (2)) 521s ***** error ... 521s gamrnd (1, 2, [2 -1 2]) 521s ***** error ... 521s gamrnd (1, 2, [2 0 2.5]) 521s ***** error ... 521s gamrnd (1, 2, 2, -1, 5) 521s ***** error ... 521s gamrnd (1, 2, 2, 1.5, 5) 521s ***** error ... 521s gamrnd (2, ones (2), 3) 521s ***** error ... 521s gamrnd (2, ones (2), [3, 2]) 521s ***** error ... 521s gamrnd (2, ones (2), 3, 2) 521s 33 tests, 33 passed, 0 known failure, 0 skipped 521s [inst/dist_fun/chi2pdf.m] 521s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/chi2pdf.m 521s ***** demo 521s ## Plot various PDFs from the chi-squared distribution 521s x = 0:0.01:8; 521s y1 = chi2pdf (x, 1); 521s y2 = chi2pdf (x, 2); 521s y3 = chi2pdf (x, 3); 521s y4 = chi2pdf (x, 4); 521s y5 = chi2pdf (x, 6); 521s y6 = chi2pdf (x, 9); 521s plot (x, y1, "-b", x, y2, "-g", x, y3, "-r", ... 521s x, y4, "-c", x, y5, "-m", x, y6, "-y") 521s grid on 521s xlim ([0, 8]) 521s ylim ([0, 0.5]) 521s legend ({"df = 1", "df = 2", "df = 3", ... 521s "df = 4", "df = 6", "df = 9"}, "location", "northeast") 521s title ("Chi-squared PDF") 521s xlabel ("values in x") 521s ylabel ("density") 521s ***** shared x, y 521s x = [-1 0 0.5 1 Inf]; 521s y = [0, 1/2 * exp(-x(2:5)/2)]; 521s ***** assert (chi2pdf (x, 2*ones (1,5)), y) 521s ***** assert (chi2pdf (x, 2), y) 521s ***** assert (chi2pdf (x, 2*[1 0 NaN 1 1]), [y(1) NaN NaN y(4:5)]) 521s ***** assert (chi2pdf ([x, NaN], 2), [y, NaN]) 521s ***** assert (chi2pdf (single ([x, NaN]), 2), single ([y, NaN])) 521s ***** assert (chi2pdf ([x, NaN], single (2)), single ([y, NaN])) 521s ***** error chi2pdf () 521s ***** error chi2pdf (1) 521s ***** error chi2pdf (1,2,3) 521s ***** error ... 521s chi2pdf (ones (3), ones (2)) 521s ***** error ... 521s chi2pdf (ones (2), ones (3)) 521s ***** error chi2pdf (i, 2) 521s ***** error chi2pdf (2, i) 521s 13 tests, 13 passed, 0 known failure, 0 skipped 521s [inst/dist_fun/unidpdf.m] 521s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/unidpdf.m 521s ***** demo 521s ## Plot various PDFs from the discrete uniform distribution 521s x = 0:10; 521s y1 = unidpdf (x, 5); 521s y2 = unidpdf (x, 9); 521s plot (x, y1, "*b", x, y2, "*g") 521s grid on 521s xlim ([0, 10]) 521s ylim ([0, 0.25]) 521s legend ({"N = 5", "N = 9"}, "location", "northeast") 521s title ("Descrete uniform PDF") 521s xlabel ("values in x") 521s ylabel ("density") 521s ***** shared x, y 521s x = [-1 0 1 2 10 11]; 521s y = [0 0 0.1 0.1 0.1 0]; 521s ***** assert (unidpdf (x, 10*ones (1,6)), y) 521s ***** assert (unidpdf (x, 10), y) 522s ***** assert (unidpdf (x, 10*[0 NaN 1 1 1 1]), [NaN NaN y(3:6)]) 522s ***** assert (unidpdf ([x, NaN], 10), [y, NaN]) 522s ***** assert (unidpdf (single ([x, NaN]), 10), single ([y, NaN])) 522s ***** assert (unidpdf ([x, NaN], single (10)), single ([y, NaN])) 522s ***** error unidpdf () 522s ***** error unidpdf (1) 522s ***** error ... 522s unidpdf (ones (3), ones (2)) 522s ***** error ... 522s unidpdf (ones (2), ones (3)) 522s ***** error unidpdf (i, 2) 522s ***** error unidpdf (2, i) 522s 12 tests, 12 passed, 0 known failure, 0 skipped 522s [inst/dist_fun/tlsinv.m] 522s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/tlsinv.m 522s ***** demo 522s ## Plot various iCDFs from the location-scale Student's T distribution 522s p = 0.001:0.001:0.999; 522s x1 = tlsinv (p, 0, 1, 1); 522s x2 = tlsinv (p, 0, 2, 2); 522s x3 = tlsinv (p, 3, 2, 5); 522s x4 = tlsinv (p, -1, 3, Inf); 522s plot (p, x1, "-b", p, x2, "-g", p, x3, "-r", p, x4, "-m") 522s grid on 522s xlim ([0, 1]) 522s ylim ([-8, 8]) 522s legend ({"mu = 0, sigma = 1, nu = 1", "mu = 0, sigma = 2, nu = 2", ... 522s "mu = 3, sigma = 2, nu = 5", 'mu = -1, sigma = 3, nu = \infty'}, ... 522s "location", "southeast") 522s title ("Location-scale Student's T iCDF") 522s xlabel ("probability") 522s ylabel ("values in x") 522s ***** shared p 522s p = [-1 0 0.5 1 2]; 522s ***** assert (tlsinv (p, 0, 1, ones (1,5)), [NaN -Inf 0 Inf NaN]) 522s ***** assert (tlsinv (p, 0, 1, 1), [NaN -Inf 0 Inf NaN], eps) 522s ***** assert (tlsinv (p, 0, 1, [1 0 NaN 1 1]), [NaN NaN NaN Inf NaN], eps) 522s ***** assert (tlsinv ([p(1:2) NaN p(4:5)], 0, 1, 1), [NaN -Inf NaN Inf NaN]) 522s ***** assert (class (tlsinv ([p, NaN], 0, 1, 1)), "double") 522s ***** assert (class (tlsinv (single ([p, NaN]), 0, 1, 1)), "single") 522s ***** assert (class (tlsinv ([p, NaN], single (0), 1, 1)), "single") 522s ***** assert (class (tlsinv ([p, NaN], 0, single (1), 1)), "single") 522s ***** assert (class (tlsinv ([p, NaN], 0, 1, single (1))), "single") 522s ***** error tlsinv () 522s ***** error tlsinv (1) 522s ***** error tlsinv (1, 2) 522s ***** error tlsinv (1, 2, 3) 522s ***** error ... 522s tlsinv (ones (3), ones (2), 1, 1) 522s ***** error ... 522s tlsinv (ones (2), 1, ones (3), 1) 522s ***** error ... 522s tlsinv (ones (2), 1, 1, ones (3)) 522s ***** error tlsinv (i, 2, 3, 4) 522s ***** error tlsinv (2, i, 3, 4) 522s ***** error tlsinv (2, 2, i, 4) 522s ***** error tlsinv (2, 2, 3, i) 522s 20 tests, 20 passed, 0 known failure, 0 skipped 522s [inst/dist_fun/wblinv.m] 522s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/wblinv.m 522s ***** demo 522s ## Plot various iCDFs from the Weibull distribution 522s p = 0.001:0.001:0.999; 522s x1 = wblinv (p, 1, 0.5); 522s x2 = wblinv (p, 1, 1); 522s x3 = wblinv (p, 1, 1.5); 522s x4 = wblinv (p, 1, 5); 522s plot (p, x1, "-b", p, x2, "-r", p, x3, "-m", p, x4, "-g") 522s ylim ([0, 2.5]) 522s grid on 522s legend ({"λ = 1, k = 0.5", "λ = 1, k = 1", ... 522s "λ = 1, k = 1.5", "λ = 1, k = 5"}, "location", "northwest") 522s title ("Weibull iCDF") 522s xlabel ("probability") 522s ylabel ("x") 522s ***** shared p 522s p = [-1 0 0.63212055882855778 1 2]; 522s ***** assert (wblinv (p, ones (1,5), ones (1,5)), [NaN 0 1 Inf NaN], eps) 522s ***** assert (wblinv (p, 1, ones (1,5)), [NaN 0 1 Inf NaN], eps) 522s ***** assert (wblinv (p, ones (1,5), 1), [NaN 0 1 Inf NaN], eps) 522s ***** assert (wblinv (p, [1 -1 NaN Inf 1], 1), [NaN NaN NaN NaN NaN]) 522s ***** assert (wblinv (p, 1, [1 -1 NaN Inf 1]), [NaN NaN NaN NaN NaN]) 522s ***** assert (wblinv ([p(1:2) NaN p(4:5)], 1, 1), [NaN 0 NaN Inf NaN]) 522s ***** assert (wblinv ([p, NaN], 1, 1), [NaN 0 1 Inf NaN NaN], eps) 522s ***** assert (wblinv (single ([p, NaN]), 1, 1), single ([NaN 0 1 Inf NaN NaN]), eps ("single")) 522s ***** assert (wblinv ([p, NaN], single (1), 1), single ([NaN 0 1 Inf NaN NaN]), eps ("single")) 522s ***** assert (wblinv ([p, NaN], 1, single (1)), single ([NaN 0 1 Inf NaN NaN]), eps ("single")) 522s ***** error wblinv () 522s ***** error wblinv (1,2,3,4) 522s ***** error ... 522s wblinv (ones (3), ones (2), ones (2)) 522s ***** error ... 522s wblinv (ones (2), ones (3), ones (2)) 522s ***** error ... 522s wblinv (ones (2), ones (2), ones (3)) 522s ***** error wblinv (i, 2, 2) 522s ***** error wblinv (2, i, 2) 522s ***** error wblinv (2, 2, i) 522s 18 tests, 18 passed, 0 known failure, 0 skipped 522s [inst/dist_fun/tinv.m] 522s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/tinv.m 522s ***** demo 522s ## Plot various iCDFs from the Student's T distribution 522s p = 0.001:0.001:0.999; 522s x1 = tinv (p, 1); 522s x2 = tinv (p, 2); 522s x3 = tinv (p, 5); 522s x4 = tinv (p, Inf); 522s plot (p, x1, "-b", p, x2, "-g", p, x3, "-r", p, x4, "-m") 522s grid on 522s xlim ([0, 1]) 522s ylim ([-5, 5]) 522s legend ({"df = 1", "df = 2", ... 522s "df = 5", 'df = \infty'}, "location", "northwest") 522s title ("Student's T iCDF") 522s xlabel ("probability") 522s ylabel ("values in x") 522s ***** shared p 522s p = [-1 0 0.5 1 2]; 522s ***** assert (tinv (p, ones (1,5)), [NaN -Inf 0 Inf NaN]) 522s ***** assert (tinv (p, 1), [NaN -Inf 0 Inf NaN], eps) 522s ***** assert (tinv (p, [1 0 NaN 1 1]), [NaN NaN NaN Inf NaN], eps) 522s ***** assert (tinv ([p(1:2) NaN p(4:5)], 1), [NaN -Inf NaN Inf NaN]) 522s ***** assert (tinv ([p, NaN], 1), [NaN -Inf 0 Inf NaN NaN], eps) 522s ***** assert (tinv (single ([p, NaN]), 1), single ([NaN -Inf 0 Inf NaN NaN]), eps ("single")) 522s ***** assert (tinv ([p, NaN], single (1)), single ([NaN -Inf 0 Inf NaN NaN]), eps ("single")) 522s ***** error tinv () 522s ***** error tinv (1) 522s ***** error ... 522s tinv (ones (3), ones (2)) 522s ***** error ... 522s tinv (ones (2), ones (3)) 522s ***** error tinv (i, 2) 522s ***** error tinv (2, i) 522s 13 tests, 13 passed, 0 known failure, 0 skipped 522s [inst/dist_fun/binornd.m] 522s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/binornd.m 522s ***** assert (size (binornd (2, 1/2)), [1 1]) 522s ***** assert (size (binornd (2 * ones (2, 1), 1/2)), [2, 1]) 522s ***** assert (size (binornd (2 * ones (2, 2), 1/2)), [2, 2]) 522s ***** assert (size (binornd (2, 1/2 * ones (2, 1))), [2, 1]) 522s ***** assert (size (binornd (1, 1/2 * ones (2, 2))), [2, 2]) 522s ***** assert (size (binornd (ones (2, 1), 1)), [2, 1]) 522s ***** assert (size (binornd (ones (2, 2), 1)), [2, 2]) 522s ***** assert (size (binornd (2, 1/2, 3)), [3, 3]) 522s ***** assert (size (binornd (1, 1, [4, 1])), [4, 1]) 522s ***** assert (size (binornd (1, 1, 4, 1)), [4, 1]) 522s ***** assert (size (binornd (1, 1, 4, 1, 5)), [4, 1, 5]) 522s ***** assert (size (binornd (1, 1, 0, 1)), [0, 1]) 522s ***** assert (size (binornd (1, 1, 1, 0)), [1, 0]) 522s ***** assert (size (binornd (1, 1, 1, 2, 0, 5)), [1, 2, 0, 5]) 522s ***** assert (class (binornd (1, 1)), "double") 522s ***** assert (class (binornd (1, single (0))), "single") 522s ***** assert (class (binornd (1, single ([0, 0]))), "single") 522s ***** assert (class (binornd (1, single (1), 2)), "single") 522s ***** assert (class (binornd (1, single ([1, 1]), 1, 2)), "single") 522s ***** assert (class (binornd (single (1), 1, 2)), "single") 522s ***** assert (class (binornd (single ([1, 1]), 1, 1, 2)), "single") 522s ***** error binornd () 522s ***** error binornd (1) 522s ***** error ... 522s binornd (ones (3), ones (2)) 522s ***** error ... 522s binornd (ones (2), ones (3)) 522s ***** error binornd (i, 2) 522s ***** error binornd (1, i) 522s ***** error ... 522s binornd (1, 1/2, -1) 522s ***** error ... 522s binornd (1, 1/2, 1.2) 522s ***** error ... 522s binornd (1, 1/2, ones (2)) 522s ***** error ... 522s binornd (1, 1/2, [2 -1 2]) 522s ***** error ... 522s binornd (1, 1/2, [2 0 2.5]) 522s ***** error ... 522s binornd (1, 1/2, 2, -1, 5) 522s ***** error ... 522s binornd (1, 1/2, 2, 1.5, 5) 522s ***** error ... 522s binornd (2, 1/2 * ones (2), 3) 522s ***** error ... 522s binornd (2, 1/2 * ones (2), [3, 2]) 522s ***** error ... 522s binornd (2, 1/2 * ones (2), 3, 2) 522s ***** error ... 522s binornd (2 * ones (2), 1/2, 3) 522s ***** error ... 522s binornd (2 * ones (2), 1/2, [3, 2]) 522s ***** error ... 522s binornd (2 * ones (2), 1/2, 3, 2) 522s 40 tests, 40 passed, 0 known failure, 0 skipped 522s [inst/dist_fun/chi2cdf.m] 522s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/chi2cdf.m 522s ***** demo 522s ## Plot various CDFs from the chi-squared distribution 522s x = 0:0.01:8; 522s p1 = chi2cdf (x, 1); 522s p2 = chi2cdf (x, 2); 522s p3 = chi2cdf (x, 3); 522s p4 = chi2cdf (x, 4); 522s p5 = chi2cdf (x, 6); 522s p6 = chi2cdf (x, 9); 522s plot (x, p1, "-b", x, p2, "-g", x, p3, "-r", ... 522s x, p4, "-c", x, p5, "-m", x, p6, "-y") 522s grid on 522s xlim ([0, 8]) 522s legend ({"df = 1", "df = 2", "df = 3", ... 522s "df = 4", "df = 6", "df = 9"}, "location", "southeast") 522s title ("Chi-squared CDF") 522s xlabel ("values in x") 522s ylabel ("probability") 522s ***** shared x, p, u 522s x = [-1, 0, 0.5, 1, 2]; 522s p = [0, (1 - exp (-x(2:end) / 2))]; 522s u = [1, 0, NaN, 0.3934693402873666, 0.6321205588285577]; 522s ***** assert (chi2cdf (x, 2 * ones (1,5)), p, eps) 522s ***** assert (chi2cdf (x, 2), p, eps) 522s ***** assert (chi2cdf (x, 2 * [1, 0, NaN, 1, 1]), [p(1), 1, NaN, p(4:5)], eps) 522s ***** assert (chi2cdf (x, 2 * [1, 0, NaN, 1, 1], "upper"), ... 522s [p(1), 1, NaN, u(4:5)], eps) 522s ***** assert (chi2cdf ([x(1:2), NaN, x(4:5)], 2), [p(1:2), NaN, p(4:5)], eps) 522s ***** assert (chi2cdf ([x, NaN], 2), [p, NaN], eps) 522s ***** assert (chi2cdf (single ([x, NaN]), 2), single ([p, NaN]), eps ("single")) 522s ***** assert (chi2cdf ([x, NaN], single (2)), single ([p, NaN]), eps ("single")) 522s ***** error chi2cdf () 522s ***** error chi2cdf (1) 522s ***** error chi2cdf (1, 2, 3, 4) 522s ***** error chi2cdf (1, 2, 3) 522s ***** error chi2cdf (1, 2, "uper") 522s ***** error ... 522s chi2cdf (ones (3), ones (2)) 522s ***** error ... 522s chi2cdf (ones (2), ones (3)) 522s ***** error chi2cdf (i, 2) 522s ***** error chi2cdf (2, i) 522s 17 tests, 17 passed, 0 known failure, 0 skipped 522s [inst/dist_fun/ricepdf.m] 522s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/ricepdf.m 522s ***** demo 522s ## Plot various PDFs from the Rician distribution 522s x = 0:0.01:8; 522s y1 = ricepdf (x, 0, 1); 522s y2 = ricepdf (x, 0.5, 1); 522s y3 = ricepdf (x, 1, 1); 522s y4 = ricepdf (x, 2, 1); 522s y5 = ricepdf (x, 4, 1); 522s plot (x, y1, "-b", x, y2, "-g", x, y3, "-r", x, y4, "-m", x, y5, "-k") 522s grid on 522s ylim ([0, 0.65]) 522s xlim ([0, 8]) 522s legend ({"s = 0, σ = 1", "s = 0.5, σ = 1", "s = 1, σ = 1", ... 522s "s = 2, σ = 1", "s = 4, σ = 1"}, "location", "northeast") 522s title ("Rician PDF") 522s xlabel ("values in x") 522s ylabel ("density") 522s ***** shared x, y 522s x = [-1 0 0.5 1 2]; 522s y = [0 0 0.1073 0.1978 0.2846]; 522s ***** assert (ricepdf (x, ones (1, 5), 2 * ones (1, 5)), y, 1e-4) 522s ***** assert (ricepdf (x, 1, 2 * ones (1, 5)), y, 1e-4) 522s ***** assert (ricepdf (x, ones (1, 5), 2), y, 1e-4) 522s ***** assert (ricepdf (x, [0 NaN 1 1 1], 2), [0 NaN y(3:5)], 1e-4) 522s ***** assert (ricepdf (x, 1, 2 * [0 NaN 1 1 1]), [0 NaN y(3:5)], 1e-4) 522s ***** assert (ricepdf ([x, NaN], 1, 2), [y, NaN], 1e-4) 522s ***** assert (ricepdf (single ([x, NaN]), 1, 2), single ([y, NaN]), 1e-4) 522s ***** assert (ricepdf ([x, NaN], single (1), 2), single ([y, NaN]), 1e-4) 522s ***** assert (ricepdf ([x, NaN], 1, single (2)), single ([y, NaN]), 1e-4) 522s ***** error ricepdf () 522s ***** error ricepdf (1) 522s ***** error ricepdf (1,2) 522s ***** error ricepdf (1,2,3,4) 522s ***** error ... 522s ricepdf (ones (3), ones (2), ones (2)) 522s ***** error ... 522s ricepdf (ones (2), ones (3), ones (2)) 522s ***** error ... 522s ricepdf (ones (2), ones (2), ones (3)) 522s ***** error ricepdf (i, 2, 2) 522s ***** error ricepdf (2, i, 2) 522s ***** error ricepdf (2, 2, i) 522s 19 tests, 19 passed, 0 known failure, 0 skipped 522s [inst/dist_fun/ncfinv.m] 522s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/ncfinv.m 522s ***** demo 522s ## Plot various iCDFs from the noncentral F distribution 522s p = 0.001:0.001:0.999; 522s x1 = ncfinv (p, 2, 5, 1); 522s x2 = ncfinv (p, 2, 5, 2); 522s x3 = ncfinv (p, 5, 10, 1); 522s x4 = ncfinv (p, 10, 20, 10); 522s plot (p, x1, "-r", p, x2, "-g", p, x3, "-k", p, x4, "-m") 522s grid on 522s ylim ([0, 5]) 522s legend ({"df1 = 2, df2 = 5, λ = 1", "df1 = 2, df2 = 5, λ = 2", ... 522s "df1 = 5, df2 = 10, λ = 1", "df1 = 10, df2 = 20, λ = 10"}, ... 522s "location", "northwest") 522s title ("Noncentral F iCDF") 522s xlabel ("probability") 522s ylabel ("values in x") 522s ***** demo 522s ## Compare the noncentral F iCDF with LAMBDA = 10 to the F iCDF with the 522s ## same number of numerator and denominator degrees of freedom (5, 20) 522s 522s p = 0.001:0.001:0.999; 522s x1 = ncfinv (p, 5, 20, 10); 522s x2 = finv (p, 5, 20); 522s plot (p, x1, "-", p, x2, "-"); 522s grid on 522s ylim ([0, 10]) 522s legend ({"Noncentral F(5,20,10)", "F(5,20)"}, "location", "northwest") 522s title ("Noncentral F vs F quantile functions") 522s xlabel ("probability") 522s ylabel ("values in x") 522s ***** test 522s x = [0,0.1775,0.3864,0.6395,0.9564,1.3712,1.9471,2.8215,4.3679,8.1865,Inf]; 522s assert (ncfinv ([0:0.1:1], 2, 3, 1), x, 1e-4); 522s ***** test 522s x = [0,0.7492,1.3539,2.0025,2.7658,3.7278,5.0324,6.9826,10.3955,18.7665,Inf]; 522s assert (ncfinv ([0:0.1:1], 2, 3, 5), x, 1e-4); 522s ***** test 522s x = [0,0.2890,0.8632,1.5653,2.4088,3.4594,4.8442,6.8286,10.0983,17.3736,Inf]; 522s assert (ncfinv ([0:0.1:1], 1, 4, 3), x, 1e-4); 522s ***** test 522s x = [0.078410, 0.212716, 0.288618, 0.335752, 0.367963, 0.391460]; 522s assert (ncfinv (0.05, [1, 2, 3, 4, 5, 6], 10, 3), x, 1e-6); 523s ***** test 523s x = [0.2574, 0.2966, 0.3188, 0.3331, 0.3432, 0.3507]; 523s assert (ncfinv (0.05, 5, [1, 2, 3, 4, 5, 6], 3), x, 1e-4); 523s ***** test 523s x = [1.6090, 1.8113, 1.9215, 1.9911, NaN, 2.0742]; 523s assert (ncfinv (0.05, 1, [1, 2, 3, 4, -1, 6], 10), x, 1e-4); 523s ***** test 523s assert (ncfinv (0.996, 3, 5, 8), 58.0912074080671, 4e-12); 523s ***** error ncfinv () 523s ***** error ncfinv (1) 523s ***** error ncfinv (1, 2) 523s ***** error ncfinv (1, 2, 3) 523s ***** error ... 523s ncfinv (ones (3), ones (2), ones (2), ones (2)) 523s ***** error ... 523s ncfinv (ones (2), ones (3), ones (2), ones (2)) 523s ***** error ... 523s ncfinv (ones (2), ones (2), ones (3), ones (2)) 523s ***** error ... 523s ncfinv (ones (2), ones (2), ones (2), ones (3)) 523s ***** error ncfinv (i, 2, 2, 2) 523s ***** error ncfinv (2, i, 2, 2) 523s ***** error ncfinv (2, 2, i, 2) 523s ***** error ncfinv (2, 2, 2, i) 523s 19 tests, 19 passed, 0 known failure, 0 skipped 523s [inst/dist_fun/logiinv.m] 523s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/logiinv.m 523s ***** demo 523s ## Plot various iCDFs from the logistic distribution 523s p = 0.001:0.001:0.999; 523s x1 = logiinv (p, 5, 2); 523s x2 = logiinv (p, 9, 3); 523s x3 = logiinv (p, 9, 4); 523s x4 = logiinv (p, 6, 2); 523s x5 = logiinv (p, 2, 1); 523s plot (p, x1, "-b", p, x2, "-g", p, x3, "-r", p, x4, "-c", p, x5, "-m") 523s grid on 523s legend ({"μ = 5, σ = 2", "μ = 9, σ = 3", "μ = 9, σ = 4", ... 523s "μ = 6, σ = 2", "μ = 2, σ = 1"}, "location", "southeast") 523s title ("Logistic iCDF") 523s xlabel ("probability") 523s ylabel ("x") 523s ***** test 523s p = [0.01:0.01:0.99]; 523s assert (logiinv (p, 0, 1), log (p ./ (1-p)), 25*eps); 523s ***** shared p 523s p = [-1 0 0.5 1 2]; 523s ***** assert (logiinv (p, 0, 1), [NaN -Inf 0 Inf NaN]) 523s ***** assert (logiinv (p, 0, [-1, 0, 1, 2, 3]), [NaN NaN 0 Inf NaN]) 523s ***** assert (logiinv ([p, NaN], 0, 1), [NaN -Inf 0 Inf NaN NaN]) 523s ***** assert (logiinv (single ([p, NaN]), 0, 1), single ([NaN -Inf 0 Inf NaN NaN])) 523s ***** assert (logiinv ([p, NaN], single (0), 1), single ([NaN -Inf 0 Inf NaN NaN])) 523s ***** assert (logiinv ([p, NaN], 0, single (1)), single ([NaN -Inf 0 Inf NaN NaN])) 523s ***** error logiinv () 523s ***** error logiinv (1) 523s ***** error ... 523s logiinv (1, 2) 523s ***** error ... 523s logiinv (1, ones (2), ones (3)) 523s ***** error ... 523s logiinv (ones (2), 1, ones (3)) 523s ***** error ... 523s logiinv (ones (2), ones (3), 1) 523s ***** error logiinv (i, 2, 3) 523s ***** error logiinv (1, i, 3) 523s ***** error logiinv (1, 2, i) 523s 16 tests, 16 passed, 0 known failure, 0 skipped 523s [inst/dist_fun/raylcdf.m] 523s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/raylcdf.m 523s ***** demo 523s ## Plot various CDFs from the Rayleigh distribution 523s x = 0:0.01:10; 523s p1 = raylcdf (x, 0.5); 523s p2 = raylcdf (x, 1); 523s p3 = raylcdf (x, 2); 523s p4 = raylcdf (x, 3); 523s p5 = raylcdf (x, 4); 523s plot (x, p1, "-b", x, p2, "g", x, p3, "-r", x, p4, "-m", x, p5, "-k") 523s grid on 523s ylim ([0, 1]) 523s legend ({"σ = 0.5", "σ = 1", "σ = 2", ... 523s "σ = 3", "σ = 4"}, "location", "southeast") 523s title ("Rayleigh CDF") 523s xlabel ("values in x") 523s ylabel ("probability") 523s ***** test 523s x = 0:0.5:2.5; 523s sigma = 1:6; 523s p = raylcdf (x, sigma); 523s expected_p = [0.0000, 0.0308, 0.0540, 0.0679, 0.0769, 0.0831]; 523s assert (p, expected_p, 0.001); 523s ***** test 523s x = 0:0.5:2.5; 523s p = raylcdf (x, 0.5); 523s expected_p = [0.0000, 0.3935, 0.8647, 0.9889, 0.9997, 1.0000]; 523s assert (p, expected_p, 0.001); 523s ***** shared x, p 523s x = [-1, 0, 1, 2, Inf]; 523s p = [0, 0, 0.39346934028737, 0.86466471676338, 1]; 523s ***** assert (raylcdf (x, 1), p, 1e-14) 523s ***** assert (raylcdf (x, 1, "upper"), 1 - p, 1e-14) 523s ***** error raylcdf () 523s ***** error raylcdf (1) 523s ***** error raylcdf (1, 2, "uper") 523s ***** error raylcdf (1, 2, 3) 523s ***** error ... 523s raylcdf (ones (3), ones (2)) 523s ***** error ... 523s raylcdf (ones (2), ones (3)) 523s ***** error raylcdf (i, 2) 523s ***** error raylcdf (2, i) 523s 12 tests, 12 passed, 0 known failure, 0 skipped 523s [inst/dist_fun/hnpdf.m] 523s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/hnpdf.m 523s ***** demo 523s ## Plot various PDFs from the half-normal distribution 523s x = 0:0.001:10; 523s y1 = hnpdf (x, 0, 1); 523s y2 = hnpdf (x, 0, 2); 523s y3 = hnpdf (x, 0, 3); 523s y4 = hnpdf (x, 0, 5); 523s plot (x, y1, "-b", x, y2, "-g", x, y3, "-r", x, y4, "-c") 523s grid on 523s xlim ([0, 10]) 523s ylim ([0, 0.9]) 523s legend ({"μ = 0, σ = 1", "μ = 0, σ = 2", ... 523s "μ = 0, σ = 3", "μ = 0, σ = 5"}, "location", "northeast") 523s title ("Half-normal PDF") 523s xlabel ("values in x") 523s ylabel ("density") 523s ***** demo 523s ## Plot half-normal against normal probability density function 523s x = -5:0.001:5; 523s y1 = hnpdf (x, 0, 1); 523s y2 = normpdf (x); 523s plot (x, y1, "-b", x, y2, "-g") 523s grid on 523s xlim ([-5, 5]) 523s ylim ([0, 0.9]) 523s legend ({"half-normal with μ = 0, σ = 1", ... 523s "standart normal (μ = 0, σ = 1)"}, "location", "northeast") 523s title ("Half-normal against standard normal PDF") 523s xlabel ("values in x") 523s ylabel ("density") 523s ***** shared x, y 523s x = [-Inf, -1, 0, 1/2, 1, Inf]; 523s y = [0, 0, 0.7979, 0.7041, 0.4839, 0]; 523s ***** assert (hnpdf ([x, NaN], 0, 1), [y, NaN], 1e-4) 523s ***** assert (hnpdf (x, 0, [-2, -1, 0, 1, 1, 1]), [nan(1,3), y([4:6])], 1e-4) 523s ***** assert (class (hncdf (single ([x, NaN]), 0, 1)), "single") 523s ***** assert (class (hncdf ([x, NaN], 0, single (1))), "single") 523s ***** assert (class (hncdf ([x, NaN], single (0), 1)), "single") 523s ***** error hnpdf () 523s ***** error hnpdf (1) 523s ***** error hnpdf (1, 2) 523s ***** error ... 523s hnpdf (1, ones (2), ones (3)) 523s ***** error ... 523s hnpdf (ones (2), 1, ones (3)) 523s ***** error ... 523s hnpdf (ones (2), ones (3), 1) 523s ***** error hnpdf (i, 2, 3) 523s ***** error hnpdf (1, i, 3) 523s ***** error hnpdf (1, 2, i) 523s 14 tests, 14 passed, 0 known failure, 0 skipped 523s [inst/dist_fun/logninv.m] 523s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/logninv.m 523s ***** demo 523s ## Plot various iCDFs from the log-normal distribution 523s p = 0.001:0.001:0.999; 523s x1 = logninv (p, 0, 1); 523s x2 = logninv (p, 0, 0.5); 523s x3 = logninv (p, 0, 0.25); 523s plot (p, x1, "-b", p, x2, "-g", p, x3, "-r") 523s grid on 523s ylim ([0, 3]) 523s legend ({"μ = 0, σ = 1", "μ = 0, σ = 0.5", "μ = 0, σ = 0.25"}, ... 523s "location", "northwest") 523s title ("Log-normal iCDF") 523s xlabel ("probability") 523s ylabel ("values in x") 523s ***** shared p 523s p = [-1 0 0.5 1 2]; 523s ***** assert (logninv (p, ones (1,5), ones (1,5)), [NaN 0 e Inf NaN]) 523s ***** assert (logninv (p, 1, ones (1,5)), [NaN 0 e Inf NaN]) 523s ***** assert (logninv (p, ones (1,5), 1), [NaN 0 e Inf NaN]) 523s ***** assert (logninv (p, [1 1 NaN 0 1], 1), [NaN 0 NaN Inf NaN]) 523s ***** assert (logninv (p, 1, [1 0 NaN Inf 1]), [NaN NaN NaN NaN NaN]) 523s ***** assert (logninv ([p(1:2) NaN p(4:5)], 1, 2), [NaN 0 NaN Inf NaN]) 523s ***** assert (logninv ([p, NaN], 1, 1), [NaN 0 e Inf NaN NaN]) 523s ***** assert (logninv (single ([p, NaN]), 1, 1), single ([NaN 0 e Inf NaN NaN])) 523s ***** assert (logninv ([p, NaN], single (1), 1), single ([NaN 0 e Inf NaN NaN])) 523s ***** assert (logninv ([p, NaN], 1, single (1)), single ([NaN 0 e Inf NaN NaN])) 523s ***** error logninv () 524s ***** error logninv (1,2,3,4) 524s ***** error logninv (ones (3), ones (2), ones (2)) 524s ***** error logninv (ones (2), ones (3), ones (2)) 524s ***** error logninv (ones (2), ones (2), ones (3)) 524s ***** error logninv (i, 2, 2) 524s ***** error logninv (2, i, 2) 524s ***** error logninv (2, 2, i) 524s 18 tests, 18 passed, 0 known failure, 0 skipped 524s [inst/dist_fun/binopdf.m] 524s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/binopdf.m 524s ***** demo 524s ## Plot various PDFs from the binomial distribution 524s x = 0:40; 524s y1 = binopdf (x, 20, 0.5); 524s y2 = binopdf (x, 20, 0.7); 524s y3 = binopdf (x, 40, 0.5); 524s plot (x, y1, "*b", x, y2, "*g", x, y3, "*r") 524s grid on 524s ylim ([0, 0.25]) 524s legend ({"n = 20, ps = 0.5", "n = 20, ps = 0.7", ... 524s "n = 40, ps = 0.5"}, "location", "northeast") 524s title ("Binomial PDF") 524s xlabel ("values in x (number of successes)") 524s ylabel ("density") 524s ***** shared x, y 524s x = [-1 0 1 2 3]; 524s y = [0 1/4 1/2 1/4 0]; 524s ***** assert (binopdf (x, 2 * ones (1, 5), 0.5 * ones (1, 5)), y, eps) 524s ***** assert (binopdf (x, 2, 0.5 * ones (1, 5)), y, eps) 524s ***** assert (binopdf (x, 2 * ones (1, 5), 0.5), y, eps) 524s ***** assert (binopdf (x, 2 * [0 -1 NaN 1.1 1], 0.5), [0 NaN NaN NaN 0]) 524s ***** assert (binopdf (x, 2, 0.5 * [0 -1 NaN 3 1]), [0 NaN NaN NaN 0]) 524s ***** assert (binopdf ([x, NaN], 2, 0.5), [y, NaN], eps) 524s ***** assert (binopdf (cat (3, x, x), 2, 0.5), cat (3, y, y), eps) 524s ***** assert (binopdf (1, 1, 1), 1) 524s ***** assert (binopdf (0, 3, 0), 1) 524s ***** assert (binopdf (2, 2, 1), 1) 524s ***** assert (binopdf (1, 2, 1), 0) 524s ***** assert (binopdf (0, 1.1, 0), NaN) 524s ***** assert (binopdf (1, 2, -1), NaN) 524s ***** assert (binopdf (1, 2, 1.5), NaN) 524s ***** assert (binopdf ([], 1, 1), []) 524s ***** assert (binopdf (1, [], 1), []) 524s ***** assert (binopdf (1, 1, []), []) 524s ***** assert (binopdf (ones (1, 0), 2, .5), ones(1, 0)) 524s ***** assert (binopdf (ones (0, 1), 2, .5), ones(0, 1)) 524s ***** assert (binopdf (ones (0, 1, 2), 2, .5), ones(0, 1, 2)) 524s ***** assert (binopdf (1, ones (0, 1, 2), .5), ones(0, 1, 2)) 524s ***** assert (binopdf (1, 2, ones (0, 1, 2)), ones(0, 1, 2)) 524s ***** assert (binopdf (ones (1, 0, 2), 2, .5), ones(1, 0, 2)) 524s ***** assert (binopdf (ones (1, 2, 0), 2, .5), ones(1, 2, 0)) 524s ***** assert (binopdf (ones (0, 1, 2), NaN, .5), ones(0, 1, 2)) 524s ***** assert (binopdf (ones (0, 1, 2), 2, NaN), ones(0, 1, 2)) 524s ***** assert (binopdf (single ([x, NaN]), 2, 0.5), single ([y, NaN])) 524s ***** assert (binopdf ([x, NaN], single (2), 0.5), single ([y, NaN])) 524s ***** assert (binopdf ([x, NaN], 2, single (0.5)), single ([y, NaN])) 524s ***** error binopdf () 524s ***** error binopdf (1) 524s ***** error binopdf (1, 2) 524s ***** error binopdf (1, 2, 3, 4) 524s ***** error ... 524s binopdf (ones (3), ones (2), ones (2)) 524s ***** error ... 524s binopdf (ones (2), ones (3), ones (2)) 524s ***** error ... 524s binopdf (ones (2), ones (2), ones (3)) 524s ***** error binopdf (i, 2, 2) 524s ***** error binopdf (2, i, 2) 524s ***** error binopdf (2, 2, i) 524s 39 tests, 39 passed, 0 known failure, 0 skipped 524s [inst/dist_fun/nctcdf.m] 524s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/nctcdf.m 524s ***** demo 524s ## Plot various CDFs from the noncentral Τ distribution 524s x = -5:0.01:5; 524s p1 = nctcdf (x, 1, 0); 524s p2 = nctcdf (x, 4, 0); 524s p3 = nctcdf (x, 1, 2); 524s p4 = nctcdf (x, 4, 2); 524s plot (x, p1, "-r", x, p2, "-g", x, p3, "-k", x, p4, "-m") 524s grid on 524s xlim ([-5, 5]) 524s legend ({"df = 1, μ = 0", "df = 4, μ = 0", ... 524s "df = 1, μ = 2", "df = 4, μ = 2"}, "location", "southeast") 524s title ("Noncentral Τ CDF") 524s xlabel ("values in x") 524s ylabel ("probability") 524s ***** demo 524s ## Compare the noncentral T CDF with MU = 1 to the T CDF 524s ## with the same number of degrees of freedom (10). 524s 524s x = -5:0.1:5; 524s p1 = nctcdf (x, 10, 1); 524s p2 = tcdf (x, 10); 524s plot (x, p1, "-", x, p2, "-") 524s grid on 524s xlim ([-5, 5]) 524s legend ({"Noncentral T(10,1)", "T(10)"}, "location", "southeast") 524s title ("Noncentral T vs T CDFs") 524s xlabel ("values in x") 524s ylabel ("probability") 524s ***** test 524s x = -2:0.1:2; 524s p = nctcdf (x, 10, 1); 524s assert (p(1), 0.003302485766631558, 1e-14); 524s assert (p(2), 0.004084668193532631, 1e-14); 524s assert (p(3), 0.005052800319478737, 1e-14); 524s assert (p(41), 0.8076115625303751, 1e-14); 524s ***** test 524s p = nctcdf (12, 10, 3); 524s assert (p, 0.9997719343243797, 1e-14); 524s ***** test 524s p = nctcdf (2, 3, 2); 524s assert (p, 0.4430757822176028, 1e-14); 524s ***** test 524s p = nctcdf (2, 3, 2, "upper"); 524s assert (p, 0.5569242177823971, 1e-14); 524s ***** test 524s p = nctcdf ([3, 6], 3, 2, "upper"); 524s assert (p, [0.3199728259444777, 0.07064855592441913], 1e-14); 524s ***** error nctcdf () 524s ***** error nctcdf (1) 524s ***** error nctcdf (1, 2) 524s ***** error nctcdf (1, 2, 3, "tail") 524s ***** error nctcdf (1, 2, 3, 4) 524s ***** error ... 524s nctcdf (ones (3), ones (2), ones (2)) 524s ***** error ... 524s nctcdf (ones (2), ones (3), ones (2)) 524s ***** error ... 524s nctcdf (ones (2), ones (2), ones (3)) 524s ***** error nctcdf (i, 2, 2) 524s ***** error nctcdf (2, i, 2) 524s ***** error nctcdf (2, 2, i) 524s 16 tests, 16 passed, 0 known failure, 0 skipped 524s [inst/dist_fun/cauchyrnd.m] 524s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/cauchyrnd.m 524s ***** assert (size (cauchyrnd (1, 1)), [1 1]) 524s ***** assert (size (cauchyrnd (1, ones (2,1))), [2, 1]) 524s ***** assert (size (cauchyrnd (1, ones (2,2))), [2, 2]) 524s ***** assert (size (cauchyrnd (ones (2,1), 1)), [2, 1]) 524s ***** assert (size (cauchyrnd (ones (2,2), 1)), [2, 2]) 524s ***** assert (size (cauchyrnd (1, 1, 3)), [3, 3]) 524s ***** assert (size (cauchyrnd (1, 1, [4, 1])), [4, 1]) 524s ***** assert (size (cauchyrnd (1, 1, 4, 1)), [4, 1]) 524s ***** assert (size (cauchyrnd (1, 1, 4, 1, 5)), [4, 1, 5]) 524s ***** assert (size (cauchyrnd (1, 1, 0, 1)), [0, 1]) 524s ***** assert (size (cauchyrnd (1, 1, 1, 0)), [1, 0]) 524s ***** assert (size (cauchyrnd (1, 1, 1, 2, 0, 5)), [1, 2, 0, 5]) 524s ***** assert (class (cauchyrnd (1, 1)), "double") 524s ***** assert (class (cauchyrnd (1, single (1))), "single") 524s ***** assert (class (cauchyrnd (1, single ([1, 1]))), "single") 524s ***** assert (class (cauchyrnd (single (1), 1)), "single") 524s ***** assert (class (cauchyrnd (single ([1, 1]), 1)), "single") 524s ***** error cauchyrnd () 524s ***** error cauchyrnd (1) 524s ***** error ... 524s cauchyrnd (ones (3), ones (2)) 524s ***** error ... 524s cauchyrnd (ones (2), ones (3)) 524s ***** error cauchyrnd (i, 2, 3) 524s ***** error cauchyrnd (1, i, 3) 524s ***** error ... 524s cauchyrnd (1, 2, -1) 524s ***** error ... 524s cauchyrnd (1, 2, 1.2) 524s ***** error ... 524s cauchyrnd (1, 2, ones (2)) 524s ***** error ... 524s cauchyrnd (1, 2, [2 -1 2]) 524s ***** error ... 524s cauchyrnd (1, 2, [2 0 2.5]) 524s ***** error ... 524s cauchyrnd (1, 2, 2, -1, 5) 524s ***** error ... 524s cauchyrnd (1, 2, 2, 1.5, 5) 524s ***** error ... 524s cauchyrnd (2, ones (2), 3) 524s ***** error ... 524s cauchyrnd (2, ones (2), [3, 2]) 524s ***** error ... 524s cauchyrnd (2, ones (2), 3, 2) 524s 33 tests, 33 passed, 0 known failure, 0 skipped 524s [inst/dist_fun/exppdf.m] 524s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/exppdf.m 524s ***** demo 524s ## Plot various PDFs from the exponential distribution 524s x = 0:0.01:5; 524s y1 = exppdf (x, 2/3); 524s y2 = exppdf (x, 1.0); 524s y3 = exppdf (x, 2.0); 524s plot (x, y1, "-b", x, y2, "-g", x, y3, "-r") 524s grid on 524s ylim ([0, 1.5]) 524s legend ({"μ = 2/3", "μ = 1", "μ = 2"}, "location", "northeast") 524s title ("Exponential PDF") 524s xlabel ("values in x") 524s ylabel ("density") 524s ***** shared x,y 524s x = [-1 0 0.5 1 Inf]; 524s y = gampdf (x, 1, 2); 524s ***** assert (exppdf (x, 2*ones (1,5)), y) 524s ***** assert (exppdf (x, 2*[1 0 NaN 1 1]), [y(1) NaN NaN y(4:5)]) 524s ***** assert (exppdf ([x, NaN], 2), [y, NaN]) 524s ***** assert (exppdf (single ([x, NaN]), 2), single ([y, NaN])) 524s ***** assert (exppdf ([x, NaN], single (2)), single ([y, NaN])) 524s ***** error exppdf () 524s ***** error exppdf (1,2,3) 524s ***** error ... 524s exppdf (ones (3), ones (2)) 524s ***** error ... 524s exppdf (ones (2), ones (3)) 524s ***** error exppdf (i, 2) 524s ***** error exppdf (2, i) 524s 11 tests, 11 passed, 0 known failure, 0 skipped 524s [inst/dist_fun/plinv.m] 524s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/plinv.m 524s ***** demo 524s ## Plot various iCDFs from the Piecewise linear distribution 524s p = 0.001:0.001:0.999; 524s x1 = [0, 1, 3, 4, 7, 10]; 524s Fx1 = [0, 0.2, 0.5, 0.6, 0.7, 1]; 524s x2 = [0, 2, 5, 6, 7, 8]; 524s Fx2 = [0, 0.1, 0.3, 0.6, 0.9, 1]; 524s data1 = plinv (p, x1, Fx1); 524s data2 = plinv (p, x2, Fx2); 524s plot (p, data1, "-b", p, data2, "-g") 524s grid on 524s legend ({"x1, Fx1", "x2, Fx2"}, "location", "northwest") 524s title ("Piecewise linear iCDF") 524s xlabel ("probability") 524s ylabel ("values in data") 524s ***** test 524s p = 0:0.2:1; 524s data = plinv (p, [0, 1], [0, 1]); 524s assert (data, p); 524s ***** test 524s p = 0:0.2:1; 524s data = plinv (p, [0, 2], [0, 1]); 524s assert (data, 2 * p); 524s ***** test 524s p = 0:0.2:1; 524s data_out = 1:6; 524s data = plinv (p, [0, 1], [0, 0.5]); 524s assert (data, [0, 0.4, 0.8, NA, NA, NA]); 524s ***** test 524s p = 0:0.2:1; 524s data_out = 1:6; 524s data = plinv (p, [0, 0.5], [0, 1]); 524s assert (data, [0:0.1:0.5]); 524s ***** error plinv () 524s ***** error plinv (1) 524s ***** error plinv (1, 2) 524s ***** error ... 524s plinv (1, [0, 1, 2], [0, 1]) 524s ***** error ... 524s plinv (1, [0], [1]) 524s ***** error ... 524s plinv (1, [0, 1, 2], [0, 1, 1.5]) 524s ***** error ... 524s plinv (1, [0, 1, 2], [0, i, 1]) 524s ***** error ... 524s plinv (i, [0, 1, 2], [0, 0.5, 1]) 524s ***** error ... 524s plinv (1, [0, i, 2], [0, 0.5, 1]) 524s ***** error ... 524s plinv (1, [0, 1, 2], [0, 0.5i, 1]) 524s 14 tests, 14 passed, 0 known failure, 0 skipped 524s [inst/dist_fun/ncx2cdf.m] 524s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/ncx2cdf.m 524s ***** demo 524s ## Plot various CDFs from the noncentral chi-squared distribution 524s x = 0:0.1:10; 524s p1 = ncx2cdf (x, 2, 1); 524s p2 = ncx2cdf (x, 2, 2); 524s p3 = ncx2cdf (x, 2, 3); 524s p4 = ncx2cdf (x, 4, 1); 524s p5 = ncx2cdf (x, 4, 2); 524s p6 = ncx2cdf (x, 4, 3); 524s plot (x, p1, "-r", x, p2, "-g", x, p3, "-k", ... 524s x, p4, "-m", x, p5, "-c", x, p6, "-y") 524s grid on 524s xlim ([0, 10]) 524s legend ({"df = 2, λ = 1", "df = 2, λ = 2", ... 524s "df = 2, λ = 3", "df = 4, λ = 1", ... 524s "df = 4, λ = 2", "df = 4, λ = 3"}, "location", "southeast") 524s title ("Noncentral chi-squared CDF") 524s xlabel ("values in x") 524s ylabel ("probability") 524s ***** demo 524s ## Compare the noncentral chi-squared CDF with LAMBDA = 2 to the 524s ## chi-squared CDF with the same number of degrees of freedom (4). 524s 524s x = 0:0.1:10; 524s p1 = ncx2cdf (x, 4, 2); 524s p2 = chi2cdf (x, 4); 524s plot (x, p1, "-", x, p2, "-") 524s grid on 524s xlim ([0, 10]) 524s legend ({"Noncentral χ^2(4,2)", "χ^2(4)"}, "location", "northwest") 524s title ("Noncentral chi-squared vs chi-squared CDFs") 524s xlabel ("values in x") 524s ylabel ("probability") 524s ***** test 524s x = -2:0.1:2; 524s p = ncx2cdf (x, 10, 1); 524s assert (p([1:21]), zeros (1, 21), 3e-84); 524s assert (p(22), 1.521400636466575e-09, 1e-14); 524s assert (p(30), 6.665480510026046e-05, 1e-14); 524s assert (p(41), 0.002406447308399836, 1e-14); 524s ***** test 524s p = ncx2cdf (12, 10, 3); 524s assert (p, 0.4845555602398649, 1e-14); 524s ***** test 524s p = ncx2cdf (2, 3, 2); 524s assert (p, 0.2207330870741212, 1e-14); 524s ***** test 524s p = ncx2cdf (2, 3, 2, "upper"); 524s assert (p, 0.7792669129258789, 1e-14); 524s ***** test 524s p = ncx2cdf ([3, 6], 3, 2, "upper"); 524s assert (p, [0.6423318186400054, 0.3152299878943012], 1e-14); 525s ***** error ncx2cdf () 525s ***** error ncx2cdf (1) 525s ***** error ncx2cdf (1, 2) 525s ***** error ncx2cdf (1, 2, 3, "tail") 525s ***** error ncx2cdf (1, 2, 3, 4) 525s ***** error ... 525s ncx2cdf (ones (3), ones (2), ones (2)) 525s ***** error ... 525s ncx2cdf (ones (2), ones (3), ones (2)) 525s ***** error ... 525s ncx2cdf (ones (2), ones (2), ones (3)) 525s ***** error ncx2cdf (i, 2, 2) 525s ***** error ncx2cdf (2, i, 2) 525s ***** error ncx2cdf (2, 2, i) 525s 16 tests, 16 passed, 0 known failure, 0 skipped 525s [inst/dist_fun/lognrnd.m] 525s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/lognrnd.m 525s ***** assert (size (lognrnd (1, 1)), [1 1]) 525s ***** assert (size (lognrnd (1, ones (2,1))), [2, 1]) 525s ***** assert (size (lognrnd (1, ones (2,2))), [2, 2]) 525s ***** assert (size (lognrnd (ones (2,1), 1)), [2, 1]) 525s ***** assert (size (lognrnd (ones (2,2), 1)), [2, 2]) 525s ***** assert (size (lognrnd (1, 1, 3)), [3, 3]) 525s ***** assert (size (lognrnd (1, 1, [4, 1])), [4, 1]) 525s ***** assert (size (lognrnd (1, 1, 4, 1)), [4, 1]) 525s ***** assert (size (lognrnd (1, 1, 4, 1, 5)), [4, 1, 5]) 525s ***** assert (size (lognrnd (1, 1, 0, 1)), [0, 1]) 525s ***** assert (size (lognrnd (1, 1, 1, 0)), [1, 0]) 525s ***** assert (size (lognrnd (1, 1, 1, 2, 0, 5)), [1, 2, 0, 5]) 525s ***** assert (class (lognrnd (1, 1)), "double") 525s ***** assert (class (lognrnd (1, single (1))), "single") 525s ***** assert (class (lognrnd (1, single ([1, 1]))), "single") 525s ***** assert (class (lognrnd (single (1), 1)), "single") 525s ***** assert (class (lognrnd (single ([1, 1]), 1)), "single") 525s ***** error lognrnd () 525s ***** error lognrnd (1) 525s ***** error ... 525s lognrnd (ones (3), ones (2)) 525s ***** error ... 525s lognrnd (ones (2), ones (3)) 525s ***** error lognrnd (i, 2, 3) 525s ***** error lognrnd (1, i, 3) 525s ***** error ... 525s lognrnd (1, 2, -1) 525s ***** error ... 525s lognrnd (1, 2, 1.2) 525s ***** error ... 525s lognrnd (1, 2, ones (2)) 525s ***** error ... 525s lognrnd (1, 2, [2 -1 2]) 525s ***** error ... 525s lognrnd (1, 2, [2 0 2.5]) 525s ***** error ... 525s lognrnd (1, 2, 2, -1, 5) 525s ***** error ... 525s lognrnd (1, 2, 2, 1.5, 5) 525s ***** error ... 525s lognrnd (2, ones (2), 3) 525s ***** error ... 525s lognrnd (2, ones (2), [3, 2]) 525s ***** error ... 525s lognrnd (2, ones (2), 3, 2) 525s 33 tests, 33 passed, 0 known failure, 0 skipped 525s [inst/dist_fun/plpdf.m] 525s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/plpdf.m 525s ***** demo 525s ## Plot various PDFs from the Piecewise linear distribution 525s data = 0:0.01:10; 525s x1 = [0, 1, 3, 4, 7, 10]; 525s Fx1 = [0, 0.2, 0.5, 0.6, 0.7, 1]; 525s x2 = [0, 2, 5, 6, 7, 8]; 525s Fx2 = [0, 0.1, 0.3, 0.6, 0.9, 1]; 525s y1 = plpdf (data, x1, Fx1); 525s y2 = plpdf (data, x2, Fx2); 525s plot (data, y1, "-b", data, y2, "g") 525s grid on 525s ylim ([0, 0.6]) 525s xlim ([0, 10]) 525s legend ({"x1, Fx1", "x2, Fx2"}, "location", "northeast") 525s title ("Piecewise linear CDF") 525s xlabel ("values in data") 525s ylabel ("density") 525s ***** shared x, Fx 525s x = [0, 1, 3, 4, 7, 10]; 525s Fx = [0, 0.2, 0.5, 0.6, 0.7, 1]; 525s ***** assert (plpdf (0.5, x, Fx), 0.2, eps); 525s ***** assert (plpdf (1.5, x, Fx), 0.15, eps); 525s ***** assert (plpdf (3.5, x, Fx), 0.1, eps); 525s ***** assert (plpdf (5, x, Fx), 0.1/3, eps); 525s ***** assert (plpdf (8, x, Fx), 0.1, eps); 525s ***** error plpdf () 525s ***** error plpdf (1) 525s ***** error plpdf (1, 2) 525s ***** error ... 525s plpdf (1, [0, 1, 2], [0, 1]) 525s ***** error ... 525s plpdf (1, [0], [1]) 525s ***** error ... 525s plpdf (1, [0, 1, 2], [0, 1, 1.5]) 525s ***** error ... 525s plpdf (1, [0, 1, 2], [0, i, 1]) 525s ***** error ... 525s plpdf (i, [0, 1, 2], [0, 0.5, 1]) 525s ***** error ... 525s plpdf (1, [0, i, 2], [0, 0.5, 1]) 525s ***** error ... 525s plpdf (1, [0, 1, 2], [0, 0.5i, 1]) 525s 15 tests, 15 passed, 0 known failure, 0 skipped 525s [inst/dist_fun/geornd.m] 525s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/geornd.m 525s ***** assert (size (geornd (0.5)), [1, 1]) 525s ***** assert (size (geornd (0.5*ones (2,1))), [2, 1]) 525s ***** assert (size (geornd (0.5*ones (2,2))), [2, 2]) 525s ***** assert (size (geornd (0.5, 3)), [3, 3]) 525s ***** assert (size (geornd (0.5, [4 1])), [4, 1]) 525s ***** assert (size (geornd (0.5, 4, 1)), [4, 1]) 525s ***** assert (class (geornd (0.5)), "double") 525s ***** assert (class (geornd (single (0.5))), "single") 525s ***** assert (class (geornd (single ([0.5 0.5]))), "single") 525s ***** assert (class (geornd (single (0))), "single") 525s ***** assert (class (geornd (single (1))), "single") 525s ***** error geornd () 525s ***** error geornd (i) 525s ***** error ... 525s geornd (1, -1) 525s ***** error ... 525s geornd (1, 1.2) 525s ***** error ... 525s geornd (1, ones (2)) 525s ***** error ... 525s geornd (1, [2 -1 2]) 525s ***** error ... 525s geornd (1, [2 0 2.5]) 525s ***** error ... 525s geornd (ones (2), ones (2)) 525s ***** error ... 525s geornd (1, 2, -1, 5) 525s ***** error ... 525s geornd (1, 2, 1.5, 5) 525s ***** error geornd (ones (2,2), 3) 525s ***** error geornd (ones (2,2), [3, 2]) 525s ***** error geornd (ones (2,2), 2, 3) 525s 24 tests, 24 passed, 0 known failure, 0 skipped 525s [inst/dist_fun/copularnd.m] 525s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/copularnd.m 525s ***** test 525s theta = 0.5; 525s r = copularnd ("Gaussian", theta); 525s assert (size (r), [1, 2]); 525s assert (all ((r >= 0) & (r <= 1))); 525s ***** test 525s theta = 0.5; 525s df = 2; 525s r = copularnd ("t", theta, df); 525s assert (size (r), [1, 2]); 525s assert (all ((r >= 0) & (r <= 1))); 525s ***** test 525s theta = 0.5; 525s r = copularnd ("Clayton", theta); 525s assert (size (r), [1, 2]); 525s assert (all ((r >= 0) & (r <= 1))); 525s ***** test 525s theta = 0.5; 525s n = 2; 525s r = copularnd ("Clayton", theta, n); 525s assert (size (r), [n, 2]); 525s assert (all ((r >= 0) & (r <= 1))); 525s ***** test 525s theta = [1; 2]; 525s n = 2; 525s d = 3; 525s r = copularnd ("Clayton", theta, n, d); 525s assert (size (r), [n, d]); 525s assert (all ((r >= 0) & (r <= 1))); 525s 5 tests, 5 passed, 0 known failure, 0 skipped 525s [inst/dist_fun/laplacernd.m] 525s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/laplacernd.m 525s ***** assert (size (laplacernd (1, 1)), [1 1]) 525s ***** assert (size (laplacernd (1, ones (2,1))), [2, 1]) 525s ***** assert (size (laplacernd (1, ones (2,2))), [2, 2]) 525s ***** assert (size (laplacernd (ones (2,1), 1)), [2, 1]) 525s ***** assert (size (laplacernd (ones (2,2), 1)), [2, 2]) 525s ***** assert (size (laplacernd (1, 1, 3)), [3, 3]) 525s ***** assert (size (laplacernd (1, 1, [4, 1])), [4, 1]) 525s ***** assert (size (laplacernd (1, 1, 4, 1)), [4, 1]) 525s ***** assert (size (laplacernd (1, 1, 4, 1, 5)), [4, 1, 5]) 525s ***** assert (size (laplacernd (1, 1, 0, 1)), [0, 1]) 525s ***** assert (size (laplacernd (1, 1, 1, 0)), [1, 0]) 525s ***** assert (size (laplacernd (1, 1, 1, 2, 0, 5)), [1, 2, 0, 5]) 525s ***** assert (class (laplacernd (1, 1)), "double") 525s ***** assert (class (laplacernd (1, single (1))), "single") 525s ***** assert (class (laplacernd (1, single ([1, 1]))), "single") 525s ***** assert (class (laplacernd (single (1), 1)), "single") 525s ***** assert (class (laplacernd (single ([1, 1]), 1)), "single") 525s ***** error laplacernd () 525s ***** error laplacernd (1) 525s ***** error ... 525s laplacernd (ones (3), ones (2)) 525s ***** error ... 525s laplacernd (ones (2), ones (3)) 525s ***** error laplacernd (i, 2, 3) 525s ***** error laplacernd (1, i, 3) 525s ***** error ... 525s laplacernd (1, 2, -1) 525s ***** error ... 525s laplacernd (1, 2, 1.2) 525s ***** error ... 525s laplacernd (1, 2, ones (2)) 525s ***** error ... 525s laplacernd (1, 2, [2 -1 2]) 525s ***** error ... 525s laplacernd (1, 2, [2 0 2.5]) 525s ***** error ... 525s laplacernd (1, 2, 2, -1, 5) 525s ***** error ... 525s laplacernd (1, 2, 2, 1.5, 5) 525s ***** error ... 525s laplacernd (2, ones (2), 3) 525s ***** error ... 525s laplacernd (2, ones (2), [3, 2]) 525s ***** error ... 525s laplacernd (2, ones (2), 3, 2) 525s 33 tests, 33 passed, 0 known failure, 0 skipped 525s [inst/dist_fun/expinv.m] 525s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/expinv.m 525s ***** demo 525s ## Plot various iCDFs from the exponential distribution 525s p = 0.001:0.001:0.999; 525s x1 = expinv (p, 2/3); 525s x2 = expinv (p, 1.0); 525s x3 = expinv (p, 2.0); 525s plot (p, x1, "-b", p, x2, "-g", p, x3, "-r") 525s grid on 525s ylim ([0, 5]) 525s legend ({"μ = 2/3", "μ = 1", "μ = 2"}, "location", "northwest") 525s title ("Exponential iCDF") 525s xlabel ("probability") 525s ylabel ("values in x") 525s ***** shared p 525s p = [-1 0 0.3934693402873666 1 2]; 525s ***** assert (expinv (p, 2*ones (1,5)), [NaN 0 1 Inf NaN], eps) 525s ***** assert (expinv (p, 2), [NaN 0 1 Inf NaN], eps) 525s ***** assert (expinv (p, 2*[1 0 NaN 1 1]), [NaN NaN NaN Inf NaN], eps) 525s ***** assert (expinv ([p(1:2) NaN p(4:5)], 2), [NaN 0 NaN Inf NaN], eps) 525s ***** assert (expinv ([p, NaN], 2), [NaN 0 1 Inf NaN NaN], eps) 525s ***** assert (expinv (single ([p, NaN]), 2), single ([NaN 0 1 Inf NaN NaN]), eps) 525s ***** assert (expinv ([p, NaN], single (2)), single ([NaN 0 1 Inf NaN NaN]), eps) 525s ***** error expinv () 525s ***** error expinv (1, 2 ,3 ,4 ,5) 525s ***** error ... 525s expinv (ones (3), ones (2)) 525s ***** error ... 525s expinv (2, 3, [1, 2]) 525s ***** error ... 525s [x, xlo, xup] = expinv (1, 2) 525s ***** error [x, xlo, xup] = ... 525s expinv (1, 2, 3, 0) 525s ***** error [x, xlo, xup] = ... 525s expinv (1, 2, 3, 1.22) 525s ***** error [x, xlo, xup] = ... 525s expinv (1, 2, 3, [0.05, 0.1]) 525s ***** error expinv (i, 2) 525s ***** error expinv (2, i) 525s ***** error ... 525s [x, xlo, xup] = expinv (1, 2, -1, 0.04) 525s 18 tests, 18 passed, 0 known failure, 0 skipped 525s [inst/dist_fun/mnpdf.m] 525s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/mnpdf.m 525s ***** test 525s x = [1, 4, 2]; 525s pk = [0.2, 0.5, 0.3]; 525s y = mnpdf (x, pk); 525s assert (y, 0.11812, 0.001); 525s ***** test 525s x = [1, 4, 2; 1, 0, 9]; 525s pk = [0.2, 0.5, 0.3; 0.1, 0.1, 0.8]; 525s y = mnpdf (x, pk); 525s assert (y, [0.11812; 0.13422], 0.001); 525s 2 tests, 2 passed, 0 known failure, 0 skipped 525s [inst/dist_fun/tripdf.m] 525s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/tripdf.m 525s ***** demo 525s ## Plot various CDFs from the triangular distribution 525s x = 0.001:0.001:10; 525s y1 = tripdf (x, 3, 4, 6); 525s y2 = tripdf (x, 1, 2, 5); 525s y3 = tripdf (x, 2, 3, 9); 525s y4 = tripdf (x, 2, 5, 9); 525s plot (x, y1, "-b", x, y2, "-g", x, y3, "-r", x, y4, "-c") 525s grid on 525s xlim ([0, 10]) 525s legend ({"a = 3, b = 4, c = 6", "a = 1, b = 2, c = 5", ... 525s "a = 2, b = 3, c = 9", "a = 2, b = 5, c = 9"}, ... 525s "location", "northeast") 525s title ("Triangular CDF") 525s xlabel ("values in x") 525s ylabel ("probability") 525s ***** shared x, y, deps 525s x = [-1, 0, 0.1, 0.5, 0.9, 1, 2] + 1; 525s y = [0, 0, 0.4, 2, 0.4, 0, 0]; 525s deps = 2*eps; 525s ***** assert (tripdf (x, ones (1,7), 1.5*ones (1,7), 2*ones (1,7)), y, deps) 525s ***** assert (tripdf (x, 1*ones (1,7), 1.5, 2), y, deps) 525s ***** assert (tripdf (x, 1, 1.5, 2*ones (1,7)), y, deps) 525s ***** assert (tripdf (x, 1, 1.5*ones (1,7), 2), y, deps) 525s ***** assert (tripdf (x, 1, 1.5, 2), y, deps) 525s ***** assert (tripdf (x, [1, 1, NaN, 1, 1, 1, 1], 1.5, 2), [y(1:2), NaN, y(4:7)], deps) 525s ***** assert (tripdf (x, 1, 1.5, 2*[1, 1, NaN, 1, 1, 1, 1]), [y(1:2), NaN, y(4:7)], deps) 525s ***** assert (tripdf (x, 1, 1.5*[1, 1, NaN, 1, 1, 1, 1], 2), [y(1:2), NaN, y(4:7)], deps) 525s ***** assert (tripdf ([x, NaN], 1, 1.5, 2), [y, NaN], deps) 525s ***** assert (tripdf (single ([x, NaN]), 1, 1.5, 2), single ([y, NaN]), eps("single")) 525s ***** assert (tripdf ([x, NaN], single (1), 1.5, 2), single ([y, NaN]), eps("single")) 525s ***** assert (tripdf ([x, NaN], 1, 1.5, single (2)), single ([y, NaN]), eps("single")) 525s ***** assert (tripdf ([x, NaN], 1, single (1.5), 2), single ([y, NaN]), eps("single")) 525s ***** error tripdf () 525s ***** error tripdf (1) 525s ***** error tripdf (1, 2) 525s ***** error tripdf (1, 2, 3) 525s ***** error ... 525s tripdf (1, 2, 3, 4, 5) 525s ***** error ... 525s tripdf (ones (3), ones (2), ones(2), ones(2)) 525s ***** error ... 525s tripdf (ones (2), ones (3), ones(2), ones(2)) 525s ***** error ... 525s tripdf (ones (2), ones (2), ones(3), ones(2)) 525s ***** error ... 525s tripdf (ones (2), ones (2), ones(2), ones(3)) 525s ***** error tripdf (i, 2, 3, 4) 525s ***** error tripdf (1, i, 3, 4) 525s ***** error tripdf (1, 2, i, 4) 525s ***** error tripdf (1, 2, 3, i) 525s 26 tests, 26 passed, 0 known failure, 0 skipped 525s [inst/dist_fun/geoinv.m] 525s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/geoinv.m 525s ***** demo 525s ## Plot various iCDFs from the geometric distribution 525s p = 0.001:0.001:0.999; 525s x1 = geoinv (p, 0.2); 525s x2 = geoinv (p, 0.5); 525s x3 = geoinv (p, 0.7); 525s plot (p, x1, "-b", p, x2, "-g", p, x3, "-r") 525s grid on 525s ylim ([0, 10]) 525s legend ({"ps = 0.2", "ps = 0.5", "ps = 0.7"}, "location", "northwest") 525s title ("Geometric iCDF") 525s xlabel ("probability") 525s ylabel ("values in x (number of failures)") 525s ***** shared p 525s p = [-1 0 0.75 1 2]; 525s ***** assert (geoinv (p, 0.5*ones (1,5)), [NaN 0 1 Inf NaN]) 525s ***** assert (geoinv (p, 0.5), [NaN 0 1 Inf NaN]) 525s ***** assert (geoinv (p, 0.5*[1 -1 NaN 4 1]), [NaN NaN NaN NaN NaN]) 525s ***** assert (geoinv ([p(1:2) NaN p(4:5)], 0.5), [NaN 0 NaN Inf NaN]) 525s ***** assert (geoinv ([p, NaN], 0.5), [NaN 0 1 Inf NaN NaN]) 525s ***** assert (geoinv (single ([p, NaN]), 0.5), single ([NaN 0 1 Inf NaN NaN])) 525s ***** assert (geoinv ([p, NaN], single (0.5)), single ([NaN 0 1 Inf NaN NaN])) 525s ***** error geoinv () 525s ***** error geoinv (1) 525s ***** error ... 525s geoinv (ones (3), ones (2)) 525s ***** error ... 525s geoinv (ones (2), ones (3)) 525s ***** error ... 525s geoinv (i, 2) 525s ***** error ... 525s geoinv (2, i) 525s 13 tests, 13 passed, 0 known failure, 0 skipped 525s [inst/dist_fun/gevinv.m] 525s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_fun/gevinv.m 525s ***** demo 525s ## Plot various iCDFs from the generalized extreme value distribution 525s p = 0.001:0.001:0.999; 525s x1 = gevinv (p, 1, 1, 1); 525s x2 = gevinv (p, 0.5, 1, 1); 525s x3 = gevinv (p, 1, 1, 5); 525s x4 = gevinv (p, 1, 2, 5); 525s x5 = gevinv (p, 1, 5, 5); 525s x6 = gevinv (p, 1, 0.5, 5); 525s plot (p, x1, "-b", p, x2, "-g", p, x3, "-r", ... 525s p, x4, "-c", p, x5, "-m", p, x6, "-k") 525s grid on 525s ylim ([-1, 10]) 525s legend ({"k = 1, σ = 1, μ = 1", "k = 0.5, σ = 1, μ = 1", ... 525s "k = 1, σ = 1, μ = 5", "k = 1, σ = 2, μ = 5", ... 525s "k = 1, σ = 5, μ = 5", "k = 1, σ = 0.5, μ = 5"}, ... 525s "location", "northwest") 525s title ("Generalized extreme value iCDF") 525s xlabel ("probability") 525s ylabel ("values in x") 525s ***** test 525s p = 0.1:0.1:0.9; 525s k = 0; 525s sigma = 1; 525s mu = 0; 525s x = gevinv (p, k, sigma, mu); 525s c = gevcdf(x, k, sigma, mu); 525s assert (c, p, 0.001); 525s ***** test 525s p = 0.1:0.1:0.9; 525s k = 1; 525s sigma = 1; 525s mu = 0; 525s x = gevinv (p, k, sigma, mu); 525s c = gevcdf(x, k, sigma, mu); 525s assert (c, p, 0.001); 525s ***** test 525s p = 0.1:0.1:0.9; 525s k = 0.3; 525s sigma = 1; 525s mu = 0; 525s x = gevinv (p, k, sigma, mu); 525s c = gevcdf(x, k, sigma, mu); 525s assert (c, p, 0.001); 525s ***** error gevinv () 525s ***** error gevinv (1) 525s ***** error gevinv (1, 2) 525s ***** error gevinv (1, 2, 3) 525s ***** error ... 525s gevinv (ones (3), ones (2), ones(2), ones(2)) 525s ***** error ... 525s gevinv (ones (2), ones (3), ones(2), ones(2)) 525s ***** error ... 525s gevinv (ones (2), ones (2), ones(3), ones(2)) 525s ***** error ... 525s gevinv (ones (2), ones (2), ones(2), ones(3)) 525s ***** error gevinv (i, 2, 3, 4) 525s ***** error gevinv (1, i, 3, 4) 525s ***** error gevinv (1, 2, i, 4) 525s ***** error gevinv (1, 2, 3, i) 525s 15 tests, 15 passed, 0 known failure, 0 skipped 525s [inst/mahal.m] 525s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/mahal.m 525s ***** error mahal () 525s ***** error mahal (1, 2, 3) 525s ***** error mahal ("A", "B") 525s ***** error mahal ([1, 2], ["A", "B"]) 525s ***** error mahal (ones (2, 2, 2)) 526s ***** error mahal (ones (2, 2), ones (2, 2, 2)) 526s ***** error mahal (ones (2, 2), ones (2, 3)) 526s ***** test 526s X = [1 0; 0 1; 1 1; 0 0]; 526s assert (mahal (X, X), [1.5; 1.5; 1.5; 1.5], 10*eps) 526s assert (mahal (X, X+1), [7.5; 7.5; 1.5; 13.5], 10*eps) 526s ***** assert (mahal ([true; true], [false; true]), [0.5; 0.5], eps) 526s 9 tests, 9 passed, 0 known failure, 0 skipped 526s [inst/jackknife.m] 526s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/jackknife.m 526s ***** demo 526s for k = 1:1000 526s rand ("seed", k); # for reproducibility 526s x = rand (10, 1); 526s s(k) = std (x); 526s jackstat = jackknife (@std, x); 526s j(k) = 10 * std (x) - 9 * mean (jackstat); 526s endfor 526s figure(); 526s hist ([s', j'], 0:sqrt(1/12)/10:2*sqrt(1/12)) 526s ***** demo 526s for k = 1:1000 526s randn ("seed", k); # for reproducibility 526s x = randn (1, 50); 526s rand ("seed", k); # for reproducibility 526s y = rand (1, 50); 526s jackstat = jackknife (@(x) std(x{1})/std(x{2}), y, x); 526s j(k) = 50 * std (y) / std (x) - 49 * mean (jackstat); 526s v(k) = sumsq ((50 * std (y) / std (x) - 49 * jackstat) - j(k)) / (50 * 49); 526s endfor 526s t = (j - sqrt (1 / 12)) ./ sqrt (v); 526s figure(); 526s plot (sort (tcdf (t, 49)), ... 526s "-;Almost linear mapping indicates good fit with t-distribution.;") 526s ***** test 526s ##Example from Quenouille, Table 1 526s d=[0.18 4.00 1.04 0.85 2.14 1.01 3.01 2.33 1.57 2.19]; 526s jackstat = jackknife ( @(x) 1/mean(x), d ); 526s assert ( 10 / mean(d) - 9 * mean(jackstat), 0.5240, 1e-5 ); 526s 1 test, 1 passed, 0 known failure, 0 skipped 526s [inst/inconsistent.m] 526s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/inconsistent.m 526s ***** error inconsistent () 526s ***** error inconsistent ([1 2 1], 2, 3) 526s ***** error inconsistent (ones (2, 2)) 526s ***** error inconsistent ([1 2 1], -1) 526s ***** error inconsistent ([1 2 1], 1.3) 526s ***** error inconsistent ([1 2 1], [1 1]) 526s ***** error inconsistent (ones (2, 3)) 526s ***** test 526s load fisheriris; 526s Z = linkage(meas, 'average', 'chebychev'); 526s assert (cond (inconsistent (Z)), 39.9, 1e-3); 526s 8 tests, 8 passed, 0 known failure, 0 skipped 526s [inst/pcacov.m] 526s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/pcacov.m 526s ***** demo 526s x = [ 7 26 6 60; 526s 1 29 15 52; 526s 11 56 8 20; 526s 11 31 8 47; 526s 7 52 6 33; 526s 11 55 9 22; 526s 3 71 17 6; 526s 1 31 22 44; 526s 2 54 18 22; 526s 21 47 4 26; 526s 1 40 23 34; 526s 11 66 9 12; 526s 10 68 8 12 526s ]; 526s Kxx = cov (x); 526s [coeff, latent, explained] = pcacov (Kxx) 526s ***** test 526s load hald 526s Kxx = cov (ingredients); 526s [coeff,latent,explained] = pcacov(Kxx); 526s c_out = [-0.0678, -0.6460, 0.5673, 0.5062; ... 526s -0.6785, -0.0200, -0.5440, 0.4933; ... 526s 0.0290, 0.7553, 0.4036, 0.5156; ... 526s 0.7309, -0.1085, -0.4684, 0.4844]; 526s l_out = [517.7969; 67.4964; 12.4054; 0.2372]; 526s e_out = [ 86.5974; 11.2882; 2.0747; 0.0397]; 526s assert (coeff, c_out, 1e-4); 526s assert (latent, l_out, 1e-4); 526s assert (explained, e_out, 1e-4); 526s ***** error pcacov (ones (2,3)) 526s ***** error pcacov (ones (3,3,3)) 526s 3 tests, 3 passed, 0 known failure, 0 skipped 526s [inst/dist_wrap/fitdist.m] 526s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_wrap/fitdist.m 526s ***** test 526s x = betarnd (1, 1, 100, 1); 526s pd = fitdist (x, "Beta"); 526s [phat, pci] = betafit (x); 526s assert ([pd.a, pd.b], phat); 526s assert (paramci (pd), pci); 526s ***** test 526s x1 = betarnd (1, 1, 100, 1); 526s x2 = betarnd (5, 2, 100, 1); 526s pd = fitdist ([x1; x2], "Beta", "By", [ones(100,1); 2*ones(100,1)]); 526s [phat, pci] = betafit (x1); 526s assert ([pd(1).a, pd(1).b], phat); 526s assert (paramci (pd(1)), pci); 526s [phat, pci] = betafit (x2); 526s assert ([pd(2).a, pd(2).b], phat); 526s assert (paramci (pd(2)), pci); 526s ***** test 526s N = 1; 526s x = binornd (N, 0.5, 100, 1); 526s pd = fitdist (x, "binomial"); 526s [phat, pci] = binofit (sum (x), numel (x)); 526s assert ([pd.N, pd.p], [N, phat]); 526s assert (paramci (pd), pci); 527s ***** test 527s N = 3; 527s x = binornd (N, 0.4, 100, 1); 527s pd = fitdist (x, "binomial", "ntrials", N); 527s [phat, pci] = binofit (sum (x), numel (x) * N); 527s assert ([pd.N, pd.p], [N, phat]); 527s assert (paramci (pd), pci); 527s ***** test 527s N = 1; 527s x1 = binornd (N, 0.5, 100, 1); 527s x2 = binornd (N, 0.7, 100, 1); 527s pd = fitdist ([x1; x2], "binomial", "By", [ones(100,1); 2*ones(100,1)]); 527s [phat, pci] = binofit (sum (x1), numel (x1)); 527s assert ([pd(1).N, pd(1).p], [N, phat]); 527s assert (paramci (pd(1)), pci); 527s [phat, pci] = binofit (sum (x2), numel (x2)); 527s assert ([pd(2).N, pd(2).p], [N, phat]); 527s assert (paramci (pd(2)), pci); 527s ***** test 527s N = 5; 527s x1 = binornd (N, 0.5, 100, 1); 527s x2 = binornd (N, 0.8, 100, 1); 527s pd = fitdist ([x1; x2], "binomial", "ntrials", N, ... 527s "By", [ones(100,1); 2*ones(100,1)]); 527s [phat, pci] = binofit (sum (x1), numel (x1) * N); 527s assert ([pd(1).N, pd(1).p], [N, phat]); 527s assert (paramci (pd(1)), pci); 527s [phat, pci] = binofit (sum (x2), numel (x2) * N); 527s assert ([pd(2).N, pd(2).p], [N, phat]); 527s assert (paramci (pd(2)), pci); 527s ***** test 527s x = bisarnd (1, 1, 100, 1); 527s pd = fitdist (x, "BirnbaumSaunders"); 527s [phat, pci] = bisafit (x); 527s assert ([pd.beta, pd.gamma], phat); 527s assert (paramci (pd), pci); 527s ***** test 527s x1 = bisarnd (1, 1, 100, 1); 527s x2 = bisarnd (5, 2, 100, 1); 527s pd = fitdist ([x1; x2], "bisa", "By", [ones(100,1); 2*ones(100,1)]); 527s [phat, pci] = bisafit (x1); 527s assert ([pd(1).beta, pd(1).gamma], phat); 527s assert (paramci (pd(1)), pci); 527s [phat, pci] = bisafit (x2); 527s assert ([pd(2).beta, pd(2).gamma], phat); 527s assert (paramci (pd(2)), pci); 528s ***** test 528s x = burrrnd (1, 2, 1, 100, 1); 528s pd = fitdist (x, "Burr"); 528s [phat, pci] = burrfit (x); 528s assert ([pd.alpha, pd.c, pd.k], phat); 528s assert (paramci (pd), pci); 528s ***** test 528s x1 = burrrnd (1, 2, 1, 100, 1); 528s x2 = burrrnd (1, 0.5, 2, 100, 1); 528s pd = fitdist ([x1; x2], "burr", "By", [ones(100,1); 2*ones(100,1)]); 528s [phat, pci] = burrfit (x1); 528s assert ([pd(1).alpha, pd(1).c, pd(1).k], phat); 528s assert (paramci (pd(1)), pci); 528s [phat, pci] = burrfit (x2); 528s assert ([pd(2).alpha, pd(2).c, pd(2).k], phat); 528s assert (paramci (pd(2)), pci); 530s ***** test 530s x = exprnd (1, 100, 1); 530s pd = fitdist (x, "exponential"); 530s [muhat, muci] = expfit (x); 530s assert ([pd.mu], muhat); 530s assert (paramci (pd), muci); 530s ***** test 530s x1 = exprnd (1, 100, 1); 530s x2 = exprnd (5, 100, 1); 530s pd = fitdist ([x1; x2], "exponential", "By", [ones(100,1); 2*ones(100,1)]); 530s [muhat, muci] = expfit (x1); 530s assert ([pd(1).mu], muhat); 530s assert (paramci (pd(1)), muci); 530s [muhat, muci] = expfit (x2); 530s assert ([pd(2).mu], muhat); 530s assert (paramci (pd(2)), muci); 530s ***** test 530s x = evrnd (1, 1, 100, 1); 530s pd = fitdist (x, "ev"); 530s [phat, pci] = evfit (x); 530s assert ([pd.mu, pd.sigma], phat); 530s assert (paramci (pd), pci); 530s ***** test 530s x1 = evrnd (1, 1, 100, 1); 530s x2 = evrnd (5, 2, 100, 1); 530s pd = fitdist ([x1; x2], "extremevalue", "By", [ones(100,1); 2*ones(100,1)]); 530s [phat, pci] = evfit (x1); 530s assert ([pd(1).mu, pd(1).sigma], phat); 530s assert (paramci (pd(1)), pci); 530s [phat, pci] = evfit (x2); 530s assert ([pd(2).mu, pd(2).sigma], phat); 530s assert (paramci (pd(2)), pci); 530s ***** test 530s x = gamrnd (1, 1, 100, 1); 530s pd = fitdist (x, "Gamma"); 530s [phat, pci] = gamfit (x); 530s assert ([pd.a, pd.b], phat); 530s assert (paramci (pd), pci); 530s ***** test 530s x1 = gamrnd (1, 1, 100, 1); 530s x2 = gamrnd (5, 2, 100, 1); 530s pd = fitdist ([x1; x2], "Gamma", "By", [ones(100,1); 2*ones(100,1)]); 530s [phat, pci] = gamfit (x1); 530s assert ([pd(1).a, pd(1).b], phat); 530s assert (paramci (pd(1)), pci); 530s [phat, pci] = gamfit (x2); 530s assert ([pd(2).a, pd(2).b], phat); 530s assert (paramci (pd(2)), pci); 530s ***** test 530s rand ("seed", 4); # for reproducibility 530s x = gevrnd (-0.5, 1, 2, 1000, 1); 530s pd = fitdist (x, "generalizedextremevalue"); 530s [phat, pci] = gevfit (x); 530s assert ([pd.k, pd.sigma, pd.mu], phat); 530s assert (paramci (pd), pci); 531s ***** test 531s rand ("seed", 5); # for reproducibility 531s x1 = gevrnd (-0.5, 1, 2, 1000, 1); 531s rand ("seed", 9); # for reproducibility 531s x2 = gevrnd (0, 1, -4, 1000, 1); 531s pd = fitdist ([x1; x2], "gev", "By", [ones(1000,1); 2*ones(1000,1)]); 531s [phat, pci] = gevfit (x1); 531s assert ([pd(1).k, pd(1).sigma, pd(1).mu], phat); 531s assert (paramci (pd(1)), pci); 531s [phat, pci] = gevfit (x2); 531s assert ([pd(2).k, pd(2).sigma, pd(2).mu], phat); 531s assert (paramci (pd(2)), pci); 532s ***** test 532s x = gprnd (1, 1, 1, 100, 1); 532s pd = fitdist (x, "GeneralizedPareto"); 532s [phat, pci] = gpfit (x, 1); 532s assert ([pd.k, pd.sigma, pd.theta], phat); 532s assert (paramci (pd), pci); 532s ***** test 532s x = gprnd (1, 1, 2, 100, 1); 532s pd = fitdist (x, "GeneralizedPareto", "theta", 2); 532s [phat, pci] = gpfit (x, 2); 532s assert ([pd.k, pd.sigma, pd.theta], phat); 532s assert (paramci (pd), pci); 533s ***** test 533s x1 = gprnd (1, 1, 1, 100, 1); 533s x2 = gprnd (0, 2, 1, 100, 1); 533s pd = fitdist ([x1; x2], "gp", "By", [ones(100,1); 2*ones(100,1)]); 533s [phat, pci] = gpfit (x1, 1); 533s assert ([pd(1).k, pd(1).sigma, pd(1).theta], phat); 533s assert (paramci (pd(1)), pci); 533s [phat, pci] = gpfit (x2, 1); 533s assert ([pd(2).k, pd(2).sigma, pd(2).theta], phat); 533s assert (paramci (pd(2)), pci); 533s ***** test 533s x1 = gprnd (3, 2, 2, 100, 1); 533s x2 = gprnd (2, 3, 2, 100, 1); 533s pd = fitdist ([x1; x2], "GeneralizedPareto", "theta", 2, ... 533s "By", [ones(100,1); 2*ones(100,1)]); 533s [phat, pci] = gpfit (x1, 2); 533s assert ([pd(1).k, pd(1).sigma, pd(1).theta], phat); 533s assert (paramci (pd(1)), pci); 533s [phat, pci] = gpfit (x2, 2); 533s assert ([pd(2).k, pd(2).sigma, pd(2).theta], phat); 533s assert (paramci (pd(2)), pci); 533s ***** test 533s x = hnrnd (0, 1, 100, 1); 533s pd = fitdist (x, "HalfNormal"); 533s [phat, pci] = hnfit (x, 0); 533s assert ([pd.mu, pd.sigma], phat); 533s assert (paramci (pd), pci); 533s ***** test 533s x = hnrnd (1, 1, 100, 1); 533s pd = fitdist (x, "HalfNormal", "mu", 1); 533s [phat, pci] = hnfit (x, 1); 533s assert ([pd.mu, pd.sigma], phat); 533s assert (paramci (pd), pci); 533s ***** test 533s x1 = hnrnd (0, 1, 100, 1); 533s x2 = hnrnd (0, 2, 100, 1); 533s pd = fitdist ([x1; x2], "HalfNormal", "By", [ones(100,1); 2*ones(100,1)]); 533s [phat, pci] = hnfit (x1, 0); 533s assert ([pd(1).mu, pd(1).sigma], phat); 533s assert (paramci (pd(1)), pci); 533s [phat, pci] = hnfit (x2, 0); 533s assert ([pd(2).mu, pd(2).sigma], phat); 533s assert (paramci (pd(2)), pci); 534s ***** test 534s x1 = hnrnd (2, 1, 100, 1); 534s x2 = hnrnd (2, 2, 100, 1); 534s pd = fitdist ([x1; x2], "HalfNormal", "mu", 2, ... 534s "By", [ones(100,1); 2*ones(100,1)]); 534s [phat, pci] = hnfit (x1, 2); 534s assert ([pd(1).mu, pd(1).sigma], phat); 534s assert (paramci (pd(1)), pci); 534s [phat, pci] = hnfit (x2, 2); 534s assert ([pd(2).mu, pd(2).sigma], phat); 534s assert (paramci (pd(2)), pci); 534s ***** test 534s x = invgrnd (1, 1, 100, 1); 534s pd = fitdist (x, "InverseGaussian"); 534s [phat, pci] = invgfit (x); 534s assert ([pd.mu, pd.lambda], phat); 534s assert (paramci (pd), pci); 534s ***** test 534s x1 = invgrnd (1, 1, 100, 1); 534s x2 = invgrnd (5, 2, 100, 1); 534s pd = fitdist ([x1; x2], "InverseGaussian", "By", [ones(100,1); 2*ones(100,1)]); 534s [phat, pci] = invgfit (x1); 534s assert ([pd(1).mu, pd(1).lambda], phat); 534s assert (paramci (pd(1)), pci); 534s [phat, pci] = invgfit (x2); 534s assert ([pd(2).mu, pd(2).lambda], phat); 534s assert (paramci (pd(2)), pci); 535s ***** test 535s x = logirnd (1, 1, 100, 1); 535s pd = fitdist (x, "logistic"); 535s [phat, pci] = logifit (x); 535s assert ([pd.mu, pd.sigma], phat); 535s assert (paramci (pd), pci); 535s ***** test 535s x1 = logirnd (1, 1, 100, 1); 535s x2 = logirnd (5, 2, 100, 1); 535s pd = fitdist ([x1; x2], "logistic", "By", [ones(100,1); 2*ones(100,1)]); 535s [phat, pci] = logifit (x1); 535s assert ([pd(1).mu, pd(1).sigma], phat); 535s assert (paramci (pd(1)), pci); 535s [phat, pci] = logifit (x2); 535s assert ([pd(2).mu, pd(2).sigma], phat); 535s assert (paramci (pd(2)), pci); 535s ***** test 535s x = loglrnd (1, 1, 100, 1); 535s pd = fitdist (x, "loglogistic"); 535s [phat, pci] = loglfit (x); 535s assert ([pd.mu, pd.sigma], phat); 535s assert (paramci (pd), pci); 536s ***** test 536s x1 = loglrnd (1, 1, 100, 1); 536s x2 = loglrnd (5, 2, 100, 1); 536s pd = fitdist ([x1; x2], "loglogistic", "By", [ones(100,1); 2*ones(100,1)]); 536s [phat, pci] = loglfit (x1); 536s assert ([pd(1).mu, pd(1).sigma], phat); 536s assert (paramci (pd(1)), pci); 536s [phat, pci] = loglfit (x2); 536s assert ([pd(2).mu, pd(2).sigma], phat); 536s assert (paramci (pd(2)), pci); 536s ***** test 536s x = lognrnd (1, 1, 100, 1); 536s pd = fitdist (x, "lognormal"); 536s [phat, pci] = lognfit (x); 536s assert ([pd.mu, pd.sigma], phat); 536s assert (paramci (pd), pci); 537s ***** test 537s x1 = lognrnd (1, 1, 100, 1); 537s x2 = lognrnd (5, 2, 100, 1); 537s pd = fitdist ([x1; x2], "lognormal", "By", [ones(100,1); 2*ones(100,1)]); 537s [phat, pci] = lognfit (x1); 537s assert ([pd(1).mu, pd(1).sigma], phat); 537s assert (paramci (pd(1)), pci); 537s [phat, pci] = lognfit (x2); 537s assert ([pd(2).mu, pd(2).sigma], phat); 537s assert (paramci (pd(2)), pci); 538s ***** test 538s x = nakarnd (2, 0.5, 100, 1); 538s pd = fitdist (x, "Nakagami"); 538s [phat, pci] = nakafit (x); 538s assert ([pd.mu, pd.omega], phat); 538s assert (paramci (pd), pci); 538s ***** test 538s x1 = nakarnd (2, 0.5, 100, 1); 538s x2 = nakarnd (5, 0.8, 100, 1); 538s pd = fitdist ([x1; x2], "Nakagami", "By", [ones(100,1); 2*ones(100,1)]); 538s [phat, pci] = nakafit (x1); 538s assert ([pd(1).mu, pd(1).omega], phat); 538s assert (paramci (pd(1)), pci); 538s [phat, pci] = nakafit (x2); 538s assert ([pd(2).mu, pd(2).omega], phat); 538s assert (paramci (pd(2)), pci); 538s ***** test 538s randp ("seed", 123); 538s randg ("seed", 321); 538s x = nbinrnd (2, 0.5, 100, 1); 538s pd = fitdist (x, "negativebinomial"); 538s [phat, pci] = nbinfit (x); 538s assert ([pd.R, pd.P], phat); 538s assert (paramci (pd), pci); 538s ***** test 538s randp ("seed", 345); 538s randg ("seed", 543); 538s x1 = nbinrnd (2, 0.5, 100, 1); 538s randp ("seed", 432); 538s randg ("seed", 234); 538s x2 = nbinrnd (5, 0.8, 100, 1); 538s pd = fitdist ([x1; x2], "nbin", "By", [ones(100,1); 2*ones(100,1)]); 538s [phat, pci] = nbinfit (x1); 538s assert ([pd(1).R, pd(1).P], phat); 538s assert (paramci (pd(1)), pci); 538s [phat, pci] = nbinfit (x2); 538s assert ([pd(2).R, pd(2).P], phat); 538s assert (paramci (pd(2)), pci); 538s ***** test 538s x = normrnd (1, 1, 100, 1); 538s pd = fitdist (x, "normal"); 538s [muhat, sigmahat, muci, sigmaci] = normfit (x); 538s assert ([pd.mu, pd.sigma], [muhat, sigmahat]); 538s assert (paramci (pd), [muci, sigmaci]); 539s ***** test 539s x1 = normrnd (1, 1, 100, 1); 539s x2 = normrnd (5, 2, 100, 1); 539s pd = fitdist ([x1; x2], "normal", "By", [ones(100,1); 2*ones(100,1)]); 539s [muhat, sigmahat, muci, sigmaci] = normfit (x1); 539s assert ([pd(1).mu, pd(1).sigma], [muhat, sigmahat]); 539s assert (paramci (pd(1)), [muci, sigmaci]); 539s [muhat, sigmahat, muci, sigmaci] = normfit (x2); 539s assert ([pd(2).mu, pd(2).sigma], [muhat, sigmahat]); 539s assert (paramci (pd(2)), [muci, sigmaci]); 540s ***** test 540s x = poissrnd (1, 100, 1); 540s pd = fitdist (x, "poisson"); 540s [phat, pci] = poissfit (x); 540s assert (pd.lambda, phat); 540s assert (paramci (pd), pci); 540s ***** test 540s x1 = poissrnd (1, 100, 1); 540s x2 = poissrnd (5, 100, 1); 540s pd = fitdist ([x1; x2], "poisson", "By", [ones(100,1); 2*ones(100,1)]); 540s [phat, pci] = poissfit (x1); 540s assert (pd(1).lambda, phat); 540s assert (paramci (pd(1)), pci); 540s [phat, pci] = poissfit (x2); 540s assert (pd(2).lambda, phat); 540s assert (paramci (pd(2)), pci); 540s ***** test 540s x = raylrnd (1, 100, 1); 540s pd = fitdist (x, "rayleigh"); 540s [phat, pci] = raylfit (x); 540s assert (pd.sigma, phat); 540s assert (paramci (pd), pci); 541s ***** test 541s x1 = raylrnd (1, 100, 1); 541s x2 = raylrnd (5, 100, 1); 541s pd = fitdist ([x1; x2], "rayleigh", "By", [ones(100,1); 2*ones(100,1)]); 541s [phat, pci] = raylfit (x1); 541s assert ( pd(1).sigma, phat); 541s assert (paramci (pd(1)), pci); 541s [phat, pci] = raylfit (x2); 541s assert (pd(2).sigma, phat); 541s assert (paramci (pd(2)), pci); 541s ***** test 541s x = ricernd (1, 1, 100, 1); 541s pd = fitdist (x, "rician"); 541s [phat, pci] = ricefit (x); 541s assert ([pd.s, pd.sigma], phat); 541s assert (paramci (pd), pci); 541s ***** test 541s x1 = ricernd (1, 1, 100, 1); 541s x2 = ricernd (5, 2, 100, 1); 541s pd = fitdist ([x1; x2], "rician", "By", [ones(100,1); 2*ones(100,1)]); 541s [phat, pci] = ricefit (x1); 541s assert ([pd(1).s, pd(1).sigma], phat); 541s assert (paramci (pd(1)), pci); 541s [phat, pci] = ricefit (x2); 541s assert ([pd(2).s, pd(2).sigma], phat); 541s assert (paramci (pd(2)), pci); 542s ***** warning ... 542s fitdist ([1 2 3 4 5], "Stable"); 542s ***** test 542s x = tlsrnd (0, 1, 1, 100, 1); 542s pd = fitdist (x, "tlocationscale"); 542s [phat, pci] = tlsfit (x); 542s assert ([pd.mu, pd.sigma, pd.nu], phat); 542s assert (paramci (pd), pci); 542s ***** test 542s x1 = tlsrnd (0, 1, 1, 100, 1); 542s x2 = tlsrnd (5, 2, 1, 100, 1); 542s pd = fitdist ([x1; x2], "tlocationscale", "By", [ones(100,1); 2*ones(100,1)]); 542s [phat, pci] = tlsfit (x1); 542s assert ([pd(1).mu, pd(1).sigma, pd(1).nu], phat); 542s assert (paramci (pd(1)), pci); 542s [phat, pci] = tlsfit (x2); 542s assert ([pd(2).mu, pd(2).sigma, pd(2).nu], phat); 542s assert (paramci (pd(2)), pci); 543s ***** test 543s x = [1 2 3 4 5]; 543s pd = fitdist (x, "weibull"); 543s [phat, pci] = wblfit (x); 543s assert ([pd.lambda, pd.k], phat); 543s assert (paramci (pd), pci); 543s ***** test 543s x = [1 2 3 4 5 6 7 8 9 10]; 543s pd = fitdist (x, "weibull", "By", [1 1 1 1 1 2 2 2 2 2]); 543s [phat, pci] = wblfit (x(1:5)); 543s assert ([pd(1).lambda, pd(1).k], phat); 543s assert (paramci (pd(1)), pci); 543s [phat, pci] = wblfit (x(6:10)); 543s assert ([pd(2).lambda, pd(2).k], phat); 543s assert (paramci (pd(2)), pci); 543s ***** error fitdist (1) 543s ***** error fitdist (1, ["as";"sd"]) 543s ***** error fitdist (1, "some") 543s ***** error ... 543s fitdist (ones (2), "normal") 543s ***** error ... 543s fitdist ([i, 2, 3], "normal") 543s ***** error ... 543s fitdist (["a", "s", "d"], "normal") 543s ***** error ... 543s fitdist ([1, 2, 3], "normal", "By") 543s ***** error ... 543s fitdist ([1, 2, 3], "normal", "By", [1, 2]) 543s ***** error ... 543s fitdist ([1, 2, 3], "normal", "Censoring", [1, 2]) 543s ***** error ... 543s fitdist ([1, 2, 3], "normal", "frequency", [1, 2]) 543s ***** error ... 543s fitdist ([1, 2, 3], "negativebinomial", "frequency", [1, -2, 3]) 543s ***** error ... 543s fitdist ([1, 2, 3], "normal", "alpha", [1, 2]) 543s ***** error ... 543s fitdist ([1, 2, 3], "normal", "alpha", i) 543s ***** error ... 543s fitdist ([1, 2, 3], "normal", "alpha", -0.5) 543s ***** error ... 543s fitdist ([1, 2, 3], "normal", "alpha", 1.5) 543s ***** error ... 543s fitdist ([1, 2, 3], "normal", "ntrials", [1, 2]) 543s ***** error ... 543s fitdist ([1, 2, 3], "normal", "ntrials", 0) 543s ***** error ... 543s fitdist ([1, 2, 3], "normal", "options", 0) 543s ***** error ... 543s fitdist ([1, 2, 3], "normal", "options", struct ("options", 1)) 543s ***** warning fitdist ([1, 2, 3], "kernel", "kernel", "normal"); 543s ***** warning fitdist ([1, 2, 3], "kernel", "support", "positive"); 543s ***** warning fitdist ([1, 2, 3], "kernel", "width", 1); 543s ***** error ... 543s fitdist ([1, 2, 3], "normal", "param", struct ("options", 1)) 543s ***** error ... 543s [pdca, gn, gl] = fitdist ([1, 2, 3], "normal"); 543s ***** error ... 543s fitdist ([1, 2, 3], "generalizedpareto", "theta", 2); 543s ***** error ... 543s fitdist ([1, 2, 3], "halfnormal", "mu", 2); 543s 77 tests, 77 passed, 0 known failure, 0 skipped 543s [inst/dist_wrap/makedist.m] 543s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_wrap/makedist.m 543s ***** test 543s pd = makedist ("beta"); 543s assert (class (pd), "BetaDistribution"); 543s assert (pd.a, 1); 543s assert (pd.b, 1); 543s ***** test 543s pd = makedist ("beta", "a", 5); 543s assert (pd.a, 5); 543s assert (pd.b, 1); 543s ***** test 543s pd = makedist ("beta", "b", 5); 543s assert (pd.a, 1); 543s assert (pd.b, 5); 543s ***** test 543s pd = makedist ("beta", "a", 3, "b", 5); 543s assert (pd.a, 3); 543s assert (pd.b, 5); 543s ***** test 543s pd = makedist ("binomial"); 543s assert (class (pd), "BinomialDistribution"); 543s assert (pd.N, 1); 543s assert (pd.p, 0.5); 543s ***** test 543s pd = makedist ("binomial", "N", 5); 543s assert (pd.N, 5); 543s assert (pd.p, 0.5); 543s ***** test 543s pd = makedist ("binomial", "p", 0.2); 543s assert (pd.N, 1); 543s assert (pd.p, 0.2); 544s ***** test 544s pd = makedist ("binomial", "N", 3, "p", 0.3); 544s assert (pd.N, 3); 544s assert (pd.p, 0.3); 544s ***** test 544s pd = makedist ("birnbaumsaunders"); 544s assert (class (pd), "BirnbaumSaundersDistribution"); 544s assert (pd.beta, 1); 544s assert (pd.gamma, 1); 544s ***** test 544s pd = makedist ("birnbaumsaunders", "beta", 5); 544s assert (pd.beta, 5); 544s assert (pd.gamma, 1); 544s ***** test 544s pd = makedist ("birnbaumsaunders", "gamma", 5); 544s assert (pd.beta, 1); 544s assert (pd.gamma, 5); 544s ***** test 544s pd = makedist ("birnbaumsaunders", "beta", 3, "gamma", 5); 544s assert (pd.beta, 3); 544s assert (pd.gamma, 5); 544s ***** test 544s pd = makedist ("burr"); 544s assert (class (pd), "BurrDistribution"); 544s assert (pd.alpha, 1); 544s assert (pd.c, 1); 544s assert (pd.k, 1); 544s ***** test 544s pd = makedist ("burr", "k", 5); 544s assert (pd.alpha, 1); 544s assert (pd.c, 1); 544s assert (pd.k, 5); 544s ***** test 544s pd = makedist ("burr", "c", 5); 544s assert (pd.alpha, 1); 544s assert (pd.c, 5); 544s assert (pd.k, 1); 544s ***** test 544s pd = makedist ("burr", "alpha", 3, "c", 5); 544s assert (pd.alpha, 3); 544s assert (pd.c, 5); 544s assert (pd.k, 1); 544s ***** test 544s pd = makedist ("burr", "k", 3, "c", 5); 544s assert (pd.alpha, 1); 544s assert (pd.c, 5); 544s assert (pd.k, 3); 544s ***** test 544s pd = makedist ("exponential"); 544s assert (class (pd), "ExponentialDistribution"); 544s assert (pd.mu, 1); 544s ***** test 544s pd = makedist ("exponential", "mu", 5); 544s assert (pd.mu, 5); 544s ***** test 544s pd = makedist ("extremevalue"); 544s assert (class (pd), "ExtremeValueDistribution"); 544s assert (pd.mu, 0); 544s assert (pd.sigma, 1); 544s ***** test 544s pd = makedist ("extremevalue", "mu", 5); 544s assert (class (pd), "ExtremeValueDistribution"); 544s assert (pd.mu, 5); 544s assert (pd.sigma, 1); 544s ***** test 544s pd = makedist ("ev", "sigma", 5); 544s assert (class (pd), "ExtremeValueDistribution"); 544s assert (pd.mu, 0); 544s assert (pd.sigma, 5); 544s ***** test 544s pd = makedist ("ev", "mu", -3, "sigma", 5); 544s assert (class (pd), "ExtremeValueDistribution"); 544s assert (pd.mu, -3); 544s assert (pd.sigma, 5); 544s ***** test 544s pd = makedist ("gamma"); 544s assert (class (pd), "GammaDistribution"); 544s assert (pd.a, 1); 544s assert (pd.b, 1); 544s ***** test 544s pd = makedist ("gamma", "a", 5); 544s assert (pd.a, 5); 544s assert (pd.b, 1); 544s ***** test 544s pd = makedist ("gamma", "b", 5); 544s assert (pd.a, 1); 544s assert (pd.b, 5); 544s ***** test 544s pd = makedist ("gamma", "a", 3, "b", 5); 544s assert (pd.a, 3); 544s assert (pd.b, 5); 544s ***** test 544s pd = makedist ("GeneralizedExtremeValue"); 544s assert (class (pd), "GeneralizedExtremeValueDistribution"); 544s assert (pd.k, 0); 544s assert (pd.sigma, 1); 544s assert (pd.mu, 0); 544s ***** test 544s pd = makedist ("GeneralizedExtremeValue", "k", 5); 544s assert (pd.k, 5); 544s assert (pd.sigma, 1); 544s assert (pd.mu, 0); 544s ***** test 544s pd = makedist ("GeneralizedExtremeValue", "sigma", 5); 544s assert (pd.k, 0); 544s assert (pd.sigma, 5); 544s assert (pd.mu, 0); 544s ***** test 544s pd = makedist ("GeneralizedExtremeValue", "k", 3, "sigma", 5); 544s assert (pd.k, 3); 544s assert (pd.sigma, 5); 544s assert (pd.mu, 0); 544s ***** test 544s pd = makedist ("GeneralizedExtremeValue", "mu", 3, "sigma", 5); 544s assert (pd.k, 0); 544s assert (pd.sigma, 5); 544s assert (pd.mu, 3); 544s ***** test 544s pd = makedist ("GeneralizedPareto"); 544s assert (class (pd), "GeneralizedParetoDistribution"); 544s assert (pd.k, 1); 544s assert (pd.sigma, 1); 544s assert (pd.theta, 1); 544s ***** test 544s pd = makedist ("GeneralizedPareto", "k", 5); 544s assert (pd.k, 5); 544s assert (pd.sigma, 1); 544s assert (pd.theta, 1); 544s ***** test 544s pd = makedist ("GeneralizedPareto", "sigma", 5); 544s assert (pd.k, 1); 544s assert (pd.sigma, 5); 544s assert (pd.theta, 1); 544s ***** test 544s pd = makedist ("GeneralizedPareto", "k", 3, "sigma", 5); 544s assert (pd.k, 3); 544s assert (pd.sigma, 5); 544s assert (pd.theta, 1); 544s ***** test 544s pd = makedist ("GeneralizedPareto", "theta", 3, "sigma", 5); 544s assert (pd.k, 1); 544s assert (pd.sigma, 5); 544s assert (pd.theta, 3); 544s ***** test 544s pd = makedist ("HalfNormal"); 544s assert (class (pd), "HalfNormalDistribution"); 544s assert (pd.mu, 0); 544s assert (pd.sigma, 1); 544s ***** test 544s pd = makedist ("HalfNormal", "mu", 5); 544s assert (pd.mu, 5); 544s assert (pd.sigma, 1); 544s ***** test 544s pd = makedist ("HalfNormal", "sigma", 5); 544s assert (pd.mu, 0); 544s assert (pd.sigma, 5); 544s ***** test 544s pd = makedist ("HalfNormal", "mu", 3, "sigma", 5); 544s assert (pd.mu, 3); 544s assert (pd.sigma, 5); 544s ***** test 544s pd = makedist ("InverseGaussian"); 544s assert (class (pd), "InverseGaussianDistribution"); 544s assert (pd.mu, 1); 544s assert (pd.lambda, 1); 544s ***** test 544s pd = makedist ("InverseGaussian", "mu", 5); 544s assert (pd.mu, 5); 544s assert (pd.lambda, 1); 544s ***** test 544s pd = makedist ("InverseGaussian", "lambda", 5); 544s assert (pd.mu, 1); 544s assert (pd.lambda, 5); 544s ***** test 544s pd = makedist ("InverseGaussian", "mu", 3, "lambda", 5); 544s assert (pd.mu, 3); 544s assert (pd.lambda, 5); 544s ***** test 544s pd = makedist ("logistic"); 544s assert (class (pd), "LogisticDistribution"); 544s assert (pd.mu, 0); 544s assert (pd.sigma, 1); 544s ***** test 544s pd = makedist ("logistic", "mu", 5); 544s assert (pd.mu, 5); 544s assert (pd.sigma, 1); 544s ***** test 544s pd = makedist ("logistic", "sigma", 5); 544s assert (pd.mu, 0); 544s assert (pd.sigma, 5); 544s ***** test 544s pd = makedist ("logistic", "mu", 3, "sigma", 5); 544s assert (pd.mu, 3); 544s assert (pd.sigma, 5); 544s ***** test 544s pd = makedist ("loglogistic"); 544s assert (class (pd), "LoglogisticDistribution"); 544s assert (pd.mu, 0); 544s assert (pd.sigma, 1); 544s ***** test 544s pd = makedist ("loglogistic", "mu", 5); 544s assert (pd.mu, 5); 544s assert (pd.sigma, 1); 544s ***** test 544s pd = makedist ("loglogistic", "sigma", 5); 544s assert (pd.mu, 0); 544s assert (pd.sigma, 5); 544s ***** test 544s pd = makedist ("loglogistic", "mu", 3, "sigma", 5); 544s assert (pd.mu, 3); 544s assert (pd.sigma, 5); 544s ***** test 544s pd = makedist ("Lognormal"); 544s assert (class (pd), "LognormalDistribution"); 544s assert (pd.mu, 0); 544s assert (pd.sigma, 1); 544s ***** test 544s pd = makedist ("Lognormal", "mu", 5); 544s assert (pd.mu, 5); 544s assert (pd.sigma, 1); 544s ***** test 544s pd = makedist ("Lognormal", "sigma", 5); 544s assert (pd.mu, 0); 544s assert (pd.sigma, 5); 544s ***** test 544s pd = makedist ("Lognormal", "mu", -3, "sigma", 5); 544s assert (pd.mu, -3); 544s assert (pd.sigma, 5); 544s ***** test 544s pd = makedist ("Loguniform"); 544s assert (class (pd), "LoguniformDistribution"); 544s assert (pd.Lower, 1); 544s assert (pd.Upper, 4); 544s ***** test 544s pd = makedist ("Loguniform", "Lower", 2); 544s assert (pd.Lower, 2); 544s assert (pd.Upper, 4); 544s ***** test 544s pd = makedist ("Loguniform", "Lower", 1, "Upper", 3); 544s assert (pd.Lower, 1); 544s assert (pd.Upper, 3); 544s ***** test 544s pd = makedist ("Multinomial"); 544s assert (class (pd), "MultinomialDistribution"); 544s assert (pd.Probabilities, [0.5, 0.5]); 544s ***** test 544s pd = makedist ("Multinomial", "Probabilities", [0.2, 0.3, 0.1, 0.4]); 544s assert (class (pd), "MultinomialDistribution"); 544s assert (pd.Probabilities, [0.2, 0.3, 0.1, 0.4]); 544s ***** test 544s pd = makedist ("Nakagami"); 544s assert (class (pd), "NakagamiDistribution"); 544s assert (pd.mu, 1); 544s assert (pd.omega, 1); 544s ***** test 544s pd = makedist ("Nakagami", "mu", 5); 544s assert (class (pd), "NakagamiDistribution"); 544s assert (pd.mu, 5); 544s assert (pd.omega, 1); 544s ***** test 544s pd = makedist ("Nakagami", "omega", 0.3); 544s assert (class (pd), "NakagamiDistribution"); 544s assert (pd.mu, 1); 544s assert (pd.omega, 0.3); 544s ***** test 544s pd = makedist ("NegativeBinomial"); 544s assert (class (pd), "NegativeBinomialDistribution"); 544s assert (pd.R, 1); 544s assert (pd.P, 0.5); 544s ***** test 544s pd = makedist ("NegativeBinomial", "R", 5); 544s assert (class (pd), "NegativeBinomialDistribution"); 544s assert (pd.R, 5); 544s assert (pd.P, 0.5); 544s ***** test 544s pd = makedist ("NegativeBinomial", "p", 0.3); 544s assert (class (pd), "NegativeBinomialDistribution"); 544s assert (pd.R, 1); 544s assert (pd.P, 0.3); 544s ***** test 544s pd = makedist ("Normal"); 544s assert (class (pd), "NormalDistribution"); 544s assert (pd.mu, 0); 544s assert (pd.sigma, 1); 544s ***** test 544s pd = makedist ("Normal", "mu", 5); 544s assert (class (pd), "NormalDistribution"); 544s assert (pd.mu, 5); 544s assert (pd.sigma, 1); 544s ***** test 544s pd = makedist ("Normal", "sigma", 5); 544s assert (class (pd), "NormalDistribution"); 544s assert (pd.mu, 0); 544s assert (pd.sigma, 5); 544s ***** test 544s pd = makedist ("Normal", "mu", -3, "sigma", 5); 544s assert (class (pd), "NormalDistribution"); 544s assert (pd.mu, -3); 544s assert (pd.sigma, 5); 544s ***** test 544s pd = makedist ("PiecewiseLinear"); 544s assert (class (pd), "PiecewiseLinearDistribution"); 544s assert (pd.x, [0; 1]); 544s assert (pd.Fx, [0; 1]); 544s ***** test 544s pd = makedist ("PiecewiseLinear", "x", [0, 1, 2], "Fx", [0, 0.5, 1]); 544s assert (pd.x, [0; 1; 2]); 544s assert (pd.Fx, [0; 0.5; 1]); 544s ***** test 544s pd = makedist ("Poisson"); 544s assert (class (pd), "PoissonDistribution"); 544s assert (pd.lambda, 1); 544s ***** test 544s pd = makedist ("Poisson", "lambda", 5); 544s assert (pd.lambda, 5); 544s ***** test 544s pd = makedist ("Rayleigh"); 544s assert (class (pd), "RayleighDistribution"); 544s assert (pd.sigma, 1); 544s ***** test 544s pd = makedist ("Rayleigh", "sigma", 5); 544s assert (pd.sigma, 5); 544s ***** test 544s pd = makedist ("Rician"); 544s assert (class (pd), "RicianDistribution"); 544s assert (pd.s, 1); 544s assert (pd.sigma, 1); 544s ***** test 544s pd = makedist ("Rician", "s", 3); 544s assert (pd.s, 3); 544s assert (pd.sigma, 1); 544s ***** test 544s pd = makedist ("Rician", "sigma", 3); 544s assert (pd.s, 1); 544s assert (pd.sigma, 3); 544s ***** test 544s pd = makedist ("Rician", "s", 2, "sigma", 3); 544s assert (pd.s, 2); 544s assert (pd.sigma, 3); 544s ***** warning 544s pd = makedist ("stable"); 544s assert (class (pd), "double"); 544s assert (isempty (pd), true); 544s ***** test 544s pd = makedist ("tlocationscale"); 544s assert (class (pd), "tLocationScaleDistribution"); 544s assert (pd.mu, 0); 544s assert (pd.sigma, 1); 544s assert (pd.nu, 5); 544s ***** test 544s pd = makedist ("tlocationscale", "mu", 5); 544s assert (pd.mu, 5); 544s assert (pd.sigma, 1); 544s assert (pd.nu, 5); 544s ***** test 544s pd = makedist ("tlocationscale", "sigma", 2); 544s assert (pd.mu, 0); 544s assert (pd.sigma, 2); 544s assert (pd.nu, 5); 544s ***** test 544s pd = makedist ("tlocationscale", "mu", 5, "sigma", 2); 544s assert (pd.mu, 5); 544s assert (pd.sigma, 2); 544s assert (pd.nu, 5); 544s ***** test 544s pd = makedist ("tlocationscale", "nu", 1, "sigma", 2); 544s assert (pd.mu, 0); 544s assert (pd.sigma, 2); 544s assert (pd.nu, 1); 544s ***** test 544s pd = makedist ("tlocationscale", "mu", -2, "sigma", 3, "nu", 1); 544s assert (pd.mu, -2); 544s assert (pd.sigma, 3); 544s assert (pd.nu, 1); 544s ***** test 544s pd = makedist ("Triangular"); 544s assert (class (pd), "TriangularDistribution"); 544s assert (pd.A, 0); 544s assert (pd.B, 0.5); 544s assert (pd.C, 1); 544s ***** test 544s pd = makedist ("Triangular", "A", -2); 544s assert (pd.A, -2); 544s assert (pd.B, 0.5); 544s assert (pd.C, 1); 544s ***** test 544s pd = makedist ("Triangular", "A", 0.5, "B", 0.9); 544s assert (pd.A, 0.5); 544s assert (pd.B, 0.9); 544s assert (pd.C, 1); 544s ***** test 544s pd = makedist ("Triangular", "A", 1, "B", 2, "C", 5); 544s assert (pd.A, 1); 544s assert (pd.B, 2); 544s assert (pd.C, 5); 544s ***** test 544s pd = makedist ("Uniform"); 544s assert (class (pd), "UniformDistribution"); 544s assert (pd.Lower, 0); 544s assert (pd.Upper, 1); 544s ***** test 544s pd = makedist ("Uniform", "Lower", -2); 544s assert (pd.Lower, -2); 544s assert (pd.Upper, 1); 544s ***** test 544s pd = makedist ("Uniform", "Lower", 1, "Upper", 3); 544s assert (pd.Lower, 1); 544s assert (pd.Upper, 3); 544s ***** test 544s pd = makedist ("Weibull"); 544s assert (class (pd), "WeibullDistribution"); 544s assert (pd.lambda, 1); 544s assert (pd.k, 1); 544s ***** test 544s pd = makedist ("Weibull", "lambda", 3); 544s assert (pd.lambda, 3); 544s assert (pd.k, 1); 544s ***** test 544s pd = makedist ("Weibull", "lambda", 3, "k", 2); 544s assert (pd.lambda, 3); 544s assert (pd.k, 2); 544s ***** error makedist (1) 544s ***** error makedist (["as";"sd"]) 544s ***** error makedist ("some") 544s ***** error ... 544s makedist ("Beta", "a") 544s ***** error ... 544s makedist ("Beta", "a", 1, "Q", 23) 544s ***** error ... 544s makedist ("Binomial", "N", 1, "Q", 23) 544s ***** error ... 544s makedist ("BirnbaumSaunders", "N", 1) 544s ***** error ... 544s makedist ("Burr", "lambda", 1, "sdfs", 34) 544s ***** error ... 544s makedist ("extremevalue", "mu", 1, "sdfs", 34) 544s ***** error ... 544s makedist ("exponential", "mu", 1, "sdfs", 34) 544s ***** error ... 544s makedist ("Gamma", "k", 1, "sdfs", 34) 544s ***** error ... 544s makedist ("GeneralizedExtremeValue", "k", 1, "sdfs", 34) 544s ***** error ... 544s makedist ("GeneralizedPareto", "k", 1, "sdfs", 34) 544s ***** error ... 544s makedist ("HalfNormal", "k", 1, "sdfs", 34) 544s ***** error ... 544s makedist ("InverseGaussian", "k", 1, "sdfs", 34) 544s ***** error ... 544s makedist ("Logistic", "k", 1, "sdfs", 34) 544s ***** error ... 544s makedist ("Loglogistic", "k", 1, "sdfs", 34) 544s ***** error ... 544s makedist ("Lognormal", "k", 1, "sdfs", 34) 544s ***** error ... 544s makedist ("Loguniform", "k", 1, "sdfs", 34) 544s ***** error ... 544s makedist ("Multinomial", "k", 1, "sdfs", 34) 544s ***** error ... 544s makedist ("Nakagami", "mu", 1, "sdfs", 34) 544s ***** error ... 544s makedist ("NegativeBinomial", "mu", 1, "sdfs", 34) 544s ***** error ... 544s makedist ("Normal", "mu", 1, "sdfs", 34) 544s ***** error ... 544s makedist ("PiecewiseLinear", "mu", 1, "sdfs", 34) 544s ***** error ... 544s makedist ("Poisson", "mu", 1, "sdfs", 34) 544s ***** error ... 544s makedist ("Rayleigh", "mu", 1, "sdfs", 34) 544s ***** error ... 544s makedist ("Rician", "mu", 1, "sdfs", 34) 544s ***** error ... 544s makedist ("Stable", "mu", 1, "sdfs", 34) 544s ***** error ... 544s makedist ("tLocationScale", "mu", 1, "sdfs", 34) 544s ***** error ... 544s makedist ("Triangular", "mu", 1, "sdfs", 34) 544s ***** error ... 544s makedist ("Uniform", "mu", 1, "sdfs", 34) 544s ***** error ... 544s makedist ("Weibull", "mu", 1, "sdfs", 34) 544s 131 tests, 131 passed, 0 known failure, 0 skipped 544s [inst/dist_wrap/pdf.m] 544s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_wrap/pdf.m 544s ***** shared x 544s x = [1:5]; 544s ***** assert (pdf ("Beta", x, 5, 2), betapdf (x, 5, 2)) 544s ***** assert (pdf ("beta", x, 5, 2), betapdf (x, 5, 2)) 544s ***** assert (pdf ("Binomial", x, 5, 2), binopdf (x, 5, 2)) 544s ***** assert (pdf ("bino", x, 5, 2), binopdf (x, 5, 2)) 544s ***** assert (pdf ("Birnbaum-Saunders", x, 5, 2), bisapdf (x, 5, 2)) 544s ***** assert (pdf ("bisa", x, 5, 2), bisapdf (x, 5, 2)) 544s ***** assert (pdf ("Burr", x, 5, 2, 2), burrpdf (x, 5, 2, 2)) 544s ***** assert (pdf ("burr", x, 5, 2, 2), burrpdf (x, 5, 2, 2)) 544s ***** assert (pdf ("Cauchy", x, 5, 2), cauchypdf (x, 5, 2)) 544s ***** assert (pdf ("cauchy", x, 5, 2), cauchypdf (x, 5, 2)) 544s ***** assert (pdf ("Chi-squared", x, 5), chi2pdf (x, 5)) 544s ***** assert (pdf ("chi2", x, 5), chi2pdf (x, 5)) 544s ***** assert (pdf ("Extreme Value", x, 5, 2), evpdf (x, 5, 2)) 544s ***** assert (pdf ("ev", x, 5, 2), evpdf (x, 5, 2)) 544s ***** assert (pdf ("Exponential", x, 5), exppdf (x, 5)) 544s ***** assert (pdf ("exp", x, 5), exppdf (x, 5)) 544s ***** assert (pdf ("F-Distribution", x, 5, 2), fpdf (x, 5, 2)) 544s ***** assert (pdf ("f", x, 5, 2), fpdf (x, 5, 2)) 544s ***** assert (pdf ("Gamma", x, 5, 2), gampdf (x, 5, 2)) 544s ***** assert (pdf ("gam", x, 5, 2), gampdf (x, 5, 2)) 544s ***** assert (pdf ("Geometric", x, 5), geopdf (x, 5)) 544s ***** assert (pdf ("geo", x, 5), geopdf (x, 5)) 544s ***** assert (pdf ("Generalized Extreme Value", x, 5, 2, 2), gevpdf (x, 5, 2, 2)) 544s ***** assert (pdf ("gev", x, 5, 2, 2), gevpdf (x, 5, 2, 2)) 544s ***** assert (pdf ("Generalized Pareto", x, 5, 2, 2), gppdf (x, 5, 2, 2)) 544s ***** assert (pdf ("gp", x, 5, 2, 2), gppdf (x, 5, 2, 2)) 544s ***** assert (pdf ("Gumbel", x, 5, 2), gumbelpdf (x, 5, 2)) 544s ***** assert (pdf ("gumbel", x, 5, 2), gumbelpdf (x, 5, 2)) 545s ***** assert (pdf ("Half-normal", x, 5, 2), hnpdf (x, 5, 2)) 545s ***** assert (pdf ("hn", x, 5, 2), hnpdf (x, 5, 2)) 545s ***** assert (pdf ("Hypergeometric", x, 5, 2, 2), hygepdf (x, 5, 2, 2)) 545s ***** assert (pdf ("hyge", x, 5, 2, 2), hygepdf (x, 5, 2, 2)) 545s ***** assert (pdf ("Inverse Gaussian", x, 5, 2), invgpdf (x, 5, 2)) 545s ***** assert (pdf ("invg", x, 5, 2), invgpdf (x, 5, 2)) 545s ***** assert (pdf ("Laplace", x, 5, 2), laplacepdf (x, 5, 2)) 545s ***** assert (pdf ("laplace", x, 5, 2), laplacepdf (x, 5, 2)) 545s ***** assert (pdf ("Logistic", x, 5, 2), logipdf (x, 5, 2)) 545s ***** assert (pdf ("logi", x, 5, 2), logipdf (x, 5, 2)) 545s ***** assert (pdf ("Log-Logistic", x, 5, 2), loglpdf (x, 5, 2)) 545s ***** assert (pdf ("logl", x, 5, 2), loglpdf (x, 5, 2)) 545s ***** assert (pdf ("Lognormal", x, 5, 2), lognpdf (x, 5, 2)) 545s ***** assert (pdf ("logn", x, 5, 2), lognpdf (x, 5, 2)) 545s ***** assert (pdf ("Nakagami", x, 5, 2), nakapdf (x, 5, 2)) 545s ***** assert (pdf ("naka", x, 5, 2), nakapdf (x, 5, 2)) 545s ***** assert (pdf ("Negative Binomial", x, 5, 2), nbinpdf (x, 5, 2)) 545s ***** assert (pdf ("nbin", x, 5, 2), nbinpdf (x, 5, 2)) 545s ***** assert (pdf ("Noncentral F-Distribution", x, 5, 2, 2), ncfpdf (x, 5, 2, 2)) 545s ***** assert (pdf ("ncf", x, 5, 2, 2), ncfpdf (x, 5, 2, 2)) 545s ***** assert (pdf ("Noncentral Student T", x, 5, 2), nctpdf (x, 5, 2)) 545s ***** assert (pdf ("nct", x, 5, 2), nctpdf (x, 5, 2)) 545s ***** assert (pdf ("Noncentral Chi-Squared", x, 5, 2), ncx2pdf (x, 5, 2)) 545s ***** assert (pdf ("ncx2", x, 5, 2), ncx2pdf (x, 5, 2)) 545s ***** assert (pdf ("Normal", x, 5, 2), normpdf (x, 5, 2)) 545s ***** assert (pdf ("norm", x, 5, 2), normpdf (x, 5, 2)) 545s ***** assert (pdf ("Poisson", x, 5), poisspdf (x, 5)) 545s ***** assert (pdf ("poiss", x, 5), poisspdf (x, 5)) 545s ***** assert (pdf ("Rayleigh", x, 5), raylpdf (x, 5)) 545s ***** assert (pdf ("rayl", x, 5), raylpdf (x, 5)) 545s ***** assert (pdf ("Rician", x, 5, 1), ricepdf (x, 5, 1)) 545s ***** assert (pdf ("rice", x, 5, 1), ricepdf (x, 5, 1)) 545s ***** assert (pdf ("Student T", x, 5), tpdf (x, 5)) 545s ***** assert (pdf ("t", x, 5), tpdf (x, 5)) 545s ***** assert (pdf ("location-scale T", x, 5, 1, 2), tlspdf (x, 5, 1, 2)) 545s ***** assert (pdf ("tls", x, 5, 1, 2), tlspdf (x, 5, 1, 2)) 545s ***** assert (pdf ("Triangular", x, 5, 2, 2), tripdf (x, 5, 2, 2)) 545s ***** assert (pdf ("tri", x, 5, 2, 2), tripdf (x, 5, 2, 2)) 545s ***** assert (pdf ("Discrete Uniform", x, 5), unidpdf (x, 5)) 545s ***** assert (pdf ("unid", x, 5), unidpdf (x, 5)) 545s ***** assert (pdf ("Uniform", x, 5, 2), unifpdf (x, 5, 2)) 545s ***** assert (pdf ("unif", x, 5, 2), unifpdf (x, 5, 2)) 545s ***** assert (pdf ("Von Mises", x, 5, 2), vmpdf (x, 5, 2)) 545s ***** assert (pdf ("vm", x, 5, 2), vmpdf (x, 5, 2)) 545s ***** assert (pdf ("Weibull", x, 5, 2), wblpdf (x, 5, 2)) 545s ***** assert (pdf ("wbl", x, 5, 2), wblpdf (x, 5, 2)) 545s ***** error pdf (1) 545s ***** error pdf ({"beta"}) 545s ***** error pdf ("beta", {[1 2 3 4 5]}) 545s ***** error pdf ("beta", "text") 545s ***** error pdf ("beta", 1+i) 545s ***** error ... 545s pdf ("Beta", x, "a", 2) 545s ***** error ... 545s pdf ("Beta", x, 5, "") 545s ***** error ... 545s pdf ("Beta", x, 5, {2}) 545s ***** error pdf ("chi2", x) 545s ***** error pdf ("Beta", x, 5) 545s ***** error pdf ("Burr", x, 5) 545s ***** error pdf ("Burr", x, 5, 2) 545s 86 tests, 86 passed, 0 known failure, 0 skipped 545s [inst/dist_wrap/cdf.m] 545s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_wrap/cdf.m 545s ***** shared x 545s x = [1:5]; 545s ***** assert (cdf ("Beta", x, 5, 2), betacdf (x, 5, 2)) 545s ***** assert (cdf ("beta", x, 5, 2, "upper"), betacdf (x, 5, 2, "upper")) 545s ***** assert (cdf ("Binomial", x, 5, 2), binocdf (x, 5, 2)) 545s ***** assert (cdf ("bino", x, 5, 2, "upper"), binocdf (x, 5, 2, "upper")) 545s ***** assert (cdf ("Birnbaum-Saunders", x, 5, 2), bisacdf (x, 5, 2)) 545s ***** assert (cdf ("bisa", x, 5, 2, "upper"), bisacdf (x, 5, 2, "upper")) 545s ***** assert (cdf ("Burr", x, 5, 2, 2), burrcdf (x, 5, 2, 2)) 545s ***** assert (cdf ("burr", x, 5, 2, 2, "upper"), burrcdf (x, 5, 2, 2, "upper")) 545s ***** assert (cdf ("Cauchy", x, 5, 2), cauchycdf (x, 5, 2)) 545s ***** assert (cdf ("cauchy", x, 5, 2, "upper"), cauchycdf (x, 5, 2, "upper")) 545s ***** assert (cdf ("Chi-squared", x, 5), chi2cdf (x, 5)) 545s ***** assert (cdf ("chi2", x, 5, "upper"), chi2cdf (x, 5, "upper")) 545s ***** assert (cdf ("Extreme Value", x, 5, 2), evcdf (x, 5, 2)) 545s ***** assert (cdf ("ev", x, 5, 2, "upper"), evcdf (x, 5, 2, "upper")) 545s ***** assert (cdf ("Exponential", x, 5), expcdf (x, 5)) 545s ***** assert (cdf ("exp", x, 5, "upper"), expcdf (x, 5, "upper")) 545s ***** assert (cdf ("F-Distribution", x, 5, 2), fcdf (x, 5, 2)) 545s ***** assert (cdf ("f", x, 5, 2, "upper"), fcdf (x, 5, 2, "upper")) 545s ***** assert (cdf ("Gamma", x, 5, 2), gamcdf (x, 5, 2)) 545s ***** assert (cdf ("gam", x, 5, 2, "upper"), gamcdf (x, 5, 2, "upper")) 545s ***** assert (cdf ("Geometric", x, 5), geocdf (x, 5)) 545s ***** assert (cdf ("geo", x, 5, "upper"), geocdf (x, 5, "upper")) 545s ***** assert (cdf ("Generalized Extreme Value", x, 5, 2, 2), gevcdf (x, 5, 2, 2)) 546s ***** assert (cdf ("gev", x, 5, 2, 2, "upper"), gevcdf (x, 5, 2, 2, "upper")) 546s ***** assert (cdf ("Generalized Pareto", x, 5, 2, 2), gpcdf (x, 5, 2, 2)) 546s ***** assert (cdf ("gp", x, 5, 2, 2, "upper"), gpcdf (x, 5, 2, 2, "upper")) 546s ***** assert (cdf ("Gumbel", x, 5, 2), gumbelcdf (x, 5, 2)) 546s ***** assert (cdf ("gumbel", x, 5, 2, "upper"), gumbelcdf (x, 5, 2, "upper")) 546s ***** assert (cdf ("Half-normal", x, 5, 2), hncdf (x, 5, 2)) 546s ***** assert (cdf ("hn", x, 5, 2, "upper"), hncdf (x, 5, 2, "upper")) 546s ***** assert (cdf ("Hypergeometric", x, 5, 2, 2), hygecdf (x, 5, 2, 2)) 546s ***** assert (cdf ("hyge", x, 5, 2, 2, "upper"), hygecdf (x, 5, 2, 2, "upper")) 546s ***** assert (cdf ("Inverse Gaussian", x, 5, 2), invgcdf (x, 5, 2)) 546s ***** assert (cdf ("invg", x, 5, 2, "upper"), invgcdf (x, 5, 2, "upper")) 546s ***** assert (cdf ("Laplace", x, 5, 2), laplacecdf (x, 5, 2)) 546s ***** assert (cdf ("laplace", x, 5, 2, "upper"), laplacecdf (x, 5, 2, "upper")) 546s ***** assert (cdf ("Logistic", x, 5, 2), logicdf (x, 5, 2)) 546s ***** assert (cdf ("logi", x, 5, 2, "upper"), logicdf (x, 5, 2, "upper")) 546s ***** assert (cdf ("Log-Logistic", x, 5, 2), loglcdf (x, 5, 2)) 546s ***** assert (cdf ("logl", x, 5, 2, "upper"), loglcdf (x, 5, 2, "upper")) 546s ***** assert (cdf ("Lognormal", x, 5, 2), logncdf (x, 5, 2)) 546s ***** assert (cdf ("logn", x, 5, 2, "upper"), logncdf (x, 5, 2, "upper")) 546s ***** assert (cdf ("Nakagami", x, 5, 2), nakacdf (x, 5, 2)) 546s ***** assert (cdf ("naka", x, 5, 2, "upper"), nakacdf (x, 5, 2, "upper")) 546s ***** assert (cdf ("Negative Binomial", x, 5, 2), nbincdf (x, 5, 2)) 546s ***** assert (cdf ("nbin", x, 5, 2, "upper"), nbincdf (x, 5, 2, "upper")) 546s ***** assert (cdf ("Noncentral F-Distribution", x, 5, 2, 2), ncfcdf (x, 5, 2, 2)) 546s ***** assert (cdf ("ncf", x, 5, 2, 2, "upper"), ncfcdf (x, 5, 2, 2, "upper")) 546s ***** assert (cdf ("Noncentral Student T", x, 5, 2), nctcdf (x, 5, 2)) 546s ***** assert (cdf ("nct", x, 5, 2, "upper"), nctcdf (x, 5, 2, "upper")) 546s ***** assert (cdf ("Noncentral Chi-Squared", x, 5, 2), ncx2cdf (x, 5, 2)) 546s ***** assert (cdf ("ncx2", x, 5, 2, "upper"), ncx2cdf (x, 5, 2, "upper")) 546s ***** assert (cdf ("Normal", x, 5, 2), normcdf (x, 5, 2)) 546s ***** assert (cdf ("norm", x, 5, 2, "upper"), normcdf (x, 5, 2, "upper")) 546s ***** assert (cdf ("Poisson", x, 5), poisscdf (x, 5)) 546s ***** assert (cdf ("poiss", x, 5, "upper"), poisscdf (x, 5, "upper")) 546s ***** assert (cdf ("Rayleigh", x, 5), raylcdf (x, 5)) 546s ***** assert (cdf ("rayl", x, 5, "upper"), raylcdf (x, 5, "upper")) 546s ***** assert (cdf ("Rician", x, 5, 1), ricecdf (x, 5, 1)) 546s ***** assert (cdf ("rice", x, 5, 1, "upper"), ricecdf (x, 5, 1, "upper")) 546s ***** assert (cdf ("Student T", x, 5), tcdf (x, 5)) 546s ***** assert (cdf ("t", x, 5, "upper"), tcdf (x, 5, "upper")) 546s ***** assert (cdf ("location-scale T", x, 5, 1, 2), tlscdf (x, 5, 1, 2)) 546s ***** assert (cdf ("tls", x, 5, 1, 2, "upper"), tlscdf (x, 5, 1, 2, "upper")) 546s ***** assert (cdf ("Triangular", x, 5, 2, 2), tricdf (x, 5, 2, 2)) 546s ***** assert (cdf ("tri", x, 5, 2, 2, "upper"), tricdf (x, 5, 2, 2, "upper")) 546s ***** assert (cdf ("Discrete Uniform", x, 5), unidcdf (x, 5)) 546s ***** assert (cdf ("unid", x, 5, "upper"), unidcdf (x, 5, "upper")) 546s ***** assert (cdf ("Uniform", x, 5, 2), unifcdf (x, 5, 2)) 546s ***** assert (cdf ("unif", x, 5, 2, "upper"), unifcdf (x, 5, 2, "upper")) 546s ***** assert (cdf ("Von Mises", x, 5, 2), vmcdf (x, 5, 2)) 546s ***** assert (cdf ("vm", x, 5, 2, "upper"), vmcdf (x, 5, 2, "upper")) 547s ***** assert (cdf ("Weibull", x, 5, 2), wblcdf (x, 5, 2)) 547s ***** assert (cdf ("wbl", x, 5, 2, "upper"), wblcdf (x, 5, 2, "upper")) 547s ***** error cdf (1) 547s ***** error cdf ({"beta"}) 547s ***** error cdf ("beta", {[1 2 3 4 5]}) 547s ***** error cdf ("beta", "text") 547s ***** error cdf ("beta", 1+i) 547s ***** error ... 547s cdf ("Beta", x, "a", 2) 547s ***** error ... 547s cdf ("Beta", x, 5, "") 547s ***** error ... 547s cdf ("Beta", x, 5, {2}) 547s ***** error cdf ("chi2", x) 547s ***** error cdf ("Beta", x, 5) 547s ***** error cdf ("Burr", x, 5) 547s ***** error cdf ("Burr", x, 5, 2) 547s 86 tests, 86 passed, 0 known failure, 0 skipped 547s [inst/dist_wrap/random.m] 547s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_wrap/random.m 547s ***** assert (size (random ("Beta", 5, 2, 2, 10)), size (betarnd (5, 2, 2, 10))) 547s ***** assert (size (random ("beta", 5, 2, 2, 10)), size (betarnd (5, 2, 2, 10))) 547s ***** assert (size (random ("Binomial", 5, 2, [10, 20])), size (binornd (5, 2, 10, 20))) 547s ***** assert (size (random ("bino", 5, 2, [10, 20])), size (binornd (5, 2, 10, 20))) 547s ***** assert (size (random ("Birnbaum-Saunders", 5, 2, [10, 20])), size (bisarnd (5, 2, 10, 20))) 547s ***** assert (size (random ("bisa", 5, 2, [10, 20])), size (bisarnd (5, 2, 10, 20))) 547s ***** assert (size (random ("Burr", 5, 2, 2, [10, 20])), size (burrrnd (5, 2, 2, 10, 20))) 547s ***** assert (size (random ("burr", 5, 2, 2, [10, 20])), size (burrrnd (5, 2, 2, 10, 20))) 547s ***** assert (size (random ("Cauchy", 5, 2, [10, 20])), size (cauchyrnd (5, 2, 10, 20))) 547s ***** assert (size (random ("cauchy", 5, 2, [10, 20])), size (cauchyrnd (5, 2, 10, 20))) 547s ***** assert (size (random ("Chi-squared", 5, [10, 20])), size (chi2rnd (5, 10, 20))) 547s ***** assert (size (random ("chi2", 5, [10, 20])), size (chi2rnd (5, 10, 20))) 547s ***** assert (size (random ("Extreme Value", 5, 2, [10, 20])), size (evrnd (5, 2, 10, 20))) 547s ***** assert (size (random ("ev", 5, 2, [10, 20])), size (evrnd (5, 2, 10, 20))) 547s ***** assert (size (random ("Exponential", 5, [10, 20])), size (exprnd (5, 10, 20))) 547s ***** assert (size (random ("exp", 5, [10, 20])), size (exprnd (5, 10, 20))) 547s ***** assert (size (random ("F-Distribution", 5, 2, [10, 20])), size (frnd (5, 2, 10, 20))) 547s ***** assert (size (random ("f", 5, 2, [10, 20])), size (frnd (5, 2, 10, 20))) 547s ***** assert (size (random ("Gamma", 5, 2, [10, 20])), size (gamrnd (5, 2, 10, 20))) 547s ***** assert (size (random ("gam", 5, 2, [10, 20])), size (gamrnd (5, 2, 10, 20))) 547s ***** assert (size (random ("Geometric", 5, [10, 20])), size (geornd (5, 10, 20))) 547s ***** assert (size (random ("geo", 5, [10, 20])), size (geornd (5, 10, 20))) 547s ***** assert (size (random ("Generalized Extreme Value", 5, 2, 2, [10, 20])), size (gevrnd (5, 2, 2, 10, 20))) 547s ***** assert (size (random ("gev", 5, 2, 2, [10, 20])), size (gevrnd (5, 2, 2, 10, 20))) 547s ***** assert (size (random ("Generalized Pareto", 5, 2, 2, [10, 20])), size (gprnd (5, 2, 2, 10, 20))) 547s ***** assert (size (random ("gp", 5, 2, 2, [10, 20])), size (gprnd (5, 2, 2, 10, 20))) 547s ***** assert (size (random ("Gumbel", 5, 2, [10, 20])), size (gumbelrnd (5, 2, 10, 20))) 547s ***** assert (size (random ("gumbel", 5, 2, [10, 20])), size (gumbelrnd (5, 2, 10, 20))) 547s ***** assert (size (random ("Half-normal", 5, 2, [10, 20])), size (hnrnd (5, 2, 10, 20))) 547s ***** assert (size (random ("hn", 5, 2, [10, 20])), size (hnrnd (5, 2, 10, 20))) 547s ***** assert (size (random ("Hypergeometric", 5, 2, 2, [10, 20])), size (hygernd (5, 2, 2, 10, 20))) 547s ***** assert (size (random ("hyge", 5, 2, 2, [10, 20])), size (hygernd (5, 2, 2, 10, 20))) 547s ***** assert (size (random ("Inverse Gaussian", 5, 2, [10, 20])), size (invgrnd (5, 2, 10, 20))) 547s ***** assert (size (random ("invg", 5, 2, [10, 20])), size (invgrnd (5, 2, 10, 20))) 547s ***** assert (size (random ("Laplace", 5, 2, [10, 20])), size (laplacernd (5, 2, 10, 20))) 547s ***** assert (size (random ("laplace", 5, 2, [10, 20])), size (laplacernd (5, 2, 10, 20))) 547s ***** assert (size (random ("Logistic", 5, 2, [10, 20])), size (logirnd (5, 2, 10, 20))) 547s ***** assert (size (random ("logi", 5, 2, [10, 20])), size (logirnd (5, 2, 10, 20))) 547s ***** assert (size (random ("Log-Logistic", 5, 2, [10, 20])), size (loglrnd (5, 2, 10, 20))) 547s ***** assert (size (random ("logl", 5, 2, [10, 20])), size (loglrnd (5, 2, 10, 20))) 547s ***** assert (size (random ("Lognormal", 5, 2, [10, 20])), size (lognrnd (5, 2, 10, 20))) 547s ***** assert (size (random ("logn", 5, 2, [10, 20])), size (lognrnd (5, 2, 10, 20))) 547s ***** assert (size (random ("Nakagami", 5, 2, [10, 20])), size (nakarnd (5, 2, 10, 20))) 547s ***** assert (size (random ("naka", 5, 2, [10, 20])), size (nakarnd (5, 2, 10, 20))) 547s ***** assert (size (random ("Negative Binomial", 5, 2, [10, 20])), size (nbinrnd (5, 2, 10, 20))) 547s ***** assert (size (random ("nbin", 5, 2, [10, 20])), size (nbinrnd (5, 2, 10, 20))) 547s ***** assert (size (random ("Noncentral F-Distribution", 5, 2, 2, [10, 20])), size (ncfrnd (5, 2, 2, 10, 20))) 547s ***** assert (size (random ("ncf", 5, 2, 2, [10, 20])), size (ncfrnd (5, 2, 2, 10, 20))) 547s ***** assert (size (random ("Noncentral Student T", 5, 2, [10, 20])), size (nctrnd (5, 2, 10, 20))) 547s ***** assert (size (random ("nct", 5, 2, [10, 20])), size (nctrnd (5, 2, 10, 20))) 547s ***** assert (size (random ("Noncentral Chi-Squared", 5, 2, [10, 20])), size (ncx2rnd (5, 2, 10, 20))) 547s ***** assert (size (random ("ncx2", 5, 2, [10, 20])), size (ncx2rnd (5, 2, 10, 20))) 547s ***** assert (size (random ("Normal", 5, 2, [10, 20])), size (normrnd (5, 2, 10, 20))) 547s ***** assert (size (random ("norm", 5, 2, [10, 20])), size (normrnd (5, 2, 10, 20))) 547s ***** assert (size (random ("Poisson", 5, [10, 20])), size (poissrnd (5, 10, 20))) 547s ***** assert (size (random ("poiss", 5, [10, 20])), size (poissrnd (5, 10, 20))) 547s ***** assert (size (random ("Rayleigh", 5, [10, 20])), size (raylrnd (5, 10, 20))) 547s ***** assert (size (random ("rayl", 5, [10, 20])), size (raylrnd (5, 10, 20))) 547s ***** assert (size (random ("Rician", 5, 1, [10, 20])), size (ricernd (5, 1, 10, 20))) 547s ***** assert (size (random ("rice", 5, 1, [10, 20])), size (ricernd (5, 1, 10, 20))) 547s ***** assert (size (random ("Student T", 5, [10, 20])), size (trnd (5, 10, 20))) 547s ***** assert (size (random ("t", 5, [10, 20])), size (trnd (5, 10, 20))) 547s ***** assert (size (random ("location-scale T", 5, 1, 2, [10, 20])), size (tlsrnd (5, 1, 2, 10, 20))) 547s ***** assert (size (random ("tls", 5, 1, 2, [10, 20])), size (tlsrnd (5, 1, 2, 10, 20))) 547s ***** assert (size (random ("Triangular", 5, 2, 2, [10, 20])), size (trirnd (5, 2, 2, 10, 20))) 547s ***** assert (size (random ("tri", 5, 2, 2, [10, 20])), size (trirnd (5, 2, 2, 10, 20))) 547s ***** assert (size (random ("Discrete Uniform", 5, [10, 20])), size (unidrnd (5, 10, 20))) 547s ***** assert (size (random ("unid", 5, [10, 20])), size (unidrnd (5, 10, 20))) 547s ***** assert (size (random ("Uniform", 5, 2, [10, 20])), size (unifrnd (5, 2, 10, 20))) 547s ***** assert (size (random ("unif", 5, 2, [10, 20])), size (unifrnd (5, 2, 10, 20))) 547s ***** assert (size (random ("Von Mises", 5, 2, [10, 20])), size (vmrnd (5, 2, 10, 20))) 547s ***** assert (size (random ("vm", 5, 2, [10, 20])), size (vmrnd (5, 2, 10, 20))) 547s ***** assert (size (random ("Weibull", 5, 2, [10, 20])), size (wblrnd (5, 2, 10, 20))) 547s ***** assert (size (random ("wbl", 5, 2, [10, 20])), size (wblrnd (5, 2, 10, 20))) 547s ***** error random (1) 547s ***** error random ({"beta"}) 547s ***** error ... 547s random ("Beta", "a", 2) 547s ***** error ... 547s random ("Beta", 5, "") 547s ***** error ... 547s random ("Beta", 5, {2}) 547s ***** error ... 547s random ("Beta", "a", 2, 2, 10) 547s ***** error ... 547s random ("Beta", 5, "", 2, 10) 547s ***** error ... 547s random ("Beta", 5, {2}, 2, 10) 547s ***** error ... 547s random ("Beta", 5, "", 2, 10) 547s ***** error random ("chi2") 547s ***** error random ("Beta", 5) 547s ***** error random ("Burr", 5) 547s ***** error random ("Burr", 5, 2) 547s 87 tests, 87 passed, 0 known failure, 0 skipped 547s [inst/dist_wrap/mle.m] 547s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_wrap/mle.m 547s ***** error mle (ones (2)) 547s ***** error mle ("text") 547s ***** error mle ([1, 2, 3, i, 5]) 547s ***** error ... 547s mle ([1:50], "distribution") 547s ***** error ... 547s mle ([1:50], "censoring", logical ([1,0,1,0])) 547s ***** error ... 547s mle ([1:50], "frequency", [1,0,1,0]) 547s ***** error ... 547s mle ([1 0 1 0], "frequency", [-1 1 0 0]) 547s ***** error ... 547s mle ([1 0 1 0], "distribution", "nbin", "frequency", [-1 1 0 0]) 547s ***** error mle ([1:50], "alpha", [0.05, 0.01]) 547s ***** error mle ([1:50], "alpha", 1) 547s ***** error mle ([1:50], "alpha", -1) 547s ***** error mle ([1:50], "alpha", i) 547s ***** error ... 547s mle ([1:50], "ntrials", -1) 547s ***** error ... 547s mle ([1:50], "ntrials", [20, 50]) 547s ***** error ... 547s mle ([1:50], "ntrials", [20.3]) 547s ***** error ... 547s mle ([1:50], "ntrials", 3i) 547s ***** error ... 547s mle ([1:50], "options", 4) 547s ***** error ... 547s mle ([1:50], "options", struct ("x", 3)) 547s ***** error mle ([1:50], "NAME", "value") 547s ***** error ... 547s mle ([1 0 1 0], "distribution", "bernoulli", "censoring", [1 1 0 0]) 547s ***** error ... 547s mle ([1 2 1 0], "distribution", "bernoulli") 547s ***** error ... 547s mle ([1 0 1 0], "distribution", "beta", "censoring", [1 1 0 0]) 547s ***** error ... 547s mle ([1 0 1 0], "distribution", "bino", "censoring", [1 1 0 0]) 547s ***** error ... 547s mle ([1 0 1 0], "distribution", "bino") 547s ***** error ... 547s mle ([1 0 1 0], "distribution", "geo", "censoring", [1 1 0 0]) 547s ***** error ... 547s mle ([1 0 1 0], "distribution", "gev", "censoring", [1 1 0 0]) 547s ***** error ... 547s mle ([1 0 1 0], "distribution", "gp", "censoring", [1 1 0 0]) 547s ***** error ... 547s mle ([1 0 -1 0], "distribution", "gp") 547s ***** error ... 547s mle ([1 0 1 0], "distribution", "hn", "censoring", [1 1 0 0]) 547s ***** error ... 547s mle ([1 0 -1 0], "distribution", "hn") 547s ***** error ... 547s mle ([1 0 1 0], "distribution", "nbin", "censoring", [1 1 0 0]) 547s ***** error ... 547s mle ([1 0 1 0], "distribution", "poisson", "censoring", [1 1 0 0]) 547s ***** error ... 547s mle ([1 0 1 0], "distribution", "unid", "censoring", [1 1 0 0]) 547s ***** error ... 547s mle ([1 0 1 0], "distribution", "unif", "censoring", [1 1 0 0]) 547s ***** error mle ([1:50], "distribution", "value") 547s ***** error ... 547s mle ([1 0 1 0], "distribution", "unif", "censoring", [1 1 0 0]) 547s 36 tests, 36 passed, 0 known failure, 0 skipped 547s [inst/dist_wrap/icdf.m] 547s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_wrap/icdf.m 547s ***** shared p 547s p = [0.05:0.05:0.5]; 547s ***** assert (icdf ("Beta", p, 5, 2), betainv (p, 5, 2)) 547s ***** assert (icdf ("beta", p, 5, 2), betainv (p, 5, 2)) 547s ***** assert (icdf ("Binomial", p, 5, 2), binoinv (p, 5, 2)) 548s ***** assert (icdf ("bino", p, 5, 2), binoinv (p, 5, 2)) 548s ***** assert (icdf ("Birnbaum-Saunders", p, 5, 2), bisainv (p, 5, 2)) 548s ***** assert (icdf ("bisa", p, 5, 2), bisainv (p, 5, 2)) 548s ***** assert (icdf ("Burr", p, 5, 2, 2), burrinv (p, 5, 2, 2)) 548s ***** assert (icdf ("burr", p, 5, 2, 2), burrinv (p, 5, 2, 2)) 548s ***** assert (icdf ("Cauchy", p, 5, 2), cauchyinv (p, 5, 2)) 548s ***** assert (icdf ("cauchy", p, 5, 2), cauchyinv (p, 5, 2)) 548s ***** assert (icdf ("Chi-squared", p, 5), chi2inv (p, 5)) 548s ***** assert (icdf ("chi2", p, 5), chi2inv (p, 5)) 548s ***** assert (icdf ("Extreme Value", p, 5, 2), evinv (p, 5, 2)) 548s ***** assert (icdf ("ev", p, 5, 2), evinv (p, 5, 2)) 548s ***** assert (icdf ("Exponential", p, 5), expinv (p, 5)) 548s ***** assert (icdf ("exp", p, 5), expinv (p, 5)) 548s ***** assert (icdf ("F-Distribution", p, 5, 2), finv (p, 5, 2)) 548s ***** assert (icdf ("f", p, 5, 2), finv (p, 5, 2)) 548s ***** assert (icdf ("Gamma", p, 5, 2), gaminv (p, 5, 2)) 548s ***** assert (icdf ("gam", p, 5, 2), gaminv (p, 5, 2)) 548s ***** assert (icdf ("Geometric", p, 5), geoinv (p, 5)) 548s ***** assert (icdf ("geo", p, 5), geoinv (p, 5)) 548s ***** assert (icdf ("Generalized Extreme Value", p, 5, 2, 2), gevinv (p, 5, 2, 2)) 548s ***** assert (icdf ("gev", p, 5, 2, 2), gevinv (p, 5, 2, 2)) 548s ***** assert (icdf ("Generalized Pareto", p, 5, 2, 2), gpinv (p, 5, 2, 2)) 548s ***** assert (icdf ("gp", p, 5, 2, 2), gpinv (p, 5, 2, 2)) 548s ***** assert (icdf ("Gumbel", p, 5, 2), gumbelinv (p, 5, 2)) 548s ***** assert (icdf ("gumbel", p, 5, 2), gumbelinv (p, 5, 2)) 548s ***** assert (icdf ("Half-normal", p, 5, 2), hninv (p, 5, 2)) 548s ***** assert (icdf ("hn", p, 5, 2), hninv (p, 5, 2)) 548s ***** assert (icdf ("Hypergeometric", p, 5, 2, 2), hygeinv (p, 5, 2, 2)) 548s ***** assert (icdf ("hyge", p, 5, 2, 2), hygeinv (p, 5, 2, 2)) 548s ***** assert (icdf ("Inverse Gaussian", p, 5, 2), invginv (p, 5, 2)) 548s ***** assert (icdf ("invg", p, 5, 2), invginv (p, 5, 2)) 548s ***** assert (icdf ("Laplace", p, 5, 2), laplaceinv (p, 5, 2)) 548s ***** assert (icdf ("laplace", p, 5, 2), laplaceinv (p, 5, 2)) 548s ***** assert (icdf ("Logistic", p, 5, 2), logiinv (p, 5, 2)) 548s ***** assert (icdf ("logi", p, 5, 2), logiinv (p, 5, 2)) 548s ***** assert (icdf ("Log-Logistic", p, 5, 2), loglinv (p, 5, 2)) 548s ***** assert (icdf ("logl", p, 5, 2), loglinv (p, 5, 2)) 548s ***** assert (icdf ("Lognormal", p, 5, 2), logninv (p, 5, 2)) 548s ***** assert (icdf ("logn", p, 5, 2), logninv (p, 5, 2)) 548s ***** assert (icdf ("Nakagami", p, 5, 2), nakainv (p, 5, 2)) 548s ***** assert (icdf ("naka", p, 5, 2), nakainv (p, 5, 2)) 548s ***** assert (icdf ("Negative Binomial", p, 5, 2), nbininv (p, 5, 2)) 548s ***** assert (icdf ("nbin", p, 5, 2), nbininv (p, 5, 2)) 548s ***** assert (icdf ("Noncentral F-Distribution", p, 5, 2, 2), ncfinv (p, 5, 2, 2)) 548s ***** assert (icdf ("ncf", p, 5, 2, 2), ncfinv (p, 5, 2, 2)) 548s ***** assert (icdf ("Noncentral Student T", p, 5, 2), nctinv (p, 5, 2)) 549s ***** assert (icdf ("nct", p, 5, 2), nctinv (p, 5, 2)) 550s ***** assert (icdf ("Noncentral Chi-Squared", p, 5, 2), ncx2inv (p, 5, 2)) 551s ***** assert (icdf ("ncx2", p, 5, 2), ncx2inv (p, 5, 2)) 552s ***** assert (icdf ("Normal", p, 5, 2), norminv (p, 5, 2)) 552s ***** assert (icdf ("norm", p, 5, 2), norminv (p, 5, 2)) 552s ***** assert (icdf ("Poisson", p, 5), poissinv (p, 5)) 552s ***** assert (icdf ("poiss", p, 5), poissinv (p, 5)) 552s ***** assert (icdf ("Rayleigh", p, 5), raylinv (p, 5)) 552s ***** assert (icdf ("rayl", p, 5), raylinv (p, 5)) 552s ***** assert (icdf ("Rician", p, 5, 1), riceinv (p, 5, 1)) 553s ***** assert (icdf ("rice", p, 5, 1), riceinv (p, 5, 1)) 555s ***** assert (icdf ("Student T", p, 5), tinv (p, 5)) 555s ***** assert (icdf ("t", p, 5), tinv (p, 5)) 555s ***** assert (icdf ("location-scale T", p, 5, 1, 2), tlsinv (p, 5, 1, 2)) 555s ***** assert (icdf ("tls", p, 5, 1, 2), tlsinv (p, 5, 1, 2)) 555s ***** assert (icdf ("Triangular", p, 5, 2, 2), triinv (p, 5, 2, 2)) 555s ***** assert (icdf ("tri", p, 5, 2, 2), triinv (p, 5, 2, 2)) 555s ***** assert (icdf ("Discrete Uniform", p, 5), unidinv (p, 5)) 555s ***** assert (icdf ("unid", p, 5), unidinv (p, 5)) 555s ***** assert (icdf ("Uniform", p, 5, 2), unifinv (p, 5, 2)) 555s ***** assert (icdf ("unif", p, 5, 2), unifinv (p, 5, 2)) 555s ***** assert (icdf ("Von Mises", p, 5, 2), vminv (p, 5, 2)) 560s ***** assert (icdf ("vm", p, 5, 2), vminv (p, 5, 2)) 564s ***** assert (icdf ("Weibull", p, 5, 2), wblinv (p, 5, 2)) 564s ***** assert (icdf ("wbl", p, 5, 2), wblinv (p, 5, 2)) 564s ***** error icdf (1) 564s ***** error icdf ({"beta"}) 564s ***** error icdf ("beta", {[1 2 3 4 5]}) 564s ***** error icdf ("beta", "text") 564s ***** error icdf ("beta", 1+i) 564s ***** error ... 564s icdf ("Beta", p, "a", 2) 564s ***** error ... 564s icdf ("Beta", p, 5, "") 564s ***** error ... 564s icdf ("Beta", p, 5, {2}) 564s ***** error icdf ("chi2", p) 564s ***** error icdf ("Beta", p, 5) 564s ***** error icdf ("Burr", p, 5) 564s ***** error icdf ("Burr", p, 5, 2) 564s 86 tests, 86 passed, 0 known failure, 0 skipped 564s [inst/dist_stat/expstat.m] 564s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_stat/expstat.m 564s ***** error expstat () 564s ***** error expstat ({}) 564s ***** error expstat ("") 564s ***** error expstat (i) 564s ***** test 564s mu = 1:6; 564s [m, v] = expstat (mu); 564s assert (m, [1, 2, 3, 4, 5, 6], 0.001); 564s assert (v, [1, 4, 9, 16, 25, 36], 0.001); 564s 5 tests, 5 passed, 0 known failure, 0 skipped 564s [inst/dist_stat/plstat.m] 564s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_stat/plstat.m 564s ***** shared x, Fx 564s x = [0, 1, 3, 4, 7, 10]; 564s Fx = [0, 0.2, 0.5, 0.6, 0.7, 1]; 564s ***** assert (plstat (x, Fx), 4.15) 564s ***** test 564s [m, v] = plstat (x, Fx); 564s assert (v, 10.3775, 1e-14) 564s ***** error plstat () 564s ***** error plstat (1) 564s ***** error ... 564s plstat ([0, 1, 2], [0, 1]) 564s ***** error ... 564s plstat ([0], [1]) 564s ***** error ... 564s plstat ([0, 1, 2], [0, 1, 1.5]) 564s ***** error ... 564s plstat ([0, 1, 2], [0, i, 1]) 565s ***** error ... 565s plstat ([0, i, 2], [0, 0.5, 1]) 565s ***** error ... 565s plstat ([0, i, 2], [0, 0.5i, 1]) 565s 10 tests, 10 passed, 0 known failure, 0 skipped 565s [inst/dist_stat/ncfstat.m] 565s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_stat/ncfstat.m 565s ***** error ncfstat () 565s ***** error ncfstat (1) 565s ***** error ncfstat (1, 2) 565s ***** error ncfstat ({}, 2, 3) 565s ***** error ncfstat (1, "", 3) 565s ***** error ncfstat (1, 2, "") 565s ***** error ncfstat (i, 2, 3) 565s ***** error ncfstat (1, i, 3) 565s ***** error ncfstat (1, 2, i) 565s ***** error ... 565s ncfstat (ones (3), ones (2), 3) 565s ***** error ... 565s ncfstat (ones (2), 2, ones (3)) 565s ***** error ... 565s ncfstat (1, ones (2), ones (3)) 565s ***** shared df1, df2, lambda 565s df1 = [2, 0, -1, 1, 4, 5]; 565s df2 = [2, 4, -1, 5, 6, 7]; 565s lambda = [1, NaN, 3, 0, 2, -1]; 565s ***** assert (ncfstat (df1, df2, lambda), [NaN, NaN, NaN, 1.6667, 2.25, 1.12], 1e-4); 565s ***** assert (ncfstat (df1(4:6), df2(4:6), 1), [3.3333, 1.8750, 1.6800], 1e-4); 565s ***** assert (ncfstat (df1(4:6), df2(4:6), 2), [5.0000, 2.2500, 1.9600], 1e-4); 565s ***** assert (ncfstat (df1(4:6), df2(4:6), 3), [6.6667, 2.6250, 2.2400], 1e-4); 565s ***** assert (ncfstat (2, [df2(1), df2(4:6)], 5), [NaN,5.8333,5.2500,4.9000], 1e-4); 565s ***** assert (ncfstat (0, [df2(1), df2(4:6)], 5), [NaN, Inf, Inf, Inf]); 565s ***** assert (ncfstat (1, [df2(1), df2(4:6)], 5), [NaN, 10, 9, 8.4], 1e-14); 565s ***** assert (ncfstat (4, [df2(1), df2(4:6)], 5), [NaN, 3.75, 3.375, 3.15], 1e-14); 565s 20 tests, 20 passed, 0 known failure, 0 skipped 565s [inst/dist_stat/loglstat.m] 565s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_stat/loglstat.m 565s ***** error loglstat () 565s ***** error loglstat (1) 565s ***** error loglstat ({}, 2) 565s ***** error loglstat (1, "") 565s ***** error loglstat (i, 2) 565s ***** error loglstat (1, i) 565s ***** error ... 565s loglstat (ones (3), ones (2)) 565s ***** error ... 565s loglstat (ones (2), ones (3)) 565s ***** test 565s [m, v] = loglstat (0, 1); 565s assert (m, Inf, 0.001); 565s assert (v, Inf, 0.001); 565s ***** test 565s [m, v] = loglstat (0, 0.8); 565s assert (m, 4.2758, 0.001); 565s assert (v, Inf, 0.001); 565s ***** test 565s [m, v] = loglstat (0, 0.6); 565s assert (m, 1.9820, 0.001); 565s assert (v, Inf, 0.001); 565s ***** test 565s [m, v] = loglstat (0, 0.4); 565s assert (m, 1.3213, 0.001); 565s assert (v, 2.5300, 0.001); 565s ***** test 565s [m, v] = loglstat (0, 0.2); 565s assert (m, 1.0690, 0.001); 565s assert (v, 0.1786, 0.001); 565s 13 tests, 13 passed, 0 known failure, 0 skipped 565s [inst/dist_stat/lognstat.m] 565s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_stat/lognstat.m 565s ***** error lognstat () 565s ***** error lognstat (1) 565s ***** error lognstat ({}, 2) 565s ***** error lognstat (1, "") 565s ***** error lognstat (i, 2) 565s ***** error lognstat (1, i) 565s ***** error ... 565s lognstat (ones (3), ones (2)) 565s ***** error ... 565s lognstat (ones (2), ones (3)) 565s ***** test 565s mu = 0:0.2:1; 565s sigma = 0.2:0.2:1.2; 565s [m, v] = lognstat (mu, sigma); 565s expected_m = [1.0202, 1.3231, 1.7860, 2.5093, 3.6693, 5.5845]; 565s expected_v = [0.0425, 0.3038, 1.3823, 5.6447, 23.1345, 100.4437]; 565s assert (m, expected_m, 0.001); 565s assert (v, expected_v, 0.001); 565s ***** test 565s sigma = 0.2:0.2:1.2; 565s [m, v] = lognstat (0, sigma); 565s expected_m = [1.0202, 1.0833, 1.1972, 1.3771, 1.6487, 2.0544]; 565s expected_v = [0.0425, 0.2036, 0.6211, 1.7002, 4.6708, 13.5936]; 565s assert (m, expected_m, 0.001); 565s assert (v, expected_v, 0.001); 565s 10 tests, 10 passed, 0 known failure, 0 skipped 565s [inst/dist_stat/binostat.m] 565s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_stat/binostat.m 565s ***** error binostat () 565s ***** error binostat (1) 565s ***** error binostat ({}, 2) 565s ***** error binostat (1, "") 565s ***** error binostat (i, 2) 565s ***** error binostat (1, i) 565s ***** error ... 565s binostat (ones (3), ones (2)) 565s ***** error ... 565s binostat (ones (2), ones (3)) 565s ***** test 565s n = 1:6; 565s ps = 0:0.2:1; 565s [m, v] = binostat (n, ps); 565s expected_m = [0.00, 0.40, 1.20, 2.40, 4.00, 6.00]; 565s expected_v = [0.00, 0.32, 0.72, 0.96, 0.80, 0.00]; 565s assert (m, expected_m, 0.001); 565s assert (v, expected_v, 0.001); 565s ***** test 565s n = 1:6; 565s [m, v] = binostat (n, 0.5); 565s expected_m = [0.50, 1.00, 1.50, 2.00, 2.50, 3.00]; 565s expected_v = [0.25, 0.50, 0.75, 1.00, 1.25, 1.50]; 565s assert (m, expected_m, 0.001); 565s assert (v, expected_v, 0.001); 565s ***** test 565s n = [-Inf -3 5 0.5 3 NaN 100, Inf]; 565s [m, v] = binostat (n, 0.5); 565s assert (isnan (m), [true true false true false true false false]) 565s assert (isnan (v), [true true false true false true false false]) 565s assert (m(end), Inf); 565s assert (v(end), Inf); 565s ***** assert (nthargout (1:2, @binostat, 5, []), {[], []}) 565s ***** assert (nthargout (1:2, @binostat, [], 5), {[], []}) 565s ***** assert (size (binostat (randi (100, 10, 5, 4), rand (10, 5, 4))), [10 5 4]) 565s ***** assert (size (binostat (randi (100, 10, 5, 4), 7)), [10 5 4]) 565s 15 tests, 15 passed, 0 known failure, 0 skipped 565s [inst/dist_stat/logistat.m] 565s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_stat/logistat.m 565s ***** error logistat () 565s ***** error logistat (1) 565s ***** error logistat ({}, 2) 565s ***** error logistat (1, "") 565s ***** error logistat (i, 2) 565s ***** error logistat (1, i) 565s ***** error ... 565s logistat (ones (3), ones (2)) 565s ***** error ... 565s logistat (ones (2), ones (3)) 565s ***** test 565s [m, v] = logistat (0, 1); 565s assert (m, 0); 565s assert (v, 3.2899, 0.001); 565s ***** test 565s [m, v] = logistat (0, 0.8); 565s assert (m, 0); 565s assert (v, 2.1055, 0.001); 565s ***** test 565s [m, v] = logistat (1, 0.6); 565s assert (m, 1); 565s assert (v, 1.1844, 0.001); 565s ***** test 565s [m, v] = logistat (0, 0.4); 565s assert (m, 0); 565s assert (v, 0.5264, 0.001); 565s ***** test 565s [m, v] = logistat (-1, 0.2); 565s assert (m, -1); 565s assert (v, 0.1316, 0.001); 565s 13 tests, 13 passed, 0 known failure, 0 skipped 565s [inst/dist_stat/normstat.m] 565s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_stat/normstat.m 565s ***** error normstat () 565s ***** error normstat (1) 565s ***** error normstat ({}, 2) 565s ***** error normstat (1, "") 565s ***** error normstat (i, 2) 565s ***** error normstat (1, i) 565s ***** error ... 565s normstat (ones (3), ones (2)) 565s ***** error ... 565s normstat (ones (2), ones (3)) 565s ***** test 565s mu = 1:6; 565s sigma = 0.2:0.2:1.2; 565s [m, v] = normstat (mu, sigma); 565s expected_v = [0.0400, 0.1600, 0.3600, 0.6400, 1.0000, 1.4400]; 565s assert (m, mu); 565s assert (v, expected_v, 0.001); 565s ***** test 565s sigma = 0.2:0.2:1.2; 565s [m, v] = normstat (0, sigma); 565s expected_mn = [0, 0, 0, 0, 0, 0]; 565s expected_v = [0.0400, 0.1600, 0.3600, 0.6400, 1.0000, 1.4400]; 565s assert (m, expected_mn, 0.001); 565s assert (v, expected_v, 0.001); 565s 10 tests, 10 passed, 0 known failure, 0 skipped 565s [inst/dist_stat/hnstat.m] 565s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_stat/hnstat.m 565s ***** error hnstat () 565s ***** error hnstat (1) 565s ***** error hnstat ({}, 2) 565s ***** error hnstat (1, "") 565s ***** error hnstat (i, 2) 565s ***** error hnstat (1, i) 565s ***** error ... 565s hnstat (ones (3), ones (2)) 565s ***** error ... 565s hnstat (ones (2), ones (3)) 565s ***** test 565s [m, v] = hnstat (0, 1); 565s assert (m, 0.7979, 1e-4); 565s assert (v, 0.3634, 1e-4); 565s ***** test 565s [m, v] = hnstat (2, 1); 565s assert (m, 2.7979, 1e-4); 565s assert (v, 0.3634, 1e-4); 565s ***** test 565s [m, v] = hnstat (2, 2); 565s assert (m, 3.5958, 1e-4); 565s assert (v, 1.4535, 1e-4); 565s ***** test 565s [m, v] = hnstat (2, 2.5); 565s assert (m, 3.9947, 1e-4); 565s assert (v, 2.2711, 1e-4); 565s ***** test 565s [m, v] = hnstat (1.5, 0.5); 565s assert (m, 1.8989, 1e-4); 565s assert (v, 0.0908, 1e-4); 565s ***** test 565s [m, v] = hnstat (-1.5, 0.5); 565s assert (m, -1.1011, 1e-4); 565s assert (v, 0.0908, 1e-4); 565s 14 tests, 14 passed, 0 known failure, 0 skipped 565s [inst/dist_stat/burrstat.m] 565s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_stat/burrstat.m 565s ***** error burrstat () 565s ***** error burrstat (1) 565s ***** error burrstat (1, 2) 565s ***** error burrstat ({}, 2, 3) 565s ***** error burrstat (1, "", 3) 565s ***** error burrstat (1, 2, "") 565s ***** error burrstat (i, 2, 3) 565s ***** error burrstat (1, i, 3) 565s ***** error burrstat (1, 2, i) 565s ***** error ... 565s burrstat (ones (3), ones (2), 3) 565s ***** error ... 565s burrstat (ones (2), 2, ones (3)) 565s ***** error ... 565s burrstat (1, ones (2), ones (3)) 565s ***** test 565s [m, v] = burrstat (1, 2, 5); 565s assert (m, 0.4295, 1e-4); 565s assert (v, 0.0655, 1e-4); 565s ***** test 565s [m, v] = burrstat (1, 1, 1); 565s assert (m, Inf); 565s assert (v, Inf); 565s ***** test 565s [m, v] = burrstat (2, 4, 1); 565s assert (m, 2.2214, 1e-4); 565s assert (v, 1.3484, 1e-4); 565s 15 tests, 15 passed, 0 known failure, 0 skipped 565s [inst/dist_stat/fstat.m] 565s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_stat/fstat.m 565s ***** error fstat () 565s ***** error fstat (1) 565s ***** error fstat ({}, 2) 565s ***** error fstat (1, "") 565s ***** error fstat (i, 2) 565s ***** error fstat (1, i) 565s ***** error ... 565s fstat (ones (3), ones (2)) 565s ***** error ... 565s fstat (ones (2), ones (3)) 565s ***** test 565s df1 = 1:6; 565s df2 = 5:10; 565s [m, v] = fstat (df1, df2); 565s expected_mn = [1.6667, 1.5000, 1.4000, 1.3333, 1.2857, 1.2500]; 565s expected_v = [22.2222, 6.7500, 3.4844, 2.2222, 1.5869, 1.2153]; 565s assert (m, expected_mn, 0.001); 565s assert (v, expected_v, 0.001); 565s ***** test 565s df1 = 1:6; 565s [m, v] = fstat (df1, 5); 565s expected_mn = [1.6667, 1.6667, 1.6667, 1.6667, 1.6667, 1.6667]; 565s expected_v = [22.2222, 13.8889, 11.1111, 9.7222, 8.8889, 8.3333]; 565s assert (m, expected_mn, 0.001); 565s assert (v, expected_v, 0.001); 565s 10 tests, 10 passed, 0 known failure, 0 skipped 565s [inst/dist_stat/gevstat.m] 565s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_stat/gevstat.m 565s ***** error gevstat () 565s ***** error gevstat (1) 565s ***** error gevstat (1, 2) 565s ***** error gevstat ({}, 2, 3) 565s ***** error gevstat (1, "", 3) 565s ***** error gevstat (1, 2, "") 565s ***** error gevstat (i, 2, 3) 565s ***** error gevstat (1, i, 3) 565s ***** error gevstat (1, 2, i) 565s ***** error ... 565s gevstat (ones (3), ones (2), 3) 565s ***** error ... 565s gevstat (ones (2), 2, ones (3)) 565s ***** error ... 565s gevstat (1, ones (2), ones (3)) 565s ***** test 565s k = [-1, -0.5, 0, 0.2, 0.4, 0.5, 1]; 565s sigma = 2; 565s mu = 1; 565s [m, v] = gevstat (k, sigma, mu); 565s expected_m = [1, 1.4551, 2.1544, 2.6423, 3.4460, 4.0898, Inf]; 565s expected_v = [4, 3.4336, 6.5797, 13.3761, 59.3288, Inf, Inf]; 565s assert (m, expected_m, -0.001); 565s assert (v, expected_v, -0.001); 565s 13 tests, 13 passed, 0 known failure, 0 skipped 565s [inst/dist_stat/poisstat.m] 565s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_stat/poisstat.m 565s ***** error poisstat () 565s ***** error poisstat ({}) 565s ***** error poisstat ("") 565s ***** error poisstat (i) 565s ***** test 565s lambda = 1 ./ (1:6); 565s [m, v] = poisstat (lambda); 565s assert (m, lambda); 565s assert (v, lambda); 565s 5 tests, 5 passed, 0 known failure, 0 skipped 565s [inst/dist_stat/tstat.m] 565s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_stat/tstat.m 565s ***** error tstat () 565s ***** error tstat ({}) 565s ***** error tstat ("") 565s ***** error tstat (i) 565s ***** test 565s df = 3:8; 565s [m, v] = tstat (df); 565s expected_m = [0, 0, 0, 0, 0, 0]; 565s expected_v = [3.0000, 2.0000, 1.6667, 1.5000, 1.4000, 1.3333]; 565s assert (m, expected_m); 565s assert (v, expected_v, 0.001); 565s 5 tests, 5 passed, 0 known failure, 0 skipped 565s [inst/dist_stat/ncx2stat.m] 565s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_stat/ncx2stat.m 565s ***** error ncx2stat () 565s ***** error ncx2stat (1) 565s ***** error ncx2stat ({}, 2) 565s ***** error ncx2stat (1, "") 565s ***** error ncx2stat (i, 2) 565s ***** error ncx2stat (1, i) 565s ***** error ... 565s ncx2stat (ones (3), ones (2)) 565s ***** error ... 565s ncx2stat (ones (2), ones (3)) 565s ***** shared df, d1 565s df = [2, 0, -1, 1, 4]; 565s d1 = [1, NaN, 3, -1, 2]; 565s ***** assert (ncx2stat (df, d1), [3, NaN, NaN, NaN, 6]); 565s ***** assert (ncx2stat ([df(1:2), df(4:5)], 1), [3, NaN, 2, 5]); 565s ***** assert (ncx2stat ([df(1:2), df(4:5)], 3), [5, NaN, 4, 7]); 565s ***** assert (ncx2stat ([df(1:2), df(4:5)], 2), [4, NaN, 3, 6]); 565s ***** assert (ncx2stat (2, [d1(1), d1(3:5)]), [3, 5, NaN, 4]); 565s ***** assert (ncx2stat (0, [d1(1), d1(3:5)]), [NaN, NaN, NaN, NaN]); 565s ***** assert (ncx2stat (1, [d1(1), d1(3:5)]), [2, 4, NaN, 3]); 565s ***** assert (ncx2stat (4, [d1(1), d1(3:5)]), [5, 7, NaN, 6]); 565s 16 tests, 16 passed, 0 known failure, 0 skipped 565s [inst/dist_stat/ricestat.m] 565s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_stat/ricestat.m 565s ***** error ricestat () 565s ***** error ricestat (1) 565s ***** error ricestat ({}, 2) 565s ***** error ricestat (1, "") 565s ***** error ricestat (i, 2) 565s ***** error ricestat (1, i) 565s ***** error ... 565s ricestat (ones (3), ones (2)) 565s ***** error ... 565s ricestat (ones (2), ones (3)) 565s ***** shared s, sigma 565s s = [2, 0, -1, 1, 4]; 565s sigma = [1, NaN, 3, -1, 2]; 565s ***** assert (ricestat (s, sigma), [2.2724, NaN, NaN, NaN, 4.5448], 1e-4); 565s ***** assert (ricestat ([s(1:2), s(4:5)], 1), [2.2724, 1.2533, 1.5486, 4.1272], 1e-4); 565s ***** assert (ricestat ([s(1:2), s(4:5)], 3), [4.1665, 3.7599, 3.8637, 5.2695], 1e-4); 565s ***** assert (ricestat ([s(1:2), s(4:5)], 2), [3.0971, 2.5066, 2.6609, 4.5448], 1e-4); 565s ***** assert (ricestat (2, [sigma(1), sigma(3:5)]), [2.2724, 4.1665, NaN, 3.0971], 1e-4); 565s ***** assert (ricestat (0, [sigma(1), sigma(3:5)]), [1.2533, 3.7599, NaN, 2.5066], 1e-4); 565s ***** assert (ricestat (1, [sigma(1), sigma(3:5)]), [1.5486, 3.8637, NaN, 2.6609], 1e-4); 565s ***** assert (ricestat (4, [sigma(1), sigma(3:5)]), [4.1272, 5.2695, NaN, 4.5448], 1e-4); 565s 16 tests, 16 passed, 0 known failure, 0 skipped 565s [inst/dist_stat/gpstat.m] 565s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_stat/gpstat.m 565s ***** error gpstat () 565s ***** error gpstat (1) 565s ***** error gpstat (1, 2) 565s ***** error gpstat ({}, 2, 3) 565s ***** error gpstat (1, "", 3) 565s ***** error gpstat (1, 2, "") 565s ***** error gpstat (i, 2, 3) 565s ***** error gpstat (1, i, 3) 565s ***** error gpstat (1, 2, i) 565s ***** error ... 565s gpstat (ones (3), ones (2), 3) 565s ***** error ... 565s gpstat (ones (2), 2, ones (3)) 565s ***** error ... 565s gpstat (1, ones (2), ones (3)) 565s ***** shared x, y 565s x = [-Inf, -1, 0, 1/2, 1, Inf]; 565s y = [0, 0.5, 1, 2, Inf, Inf]; 565s ***** assert (gpstat (x, ones (1,6), zeros (1,6)), y, eps) 565s ***** assert (gpstat (single (x), 1, 0), single (y), eps("single")) 565s ***** assert (gpstat (x, single (1), 0), single (y), eps("single")) 565s ***** assert (gpstat (x, 1, single (0)), single (y), eps("single")) 565s ***** assert (gpstat (single ([x, NaN]), 1, 0), single ([y, NaN]), eps("single")) 565s ***** assert (gpstat ([x, NaN], single (1), 0), single ([y, NaN]), eps("single")) 565s ***** assert (gpstat ([x, NaN], 1, single (0)), single ([y, NaN]), eps("single")) 565s 19 tests, 19 passed, 0 known failure, 0 skipped 565s [inst/dist_stat/nbinstat.m] 565s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_stat/nbinstat.m 565s ***** error nbinstat () 565s ***** error nbinstat (1) 565s ***** error nbinstat ({}, 2) 565s ***** error nbinstat (1, "") 565s ***** error nbinstat (i, 2) 565s ***** error nbinstat (1, i) 565s ***** error ... 565s nbinstat (ones (3), ones (2)) 565s ***** error ... 565s nbinstat (ones (2), ones (3)) 565s ***** test 565s r = 1:4; 565s ps = 0.2:0.2:0.8; 565s [m, v] = nbinstat (r, ps); 565s expected_m = [ 4.0000, 3.0000, 2.0000, 1.0000]; 565s expected_v = [20.0000, 7.5000, 3.3333, 1.2500]; 565s assert (m, expected_m, 0.001); 565s assert (v, expected_v, 0.001); 565s ***** test 565s r = 1:4; 565s [m, v] = nbinstat (r, 0.5); 565s expected_m = [1, 2, 3, 4]; 565s expected_v = [2, 4, 6, 8]; 565s assert (m, expected_m, 0.001); 565s assert (v, expected_v, 0.001); 565s 10 tests, 10 passed, 0 known failure, 0 skipped 565s [inst/dist_stat/unidstat.m] 565s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_stat/unidstat.m 565s ***** error unidstat () 565s ***** error unidstat ({}) 565s ***** error unidstat ("") 565s ***** error unidstat (i) 565s ***** test 565s N = 1:6; 565s [m, v] = unidstat (N); 565s expected_m = [1.0000, 1.5000, 2.0000, 2.5000, 3.0000, 3.5000]; 565s expected_v = [0.0000, 0.2500, 0.6667, 1.2500, 2.0000, 2.9167]; 565s assert (m, expected_m, 0.001); 565s assert (v, expected_v, 0.001); 565s 5 tests, 5 passed, 0 known failure, 0 skipped 565s [inst/dist_stat/invgstat.m] 565s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_stat/invgstat.m 565s ***** error invgstat () 565s ***** error invgstat (1) 565s ***** error invgstat ({}, 2) 565s ***** error invgstat (1, "") 565s ***** error invgstat (i, 2) 565s ***** error invgstat (1, i) 565s ***** error ... 565s invgstat (ones (3), ones (2)) 565s ***** error ... 565s invgstat (ones (2), ones (3)) 565s ***** test 565s [m, v] = invgstat (1, 1); 565s assert (m, 1); 565s assert (v, 1); 565s ***** test 565s [m, v] = invgstat (2, 1); 565s assert (m, 2); 565s assert (v, 8); 565s ***** test 565s [m, v] = invgstat (2, 2); 565s assert (m, 2); 565s assert (v, 4); 565s ***** test 565s [m, v] = invgstat (2, 2.5); 565s assert (m, 2); 565s assert (v, 3.2); 565s ***** test 565s [m, v] = invgstat (1.5, 0.5); 565s assert (m, 1.5); 565s assert (v, 6.75); 565s 13 tests, 13 passed, 0 known failure, 0 skipped 565s [inst/dist_stat/gamstat.m] 565s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_stat/gamstat.m 565s ***** error gamstat () 565s ***** error gamstat (1) 565s ***** error gamstat ({}, 2) 565s ***** error gamstat (1, "") 566s ***** error gamstat (i, 2) 566s ***** error gamstat (1, i) 566s ***** error ... 566s gamstat (ones (3), ones (2)) 566s ***** error ... 566s gamstat (ones (2), ones (3)) 566s ***** test 566s a = 1:6; 566s b = 1:0.2:2; 566s [m, v] = gamstat (a, b); 566s expected_m = [1.00, 2.40, 4.20, 6.40, 9.00, 12.00]; 566s expected_v = [1.00, 2.88, 5.88, 10.24, 16.20, 24.00]; 566s assert (m, expected_m, 0.001); 566s assert (v, expected_v, 0.001); 566s ***** test 566s a = 1:6; 566s [m, v] = gamstat (a, 1.5); 566s expected_m = [1.50, 3.00, 4.50, 6.00, 7.50, 9.00]; 566s expected_v = [2.25, 4.50, 6.75, 9.00, 11.25, 13.50]; 566s assert (m, expected_m, 0.001); 566s assert (v, expected_v, 0.001); 566s 10 tests, 10 passed, 0 known failure, 0 skipped 566s [inst/dist_stat/raylstat.m] 566s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_stat/raylstat.m 566s ***** error raylstat () 566s ***** error raylstat ({}) 566s ***** error raylstat ("") 566s ***** error raylstat (i) 566s ***** test 566s sigma = 1:6; 566s [m, v] = raylstat (sigma); 566s expected_m = [1.2533, 2.5066, 3.7599, 5.0133, 6.2666, 7.5199]; 566s expected_v = [0.4292, 1.7168, 3.8628, 6.8673, 10.7301, 15.4513]; 566s assert (m, expected_m, 0.001); 566s assert (v, expected_v, 0.001); 566s 5 tests, 5 passed, 0 known failure, 0 skipped 566s [inst/dist_stat/chi2stat.m] 566s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_stat/chi2stat.m 566s ***** error chi2stat () 566s ***** error chi2stat ({}) 566s ***** error chi2stat ("") 566s ***** error chi2stat (i) 566s ***** test 566s df = 1:6; 566s [m, v] = chi2stat (df); 566s assert (m, df); 566s assert (v, [2, 4, 6, 8, 10, 12], 0.001); 566s 5 tests, 5 passed, 0 known failure, 0 skipped 566s [inst/dist_stat/tlsstat.m] 566s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_stat/tlsstat.m 566s ***** error tlsstat () 566s ***** error tlsstat (1) 566s ***** error tlsstat (1, 2) 566s ***** error tlsstat ({}, 2, 3) 566s ***** error tlsstat (1, "", 3) 566s ***** error tlsstat (1, 2, ["d"]) 566s ***** error tlsstat (i, 2, 3) 566s ***** error tlsstat (1, i, 3) 566s ***** error tlsstat (1, 2, i) 566s ***** error ... 566s tlsstat (ones (3), ones (2), 1) 566s ***** error ... 566s tlsstat (ones (2), 1, ones (3)) 566s ***** error ... 566s tlsstat (1, ones (2), ones (3)) 566s ***** test 566s [m, v] = tlsstat (0, 1, 0); 566s assert (m, NaN); 566s assert (v, NaN); 566s ***** test 566s [m, v] = tlsstat (0, 1, 1); 566s assert (m, NaN); 566s assert (v, NaN); 566s ***** test 566s [m, v] = tlsstat (2, 1, 1); 566s assert (m, NaN); 566s assert (v, NaN); 566s ***** test 566s [m, v] = tlsstat (-2, 1, 1); 566s assert (m, NaN); 566s assert (v, NaN); 566s ***** test 566s [m, v] = tlsstat (0, 1, 2); 566s assert (m, 0); 566s assert (v, NaN); 566s ***** test 566s [m, v] = tlsstat (2, 1, 2); 566s assert (m, 2); 566s assert (v, NaN); 566s ***** test 566s [m, v] = tlsstat (-2, 1, 2); 566s assert (m, -2); 566s assert (v, NaN); 566s ***** test 566s [m, v] = tlsstat (0, 2, 2); 566s assert (m, 0); 566s assert (v, NaN); 566s ***** test 566s [m, v] = tlsstat (2, 2, 2); 566s assert (m, 2); 566s assert (v, NaN); 566s ***** test 566s [m, v] = tlsstat (-2, 2, 2); 566s assert (m, -2); 566s assert (v, NaN); 566s ***** test 566s [m, v] = tlsstat (0, 1, 3); 566s assert (m, 0); 566s assert (v, 3); 566s ***** test 566s [m, v] = tlsstat (0, 2, 3); 566s assert (m, 0); 566s assert (v, 6); 566s ***** test 566s [m, v] = tlsstat (2, 1, 3); 566s assert (m, 2); 566s assert (v, 3); 566s ***** test 566s [m, v] = tlsstat (2, 2, 3); 566s assert (m, 2); 566s assert (v, 6); 566s ***** test 566s [m, v] = tlsstat (-2, 1, 3); 566s assert (m, -2); 566s assert (v, 3); 566s ***** test 566s [m, v] = tlsstat (-2, 2, 3); 566s assert (m, -2); 566s assert (v, 6); 566s 28 tests, 28 passed, 0 known failure, 0 skipped 566s [inst/dist_stat/hygestat.m] 566s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_stat/hygestat.m 566s ***** error hygestat () 566s ***** error hygestat (1) 566s ***** error hygestat (1, 2) 566s ***** error hygestat ({}, 2, 3) 566s ***** error hygestat (1, "", 3) 566s ***** error hygestat (1, 2, "") 566s ***** error hygestat (i, 2, 3) 566s ***** error hygestat (1, i, 3) 566s ***** error hygestat (1, 2, i) 566s ***** error ... 566s hygestat (ones (3), ones (2), 3) 566s ***** error ... 566s hygestat (ones (2), 2, ones (3)) 566s ***** error ... 566s hygestat (1, ones (2), ones (3)) 566s ***** test 566s m = 4:9; 566s k = 0:5; 566s n = 1:6; 566s [mn, v] = hygestat (m, k, n); 566s expected_mn = [0.0000, 0.4000, 1.0000, 1.7143, 2.5000, 3.3333]; 566s expected_v = [0.0000, 0.2400, 0.4000, 0.4898, 0.5357, 0.5556]; 566s assert (mn, expected_mn, 0.001); 566s assert (v, expected_v, 0.001); 566s ***** test 566s m = 4:9; 566s k = 0:5; 566s [mn, v] = hygestat (m, k, 2); 566s expected_mn = [0.0000, 0.4000, 0.6667, 0.8571, 1.0000, 1.1111]; 566s expected_v = [0.0000, 0.2400, 0.3556, 0.4082, 0.4286, 0.4321]; 566s assert (mn, expected_mn, 0.001); 566s assert (v, expected_v, 0.001); 566s 14 tests, 14 passed, 0 known failure, 0 skipped 566s [inst/dist_stat/wblstat.m] 566s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_stat/wblstat.m 566s ***** error wblstat () 566s ***** error wblstat (1) 566s ***** error wblstat ({}, 2) 566s ***** error wblstat (1, "") 566s ***** error wblstat (i, 2) 566s ***** error wblstat (1, i) 566s ***** error ... 566s wblstat (ones (3), ones (2)) 566s ***** error ... 566s wblstat (ones (2), ones (3)) 566s ***** test 566s lambda = 3:8; 566s k = 1:6; 566s [m, v] = wblstat (lambda, k); 566s expected_m = [3.0000, 3.5449, 4.4649, 5.4384, 6.4272, 7.4218]; 566s expected_v = [9.0000, 3.4336, 2.6333, 2.3278, 2.1673, 2.0682]; 566s assert (m, expected_m, 0.001); 566s assert (v, expected_v, 0.001); 566s ***** test 566s k = 1:6; 566s [m, v] = wblstat (6, k); 566s expected_m = [ 6.0000, 5.3174, 5.3579, 5.4384, 5.5090, 5.5663]; 566s expected_v = [36.0000, 7.7257, 3.7920, 2.3278, 1.5923, 1.1634]; 566s assert (m, expected_m, 0.001); 566s assert (v, expected_v, 0.001); 566s 10 tests, 10 passed, 0 known failure, 0 skipped 566s [inst/dist_stat/unifstat.m] 566s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_stat/unifstat.m 566s ***** error unifstat () 566s ***** error unifstat (1) 566s ***** error unifstat ({}, 2) 566s ***** error unifstat (1, "") 566s ***** error unifstat (i, 2) 566s ***** error unifstat (1, i) 566s ***** error ... 566s unifstat (ones (3), ones (2)) 566s ***** error ... 566s unifstat (ones (2), ones (3)) 566s ***** test 566s a = 1:6; 566s b = 2:2:12; 566s [m, v] = unifstat (a, b); 566s expected_m = [1.5000, 3.0000, 4.5000, 6.0000, 7.5000, 9.0000]; 566s expected_v = [0.0833, 0.3333, 0.7500, 1.3333, 2.0833, 3.0000]; 566s assert (m, expected_m, 0.001); 566s assert (v, expected_v, 0.001); 566s ***** test 566s a = 1:6; 566s [m, v] = unifstat (a, 10); 566s expected_m = [5.5000, 6.0000, 6.5000, 7.0000, 7.5000, 8.0000]; 566s expected_v = [6.7500, 5.3333, 4.0833, 3.0000, 2.0833, 1.3333]; 566s assert (m, expected_m, 0.001); 566s assert (v, expected_v, 0.001); 566s 10 tests, 10 passed, 0 known failure, 0 skipped 566s [inst/dist_stat/tristat.m] 566s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_stat/tristat.m 566s ***** error tristat () 566s ***** error tristat (1) 566s ***** error tristat (1, 2) 566s ***** error tristat ("i", 2, 1) 566s ***** error tristat (0, "d", 1) 566s ***** error tristat (0, 3, {}) 566s ***** error tristat (i, 2, 1) 566s ***** error tristat (0, i, 1) 566s ***** error tristat (0, 3, i) 566s ***** test 566s a = 1:5; 566s b = 3:7; 566s c = 5:9; 566s [m, v] = tristat (a, b, c); 566s expected_m = [3, 4, 5, 6, 7]; 566s assert (m, expected_m); 566s assert (v, ones (1, 5) * (2/3)); 566s 10 tests, 10 passed, 0 known failure, 0 skipped 566s [inst/dist_stat/geostat.m] 566s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_stat/geostat.m 566s ***** error geostat () 566s ***** error geostat ({}) 566s ***** error geostat ("") 566s ***** error geostat (i) 566s ***** test 566s ps = 1 ./ (1:6); 566s [m, v] = geostat (ps); 566s assert (m, [0, 1, 2, 3, 4, 5], 0.001); 566s assert (v, [0, 2, 6, 12, 20, 30], 0.001); 566s 5 tests, 5 passed, 0 known failure, 0 skipped 566s [inst/dist_stat/bisastat.m] 566s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_stat/bisastat.m 566s ***** error bisastat () 566s ***** error bisastat (1) 566s ***** error bisastat ({}, 2) 566s ***** error bisastat (1, "") 566s ***** error bisastat (i, 2) 566s ***** error bisastat (1, i) 566s ***** error ... 566s bisastat (ones (3), ones (2)) 566s ***** error ... 566s bisastat (ones (2), ones (3)) 566s ***** test 566s beta = 1:6; 566s gamma = 1:0.2:2; 566s [m, v] = bisastat (beta, gamma); 566s expected_m = [1.50, 3.44, 5.94, 9.12, 13.10, 18]; 566s expected_v = [2.25, 16.128, 60.858, 172.032, 409.050, 864]; 566s assert (m, expected_m, 1e-2); 566s assert (v, expected_v, 1e-3); 566s ***** test 566s beta = 1:6; 566s [m, v] = bisastat (beta, 1.5); 566s expected_m = [2.125, 4.25, 6.375, 8.5, 10.625, 12.75]; 566s expected_v = [8.5781, 34.3125, 77.2031, 137.2500, 214.4531, 308.8125]; 566s assert (m, expected_m, 1e-3); 566s assert (v, expected_v, 1e-4); 566s 10 tests, 10 passed, 0 known failure, 0 skipped 566s [inst/dist_stat/nakastat.m] 566s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_stat/nakastat.m 566s ***** error nakastat () 566s ***** error nakastat (1) 566s ***** error nakastat ({}, 2) 566s ***** error nakastat (1, "") 566s ***** error nakastat (i, 2) 566s ***** error nakastat (1, i) 566s ***** error ... 566s nakastat (ones (3), ones (2)) 566s ***** error ... 566s nakastat (ones (2), ones (3)) 566s ***** test 566s [m, v] = nakastat (1, 1); 566s assert (m, 0.8862269254, 1e-10); 566s assert (v, 0.2146018366, 1e-10); 566s ***** test 566s [m, v] = nakastat (1, 2); 566s assert (m, 1.25331413731, 1e-10); 566s assert (v, 0.42920367321, 1e-10); 566s ***** test 566s [m, v] = nakastat (2, 1); 566s assert (m, 0.93998560299, 1e-10); 566s assert (v, 0.11642706618, 1e-10); 566s 11 tests, 11 passed, 0 known failure, 0 skipped 566s [inst/dist_stat/evstat.m] 566s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_stat/evstat.m 566s ***** error evstat () 566s ***** error evstat (1) 566s ***** error evstat ({}, 2) 566s ***** error evstat (1, "") 566s ***** error evstat (i, 2) 566s ***** error evstat (1, i) 566s ***** error ... 566s evstat (ones (3), ones (2)) 566s ***** error ... 566s evstat (ones (2), ones (3)) 566s ***** shared x, y0, y1 566s x = [-5, 0, 1, 2, 3]; 566s y0 = [NaN, NaN, 0.4228, 0.8456, 1.2684]; 566s y1 = [-5.5772, -3.4633, -3.0405, -2.6177, -2.1949]; 566s ***** assert (evstat (x, x), y0, 1e-4) 566s ***** assert (evstat (x, x+6), y1, 1e-4) 566s ***** assert (evstat (x, x-6), NaN (1,5)) 566s 11 tests, 11 passed, 0 known failure, 0 skipped 566s [inst/dist_stat/nctstat.m] 566s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_stat/nctstat.m 566s ***** error nctstat () 566s ***** error nctstat (1) 566s ***** error nctstat ({}, 2) 566s ***** error nctstat (1, "") 566s ***** error nctstat (i, 2) 566s ***** error nctstat (1, i) 566s ***** error ... 566s nctstat (ones (3), ones (2)) 566s ***** error ... 566s nctstat (ones (2), ones (3)) 566s ***** shared df, mu 566s df = [2, 0, -1, 1, 4]; 566s mu = [1, NaN, 3, -1, 2]; 566s ***** assert (nctstat (df, mu), [1.7725, NaN, NaN, NaN, 2.5066], 1e-4); 566s ***** assert (nctstat ([df(1:2), df(4:5)], 1), [1.7725, NaN, NaN, 1.2533], 1e-4); 566s ***** assert (nctstat ([df(1:2), df(4:5)], 3), [5.3174, NaN, NaN, 3.7599], 1e-4); 566s ***** assert (nctstat ([df(1:2), df(4:5)], 2), [3.5449, NaN, NaN, 2.5066], 1e-4); 566s ***** assert (nctstat (2, [mu(1), mu(3:5)]), [1.7725,5.3174,-1.7725,3.5449], 1e-4); 566s ***** assert (nctstat (0, [mu(1), mu(3:5)]), [NaN, NaN, NaN, NaN]); 566s ***** assert (nctstat (1, [mu(1), mu(3:5)]), [NaN, NaN, NaN, NaN]); 566s ***** assert (nctstat (4, [mu(1), mu(3:5)]), [1.2533,3.7599,-1.2533,2.5066], 1e-4); 566s 16 tests, 16 passed, 0 known failure, 0 skipped 566s [inst/dist_stat/betastat.m] 566s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_stat/betastat.m 566s ***** error betastat () 566s ***** error betastat (1) 566s ***** error betastat ({}, 2) 566s ***** error betastat (1, "") 566s ***** error betastat (i, 2) 566s ***** error betastat (1, i) 566s ***** error ... 566s betastat (ones (3), ones (2)) 566s ***** error ... 566s betastat (ones (2), ones (3)) 566s ***** test 566s a = -2:6; 566s b = 0.4:0.2:2; 566s [m, v] = betastat (a, b); 566s expected_m = [NaN NaN NaN 1/2 2/3.2 3/4.4 4/5.6 5/6.8 6/8]; 566s expected_v = [NaN NaN NaN 0.0833, 0.0558, 0.0402, 0.0309, 0.0250, 0.0208]; 566s assert (m, expected_m, eps*100); 566s assert (v, expected_v, 0.001); 566s ***** test 566s a = -2:1:6; 566s [m, v] = betastat (a, 1.5); 566s expected_m = [NaN NaN NaN 1/2.5 2/3.5 3/4.5 4/5.5 5/6.5 6/7.5]; 566s expected_v = [NaN NaN NaN 0.0686, 0.0544, 0.0404, 0.0305, 0.0237, 0.0188]; 566s assert (m, expected_m); 566s assert (v, expected_v, 0.001); 566s ***** test 566s a = [14 Inf 10 NaN 10]; 566s b = [12 9 NaN Inf 12]; 566s [m, v] = betastat (a, b); 566s expected_m = [14/26 NaN NaN NaN 10/22]; 566s expected_v = [168/18252 NaN NaN NaN 120/11132]; 566s assert (m, expected_m); 566s assert (v, expected_v); 566s ***** assert (nthargout (1:2, @betastat, 5, []), {[], []}) 566s ***** assert (nthargout (1:2, @betastat, [], 5), {[], []}) 566s ***** assert (size (betastat (rand (10, 5, 4), rand (10, 5, 4))), [10 5 4]) 566s ***** assert (size (betastat (rand (10, 5, 4), 7)), [10 5 4]) 566s 15 tests, 15 passed, 0 known failure, 0 skipped 566s [inst/bar3h.m] 566s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/bar3h.m 566s ***** demo 566s ## Ploting 5 bars in the same series. 566s 566s y = [50; 40; 30; 20; 10]; 566s bar3h (y); 566s ***** demo 566s ## Ploting 5 bars in different groups. 566s 566s y = [50, 40, 30, 20, 10]; 566s bar3h (y); 566s ***** demo 566s ## A 3D bar graph with each series corresponding to a column in y. 566s 566s y = [1, 4, 7; 2, 5, 8; 3, 6, 9; 4, 7, 10]; 566s bar3h (y); 566s ***** demo 566s ## Specify z-axis locations as tick names. z must be a column vector! 566s 566s z = [1950, 1960, 1970, 1980, 1990]'; 566s y = [16, 8, 4, 2, 1]'; 566s bar3h (z, y); 566s ***** demo 566s ## Plot 3 series as a grouped plot without any space between the grouped bars 566s 566s y = [70 50 33 10; 75 55 35 15; 80 60 40 20]; 566s bar3h (y, 1, 'grouped'); 566s ***** demo 566s ## Plot a stacked style 3D bar graph 566s 566s y = [19, 30, 21, 30; 40, 16, 32, 12]; 566s b = bar3h (y, 0.5, 'stacked'); 566s ***** error bar3h ("A") 566s ***** error bar3h ({2,3,4,5}) 566s ***** error ... 566s bar3h ([1,2,3]', ones (2)) 566s ***** error ... 566s bar3h ([1:5], 1.2) 566s ***** error ... 566s bar3h ([1:5]', ones (5), 1.2) 566s ***** error ... 566s bar3h ([1:5]', ones (5), [0.8, 0.7]) 566s ***** error ... 566s bar3h (ones (5), 'width') 566s ***** error ... 566s bar3h (ones (5), 'width', 1.2) 566s ***** error ... 566s bar3h (ones (5), 'width', [0.8, 0.8, 0.8]) 566s ***** error ... 566s bar3h (ones (5), 'color') 566s ***** error ... 566s bar3h (ones (5), 'color', [0.8, 0.8]) 566s ***** error ... 566s bar3h (ones (5), 'color', "brown") 566s ***** error ... 566s bar3h (ones (5), 'color', {"r", "k", "c", "m", "brown"}) 566s ***** error ... 566s bar3h (ones (5), 'xlabel') 566s ***** error ... 566s bar3h (ones (5), 'xlabel', 4) 566s ***** error ... 566s bar3h (ones (5), 'zlabel') 566s ***** error ... 566s bar3h (ones (5), 'zlabel', 4) 566s ***** error bar3h (ones (5), 'this', 4) 566s ***** error ... 566s bar3h (ones (5), 'xlabel', {"A", "B", "C"}) 566s ***** error ... 566s bar3h (ones (5), 'zlabel', {"A", "B", "C"}) 566s 20 tests, 20 passed, 0 known failure, 0 skipped 566s [inst/fitrgam.m] 566s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/fitrgam.m 566s ***** demo 566s # Train a RegressionGAM Model for synthetic values 566s 566s f1 = @(x) cos (3 *x); 566s f2 = @(x) x .^ 3; 566s 566s # generate x1 and x2 for f1 and f2 566s x1 = 2 * rand (50, 1) - 1; 566s x2 = 2 * rand (50, 1) - 1; 566s 566s # calculate y 566s y = f1(x1) + f2(x2); 566s 566s # add noise 566s y = y + y .* 0.2 .* rand (50,1); 566s X = [x1, x2]; 566s 566s # create an object 566s a = fitrgam (X, y, "tol", 1e-3) 566s ***** test 566s x = [1, 2, 3; 4, 5, 6; 7, 8, 9; 3, 2, 1]; 566s y = [1; 2; 3; 4]; 566s a = fitrgam (x, y); 566s assert ({a.X, a.Y}, {x, y}) 566s assert ({a.BaseModel.Intercept}, {2.5000}) 566s assert ({a.Knots, a.Order, a.DoF}, {[5, 5, 5], [3, 3, 3], [8, 8, 8]}) 566s assert ({a.NumObservations, a.NumPredictors}, {4, 3}) 566s assert ({a.ResponseName, a.PredictorNames}, {"Y", {"x1", "x2", "x3"}}) 566s assert ({a.Formula}, {[]}) 566s ***** test 566s x = [1, 2, 3, 4; 4, 5, 6, 7; 7, 8, 9, 1; 3, 2, 1, 2]; 566s y = [1; 2; 3; 4]; 566s pnames = {"A", "B", "C", "D"}; 566s formula = "Y ~ A + B + C + D + A:C"; 566s intMat = logical ([1,0,0,0;0,1,0,0;0,0,1,0;0,0,0,1;1,0,1,0]); 566s a = fitrgam (x, y, "predictors", pnames, "formula", formula); 566s assert ({a.IntMatrix}, {intMat}) 566s assert ({a.ResponseName, a.PredictorNames}, {"Y", pnames}) 566s assert ({a.Formula}, {formula}) 567s ***** error fitrgam () 567s ***** error fitrgam (ones(10,2)) 567s ***** error 567s fitrgam (ones (4,2), ones (4, 1), "K") 567s ***** error 567s fitrgam (ones (4,2), ones (3, 1)) 567s ***** error 567s fitrgam (ones (4,2), ones (3, 1), "K", 2) 567s 7 tests, 7 passed, 0 known failure, 0 skipped 567s [inst/hmmviterbi.m] 567s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/hmmviterbi.m 567s ***** test 567s sequence = [1, 2, 1, 1, 1, 2, 2, 1, 2, 3, 3, 3, ... 567s 3, 2, 3, 1, 1, 1, 1, 3, 3, 2, 3, 1, 3]; 567s transprob = [0.8, 0.2; 0.4, 0.6]; 567s outprob = [0.2, 0.4, 0.4; 0.7, 0.2, 0.1]; 567s vpath = hmmviterbi (sequence, transprob, outprob); 567s expected = [1, 1, 2, 2, 2, 1, 1, 1, 1, 1, 1, 1, ... 567s 1, 1, 1, 2, 2, 2, 2, 1, 1, 1, 1, 1, 1]; 567s assert (vpath, expected); 567s ***** test 567s sequence = {"A", "B", "A", "A", "A", "B", "B", "A", "B", "C", "C", "C", ... 567s "C", "B", "C", "A", "A", "A", "A", "C", "C", "B", "C", "A", "C"}; 567s transprob = [0.8, 0.2; 0.4, 0.6]; 567s outprob = [0.2, 0.4, 0.4; 0.7, 0.2, 0.1]; 567s symbols = {"A", "B", "C"}; 567s statenames = {"One", "Two"}; 567s vpath = hmmviterbi (sequence, transprob, outprob, "symbols", symbols, ... 567s "statenames", statenames); 567s expected = {"One", "One", "Two", "Two", "Two", "One", "One", "One", ... 567s "One", "One", "One", "One", "One", "One", "One", "Two", ... 567s "Two", "Two", "Two", "One", "One", "One", "One", "One", "One"}; 567s assert (vpath, expected); 567s 2 tests, 2 passed, 0 known failure, 0 skipped 567s [inst/stepwisefit.m] 567s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/stepwisefit.m 567s ***** test 567s % Sample data from Draper and Smith (n = 13, k = 4) 567s X = [7 1 11 11 7 11 3 1 2 21 1 11 10; ... 567s 26 29 56 31 52 55 71 31 54 47 40 66 68; ... 567s 6 15 8 8 6 9 17 22 18 4 23 9 8; ... 567s 60 52 20 47 33 22 6 44 22 26 34 12 12]'; 567s y = [78.5 74.3 104.3 87.6 95.9 109.2 102.7 72.5 93.1 115.9 83.8 113.3 109.4]'; 567s [X_use, b, bint, r, rint, stats] = stepwisefit(y, X); 567s assert(X_use, [4 1]) 567s assert(b, regress(y, [ones(size(y)) X(:, X_use)], 0.05)) 567s [X_use, b, bint, r, rint, stats] = stepwisefit(y, X, 0.05, 0.1, "corr"); 567s assert(X_use, [4 1]) 567s assert(b, regress(y, [ones(size(y)) X(:, X_use)], 0.05)) 567s [X_use, b, bint, r, rint, stats] = stepwisefit(y, X, [], [], "p"); 567s assert(X_use, [4 1]) 567s assert(b, regress(y, [ones(size(y)) X(:, X_use)], 0.05)) 567s 1 test, 1 passed, 0 known failure, 0 skipped 567s [inst/loadmodel.m] 567s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/loadmodel.m 567s ***** error loadmodel () 567s ***** error ... 567s loadmodel ("fisheriris.mat") 567s ***** error ... 567s loadmodel ("fail_loadmodel.mdl") 567s ***** error ... 567s loadmodel ("fail_load_model.mdl") 567s 4 tests, 4 passed, 0 known failure, 0 skipped 567s [inst/nanmin.m] 567s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/nanmin.m 567s ***** demo 567s ## Find the column minimum values and their indices 567s ## for matrix data with missing values. 567s 567s x = magic (3); 567s x([1, 6:9]) = NaN 567s [y, ind] = nanmin (x) 567s ***** demo 567s ## Find the minimum of all the values in an array, ignoring missing values. 567s ## Create a 2-by-5-by-3 array x with some missing values. 567s 567s x = reshape (1:30, [2, 5, 3]); 567s x([10:12, 25]) = NaN 567s 567s ## Find the minimum of the elements of x. 567s 567s y = nanmin (x, [], 'all') 567s ***** assert (nanmin ([2, 4, NaN, 7]), 2) 567s ***** assert (nanmin ([2, 4, NaN, -Inf]), -Inf) 567s ***** assert (nanmin ([1, NaN, 3; NaN, 5, 6; 7, 8, NaN]), [1, 5, 3]) 567s ***** assert (nanmin ([1, NaN, 3; NaN, 5, 6; 7, 8, NaN]'), [1, 5, 7]) 567s ***** assert (nanmin (single ([1, NaN, 3; NaN, 5, 6; 7, 8, NaN])), single ([1, 5, 3])) 567s ***** shared x, y 567s x(:,:,1) = [1.77, -0.005, NaN, -2.95; NaN, 0.34, NaN, 0.19]; 567s x(:,:,2) = [1.77, -0.005, NaN, -2.95; NaN, 0.34, NaN, 0.19] + 5; 567s y = x; 567s y(2,3,1) = 0.51; 567s ***** assert (nanmin (x, [], [1, 2])(:), [-2.95; 2.05]) 567s ***** assert (nanmin (x, [], [1, 3])(:), [1.77; -0.005; NaN; -2.95]) 567s ***** assert (nanmin (x, [], [2, 3])(:), [-2.95; 0.19]) 567s ***** assert (nanmin (x, [], [1, 2, 3]), -2.95) 567s ***** assert (nanmin (x, [], 'all'), -2.95) 567s ***** assert (nanmin (y, [], [1, 3])(:), [1.77; -0.005; 0.51; -2.95]) 567s ***** assert (nanmin (x(1,:,1), x(2,:,1)), [1.77, -0.005, NaN, -2.95]) 567s ***** assert (nanmin (x(1,:,2), x(2,:,2)), [6.77, 4.995, NaN, 2.05]) 567s ***** assert (nanmin (y(1,:,1), y(2,:,1)), [1.77, -0.005, 0.51, -2.95]) 567s ***** assert (nanmin (y(1,:,2), y(2,:,2)), [6.77, 4.995, NaN, 2.05]) 567s ***** test 567s xx = repmat ([1:20;6:25], [5 2 6 3]); 567s assert (size (nanmin (xx, [], [3, 2])), [10, 1, 1, 3]); 567s assert (size (nanmin (xx, [], [1, 2])), [1, 1, 6, 3]); 567s assert (size (nanmin (xx, [], [1, 2, 4])), [1, 1, 6]); 567s assert (size (nanmin (xx, [], [1, 4, 3])), [1, 40]); 567s assert (size (nanmin (xx, [], [1, 2, 3, 4])), [1, 1]); 567s ***** assert (nanmin (ones (2), [], 3), ones (2, 2)) 567s ***** assert (nanmin (ones (2, 2, 2), [], 99), ones (2, 2, 2)) 567s ***** assert (nanmin (magic (3), [], 3), magic (3)) 567s ***** assert (nanmin (magic (3), [], [1, 3]), [3, 1, 2]) 567s ***** assert (nanmin (magic (3), [], [1, 99]), [3, 1, 2]) 567s ***** assert (nanmin (ones (2), 3), ones (2,2)) 567s ***** error ... 567s nanmin (y, [], [1, 1, 2]) 567s ***** error ... 567s [v, idx] = nanmin(x, y, [1 2]) 567s 24 tests, 24 passed, 0 known failure, 0 skipped 567s [inst/pcares.m] 567s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/pcares.m 567s ***** demo 567s x = [ 7 26 6 60; 567s 1 29 15 52; 567s 11 56 8 20; 567s 11 31 8 47; 567s 7 52 6 33; 567s 11 55 9 22; 567s 3 71 17 6; 567s 1 31 22 44; 567s 2 54 18 22; 567s 21 47 4 26; 567s 1 40 23 34; 567s 11 66 9 12; 567s 10 68 8 12]; 567s 567s ## As we increase the number of principal components, the norm 567s ## of the residuals matrix will decrease 567s r1 = pcares (x,1); 567s n1 = norm (r1) 567s r2 = pcares (x,2); 567s n2 = norm (r2) 567s r3 = pcares (x,3); 567s n3 = norm (r3) 567s r4 = pcares (x,4); 567s n4 = norm (r4) 567s ***** test 567s load hald 567s r1 = pcares (ingredients,1); 567s r2 = pcares (ingredients,2); 567s r3 = pcares (ingredients,3); 567s assert (r1(1,:), [2.0350, 2.8304, -6.8378, 3.0879], 1e-4); 567s assert (r2(1,:), [-2.4037, 2.6930, -1.6482, 2.3425], 1e-4); 567s assert (r3(1,:), [ 0.2008, 0.1957, 0.2045, 0.1921], 1e-4); 567s ***** error pcares (ones (20, 3)) 567s ***** error ... 567s pcares (ones (30, 2), 3) 567s 3 tests, 3 passed, 0 known failure, 0 skipped 567s [inst/levene_test.m] 567s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/levene_test.m 567s ***** error levene_test () 567s ***** error ... 567s levene_test (1, 2, 3, 4, 5); 567s ***** error levene_test (randn (50, 2), 0); 567s ***** error ... 567s levene_test (randn (50, 2), [1, 2, 3]); 567s ***** error ... 567s levene_test (randn (50, 1), ones (55, 1)); 567s ***** error ... 567s levene_test (randn (50, 1), ones (50, 2)); 567s ***** error ... 567s levene_test (randn (50, 2), [], 1.2); 567s ***** error ... 567s levene_test (randn (50, 2), "some_string"); 567s ***** error ... 567s levene_test (randn (50, 2), [], "alpha"); 567s ***** error ... 567s levene_test (randn (50, 1), [ones(25, 1); 2*ones(25, 1)], 1.2); 567s ***** error ... 567s levene_test (randn (50, 1), [ones(25, 1); 2*ones(25, 1)], "err"); 567s ***** error ... 567s levene_test (randn (50, 1), [ones(25, 1); 2*ones(25, 1)], 0.05, "type"); 567s ***** warning ... 567s levene_test (randn (50, 1), [ones(24, 1); 2*ones(25, 1); 3]); 567s ***** test 567s load examgrades 567s [h, pval, W, df] = levene_test (grades); 567s assert (h, 1); 567s assert (pval, 9.523239714592791e-07, 1e-14); 567s assert (W, 8.59529, 1e-5); 567s assert (df, [4, 595]); 567s ***** test 567s load examgrades 567s [h, pval, W, df] = levene_test (grades, [], "quadratic"); 567s assert (h, 1); 567s assert (pval, 9.523239714592791e-07, 1e-14); 567s assert (W, 8.59529, 1e-5); 567s assert (df, [4, 595]); 567s ***** test 567s load examgrades 567s [h, pval, W, df] = levene_test (grades, [], "median"); 567s assert (h, 1); 567s assert (pval, 1.312093241723211e-06, 1e-14); 567s assert (W, 8.415969, 1e-6); 567s assert (df, [4, 595]); 567s ***** test 567s load examgrades 567s [h, pval, W, df] = levene_test (grades(:,[1:3])); 567s assert (h, 1); 567s assert (pval, 0.004349390980463497, 1e-14); 567s assert (W, 5.52139, 1e-5); 567s assert (df, [2, 357]); 567s ***** test 567s load examgrades 567s [h, pval, W, df] = levene_test (grades(:,[1:3]), "median"); 567s assert (h, 1); 567s assert (pval, 0.004355216763951453, 1e-14); 567s assert (W, 5.52001, 1e-5); 567s assert (df, [2, 357]); 567s ***** test 567s load examgrades 567s [h, pval, W, df] = levene_test (grades(:,[3,4]), "quadratic"); 567s assert (h, 0); 567s assert (pval, 0.1807494957440653, 2e-14); 567s assert (W, 1.80200, 1e-5); 567s assert (df, [1, 238]); 568s ***** test 568s load examgrades 568s [h, pval, W, df] = levene_test (grades(:,[3,4]), "median"); 568s assert (h, 0); 568s assert (pval, 0.1978225622063785, 2e-14); 568s assert (W, 1.66768, 1e-5); 568s assert (df, [1, 238]); 568s 20 tests, 20 passed, 0 known failure, 0 skipped 568s [inst/signrank.m] 568s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/signrank.m 568s ***** test 568s load gradespaired.mat 568s [p, h, stats] = signrank (gradespaired(:,1), ... 568s gradespaired(:,2), 'tail', 'left'); 568s assert (p, 0.0047, 1e-4); 568s assert (h, true); 568s assert (stats.zval, -2.5982, 1e-4); 568s assert (stats.signedrank, 2017.5); 568s ***** test 568s load ('gradespaired.mat'); 568s [p, h, stats] = signrank (gradespaired(:,1), gradespaired(:,2), ... 568s 'tail', 'left', 'method', 'exact'); 568s assert (p, 0.0045, 1e-4); 568s assert (h, true); 568s assert (stats.zval, NaN); 568s assert (stats.signedrank, 2017.5); 568s ***** test 568s load mileage 568s [p, h, stats] = signrank (mileage(:,2), 33); 568s assert (p, 0.0312, 1e-4); 568s assert (h, true); 568s assert (stats.zval, NaN); 568s assert (stats.signedrank, 21); 568s ***** test 568s load mileage 568s [p, h, stats] = signrank (mileage(:,2), 33, 'tail', 'right'); 568s assert (p, 0.0156, 1e-4); 568s assert (h, true); 568s assert (stats.zval, NaN); 568s assert (stats.signedrank, 21); 568s ***** test 568s load mileage 568s [p, h, stats] = signrank (mileage(:,2), 33, 'tail', 'right', ... 568s 'alpha', 0.01, 'method', 'approximate'); 568s assert (p, 0.0180, 1e-4); 568s assert (h, false); 568s assert (stats.zval, 2.0966, 1e-4); 568s assert (stats.signedrank, 21); 568s ***** error signrank (ones (2)) 568s ***** error ... 568s signrank ([1, 2, 3, 4], ones (2)) 568s ***** error ... 568s signrank ([1, 2, 3, 4], [1, 2, 3]) 568s ***** error ... 568s signrank ([1, 2, 3, 4], [], 'tail') 568s ***** error ... 568s signrank ([1, 2, 3, 4], [], 'alpha', 1.2) 568s ***** error ... 568s signrank ([1, 2, 3, 4], [], 'alpha', 0) 568s ***** error ... 568s signrank ([1, 2, 3, 4], [], 'alpha', -0.05) 568s ***** error ... 568s signrank ([1, 2, 3, 4], [], 'alpha', "a") 568s ***** error ... 568s signrank ([1, 2, 3, 4], [], 'alpha', [0.01, 0.05]) 568s ***** error ... 568s signrank ([1, 2, 3, 4], [], 'tail', 0.01) 568s ***** error ... 568s signrank ([1, 2, 3, 4], [], 'tail', {"both"}) 568s ***** error ... 568s signrank ([1, 2, 3, 4], [], 'tail', "some") 568s ***** error ... 568s signrank ([1, 2, 3, 4], [], 'method', 'exact', 'tail', "some") 568s ***** error ... 568s signrank ([1, 2, 3, 4], [], 'method', 0.01) 568s ***** error ... 568s signrank ([1, 2, 3, 4], [], 'method', {"exact"}) 568s ***** error ... 568s signrank ([1, 2, 3, 4], [], 'method', "some") 568s ***** error ... 568s signrank ([1, 2, 3, 4], [], 'tail', "both", 'method', "some") 568s 22 tests, 22 passed, 0 known failure, 0 skipped 568s [inst/@cvpartition/training.m] 568s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/@cvpartition/training.m 568s ***** shared C 568s C = cvpartition (ones (10, 1), "KFold", 5); 568s ***** assert (training (C, 1), logical ([0 0 1 1 1 1 1 1 1 1]')) 568s ***** assert (training (C, 2), logical ([1 1 0 0 1 1 1 1 1 1]')) 568s ***** assert (training (C, 3), logical ([1 1 1 1 0 0 1 1 1 1]')) 568s ***** assert (training (C, 4), logical ([1 1 1 1 1 1 0 0 1 1]')) 568s ***** assert (training (C, 5), logical ([1 1 1 1 1 1 1 1 0 0]')) 568s ***** test 568s C = set (C, "inds", [1 2 2 2 3 4 3 4 5 5]'); 568s ***** assert (training (C), logical ([0 1 1 1 1 1 1 1 1 1]')) 568s ***** assert (training (C, 2), logical ([1 0 0 0 1 1 1 1 1 1]')) 568s ***** assert (training (C, 3), logical ([1 1 1 1 0 1 0 1 1 1]')) 568s 9 tests, 9 passed, 0 known failure, 0 skipped 568s [inst/@cvpartition/test.m] 568s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/@cvpartition/test.m 568s ***** shared C 568s C = cvpartition (ones (10, 1), "KFold", 5); 568s ***** assert (test (C, 1), logical ([1 1 0 0 0 0 0 0 0 0]')) 568s ***** assert (test (C, 2), logical ([0 0 1 1 0 0 0 0 0 0]')) 568s ***** assert (test (C, 3), logical ([0 0 0 0 1 1 0 0 0 0]')) 568s ***** assert (test (C, 4), logical ([0 0 0 0 0 0 1 1 0 0]')) 568s ***** assert (test (C, 5), logical ([0 0 0 0 0 0 0 0 1 1]')) 568s ***** test 568s C = set (C, "inds", [1 2 2 2 3 4 3 4 5 5]'); 568s ***** assert (test (C), logical ([1 0 0 0 0 0 0 0 0 0]')) 568s ***** assert (test (C, 2), logical ([0 1 1 1 0 0 0 0 0 0]')) 568s ***** assert (test (C, 3), logical ([0 0 0 0 1 0 1 0 0 0]')) 568s 9 tests, 9 passed, 0 known failure, 0 skipped 568s [inst/@cvpartition/cvpartition.m] 568s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/@cvpartition/cvpartition.m 568s ***** demo 568s ## Partition with Fisher iris dataset (n = 150) 568s ## Stratified by species 568s load fisheriris 568s y = species; 568s ## 10-fold cross-validation partition 568s c = cvpartition (species, 'KFold', 10) 568s ## leave-10-out partition 568s c1 = cvpartition (species, 'HoldOut', 10) 568s idx1 = test (c, 2); 568s idx2 = training (c, 2); 568s ## another leave-10-out partition 568s c2 = repartition (c1) 568s ***** test 568s C = cvpartition (ones (10, 1)); 568s assert (isa (C, "cvpartition"), true); 568s ***** test 568s C = cvpartition (ones (10, 1), "KFold", 5); 568s assert (get (C, "NumObservations"), 10); 568s assert (get (C, "NumTestSets"), 5); 568s assert (get (C, "TrainSize"), ones(5,1) * 8); 568s assert (get (C, "TestSize"), ones (5,1) * 2); 568s assert (get (C, "inds"), [1 1 2 2 3 3 4 4 5 5]'); 568s assert (get (C, "Type"), "kfold"); 568s ***** test 568s C = cvpartition (ones (10, 1), "KFold", 2); 568s assert (get (C, "NumObservations"), 10); 568s assert (get (C, "NumTestSets"), 2); 568s assert (get (C, "TrainSize"), [5; 5]); 568s assert (get (C, "TestSize"), [5; 5]); 568s assert (get (C, "inds"), [1 1 1 1 1 2 2 2 2 2]'); 568s assert (get (C, "Type"), "kfold"); 568s ***** test 568s C = cvpartition (ones (10, 1), "HoldOut", 5); 568s assert (get (C, "NumObservations"), 10); 568s assert (get (C, "NumTestSets"), 1); 568s assert (get (C, "TrainSize"), 5); 568s assert (get (C, "TestSize"), 5); 568s assert (class (get (C, "inds")), "logical"); 568s assert (length (get (C, "inds")), 10); 568s assert (get (C, "Type"), "holdout"); 568s ***** test 568s C = cvpartition ([1 2 3 4 5 6 7 8 9 10], "LeaveOut", 5); 568s assert (get (C, "NumObservations"), 10); 568s assert (get (C, "NumTestSets"), 10); 568s assert (get (C, "TrainSize"), ones (10, 1)); 568s assert (get (C, "TestSize"), ones (10, 1) * 9); 568s assert (get (C, "inds"), []); 568s assert (get (C, "Type"), "leaveout"); 568s ***** test 568s C = cvpartition ([1 2 3 4 5 6 7 8 9 10], "resubstitution", 5); 568s assert (get (C, "NumObservations"), 10); 568s assert (get (C, "NumTestSets"), 1); 568s assert (get (C, "TrainSize"), 10); 568s assert (get (C, "TestSize"), 10); 568s assert (get (C, "inds"), []); 568s assert (get (C, "Type"), "resubstitution"); 568s ***** test 568s C = cvpartition ([1 2 3 4 5 6 7 8 9 10], "Given", 2); 568s assert (get (C, "NumObservations"), 10); 568s assert (get (C, "NumTestSets"), 10); 568s assert (get (C, "TrainSize"), ones (10, 1) * 9); 568s assert (get (C, "TestSize"), ones (10, 1)); 568s assert (get (C, "inds"), [1:10]'); 568s assert (get (C, "Type"), "given"); 568s ***** warning ... 568s C = cvpartition ([1 2 3 4 5 6 7 8 9 10], "some", 2); 568s 8 tests, 8 passed, 0 known failure, 0 skipped 568s [inst/@cvpartition/display.m] 568s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/@cvpartition/display.m 568s ***** test 568s C = cvpartition (ones (10, 1), "KFold", 5); 568s s = evalc ("display (C)"); 568s sout = "K-fold cross validation partition"; 568s assert (strcmpi (s(1:length (sout)), sout), true); 568s ***** test 568s C = cvpartition (ones (10, 1), "HoldOut", 5); 568s s = evalc ("display (C)"); 568s sout = "HoldOut cross validation partition"; 568s assert (strcmpi (s(1:length (sout)), sout), true); 568s ***** test 568s C = cvpartition (ones (10, 1), "LeaveOut", 5); 568s s = evalc ("display (C)"); 568s sout = "Leave-One-Out cross validation partition"; 568s assert (strcmpi (s(1:length (sout)), sout), true); 568s ***** test 568s C = cvpartition (ones (10, 1), "resubstitution", 5); 568s s = evalc ("display (C)"); 568s sout = "Resubstitution cross validation partition"; 568s assert (strcmpi (s(1:length (sout)), sout), true); 568s ***** test 568s C = cvpartition (ones (10, 1), "Given", 5); 568s s = evalc ("display (C)"); 568s sout = "Given cross validation partition"; 568s assert (strcmpi (s(1:length (sout)), sout), true); 568s ***** error display () 568s 6 tests, 6 passed, 0 known failure, 0 skipped 568s [inst/@cvpartition/get.m] 568s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/@cvpartition/get.m 568s ***** shared C 568s C = cvpartition (ones (10, 1), "KFold", 5); 568s ***** assert (get (C, "NumObservations"), 10); 568s ***** assert (get (C, "NumTestSets"), 5); 568s ***** assert (get (C, "TrainSize"), ones(5,1) * 8); 568s ***** assert (get (C, "TestSize"), ones (5,1) * 2); 568s ***** assert (get (C, "inds"), [1 1 2 2 3 3 4 4 5 5]'); 568s ***** assert (get (C, "Type"), "kfold"); 568s ***** error get (C, "some") 568s ***** error get (C, 25) 568s ***** error get (C, {25}) 568s 9 tests, 9 passed, 0 known failure, 0 skipped 568s [inst/@cvpartition/repartition.m] 568s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/@cvpartition/repartition.m 568s ***** test 568s C = cvpartition (ones (10, 1), "KFold", 5); 568s Cnew = repartition (C); 568s assert (isa (Cnew, "cvpartition"), true); 568s ***** test 568s C = cvpartition (ones (100, 1), "HoldOut", 5); 568s Cnew = repartition (C); 568s indC = get (C, "inds"); 568s indCnew = get (Cnew, "inds"); 568s assert (isequal (indC, indCnew), false); 568s 2 tests, 2 passed, 0 known failure, 0 skipped 568s [inst/@cvpartition/set.m] 568s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/@cvpartition/set.m 568s ***** shared C 568s C = cvpartition (ones (10, 1), "KFold", 5); 568s ***** test 568s Cnew = set (C, "inds", [1 2 2 2 3 4 3 4 5 5]'); 568s assert (get (Cnew, "inds"), [1 2 2 2 3 4 3 4 5 5]'); 568s ***** error set (C) 568s ***** error set (C, "NumObservations") 568s ***** error set (C, "some", 15) 568s ***** error set (C, 15, 15) 568s 5 tests, 5 passed, 0 known failure, 0 skipped 568s [inst/vartest.m] 568s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/vartest.m 568s ***** error vartest (); 568s ***** error vartest ([1, 2, 3, 4], -0.5); 568s ***** error ... 568s vartest ([1, 2, 3, 4], 1, "alpha", 0); 568s ***** error ... 568s vartest ([1, 2, 3, 4], 1, "alpha", 1.2); 568s ***** error ... 568s vartest ([1, 2, 3, 4], 1, "alpha", "val"); 568s ***** error ... 568s vartest ([1, 2, 3, 4], 1, "tail", "val"); 568s ***** error ... 568s vartest ([1, 2, 3, 4], 1, "alpha", 0.01, "tail", "val"); 568s ***** error ... 568s vartest ([1, 2, 3, 4], 1, "dim", 3); 568s ***** error ... 568s vartest ([1, 2, 3, 4], 1, "alpha", 0.01, "tail", "both", "dim", 3); 568s ***** error ... 568s vartest ([1, 2, 3, 4], 1, "alpha", 0.01, "tail", "both", "badoption", 3); 568s ***** error ... 568s vartest ([1, 2, 3, 4], 1, "alpha", 0.01, "tail"); 568s ***** test 568s load carsmall 568s [h, pval, ci] = vartest (MPG, 7^2); 568s assert (h, 1); 568s assert (pval, 0.04335086742174443, 1e-14); 568s assert (ci, [49.397; 88.039], 1e-3); 568s 12 tests, 12 passed, 0 known failure, 0 skipped 568s [inst/evalclusters.m] 568s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/evalclusters.m 568s ***** demo 568s load fisheriris; 568s eva = evalclusters (meas, "kmeans", "calinskiharabasz", "KList", [1:6]) 568s plot (eva) 568s ***** error evalclusters () 568s ***** error evalclusters ([1 1;0 1]) 569s ***** error evalclusters ([1 1;0 1], "kmeans") 569s ***** error <'x' must be a numeric*> evalclusters ("abc", "kmeans", "gap") 569s ***** error evalclusters ([1 1;0 1], "xxx", "gap") 569s ***** error evalclusters ([1 1;0 1], [1 2], "gap") 569s ***** error evalclusters ([1 1;0 1], 1.2, "gap") 569s ***** error evalclusters ([1 1;0 1], [1; 2], 123) 569s ***** error evalclusters ([1 1;0 1], [1; 2], "xxx") 569s ***** error <'KList' can be empty*> evalclusters ([1 1;0 1], "kmeans", "gap") 569s ***** error evalclusters ([1 1;0 1], [1; 2], "gap", 1) 569s ***** error evalclusters ([1 1;0 1], [1; 2], "gap", 1, 1) 569s ***** error evalclusters ([1 1;0 1], [1; 2], "gap", "xxx", 1) 569s ***** error <'KList'*> evalclusters ([1 1;0 1], [1; 2], "gap", "KList", [-1 0]) 569s ***** error <'KList'*> evalclusters ([1 1;0 1], [1; 2], "gap", "KList", [1 .5]) 569s ***** error <'KList'*> evalclusters ([1 1;0 1], [1; 2], "gap", "KList", [1 1; 1 1]) 569s ***** error evalclusters ([1 1;0 1], [1; 2], "gap", ... 569s "distance", "a") 569s ***** error evalclusters ([1 1;0 1], [1; 2], "daviesbouldin", ... 569s "distance", "a") 569s ***** error evalclusters ([1 1;0 1], [1; 2], "gap", ... 569s "clusterpriors", "equal") 569s ***** error evalclusters ([1 1;0 1], [1; 2], ... 569s "silhouette", "clusterpriors", "xxx") 569s ***** error <'clust' must be a clustering*> evalclusters ([1 1;0 1], [1; 2], "gap") 569s ***** test 569s load fisheriris; 569s eva = evalclusters (meas, "kmeans", "calinskiharabasz", "KList", [1:6]); 569s assert (isa (eva, "CalinskiHarabaszEvaluation")); 569s assert (eva.NumObservations, 150); 569s assert (eva.OptimalK, 3); 569s assert (eva.InspectedK, [1 2 3 4 5 6]); 569s 22 tests, 22 passed, 0 known failure, 0 skipped 569s [inst/cluster.m] 569s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/cluster.m 569s ***** error cluster () 569s ***** error cluster ([1 1], "Cutoff", 1) 569s ***** error cluster ([1 2 1], "Bogus", 1) 569s ***** error cluster ([1 2 1], "Cutoff", -1) 569s ***** error cluster ([1 2 1], "Cutoff", 1, "Bogus", 1) 569s ***** test 569s 6 tests, 6 passed, 0 known failure, 0 skipped 569s [inst/glmfit.m] 569s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/glmfit.m 569s ***** demo 569s rand ("seed", 1); 569s X = rand (100, 1); 569s b_true = [0.5; -1.2]; 569s mu = exp (b_true(1) + b_true(2) * X); 569s randp ("seed", 1); 569s y = poissrnd (mu); 569s ## Fit a GLM model using the poisson distribution 569s [b,dev] = glmfit (X, y, 'poisson'); 569s ***** demo 569s x = [2100 2300 2500 2700 2900 3100 3300 3500 3700 3900 4100 4300]'; 569s n = [48 42 31 34 31 21 23 23 21 16 17 21]'; 569s y = [1 2 0 3 8 8 14 17 19 15 17 21]'; 569s [b,dev] = glmfit (x,[y n],'binomial','Link','probit'); 569s ***** test 569s rand ("seed", 1); 569s X = rand (50, 1); 569s b_true = [0.4; 1.5]; 569s mu_true = exp (b_true(1) + b_true(2) * X); 569s randp ("seed", 1); 569s y = poissrnd (mu_true); 569s b = glmfit (X, y, "poisson", "link", "log"); 569s assert (b(1), b_true(1), 0.5); 569s assert (b(2), b_true(2), 0.5); 569s ***** test 569s rand ("seed", 1); 569s X1 = rand (50, 1); 569s X2 = rand (50, 1) * 0.5; 569s b_true = [0.4; 1.5; -0.7]; 569s mu_true = exp (b_true(1) + b_true(2) * X1 + b_true(3) * X2); 569s randp ("seed", 1); 569s y = poissrnd(mu_true); 569s [b, dev] = glmfit ([X1, X2], y, "poisson", "link", "log"); 569s assert (b(1), b_true(1), 1); 569s assert (b(2), b_true(2), 1); 569s assert (b(3), b_true(3), 1); 569s assert (dev < 60, true); 569s ***** error glmfit () 569s ***** error glmfit (1) 569s ***** error glmfit (1, 2) 569s ***** error ... 569s glmfit (rand (6, 1), rand (6, 1), 'poisson', 'link') 569s ***** error ... 569s glmfit ('abc', rand (6, 1), 'poisson') 569s ***** error ... 569s glmfit (rand (5, 2), 'abc', 'poisson') 569s ***** error ... 569s glmfit (rand (5, 2), rand (6, 1), 'poisson') 569s ***** error ... 569s glmfit (rand (6, 2), rand (6, 1), 3) 569s ***** error ... 569s glmfit (rand (6, 2), rand (6, 1), {'poisson'}) 569s ***** error ... 569s glmfit (rand (5, 2), rand (5, 3), 'binomial') 569s ***** error ... 569s glmfit (rand (5, 2), rand (5, 2), 'normal') 569s ***** error ... 569s glmfit (rand (5, 2), rand (5, 1), 'gamma') 569s ***** error ... 569s glmfit (rand (5, 2), rand (5, 1), 'inverse gaussian') 569s ***** error ... 569s glmfit (rand (5, 2), rand (5, 1), 'loguniform') 569s ***** error ... 569s glmfit (rand(5,2), rand(5,1), 'poisson', 'link', {'log'}) 569s ***** error ... 569s glmfit (rand(5,2), rand(5,1), 'poisson', 'link', {'log', 'hijy'}) 569s ***** error ... 569s glmfit (rand(5,2), rand(5,1), 'poisson', 'link', {'log','dfv','dfgvd'}) 569s ***** error ... 569s glmfit (rand(5,2), rand(5,1), 'poisson', 'link', {@log, 'derivative', @exp}) 569s ***** error ... 569s glmfit (rand(5,2), rand(5,1), 'poisson', 'link', {@exp, @log, @(x) eye(e)}) 569s ***** error ... 569s glmfit (rand(5,2), rand(5,1), 'poisson', 'link', 'somelinkfunction') 569s ***** error ... 569s glmfit (rand(5,2), rand(5,1), 'poisson', 'link', 2) 569s ***** error ... 569s glmfit (rand(5,2), rand(5,1), 'poisson', 'link', 'log', 'constant', 0) 569s ***** error ... 569s glmfit (rand(5,2), rand(5,1), 'poisson', 'link', 'log', 'constant', 'asda') 569s ***** error ... 569s glmfit (rand(5,2), rand(5,1), 'poisson', 'param', 'log', 'constant', 'on') 569s 26 tests, 26 passed, 0 known failure, 0 skipped 569s [inst/grp2idx.m] 569s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/grp2idx.m 569s ***** test 569s in = [true false false true]; 569s out = {[1; 2; 2; 1] {"1"; "0"} [true; false]}; 569s assert (nthargout (1:3, @grp2idx, in), out) 569s assert (nthargout (1:3, @grp2idx, in), nthargout (1:3, @grp2idx, in')) 569s ***** test 569s assert (nthargout (1:3, @grp2idx, [false, true]), 569s {[1; 2] {"0"; "1"} [false; true]}); 569s assert (nthargout (1:3, @grp2idx, [true, false]), 569s {[1; 2] {"1"; "0"} [true; false]}); 570s ***** assert (nthargout (1:3, @grp2idx, ["oct"; "sci"; "oct"; "oct"; "sci"]), 570s {[1; 2; 1; 1; 2] {"oct"; "sci"} ["oct"; "sci"]}); 570s ***** assert (nthargout (1:3, @grp2idx, {"oct"; "sci"; "oct"; "oct"; "sci"}), 570s {[1; 2; 1; 1; 2] {"oct"; "sci"} {"oct"; "sci"}}); 570s ***** assert (nthargout (1:3, @grp2idx, [ 1 -3 -2 -3 -3 2 1 -1 3 -3]), 570s {[1; 2; 3; 2; 2; 4; 1; 5; 6; 2], {"1"; "-3"; "-2"; "2"; "-1"; "3"}, ... 570s [1; -3; -2; 2; -1; 3]}); 570s ***** assert (nthargout (1:3, @grp2idx, [2 2 3 NaN 2 3]), 570s {[1; 1; 2; NaN; 1; 2] {"2"; "3"} [2; 3]}) 570s ***** assert (nthargout (1:3, @grp2idx, {"et" "sa" "sa" "" "et"}), 570s {[1; 2; 2; NaN; 1] {"et"; "sa"} {"et"; "sa"}}) 570s ***** test assert (nthargout (1:3, @grp2idx, ["sci"; "oct"; "sci"; "oct"; "oct"]), 570s {[1; 2; 1; 2; 2] {"sci"; "oct"} ["sci"; "oct"]}); 570s ***** test assert (nthargout (1:3, @grp2idx, {"sci"; "oct"; "sci"; "oct"; "oct"}), 570s {[1; 2; 1; 2; 2] {"sci"; "oct"} {"sci"; "oct"}}); 570s ***** test assert (nthargout (1:3, @grp2idx, {"sa" "et" "et" "" "sa"}), 570s {[1; 2; 2; NaN; 1] {"sa"; "et"} {"sa"; "et"}}) 570s 10 tests, 10 passed, 0 known failure, 0 skipped 570s [inst/mcnemar_test.m] 570s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/mcnemar_test.m 570s ***** test 570s [h, pval, chisq] = mcnemar_test ([101,121;59,33]); 570s assert (h, 1); 570s assert (pval, 3.8151e-06, 1e-10); 570s assert (chisq, 21.356, 1e-3); 570s ***** test 570s [h, pval, chisq] = mcnemar_test ([59,6;16,80]); 570s assert (h, 1); 570s assert (pval, 0.034690, 1e-6); 570s assert (isempty (chisq), true); 570s ***** test 570s [h, pval, chisq] = mcnemar_test ([59,6;16,80], 0.01); 570s assert (h, 0); 570s assert (pval, 0.034690, 1e-6); 570s assert (isempty (chisq), true); 570s ***** test 570s [h, pval, chisq] = mcnemar_test ([59,6;16,80], "mid-p"); 570s assert (h, 1); 570s assert (pval, 0.034690, 1e-6); 570s assert (isempty (chisq), true); 570s ***** test 570s [h, pval, chisq] = mcnemar_test ([59,6;16,80], "asymptotic"); 570s assert (h, 1); 570s assert (pval, 0.033006, 1e-6); 570s assert (chisq, 4.5455, 1e-4); 570s ***** test 570s [h, pval, chisq] = mcnemar_test ([59,6;16,80], "exact"); 570s assert (h, 0); 570s assert (pval, 0.052479, 1e-6); 570s assert (isempty (chisq), true); 570s ***** test 570s [h, pval, chisq] = mcnemar_test ([59,6;16,80], "corrected"); 570s assert (h, 0); 570s assert (pval, 0.055009, 1e-6); 570s assert (chisq, 3.6818, 1e-4); 570s ***** test 570s [h, pval, chisq] = mcnemar_test ([59,6;16,80], 0.1, "corrected"); 570s assert (h, 1); 570s assert (pval, 0.055009, 1e-6); 570s assert (chisq, 3.6818, 1e-4); 570s ***** error mcnemar_test (59, 6, 16, 80) 570s ***** error mcnemar_test (ones (3, 3)) 570s ***** error ... 570s mcnemar_test ([59,6;16,-80]) 570s ***** error ... 570s mcnemar_test ([59,6;16,4.5]) 570s ***** error ... 570s mcnemar_test ([59,6;16,80], {""}) 570s ***** error ... 570s mcnemar_test ([59,6;16,80], -0.2) 570s ***** error ... 570s mcnemar_test ([59,6;16,80], [0.05, 0.1]) 570s ***** error ... 570s mcnemar_test ([59,6;16,80], 1) 570s ***** error ... 570s mcnemar_test ([59,6;16,80], "") 570s 17 tests, 17 passed, 0 known failure, 0 skipped 570s [inst/fullfact.m] 570s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/fullfact.m 570s ***** demo 570s ## Full factorial design with 3 binary variables 570s fullfact (3) 570s ***** demo 570s ## Full factorial design with 3 ordinal variables 570s fullfact ([2, 3, 4]) 570s ***** error fullfact (); 570s ***** error fullfact (2, 5); 570s ***** error fullfact (2.5); 570s ***** error fullfact (0); 570s ***** error fullfact (-3); 570s ***** error fullfact (3+2i); 570s ***** error fullfact (Inf); 570s ***** error fullfact (NaN); 570s ***** error fullfact ([1, 2, -3]); 570s ***** error fullfact ([0, 1, 2]); 570s ***** error fullfact ([1, 2, NaN]); 570s ***** error fullfact ([1, 2, Inf]); 570s ***** test 570s A = fullfact (2); 570s assert (A, [0, 0; 0, 1; 1, 0; 1, 1]); 570s ***** test 570s A = fullfact ([1, 2]); 570s assert (A, [1, 1; 1, 2]); 570s ***** test 570s A = fullfact ([1, 2, 4]); 570s A_out = [1, 1, 1; 1, 1, 2; 1, 1, 3; 1, 1, 4; ... 570s 1, 2, 1; 1, 2, 2; 1, 2, 3; 1, 2, 4]; 570s assert (A, A_out); 570s 15 tests, 15 passed, 0 known failure, 0 skipped 570s [inst/dist_obj/PoissonDistribution.m] 570s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_obj/PoissonDistribution.m 570s ***** shared pd, t, t_inf 570s pd = PoissonDistribution; 570s t = truncate (pd, 2, 4); 570s t_inf = truncate (pd, 2, Inf); 570s ***** assert (cdf (pd, [0:5]), [0.3679, 0.7358, 0.9197, 0.9810, 0.9963, 0.9994], 1e-4); 570s ***** assert (cdf (t, [0:5]), [0, 0, 0.7059, 0.9412, 1, 1], 1e-4); 570s ***** assert (cdf (t_inf, [0:5]), [0, 0, 0.6961, 0.9281, 0.9861, 0.9978], 1e-4); 570s ***** assert (cdf (pd, [1.5, 2, 3, 4]), [0.7358, 0.9197, 0.9810, 0.9963], 1e-4); 570s ***** assert (cdf (t, [1.5, 2, 3, 4]), [0, 0.7059, 0.9412, 1], 1e-4); 570s ***** assert (icdf (pd, [0:0.2:1]), [0, 0, 1, 1, 2, Inf], 1e-4); 570s ***** assert (icdf (t, [0:0.2:1]), [2, 2, 2, 2, 3, 4], 1e-4); 570s ***** assert (icdf (t_inf, [0:0.2:1]), [2, 2, 2, 2, 3, Inf], 1e-4); 570s ***** assert (icdf (pd, [-1, 0.4:0.2:1, NaN]), [NaN, 1, 1, 2, Inf, NaN], 1e-4); 570s ***** assert (icdf (t, [-1, 0.4:0.2:1, NaN]), [NaN, 2, 2, 3, 4, NaN], 1e-4); 570s ***** assert (iqr (pd), 2); 570s ***** assert (iqr (t), 1); 570s ***** assert (mean (pd), 1); 570s ***** assert (mean (t), 2.3529, 1e-4); 570s ***** assert (mean (t_inf), 2.3922, 1e-4); 570s ***** assert (median (pd), 1); 570s ***** assert (median (t), 2); 570s ***** assert (median (t_inf), 2); 570s ***** assert (pdf (pd, [0:5]), [0.3679, 0.3679, 0.1839, 0.0613, 0.0153, 0.0031], 1e-4); 570s ***** assert (pdf (t, [0:5]), [0, 0, 0.7059, 0.2353, 0.0588, 0], 1e-4); 570s ***** assert (pdf (t_inf, [0:5]), [0, 0, 0.6961, 0.2320, 0.0580, 0.0116], 1e-4); 570s ***** assert (pdf (pd, [-1, 1:4, NaN]), [0, 0.3679, 0.1839, 0.0613, 0.0153, NaN], 1e-4); 570s ***** assert (pdf (t, [-1, 1:4, NaN]), [0, 0, 0.7059, 0.2353, 0.0588, NaN], 1e-4); 570s ***** assert (isequal (size (random (pd, 100, 50)), [100, 50])) 570s ***** assert (any (random (t, 1000, 1) < 2), false); 570s ***** assert (any (random (t, 1000, 1) > 4), false); 570s ***** assert (std (pd), 1); 570s ***** assert (std (t), 0.5882, 1e-4); 570s ***** assert (std (t_inf), 0.6738, 1e-4); 570s ***** assert (var (pd), 1); 570s ***** assert (var (t), 0.3460, 1e-4); 570s ***** assert (var (t_inf), 0.4540, 1e-4); 570s ***** error ... 570s PoissonDistribution(0) 570s ***** error ... 570s PoissonDistribution(-1) 570s ***** error ... 570s PoissonDistribution(Inf) 570s ***** error ... 570s PoissonDistribution(i) 570s ***** error ... 570s PoissonDistribution("a") 570s ***** error ... 570s PoissonDistribution([1, 2]) 570s ***** error ... 570s PoissonDistribution(NaN) 570s ***** error ... 570s cdf (PoissonDistribution, 2, "uper") 570s ***** error ... 570s cdf (PoissonDistribution, 2, 3) 570s ***** shared x 570s x = poissrnd (1, [1, 100]); 570s ***** error ... 570s paramci (PoissonDistribution.fit (x), "alpha") 570s ***** error ... 570s paramci (PoissonDistribution.fit (x), "alpha", 0) 570s ***** error ... 570s paramci (PoissonDistribution.fit (x), "alpha", 1) 570s ***** error ... 570s paramci (PoissonDistribution.fit (x), "alpha", [0.5 2]) 570s ***** error ... 570s paramci (PoissonDistribution.fit (x), "alpha", "") 570s ***** error ... 570s paramci (PoissonDistribution.fit (x), "alpha", {0.05}) 570s ***** error ... 570s paramci (PoissonDistribution.fit (x), "parameter", "lambda", "alpha", {0.05}) 570s ***** error ... 570s paramci (PoissonDistribution.fit (x), "parameter", {"lambda", "param"}) 570s ***** error ... 570s paramci (PoissonDistribution.fit (x), "alpha", 0.01, ... 570s "parameter", {"lambda", "param"}) 570s ***** error ... 570s paramci (PoissonDistribution.fit (x), "parameter", "param") 570s ***** error ... 570s paramci (PoissonDistribution.fit (x), "alpha", 0.01, "parameter", "param") 570s ***** error ... 570s paramci (PoissonDistribution.fit (x), "NAME", "value") 570s ***** error ... 570s paramci (PoissonDistribution.fit (x), "alpha", 0.01, "NAME", "value") 570s ***** error ... 570s paramci (PoissonDistribution.fit (x), "alpha", 0.01, ... 570s "parameter", "lambda", "NAME", "value") 570s ***** error ... 570s plot (PoissonDistribution, "Parent") 570s ***** error ... 570s plot (PoissonDistribution, "PlotType", 12) 570s ***** error ... 570s plot (PoissonDistribution, "PlotType", {"pdf", "cdf"}) 570s ***** error ... 570s plot (PoissonDistribution, "PlotType", "pdfcdf") 570s ***** error ... 570s plot (PoissonDistribution, "Discrete", "pdfcdf") 570s ***** error ... 570s plot (PoissonDistribution, "Discrete", [1, 0]) 570s ***** error ... 570s plot (PoissonDistribution, "Discrete", {true}) 570s ***** error ... 570s plot (PoissonDistribution, "Parent", 12) 570s ***** error ... 570s plot (PoissonDistribution, "Parent", "hax") 570s ***** error ... 570s plot (PoissonDistribution, "invalidNAME", "pdf") 570s ***** error ... 570s plot (PoissonDistribution, "PlotType", "probability") 570s ***** error ... 570s proflik (PoissonDistribution, 2) 570s ***** error ... 570s proflik (PoissonDistribution.fit (x), 3) 570s ***** error ... 570s proflik (PoissonDistribution.fit (x), [1, 2]) 570s ***** error ... 570s proflik (PoissonDistribution.fit (x), {1}) 570s ***** error ... 570s proflik (PoissonDistribution.fit (x), 1, ones (2)) 570s ***** error ... 570s proflik (PoissonDistribution.fit (x), 1, "Display") 570s ***** error ... 570s proflik (PoissonDistribution.fit (x), 1, "Display", 1) 570s ***** error ... 570s proflik (PoissonDistribution.fit (x), 1, "Display", {1}) 570s ***** error ... 570s proflik (PoissonDistribution.fit (x), 1, "Display", {"on"}) 570s ***** error ... 570s proflik (PoissonDistribution.fit (x), 1, "Display", ["on"; "on"]) 570s ***** error ... 570s proflik (PoissonDistribution.fit (x), 1, "Display", "onnn") 570s ***** error ... 570s proflik (PoissonDistribution.fit (x), 1, "NAME", "on") 570s ***** error ... 570s proflik (PoissonDistribution.fit (x), 1, {"NAME"}, "on") 570s ***** error ... 570s proflik (PoissonDistribution.fit (x), 1, {[1 2 3 4]}, "Display", "on") 570s ***** error ... 570s truncate (PoissonDistribution) 570s ***** error ... 570s truncate (PoissonDistribution, 2) 570s ***** error ... 570s truncate (PoissonDistribution, 4, 2) 570s ***** shared pd 570s pd = PoissonDistribution(1); 570s pd(2) = PoissonDistribution(3); 570s ***** error cdf (pd, 1) 570s ***** error icdf (pd, 0.5) 570s ***** error iqr (pd) 570s ***** error mean (pd) 570s ***** error median (pd) 570s ***** error negloglik (pd) 570s ***** error paramci (pd) 570s ***** error pdf (pd, 1) 570s ***** error plot (pd) 570s ***** error proflik (pd, 2) 570s ***** error random (pd) 570s ***** error std (pd) 570s ***** error ... 570s truncate (pd, 2, 4) 570s ***** error var (pd) 570s 97 tests, 97 passed, 0 known failure, 0 skipped 570s [inst/dist_obj/ExponentialDistribution.m] 570s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_obj/ExponentialDistribution.m 570s ***** shared pd, t 570s pd = ExponentialDistribution (1); 570s t = truncate (pd, 2, 4); 570s ***** assert (cdf (pd, [0:5]), [0, 0.6321, 0.8647, 0.9502, 0.9817, 0.9933], 1e-4); 570s ***** assert (cdf (t, [0:5]), [0, 0, 0, 0.7311, 1, 1], 1e-4); 570s ***** assert (cdf (pd, [1.5, 2, 3, 4]), [0.7769, 0.8647, 0.9502, 0.9817], 1e-4); 570s ***** assert (cdf (t, [1.5, 2, 3, 4]), [0, 0, 0.7311, 1], 1e-4); 570s ***** assert (icdf (pd, [0:0.2:1]), [0, 0.2231, 0.5108, 0.9163, 1.6094, Inf], 1e-4); 570s ***** assert (icdf (t, [0:0.2:1]), [2, 2.1899, 2.4244, 2.7315, 3.1768, 4], 1e-4); 570s ***** assert (icdf (pd, [-1, 0.4:0.2:1, NaN]), [NaN, 0.5108, 0.9163, 1.6094, Inf, NaN], 1e-4); 570s ***** assert (icdf (t, [-1, 0.4:0.2:1, NaN]), [NaN, 2.4244, 2.7315, 3.1768, 4, NaN], 1e-4); 570s ***** assert (iqr (pd), 1.0986, 1e-4); 570s ***** assert (iqr (t), 0.8020, 1e-4); 570s ***** assert (mean (pd), 1); 570s ***** assert (mean (t), 2.6870, 1e-4); 570s ***** assert (median (pd), 0.6931, 1e-4); 570s ***** assert (median (t), 2.5662, 1e-4); 570s ***** assert (pdf (pd, [0:5]), [1, 0.3679, 0.1353, 0.0498, 0.0183, 0.0067], 1e-4); 570s ***** assert (pdf (t, [0:5]), [0, 0, 1.1565, 0.4255, 0.1565, 0], 1e-4); 570s ***** assert (pdf (pd, [-1, 1:4, NaN]), [0, 0.3679, 0.1353, 0.0498, 0.0183, NaN], 1e-4); 570s ***** assert (pdf (t, [-1, 1:4, NaN]), [0, 0, 1.1565, 0.4255, 0.1565, NaN], 1e-4); 570s ***** assert (isequal (size (random (pd, 100, 50)), [100, 50])) 570s ***** assert (any (random (t, 1000, 1) < 2), false); 570s ***** assert (any (random (t, 1000, 1) > 4), false); 571s ***** assert (std (pd), 1); 571s ***** assert (std (t), 0.5253, 1e-4); 571s ***** assert (var (pd), 1); 571s ***** assert (var (t), 0.2759, 1e-4); 571s ***** error ... 571s ExponentialDistribution(0) 571s ***** error ... 571s ExponentialDistribution(-1) 571s ***** error ... 571s ExponentialDistribution(Inf) 571s ***** error ... 571s ExponentialDistribution(i) 571s ***** error ... 571s ExponentialDistribution("a") 571s ***** error ... 571s ExponentialDistribution([1, 2]) 571s ***** error ... 571s ExponentialDistribution(NaN) 571s ***** error ... 571s cdf (ExponentialDistribution, 2, "uper") 571s ***** error ... 571s cdf (ExponentialDistribution, 2, 3) 571s ***** shared x 571s x = exprnd (1, [100, 1]); 571s ***** error ... 571s paramci (ExponentialDistribution.fit (x), "alpha") 571s ***** error ... 571s paramci (ExponentialDistribution.fit (x), "alpha", 0) 571s ***** error ... 571s paramci (ExponentialDistribution.fit (x), "alpha", 1) 571s ***** error ... 571s paramci (ExponentialDistribution.fit (x), "alpha", [0.5 2]) 571s ***** error ... 571s paramci (ExponentialDistribution.fit (x), "alpha", "") 571s ***** error ... 571s paramci (ExponentialDistribution.fit (x), "alpha", {0.05}) 571s ***** error ... 571s paramci (ExponentialDistribution.fit (x), "parameter", "mu", ... 571s "alpha", {0.05}) 571s ***** error ... 571s paramci (ExponentialDistribution.fit (x), "parameter", {"mu", "param"}) 571s ***** error ... 571s paramci (ExponentialDistribution.fit (x), "alpha", 0.01, ... 571s "parameter", {"mu", "param"}) 571s ***** error ... 571s paramci (ExponentialDistribution.fit (x), "parameter", "param") 571s ***** error ... 571s paramci (ExponentialDistribution.fit (x), "alpha", 0.01, "parameter", "parm") 571s ***** error ... 571s paramci (ExponentialDistribution.fit (x), "NAME", "value") 571s ***** error ... 571s paramci (ExponentialDistribution.fit (x), "alpha", 0.01, "NAME", "value") 571s ***** error ... 571s paramci (ExponentialDistribution.fit (x), "alpha", 0.01, ... 571s "parameter", "mu", "NAME", "value") 571s ***** error ... 571s plot (ExponentialDistribution, "Parent") 571s ***** error ... 571s plot (ExponentialDistribution, "PlotType", 12) 571s ***** error ... 571s plot (ExponentialDistribution, "PlotType", {"pdf", "cdf"}) 571s ***** error ... 571s plot (ExponentialDistribution, "PlotType", "pdfcdf") 571s ***** error ... 571s plot (ExponentialDistribution, "Discrete", "pdfcdf") 571s ***** error ... 571s plot (ExponentialDistribution, "Discrete", [1, 0]) 571s ***** error ... 571s plot (ExponentialDistribution, "Discrete", {true}) 571s ***** error ... 571s plot (ExponentialDistribution, "Parent", 12) 571s ***** error ... 571s plot (ExponentialDistribution, "Parent", "hax") 571s ***** error ... 571s plot (ExponentialDistribution, "invalidNAME", "pdf") 571s ***** error ... 571s plot (ExponentialDistribution, "PlotType", "probability") 571s ***** error ... 571s proflik (ExponentialDistribution, 2) 571s ***** error ... 571s proflik (ExponentialDistribution.fit (x), 3) 571s ***** error ... 571s proflik (ExponentialDistribution.fit (x), [1, 2]) 571s ***** error ... 571s proflik (ExponentialDistribution.fit (x), {1}) 571s ***** error ... 571s proflik (ExponentialDistribution.fit (x), 1, ones (2)) 571s ***** error ... 571s proflik (ExponentialDistribution.fit (x), 1, "Display") 572s ***** error ... 572s proflik (ExponentialDistribution.fit (x), 1, "Display", 1) 572s ***** error ... 572s proflik (ExponentialDistribution.fit (x), 1, "Display", {1}) 572s ***** error ... 572s proflik (ExponentialDistribution.fit (x), 1, "Display", {"on"}) 572s ***** error ... 572s proflik (ExponentialDistribution.fit (x), 1, "Display", ["on"; "on"]) 572s ***** error ... 572s proflik (ExponentialDistribution.fit (x), 1, "Display", "onnn") 572s ***** error ... 572s proflik (ExponentialDistribution.fit (x), 1, "NAME", "on") 572s ***** error ... 572s proflik (ExponentialDistribution.fit (x), 1, {"NAME"}, "on") 572s ***** error ... 572s proflik (ExponentialDistribution.fit (x), 1, {[1 2 3 4]}, "Display", "on") 572s ***** error ... 572s truncate (ExponentialDistribution) 572s ***** error ... 572s truncate (ExponentialDistribution, 2) 572s ***** error ... 572s truncate (ExponentialDistribution, 4, 2) 572s ***** shared pd 572s pd = ExponentialDistribution(1); 572s pd(2) = ExponentialDistribution(3); 572s ***** error cdf (pd, 1) 572s ***** error icdf (pd, 0.5) 572s ***** error iqr (pd) 572s ***** error mean (pd) 572s ***** error median (pd) 572s ***** error negloglik (pd) 572s ***** error paramci (pd) 572s ***** error pdf (pd, 1) 572s ***** error plot (pd) 572s ***** error proflik (pd, 2) 572s ***** error random (pd) 572s ***** error std (pd) 572s ***** error ... 572s truncate (pd, 2, 4) 572s ***** error var (pd) 572s 90 tests, 90 passed, 0 known failure, 0 skipped 572s [inst/dist_obj/NegativeBinomialDistribution.m] 572s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_obj/NegativeBinomialDistribution.m 572s ***** shared pd, t, t_inf 572s pd = NegativeBinomialDistribution (5, 0.5); 572s t = truncate (pd, 2, 4); 572s t_inf = truncate (pd, 2, Inf); 572s ***** assert (cdf (pd, [0:5]), [0.0312, 0.1094, 0.2266, 0.3633, 0.5, 0.6230], 1e-4); 572s ***** assert (cdf (t, [0:5]), [0, 0, 0.3, 0.65, 1, 1], 1e-4); 572s ***** assert (cdf (t_inf, [0:5]), [0, 0, 0.1316, 0.2851, 0.4386, 0.5768], 1e-4); 572s ***** assert (cdf (pd, [1.5, 2, 3, 4]), [0.1094, 0.2266, 0.3633, 0.5000], 1e-4); 572s ***** assert (cdf (t, [1.5, 2, 3, 4]), [0, 0.3, 0.65, 1], 1e-4); 572s ***** assert (icdf (pd, [0:0.2:1]), [0, 2, 4, 5, 7, Inf], 1e-4); 572s ***** assert (icdf (t, [0:0.2:1]), [2, 2, 3, 3, 4, 4], 1e-4); 572s ***** assert (icdf (t_inf, [0:0.2:1]), [2, 3, 4, 6, 8, Inf], 1e-4); 572s ***** assert (icdf (pd, [-1, 0.4:0.2:1, NaN]), [NaN, 4, 5, 7, Inf, NaN], 1e-4); 572s ***** assert (icdf (t, [-1, 0.4:0.2:1, NaN]), [NaN, 3, 3, 4, 4, NaN], 1e-4); 572s ***** assert (iqr (pd), 4); 572s ***** assert (iqr (t), 2); 572s ***** assert (mean (pd), 5); 572s ***** assert (mean (t), 3.0500, 1e-4); 572s ***** assert (mean (t_inf), 5.5263, 1e-4); 572s ***** assert (median (pd), 4); 572s ***** assert (median (t), 3); 572s ***** assert (pdf (pd, [0:5]), [0.0312, 0.0781, 0.1172, 0.1367, 0.1367, 0.1230], 1e-4); 572s ***** assert (pdf (t, [0:5]), [0, 0, 0.3, 0.35, 0.35, 0], 1e-4); 572s ***** assert (pdf (t_inf, [0:5]), [0, 0, 0.1316, 0.1535, 0.1535, 0.1382], 1e-4); 572s ***** assert (pdf (pd, [-1, 1:4, NaN]), [0, 0.0781, 0.1172, 0.1367, 0.1367, NaN], 1e-4); 572s ***** assert (pdf (t, [-1, 1:4, NaN]), [0, 0, 0.3, 0.35, 0.35, NaN], 1e-4); 572s ***** assert (isequal (size (random (pd, 100, 50)), [100, 50])) 572s ***** assert (any (random (t, 1000, 1) < 2), false); 572s ***** assert (any (random (t, 1000, 1) > 4), false); 572s ***** assert (std (pd), 3.1623, 1e-4); 572s ***** assert (std (t), 0.8047, 1e-4); 572s ***** assert (std (t_inf), 2.9445, 1e-4); 572s ***** assert (var (pd), 10); 572s ***** assert (var (t), 0.6475, 1e-4); 572s ***** assert (var (t_inf), 8.6704, 1e-4); 572s ***** error ... 572s NegativeBinomialDistribution(Inf, 1) 572s ***** error ... 572s NegativeBinomialDistribution(i, 1) 572s ***** error ... 572s NegativeBinomialDistribution("a", 1) 572s ***** error ... 572s NegativeBinomialDistribution([1, 2], 1) 572s ***** error ... 572s NegativeBinomialDistribution(NaN, 1) 572s ***** error ... 572s NegativeBinomialDistribution(1, 0) 572s ***** error ... 572s NegativeBinomialDistribution(1, -1) 572s ***** error ... 572s NegativeBinomialDistribution(1, Inf) 572s ***** error ... 572s NegativeBinomialDistribution(1, i) 572s ***** error ... 572s NegativeBinomialDistribution(1, "a") 572s ***** error ... 572s NegativeBinomialDistribution(1, [1, 2]) 572s ***** error ... 572s NegativeBinomialDistribution(1, NaN) 572s ***** error ... 572s NegativeBinomialDistribution(1, 1.2) 572s ***** error ... 572s cdf (NegativeBinomialDistribution, 2, "uper") 572s ***** error ... 572s cdf (NegativeBinomialDistribution, 2, 3) 572s ***** shared x 572s x = nbinrnd (1, 0.5, [1, 100]); 572s ***** error ... 572s paramci (NegativeBinomialDistribution.fit (x), "alpha") 572s ***** error ... 572s paramci (NegativeBinomialDistribution.fit (x), "alpha", 0) 572s ***** error ... 572s paramci (NegativeBinomialDistribution.fit (x), "alpha", 1) 572s ***** error ... 572s paramci (NegativeBinomialDistribution.fit (x), "alpha", [0.5 2]) 572s ***** error ... 572s paramci (NegativeBinomialDistribution.fit (x), "alpha", "") 573s ***** error ... 573s paramci (NegativeBinomialDistribution.fit (x), "alpha", {0.05}) 573s ***** error ... 573s paramci (NegativeBinomialDistribution.fit (x), "parameter", "R", ... 573s "alpha", {0.05}) 573s ***** error ... 573s paramci (NegativeBinomialDistribution.fit (x), ... 573s "parameter", {"R", "P", "param"}) 573s ***** error ... 573s paramci (NegativeBinomialDistribution.fit (x), "alpha", 0.01, ... 573s "parameter", {"R", "P", "param"}) 573s ***** error ... 573s paramci (NegativeBinomialDistribution.fit (x), "parameter", "param") 573s ***** error ... 573s paramci (NegativeBinomialDistribution.fit (x), "alpha", 0.01, ... 573s "parameter", "param") 573s ***** error ... 573s paramci (NegativeBinomialDistribution.fit (x), "NAME", "value") 573s ***** error ... 573s paramci (NegativeBinomialDistribution.fit (x), "alpha", 0.01, ... 573s "NAME", "value") 573s ***** error ... 573s paramci (NegativeBinomialDistribution.fit (x), "alpha", 0.01, ... 573s "parameter", "R", "NAME", "value") 573s ***** error ... 573s plot (NegativeBinomialDistribution, "Parent") 573s ***** error ... 573s plot (NegativeBinomialDistribution, "PlotType", 12) 573s ***** error ... 573s plot (NegativeBinomialDistribution, "PlotType", {"pdf", "cdf"}) 573s ***** error ... 573s plot (NegativeBinomialDistribution, "PlotType", "pdfcdf") 573s ***** error ... 573s plot (NegativeBinomialDistribution, "Discrete", "pdfcdf") 573s ***** error ... 573s plot (NegativeBinomialDistribution, "Discrete", [1, 0]) 573s ***** error ... 573s plot (NegativeBinomialDistribution, "Discrete", {true}) 573s ***** error ... 573s plot (NegativeBinomialDistribution, "Parent", 12) 573s ***** error ... 573s plot (NegativeBinomialDistribution, "Parent", "hax") 573s ***** error ... 573s plot (NegativeBinomialDistribution, "invalidNAME", "pdf") 573s ***** error ... 573s plot (NegativeBinomialDistribution, "PlotType", "probability") 573s ***** error ... 573s proflik (NegativeBinomialDistribution, 2) 573s ***** error ... 573s proflik (NegativeBinomialDistribution.fit (x), 3) 573s ***** error ... 573s proflik (NegativeBinomialDistribution.fit (x), [1, 2]) 573s ***** error ... 573s proflik (NegativeBinomialDistribution.fit (x), {1}) 573s ***** error ... 573s proflik (NegativeBinomialDistribution.fit (x), 1, ones (2)) 573s ***** error ... 573s proflik (NegativeBinomialDistribution.fit (x), 1, "Display") 573s ***** error ... 573s proflik (NegativeBinomialDistribution.fit (x), 1, "Display", 1) 573s ***** error ... 573s proflik (NegativeBinomialDistribution.fit (x), 1, "Display", {1}) 573s ***** error ... 573s proflik (NegativeBinomialDistribution.fit (x), 1, "Display", {"on"}) 573s ***** error ... 573s proflik (NegativeBinomialDistribution.fit (x), 1, "Display", ["on"; "on"]) 573s ***** error ... 573s proflik (NegativeBinomialDistribution.fit (x), 1, "Display", "onnn") 573s ***** error ... 573s proflik (NegativeBinomialDistribution.fit (x), 1, "NAME", "on") 573s ***** error ... 573s proflik (NegativeBinomialDistribution.fit (x), 1, {"NAME"}, "on") 573s ***** error ... 573s proflik (NegativeBinomialDistribution.fit (x), 1, {[1 2 3]}, "Display", "on") 573s ***** error ... 573s truncate (NegativeBinomialDistribution) 573s ***** error ... 573s truncate (NegativeBinomialDistribution, 2) 573s ***** error ... 573s truncate (NegativeBinomialDistribution, 4, 2) 573s ***** shared pd 573s pd = NegativeBinomialDistribution(1, 0.5); 573s pd(2) = NegativeBinomialDistribution(1, 0.6); 573s ***** error cdf (pd, 1) 573s ***** error icdf (pd, 0.5) 573s ***** error iqr (pd) 573s ***** error mean (pd) 573s ***** error median (pd) 573s ***** error negloglik (pd) 573s ***** error paramci (pd) 573s ***** error pdf (pd, 1) 573s ***** error plot (pd) 573s ***** error proflik (pd, 2) 573s ***** error random (pd) 573s ***** error std (pd) 573s ***** error ... 573s truncate (pd, 2, 4) 573s ***** error var (pd) 573s 102 tests, 102 passed, 0 known failure, 0 skipped 573s [inst/dist_obj/RayleighDistribution.m] 573s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_obj/RayleighDistribution.m 573s ***** shared pd, t 573s pd = RayleighDistribution; 573s t = truncate (pd, 2, 4); 573s ***** assert (cdf (pd, [0:5]), [0, 0.3935, 0.8647, 0.9889, 0.9997, 1], 1e-4); 573s ***** assert (cdf (t, [0:5]), [0, 0, 0, 0.9202, 1, 1], 1e-4); 573s ***** assert (cdf (pd, [1.5, 2, 3, 4, NaN]), [0.6753, 0.8647, 0.9889, 0.9997, NaN], 1e-4); 573s ***** assert (cdf (t, [1.5, 2, 3, 4, NaN]), [0, 0, 0.9202, 1, NaN], 1e-4); 573s ***** assert (icdf (pd, [0:0.2:1]), [0, 0.6680, 1.0108, 1.3537, 1.7941, Inf], 1e-4); 573s ***** assert (icdf (t, [0:0.2:1]), [2, 2.1083, 2.2402, 2.4135, 2.6831, 4], 1e-4); 573s ***** assert (icdf (pd, [-1, 0.4:0.2:1, NaN]), [NaN, 1.0108, 1.3537, 1.7941, Inf, NaN], 1e-4); 573s ***** assert (icdf (t, [-1, 0.4:0.2:1, NaN]), [NaN, 2.2402, 2.4135, 2.6831, 4, NaN], 1e-4); 573s ***** assert (iqr (pd), 0.9066, 1e-4); 573s ***** assert (iqr (t), 0.4609, 1e-4); 573s ***** assert (mean (pd), 1.2533, 1e-4); 573s ***** assert (mean (t), 2.4169, 1e-4); 573s ***** assert (median (pd), 1.1774, 1e-4); 573s ***** assert (median (t), 2.3198, 1e-4); 573s ***** assert (pdf (pd, [0:5]), [0, 0.6065, 0.2707, 0.0333, 0.0013, 0], 1e-4); 573s ***** assert (pdf (t, [0:5]), [0, 0, 2.0050, 0.2469, 0.0099, 0], 1e-4); 573s ***** assert (pdf (pd, [-1, 1.5, NaN]), [0, 0.4870, NaN], 1e-4); 573s ***** assert (pdf (t, [-1, 1.5, NaN]), [0, 0, NaN], 1e-4); 573s ***** assert (isequal (size (random (pd, 100, 50)), [100, 50])) 573s ***** assert (any (random (t, 1000, 1) < 2), false); 573s ***** assert (any (random (t, 1000, 1) > 4), false); 573s ***** assert (std (pd), 0.6551, 1e-4); 573s ***** assert (std (t), 0.3591, 1e-4); 573s ***** assert (var (pd), 0.4292, 1e-4); 573s ***** assert (var (t), 0.1290, 1e-4); 573s ***** error ... 573s RayleighDistribution(0) 573s ***** error ... 573s RayleighDistribution(-1) 573s ***** error ... 573s RayleighDistribution(Inf) 573s ***** error ... 573s RayleighDistribution(i) 573s ***** error ... 573s RayleighDistribution("a") 573s ***** error ... 573s RayleighDistribution([1, 2]) 573s ***** error ... 573s RayleighDistribution(NaN) 573s ***** error ... 573s cdf (RayleighDistribution, 2, "uper") 573s ***** error ... 573s cdf (RayleighDistribution, 2, 3) 573s ***** shared x 573s x = raylrnd (1, [1, 100]); 573s ***** error ... 573s paramci (RayleighDistribution.fit (x), "alpha") 573s ***** error ... 573s paramci (RayleighDistribution.fit (x), "alpha", 0) 573s ***** error ... 573s paramci (RayleighDistribution.fit (x), "alpha", 1) 573s ***** error ... 573s paramci (RayleighDistribution.fit (x), "alpha", [0.5 2]) 574s ***** error ... 574s paramci (RayleighDistribution.fit (x), "alpha", "") 574s ***** error ... 574s paramci (RayleighDistribution.fit (x), "alpha", {0.05}) 574s ***** error ... 574s paramci (RayleighDistribution.fit (x), "parameter", "sigma", "alpha", {0.05}) 574s ***** error ... 574s paramci (RayleighDistribution.fit (x), "parameter", {"sigma", "param"}) 574s ***** error ... 574s paramci (RayleighDistribution.fit (x), "alpha", 0.01, ... 574s "parameter", {"sigma", "param"}) 574s ***** error ... 574s paramci (RayleighDistribution.fit (x), "parameter", "param") 574s ***** error ... 574s paramci (RayleighDistribution.fit (x), "alpha", 0.01, "parameter", "param") 574s ***** error ... 574s paramci (RayleighDistribution.fit (x), "NAME", "value") 574s ***** error ... 574s paramci (RayleighDistribution.fit (x), "alpha", 0.01, "NAME", "value") 574s ***** error ... 574s paramci (RayleighDistribution.fit (x), "alpha", 0.01, ... 574s "parameter", "sigma", "NAME", "value") 574s ***** error ... 574s plot (RayleighDistribution, "Parent") 574s ***** error ... 574s plot (RayleighDistribution, "PlotType", 12) 574s ***** error ... 574s plot (RayleighDistribution, "PlotType", {"pdf", "cdf"}) 574s ***** error ... 574s plot (RayleighDistribution, "PlotType", "pdfcdf") 574s ***** error ... 574s plot (RayleighDistribution, "Discrete", "pdfcdf") 574s ***** error ... 574s plot (RayleighDistribution, "Discrete", [1, 0]) 574s ***** error ... 574s plot (RayleighDistribution, "Discrete", {true}) 574s ***** error ... 574s plot (RayleighDistribution, "Parent", 12) 574s ***** error ... 574s plot (RayleighDistribution, "Parent", "hax") 574s ***** error ... 574s plot (RayleighDistribution, "invalidNAME", "pdf") 574s ***** error ... 574s plot (RayleighDistribution, "PlotType", "probability") 574s ***** error ... 574s proflik (RayleighDistribution, 2) 574s ***** error ... 574s proflik (RayleighDistribution.fit (x), 3) 574s ***** error ... 574s proflik (RayleighDistribution.fit (x), [1, 2]) 574s ***** error ... 574s proflik (RayleighDistribution.fit (x), {1}) 574s ***** error ... 574s proflik (RayleighDistribution.fit (x), 1, ones (2)) 574s ***** error ... 574s proflik (RayleighDistribution.fit (x), 1, "Display") 574s ***** error ... 574s proflik (RayleighDistribution.fit (x), 1, "Display", 1) 574s ***** error ... 574s proflik (RayleighDistribution.fit (x), 1, "Display", {1}) 574s ***** error ... 574s proflik (RayleighDistribution.fit (x), 1, "Display", {"on"}) 574s ***** error ... 574s proflik (RayleighDistribution.fit (x), 1, "Display", ["on"; "on"]) 574s ***** error ... 574s proflik (RayleighDistribution.fit (x), 1, "Display", "onnn") 574s ***** error ... 574s proflik (RayleighDistribution.fit (x), 1, "NAME", "on") 574s ***** error ... 574s proflik (RayleighDistribution.fit (x), 1, {"NAME"}, "on") 575s ***** error ... 575s proflik (RayleighDistribution.fit (x), 1, {[1 2 3 4]}, "Display", "on") 575s ***** error ... 575s truncate (RayleighDistribution) 575s ***** error ... 575s truncate (RayleighDistribution, 2) 575s ***** error ... 575s truncate (RayleighDistribution, 4, 2) 575s ***** shared pd 575s pd = RayleighDistribution(1); 575s pd(2) = RayleighDistribution(3); 575s ***** error cdf (pd, 1) 575s ***** error icdf (pd, 0.5) 575s ***** error iqr (pd) 575s ***** error mean (pd) 575s ***** error median (pd) 575s ***** error negloglik (pd) 575s ***** error paramci (pd) 575s ***** error pdf (pd, 1) 575s ***** error plot (pd) 575s ***** error proflik (pd, 2) 575s ***** error random (pd) 575s ***** error std (pd) 575s ***** error ... 575s truncate (pd, 2, 4) 575s ***** error var (pd) 575s 90 tests, 90 passed, 0 known failure, 0 skipped 575s [inst/dist_obj/NakagamiDistribution.m] 575s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_obj/NakagamiDistribution.m 575s ***** shared pd, t 575s pd = NakagamiDistribution; 575s t = truncate (pd, 2, 4); 575s ***** assert (cdf (pd, [0:5]), [0, 0.6321, 0.9817, 0.9999, 1, 1], 1e-4); 575s ***** assert (cdf (t, [0:5]), [0, 0, 0, 0.9933, 1, 1], 1e-4); 575s ***** assert (cdf (pd, [1.5, 2, 3, 4]), [0.8946, 0.9817, 0.9999, 1], 1e-4); 575s ***** assert (cdf (t, [1.5, 2, 3, 4]), [0, 0, 0.9933, 1], 1e-4); 575s ***** assert (icdf (pd, [0:0.2:1]), [0, 0.4724, 0.7147, 0.9572, 1.2686, Inf], 1e-4); 575s ***** assert (icdf (t, [0:0.2:1]), [2, 2.0550, 2.1239, 2.2173, 2.3684, 4], 1e-4); 575s ***** assert (icdf (pd, [-1, 0.4:0.2:1, NaN]), [NaN, 0.7147, 0.9572, 1.2686, Inf, NaN], 1e-4); 575s ***** assert (icdf (t, [-1, 0.4:0.2:1, NaN]), [NaN, 2.1239, 2.2173, 2.3684, 4, NaN], 1e-4); 575s ***** assert (iqr (pd), 0.6411, 1e-4); 575s ***** assert (iqr (t), 0.2502, 1e-4); 575s ***** assert (mean (pd), 0.8862, 1e-4); 575s ***** assert (mean (t), 2.2263, 1e-4); 575s ***** assert (median (pd), 0.8326, 1e-4); 575s ***** assert (median (t), 2.1664, 1e-4); 575s ***** assert (pdf (pd, [0:5]), [0, 0.7358, 0.0733, 0.0007, 0, 0], 1e-4); 575s ***** assert (pdf (t, [0:5]), [0, 0, 4, 0.0404, 0, 0], 1e-4); 575s ***** assert (pdf (pd, [-1, 1:4, NaN]), [0, 0.7358, 0.0733, 0.0007, 0, NaN], 1e-4); 575s ***** assert (pdf (t, [-1, 1:4, NaN]), [0, 0, 4, 0.0404, 0, NaN], 1e-4); 575s ***** assert (isequal (size (random (pd, 100, 50)), [100, 50])) 575s ***** assert (any (random (t, 1000, 1) < 2), false); 575s ***** assert (any (random (t, 1000, 1) > 4), false); 575s ***** assert (std (pd), 0.4633, 1e-4); 575s ***** assert (std (t), 0.2083, 1e-4); 575s ***** assert (var (pd), 0.2146, 1e-4); 575s ***** assert (var (t), 0.0434, 1e-4); 575s ***** error ... 575s NakagamiDistribution(Inf, 1) 575s ***** error ... 575s NakagamiDistribution(i, 1) 575s ***** error ... 575s NakagamiDistribution("a", 1) 575s ***** error ... 575s NakagamiDistribution([1, 2], 1) 575s ***** error ... 575s NakagamiDistribution(NaN, 1) 575s ***** error ... 575s NakagamiDistribution(1, 0) 575s ***** error ... 575s NakagamiDistribution(1, -1) 575s ***** error ... 575s NakagamiDistribution(1, Inf) 575s ***** error ... 575s NakagamiDistribution(1, i) 575s ***** error ... 575s NakagamiDistribution(1, "a") 575s ***** error ... 575s NakagamiDistribution(1, [1, 2]) 575s ***** error ... 575s NakagamiDistribution(1, NaN) 575s ***** error ... 575s cdf (NakagamiDistribution, 2, "uper") 575s ***** error ... 575s cdf (NakagamiDistribution, 2, 3) 575s ***** shared x 575s x = nakarnd (1, 0.5, [1, 100]); 575s ***** error ... 575s paramci (NakagamiDistribution.fit (x), "alpha") 575s ***** error ... 575s paramci (NakagamiDistribution.fit (x), "alpha", 0) 575s ***** error ... 575s paramci (NakagamiDistribution.fit (x), "alpha", 1) 575s ***** error ... 575s paramci (NakagamiDistribution.fit (x), "alpha", [0.5 2]) 575s ***** error ... 575s paramci (NakagamiDistribution.fit (x), "alpha", "") 575s ***** error ... 575s paramci (NakagamiDistribution.fit (x), "alpha", {0.05}) 575s ***** error ... 575s paramci (NakagamiDistribution.fit (x), "parameter", "mu", "alpha", {0.05}) 575s ***** error ... 575s paramci (NakagamiDistribution.fit (x), "parameter", {"mu", "omega", "param"}) 575s ***** error ... 575s paramci (NakagamiDistribution.fit (x), "alpha", 0.01, ... 575s "parameter", {"mu", "omega", "param"}) 575s ***** error ... 575s paramci (NakagamiDistribution.fit (x), "parameter", "param") 575s ***** error ... 575s paramci (NakagamiDistribution.fit (x), "alpha", 0.01, "parameter", "param") 575s ***** error ... 575s paramci (NakagamiDistribution.fit (x), "NAME", "value") 575s ***** error ... 575s paramci (NakagamiDistribution.fit (x), "alpha", 0.01, "NAME", "value") 575s ***** error ... 575s paramci (NakagamiDistribution.fit (x), "alpha", 0.01, "parameter", "mu", ... 575s "NAME", "value") 575s ***** error ... 575s plot (NakagamiDistribution, "Parent") 575s ***** error ... 575s plot (NakagamiDistribution, "PlotType", 12) 575s ***** error ... 575s plot (NakagamiDistribution, "PlotType", {"pdf", "cdf"}) 575s ***** error ... 575s plot (NakagamiDistribution, "PlotType", "pdfcdf") 575s ***** error ... 575s plot (NakagamiDistribution, "Discrete", "pdfcdf") 575s ***** error ... 575s plot (NakagamiDistribution, "Discrete", [1, 0]) 575s ***** error ... 575s plot (NakagamiDistribution, "Discrete", {true}) 575s ***** error ... 575s plot (NakagamiDistribution, "Parent", 12) 575s ***** error ... 575s plot (NakagamiDistribution, "Parent", "hax") 575s ***** error ... 575s plot (NakagamiDistribution, "invalidNAME", "pdf") 575s ***** error ... 575s plot (NakagamiDistribution, "PlotType", "probability") 575s ***** error ... 575s proflik (NakagamiDistribution, 2) 575s ***** error ... 575s proflik (NakagamiDistribution.fit (x), 3) 576s ***** error ... 576s proflik (NakagamiDistribution.fit (x), [1, 2]) 576s ***** error ... 576s proflik (NakagamiDistribution.fit (x), {1}) 576s ***** error ... 576s proflik (NakagamiDistribution.fit (x), 1, ones (2)) 576s ***** error ... 576s proflik (NakagamiDistribution.fit (x), 1, "Display") 576s ***** error ... 576s proflik (NakagamiDistribution.fit (x), 1, "Display", 1) 576s ***** error ... 576s proflik (NakagamiDistribution.fit (x), 1, "Display", {1}) 576s ***** error ... 576s proflik (NakagamiDistribution.fit (x), 1, "Display", {"on"}) 576s ***** error ... 576s proflik (NakagamiDistribution.fit (x), 1, "Display", ["on"; "on"]) 576s ***** error ... 576s proflik (NakagamiDistribution.fit (x), 1, "Display", "onnn") 576s ***** error ... 576s proflik (NakagamiDistribution.fit (x), 1, "NAME", "on") 576s ***** error ... 576s proflik (NakagamiDistribution.fit (x), 1, {"NAME"}, "on") 576s ***** error ... 576s proflik (NakagamiDistribution.fit (x), 1, {[1 2 3 4]}, "Display", "on") 576s ***** error ... 576s truncate (NakagamiDistribution) 576s ***** error ... 576s truncate (NakagamiDistribution, 2) 576s ***** error ... 576s truncate (NakagamiDistribution, 4, 2) 576s ***** shared pd 576s pd = NakagamiDistribution(1, 0.5); 576s pd(2) = NakagamiDistribution(1, 0.6); 576s ***** error cdf (pd, 1) 576s ***** error icdf (pd, 0.5) 576s ***** error iqr (pd) 576s ***** error mean (pd) 576s ***** error median (pd) 576s ***** error negloglik (pd) 576s ***** error paramci (pd) 576s ***** error pdf (pd, 1) 576s ***** error plot (pd) 576s ***** error proflik (pd, 2) 576s ***** error random (pd) 576s ***** error std (pd) 576s ***** error ... 576s truncate (pd, 2, 4) 576s ***** error var (pd) 576s 95 tests, 95 passed, 0 known failure, 0 skipped 576s [inst/dist_obj/NormalDistribution.m] 576s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_obj/NormalDistribution.m 576s ***** shared pd, t 576s pd = NormalDistribution; 576s t = truncate (pd, -2, 2); 576s ***** assert (cdf (pd, [0:5]), [0.5, 0.8413, 0.9772, 0.9987, 1, 1], 1e-4); 576s ***** assert (cdf (t, [0:5]), [0.5, 0.8576, 1, 1, 1, 1], 1e-4); 576s ***** assert (cdf (pd, [1.5, 2, 3, 4]), [0.9332, 0.9772, 0.9987, 1], 1e-4); 576s ***** assert (cdf (t, [1.5, 2, 3, 4]), [0.9538, 1, 1, 1], 1e-4); 576s ***** assert (icdf (pd, [0:0.2:1]), [-Inf, -0.8416, -0.2533, 0.2533, 0.8416, Inf], 1e-4); 576s ***** assert (icdf (t, [0:0.2:1]), [-2, -0.7938, -0.2416, 0.2416, 0.7938, 2], 1e-4); 576s ***** assert (icdf (pd, [-1, 0.4:0.2:1, NaN]), [NaN, -0.2533, 0.2533, 0.8416, Inf, NaN], 1e-4); 576s ***** assert (icdf (t, [-1, 0.4:0.2:1, NaN]), [NaN, -0.2416, 0.2416, 0.7938, 2, NaN], 1e-4); 576s ***** assert (iqr (pd), 1.3490, 1e-4); 576s ***** assert (iqr (t), 1.2782, 1e-4); 576s ***** assert (mean (pd), 0); 576s ***** assert (mean (t), 0, 3e-16); 576s ***** assert (median (pd), 0); 576s ***** assert (median (t), 0, 3e-16); 576s ***** assert (pdf (pd, [0:5]), [0.3989, 0.2420, 0.0540, 0.0044, 0.0001, 0], 1e-4); 576s ***** assert (pdf (t, [0:5]), [0.4180, 0.2535, 0.0566, 0, 0, 0], 1e-4); 576s ***** assert (pdf (pd, [-1, 1:4, NaN]), [0.2420, 0.2420, 0.0540, 0.0044, 0.0001, NaN], 1e-4); 576s ***** assert (pdf (t, [-1, 1:4, NaN]), [0.2535, 0.2535, 0.0566, 0, 0, NaN], 1e-4); 576s ***** assert (isequal (size (random (pd, 100, 50)), [100, 50])) 576s ***** assert (any (random (t, 1000, 1) < -2), false); 576s ***** assert (any (random (t, 1000, 1) > 2), false); 576s ***** assert (std (pd), 1); 576s ***** assert (std (t), 0.8796, 1e-4); 576s ***** assert (var (pd), 1); 576s ***** assert (var (t), 0.7737, 1e-4); 576s ***** error ... 576s NormalDistribution(Inf, 1) 576s ***** error ... 576s NormalDistribution(i, 1) 576s ***** error ... 576s NormalDistribution("a", 1) 576s ***** error ... 576s NormalDistribution([1, 2], 1) 576s ***** error ... 576s NormalDistribution(NaN, 1) 576s ***** error ... 576s NormalDistribution(1, 0) 576s ***** error ... 576s NormalDistribution(1, -1) 576s ***** error ... 576s NormalDistribution(1, Inf) 576s ***** error ... 576s NormalDistribution(1, i) 576s ***** error ... 576s NormalDistribution(1, "a") 576s ***** error ... 576s NormalDistribution(1, [1, 2]) 576s ***** error ... 576s NormalDistribution(1, NaN) 576s ***** error ... 576s cdf (NormalDistribution, 2, "uper") 576s ***** error ... 576s cdf (NormalDistribution, 2, 3) 576s ***** shared x 576s x = normrnd (1, 1, [1, 100]); 576s ***** error ... 576s paramci (NormalDistribution.fit (x), "alpha") 576s ***** error ... 576s paramci (NormalDistribution.fit (x), "alpha", 0) 577s ***** error ... 577s paramci (NormalDistribution.fit (x), "alpha", 1) 577s ***** error ... 577s paramci (NormalDistribution.fit (x), "alpha", [0.5 2]) 577s ***** error ... 577s paramci (NormalDistribution.fit (x), "alpha", "") 577s ***** error ... 577s paramci (NormalDistribution.fit (x), "alpha", {0.05}) 577s ***** error ... 577s paramci (NormalDistribution.fit (x), "parameter", "mu", "alpha", {0.05}) 578s ***** error ... 578s paramci (NormalDistribution.fit (x), "parameter", {"mu", "sigma", "param"}) 578s ***** error ... 578s paramci (NormalDistribution.fit (x), "alpha", 0.01, ... 578s "parameter", {"mu", "sigma", "param"}) 578s ***** error ... 578s paramci (NormalDistribution.fit (x), "parameter", "param") 578s ***** error ... 578s paramci (NormalDistribution.fit (x), "alpha", 0.01, "parameter", "param") 578s ***** error ... 578s paramci (NormalDistribution.fit (x), "NAME", "value") 578s ***** error ... 578s paramci (NormalDistribution.fit (x), "alpha", 0.01, "NAME", "value") 579s ***** error ... 579s paramci (NormalDistribution.fit (x), "alpha", 0.01, "parameter", "mu", ... 579s "NAME", "value") 579s ***** error ... 579s plot (NormalDistribution, "Parent") 579s ***** error ... 579s plot (NormalDistribution, "PlotType", 12) 579s ***** error ... 579s plot (NormalDistribution, "PlotType", {"pdf", "cdf"}) 579s ***** error ... 579s plot (NormalDistribution, "PlotType", "pdfcdf") 579s ***** error ... 579s plot (NormalDistribution, "Discrete", "pdfcdf") 579s ***** error ... 579s plot (NormalDistribution, "Discrete", [1, 0]) 579s ***** error ... 579s plot (NormalDistribution, "Discrete", {true}) 579s ***** error ... 579s plot (NormalDistribution, "Parent", 12) 579s ***** error ... 579s plot (NormalDistribution, "Parent", "hax") 579s ***** error ... 579s plot (NormalDistribution, "invalidNAME", "pdf") 579s ***** error ... 579s plot (NormalDistribution, "PlotType", "probability") 579s ***** error ... 579s proflik (NormalDistribution, 2) 579s ***** error ... 579s proflik (NormalDistribution.fit (x), 3) 579s ***** error ... 579s proflik (NormalDistribution.fit (x), [1, 2]) 579s ***** error ... 579s proflik (NormalDistribution.fit (x), {1}) 579s ***** error ... 579s proflik (NormalDistribution.fit (x), 1, ones (2)) 579s ***** error ... 579s proflik (NormalDistribution.fit (x), 1, "Display") 580s ***** error ... 580s proflik (NormalDistribution.fit (x), 1, "Display", 1) 580s ***** error ... 580s proflik (NormalDistribution.fit (x), 1, "Display", {1}) 580s ***** error ... 580s proflik (NormalDistribution.fit (x), 1, "Display", {"on"}) 580s ***** error ... 580s proflik (NormalDistribution.fit (x), 1, "Display", ["on"; "on"]) 580s ***** error ... 580s proflik (NormalDistribution.fit (x), 1, "Display", "onnn") 580s ***** error ... 580s proflik (NormalDistribution.fit (x), 1, "NAME", "on") 581s ***** error ... 581s proflik (NormalDistribution.fit (x), 1, {"NAME"}, "on") 581s ***** error ... 581s proflik (NormalDistribution.fit (x), 1, {[1 2 3 4]}, "Display", "on") 581s ***** error ... 581s truncate (NormalDistribution) 581s ***** error ... 581s truncate (NormalDistribution, 2) 581s ***** error ... 581s truncate (NormalDistribution, 4, 2) 581s ***** shared pd 581s pd = NormalDistribution(1, 1); 581s pd(2) = NormalDistribution(1, 3); 581s ***** error cdf (pd, 1) 581s ***** error icdf (pd, 0.5) 581s ***** error iqr (pd) 581s ***** error mean (pd) 581s ***** error median (pd) 581s ***** error negloglik (pd) 581s ***** error paramci (pd) 581s ***** error pdf (pd, 1) 581s ***** error plot (pd) 581s ***** error proflik (pd, 2) 581s ***** error random (pd) 581s ***** error std (pd) 581s ***** error ... 581s truncate (pd, 2, 4) 581s ***** error var (pd) 581s 95 tests, 95 passed, 0 known failure, 0 skipped 581s [inst/dist_obj/UniformDistribution.m] 581s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_obj/UniformDistribution.m 581s ***** shared pd, t 581s pd = UniformDistribution (0, 5); 581s t = truncate (pd, 2, 4); 581s ***** assert (cdf (pd, [0:5]), [0, 0.2, 0.4, 0.6, 0.8, 1], 1e-4); 581s ***** assert (cdf (t, [0:5]), [0, 0, 0, 0.5, 1, 1], 1e-4); 581s ***** assert (cdf (pd, [1.5, 2, 3, 4, NaN]), [0.3, 0.4, 0.6, 0.8, NaN], 1e-4); 581s ***** assert (cdf (t, [1.5, 2, 3, 4, NaN]), [0, 0, 0.5, 1, NaN], 1e-4); 581s ***** assert (icdf (pd, [0:0.2:1]), [0, 1, 2, 3, 4, 5], 1e-4); 581s ***** assert (icdf (t, [0:0.2:1]), [2, 2.4, 2.8, 3.2, 3.6, 4], 1e-4); 581s ***** assert (icdf (pd, [-1, 0.4:0.2:1, NaN]), [NaN, 2, 3, 4, 5, NaN], 1e-4); 581s ***** assert (icdf (t, [-1, 0.4:0.2:1, NaN]), [NaN, 2.8, 3.2, 3.6, 4, NaN], 1e-4); 581s ***** assert (iqr (pd), 2.5, 1e-14); 581s ***** assert (iqr (t), 1, 1e-14); 581s ***** assert (mean (pd), 2.5, 1e-14); 581s ***** assert (mean (t), 3, 1e-14); 581s ***** assert (median (pd), 2.5, 1e-14); 581s ***** assert (median (t), 3, 1e-14); 581s ***** assert (pdf (pd, [0:5]), [0.2, 0.2, 0.2, 0.2, 0.2, 0.2], 1e-4); 581s ***** assert (pdf (t, [0:5]), [0, 0, 0.5, 0.5, 0.5, 0], 1e-4); 581s ***** assert (pdf (pd, [-1, 1.5, NaN]), [0, 0.2, NaN], 1e-4); 581s ***** assert (pdf (t, [-1, 1.5, NaN]), [0, 0, NaN], 1e-4); 581s ***** assert (isequal (size (random (pd, 100, 50)), [100, 50])) 581s ***** assert (any (random (t, 1000, 1) < 2), false); 581s ***** assert (any (random (t, 1000, 1) > 4), false); 581s ***** assert (std (pd), 1.4434, 1e-4); 581s ***** assert (std (t), 0.5774, 1e-4); 581s ***** assert (var (pd), 2.0833, 1e-4); 581s ***** assert (var (t), 0.3333, 1e-4); 581s ***** error ... 581s UniformDistribution (i, 1) 581s ***** error ... 581s UniformDistribution (Inf, 1) 581s ***** error ... 581s UniformDistribution ([1, 2], 1) 581s ***** error ... 581s UniformDistribution ("a", 1) 581s ***** error ... 581s UniformDistribution (NaN, 1) 581s ***** error ... 581s UniformDistribution (1, i) 581s ***** error ... 581s UniformDistribution (1, Inf) 581s ***** error ... 581s UniformDistribution (1, [1, 2]) 581s ***** error ... 581s UniformDistribution (1, "a") 581s ***** error ... 581s UniformDistribution (1, NaN) 581s ***** error ... 581s UniformDistribution (2, 1) 581s ***** error ... 581s cdf (UniformDistribution, 2, "uper") 581s ***** error ... 581s cdf (UniformDistribution, 2, 3) 581s ***** error ... 581s plot (UniformDistribution, "Parent") 581s ***** error ... 581s plot (UniformDistribution, "PlotType", 12) 581s ***** error ... 581s plot (UniformDistribution, "PlotType", {"pdf", "cdf"}) 581s ***** error ... 581s plot (UniformDistribution, "PlotType", "pdfcdf") 581s ***** error ... 581s plot (UniformDistribution, "Discrete", "pdfcdf") 581s ***** error ... 581s plot (UniformDistribution, "Discrete", [1, 0]) 581s ***** error ... 581s plot (UniformDistribution, "Discrete", {true}) 581s ***** error ... 581s plot (UniformDistribution, "Parent", 12) 581s ***** error ... 581s plot (UniformDistribution, "Parent", "hax") 581s ***** error ... 581s plot (UniformDistribution, "invalidNAME", "pdf") 581s ***** error ... 581s plot (UniformDistribution, "PlotType", "probability") 581s ***** error ... 581s truncate (UniformDistribution) 581s ***** error ... 581s truncate (UniformDistribution, 2) 581s ***** error ... 581s truncate (UniformDistribution, 4, 2) 581s ***** shared pd 581s pd = UniformDistribution (0, 1); 581s pd(2) = UniformDistribution (0, 2); 581s ***** error cdf (pd, 1) 581s ***** error icdf (pd, 0.5) 581s ***** error iqr (pd) 581s ***** error mean (pd) 581s ***** error median (pd) 581s ***** error pdf (pd, 1) 581s ***** error plot (pd) 581s ***** error random (pd) 581s ***** error std (pd) 581s ***** error ... 581s truncate (pd, 2, 4) 581s ***** error var (pd) 581s 63 tests, 63 passed, 0 known failure, 0 skipped 581s [inst/dist_obj/MultinomialDistribution.m] 581s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_obj/MultinomialDistribution.m 581s ***** shared pd, t 581s pd = MultinomialDistribution ([0.1, 0.2, 0.3, 0.2, 0.1, 0.1]); 581s t = truncate (pd, 2, 4); 581s ***** assert (cdf (pd, [2, 3, 4]), [0.3, 0.6, 0.8], eps); 581s ***** assert (cdf (t, [2, 3, 4]), [0.2857, 0.7143, 1], 1e-4); 581s ***** assert (cdf (pd, [1.5, 2, 3, 4]), [0.1, 0.3, 0.6, 0.8], eps); 581s ***** assert (cdf (pd, [1.5, 2-eps, 3, 4]), [0.1, 0.1, 0.6, 0.8], eps); 581s ***** assert (cdf (t, [1.5, 2, 3, 4]), [0, 0.2857, 0.7143, 1], 1e-4); 581s ***** assert (cdf (t, [1.5, 2-eps, 3, 4]), [0, 0, 0.7143, 1], 1e-4); 581s ***** assert (cdf (pd, [1, 2.5, 4, 6]), [0.1, 0.3, 0.8, 1], eps); 581s ***** assert (icdf (pd, [0, 0.2857, 0.7143, 1]), [1, 2, 4, 6]); 581s ***** assert (icdf (t, [0, 0.2857, 0.7143, 1]), [2, 2, 4, 4]); 581s ***** assert (icdf (t, [0, 0.35, 0.7143, 1]), [2, 3, 4, 4]); 581s ***** assert (icdf (t, [0, 0.35, 0.7143, 1, NaN]), [2, 3, 4, 4, NaN]); 581s ***** assert (icdf (t, [-0.5, 0, 0.35, 0.7143, 1, NaN]), [NaN, 2, 3, 4, 4, NaN]); 581s ***** assert (icdf (pd, [-0.5, 0, 0.35, 0.7143, 1, NaN]), [NaN, 1, 3, 4, 6, NaN]); 581s ***** assert (iqr (pd), 2); 581s ***** assert (iqr (t), 2); 581s ***** assert (mean (pd), 3.3, 1e-14); 581s ***** assert (mean (t), 3, eps); 581s ***** assert (median (pd), 3); 581s ***** assert (median (t), 3); 581s ***** assert (pdf (pd, [-5, 1, 2.5, 4, 6, NaN, 9]), [0, 0.1, 0, 0.2, 0.1, NaN, 0]); 581s ***** assert (pdf (pd, [-5, 1, 2, 3, 4, 6, NaN, 9]), ... 581s [0, 0.1, 0.2, 0.3, 0.2, 0.1, NaN, 0]); 581s ***** assert (pdf (t, [-5, 1, 2, 3, 4, 6, NaN, 0]), ... 581s [0, 0, 0.2857, 0.4286, 0.2857, 0, NaN, 0], 1e-4); 581s ***** assert (pdf (t, [-5, 1, 2, 4, 6, NaN, 0]), ... 581s [0, 0, 0.2857, 0.2857, 0, NaN, 0], 1e-4); 581s ***** assert (unique (random (pd, 1000, 5)), [1, 2, 3, 4, 5, 6]'); 581s ***** assert (unique (random (t, 1000, 5)), [2, 3, 4]'); 581s ***** assert (std (pd), 1.4177, 1e-4); 581s ***** assert (std (t), 0.7559, 1e-4); 581s ***** assert (var (pd), 2.0100, 1e-4); 581s ***** assert (var (t), 0.5714, 1e-4); 581s ***** error ... 581s MultinomialDistribution(0) 581s ***** error ... 581s MultinomialDistribution(-1) 581s ***** error ... 581s MultinomialDistribution(Inf) 581s ***** error ... 581s MultinomialDistribution(i) 581s ***** error ... 581s MultinomialDistribution("a") 581s ***** error ... 581s MultinomialDistribution([1, 2]) 581s ***** error ... 581s MultinomialDistribution(NaN) 581s ***** error ... 581s cdf (MultinomialDistribution, 2, "uper") 581s ***** error ... 581s cdf (MultinomialDistribution, 2, 3) 581s ***** error ... 581s cdf (MultinomialDistribution, i) 581s ***** error ... 581s plot (MultinomialDistribution, "Parent") 581s ***** error ... 581s plot (MultinomialDistribution, "PlotType", 12) 581s ***** error ... 581s plot (MultinomialDistribution, "PlotType", {"pdf", "cdf"}) 581s ***** error ... 581s plot (MultinomialDistribution, "PlotType", "pdfcdf") 581s ***** error ... 581s plot (MultinomialDistribution, "Discrete", "pdfcdf") 581s ***** error ... 581s plot (MultinomialDistribution, "Discrete", [1, 0]) 581s ***** error ... 581s plot (MultinomialDistribution, "Discrete", {true}) 581s ***** error ... 581s plot (MultinomialDistribution, "Parent", 12) 581s ***** error ... 581s plot (MultinomialDistribution, "Parent", "hax") 581s ***** error ... 581s plot (MultinomialDistribution, "invalidNAME", "pdf") 581s ***** error ... 581s plot (MultinomialDistribution, "PlotType", "probability") 581s ***** error ... 581s truncate (MultinomialDistribution) 581s ***** error ... 581s truncate (MultinomialDistribution, 2) 581s ***** error ... 581s truncate (MultinomialDistribution, 4, 2) 581s ***** shared pd 581s pd = MultinomialDistribution([0.1, 0.2, 0.3, 0.4]); 581s pd(2) = MultinomialDistribution([0.1, 0.2, 0.3, 0.4]); 581s ***** error cdf (pd, 1) 581s ***** error icdf (pd, 0.5) 581s ***** error iqr (pd) 581s ***** error mean (pd) 581s ***** error median (pd) 581s ***** error pdf (pd, 1) 581s ***** error plot (pd) 581s ***** error random (pd) 581s ***** error std (pd) 581s ***** error ... 581s truncate (pd, 2, 4) 581s ***** error var (pd) 581s 64 tests, 64 passed, 0 known failure, 0 skipped 581s [inst/dist_obj/GammaDistribution.m] 581s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_obj/GammaDistribution.m 581s ***** shared pd, t 581s pd = GammaDistribution (1, 1); 581s t = truncate (pd, 2, 4); 581s ***** assert (cdf (pd, [0:5]), [0, 0.6321, 0.8647, 0.9502, 0.9817, 0.9933], 1e-4); 581s ***** assert (cdf (t, [0:5]), [0, 0, 0, 0.7311, 1, 1], 1e-4); 581s ***** assert (cdf (pd, [1.5, 2, 3, 4]), [0.7769, 0.8647, 0.9502, 0.9817], 1e-4); 581s ***** assert (cdf (t, [1.5, 2, 3, 4]), [0, 0, 0.7311, 1], 1e-4); 581s ***** assert (icdf (pd, [0:0.2:1]), [0, 0.2231, 0.5108, 0.9163, 1.6094, Inf], 1e-4); 581s ***** assert (icdf (t, [0:0.2:1]), [2, 2.1899, 2.4244, 2.7315, 3.1768, 4], 1e-4); 582s ***** assert (icdf (pd, [-1, 0.4:0.2:1, NaN]), [NaN, 0.5108, 0.9163, 1.6094, Inf, NaN], 1e-4); 582s ***** assert (icdf (t, [-1, 0.4:0.2:1, NaN]), [NaN, 2.4244, 2.7315, 3.1768, 4, NaN], 1e-4); 582s ***** assert (iqr (pd), 1.0986, 1e-4); 582s ***** assert (iqr (t), 0.8020, 1e-4); 582s ***** assert (mean (pd), 1); 582s ***** assert (mean (t), 2.6870, 1e-4); 582s ***** assert (median (pd), 0.6931, 1e-4); 582s ***** assert (median (t), 2.5662, 1e-4); 582s ***** assert (pdf (pd, [0:5]), [1, 0.3679, 0.1353, 0.0498, 0.0183, 0.0067], 1e-4); 582s ***** assert (pdf (t, [0:5]), [0, 0, 1.1565, 0.4255, 0.1565, 0], 1e-4); 582s ***** assert (pdf (pd, [-1, 1:4, NaN]), [0, 0.3679, 0.1353, 0.0498, 0.0183, NaN], 1e-4); 582s ***** assert (pdf (t, [-1, 1:4, NaN]), [0, 0, 1.1565, 0.4255, 0.1565, NaN], 1e-4); 582s ***** assert (isequal (size (random (pd, 100, 50)), [100, 50])) 582s ***** assert (any (random (t, 1000, 1) < 2), false); 582s ***** assert (any (random (t, 1000, 1) > 4), false); 582s ***** assert (std (pd), 1); 582s ***** assert (std (t), 0.5253, 1e-4); 582s ***** assert (var (pd), 1); 582s ***** assert (var (t), 0.2759, 1e-4); 582s ***** error ... 582s GammaDistribution(0, 1) 582s ***** error ... 582s GammaDistribution(Inf, 1) 582s ***** error ... 582s GammaDistribution(i, 1) 582s ***** error ... 582s GammaDistribution("a", 1) 582s ***** error ... 582s GammaDistribution([1, 2], 1) 582s ***** error ... 582s GammaDistribution(NaN, 1) 582s ***** error ... 582s GammaDistribution(1, 0) 582s ***** error ... 582s GammaDistribution(1, -1) 582s ***** error ... 582s GammaDistribution(1, Inf) 582s ***** error ... 582s GammaDistribution(1, i) 582s ***** error ... 582s GammaDistribution(1, "a") 582s ***** error ... 582s GammaDistribution(1, [1, 2]) 582s ***** error ... 582s GammaDistribution(1, NaN) 582s ***** error ... 582s cdf (GammaDistribution, 2, "uper") 582s ***** error ... 582s cdf (GammaDistribution, 2, 3) 582s ***** shared x 582s x = gamrnd (1, 1, [100, 1]); 582s ***** error ... 582s paramci (GammaDistribution.fit (x), "alpha") 582s ***** error ... 582s paramci (GammaDistribution.fit (x), "alpha", 0) 582s ***** error ... 582s paramci (GammaDistribution.fit (x), "alpha", 1) 582s ***** error ... 582s paramci (GammaDistribution.fit (x), "alpha", [0.5 2]) 582s ***** error ... 582s paramci (GammaDistribution.fit (x), "alpha", "") 582s ***** error ... 582s paramci (GammaDistribution.fit (x), "alpha", {0.05}) 582s ***** error ... 582s paramci (GammaDistribution.fit (x), "parameter", "a", "alpha", {0.05}) 582s ***** error ... 582s paramci (GammaDistribution.fit (x), "parameter", {"a", "b", "param"}) 582s ***** error ... 582s paramci (GammaDistribution.fit (x), "alpha", 0.01, ... 582s "parameter", {"a", "b", "param"}) 582s ***** error ... 582s paramci (GammaDistribution.fit (x), "parameter", "param") 582s ***** error ... 582s paramci (GammaDistribution.fit (x), "alpha", 0.01, "parameter", "param") 582s ***** error ... 582s paramci (GammaDistribution.fit (x), "NAME", "value") 582s ***** error ... 582s paramci (GammaDistribution.fit (x), "alpha", 0.01, "NAME", "value") 582s ***** error ... 582s paramci (GammaDistribution.fit (x), "alpha", 0.01, "parameter", "a", ... 582s "NAME", "value") 582s ***** error ... 582s plot (GammaDistribution, "Parent") 582s ***** error ... 582s plot (GammaDistribution, "PlotType", 12) 582s ***** error ... 582s plot (GammaDistribution, "PlotType", {"pdf", "cdf"}) 582s ***** error ... 582s plot (GammaDistribution, "PlotType", "pdfcdf") 582s ***** error ... 582s plot (GammaDistribution, "Discrete", "pdfcdf") 582s ***** error ... 582s plot (GammaDistribution, "Discrete", [1, 0]) 582s ***** error ... 582s plot (GammaDistribution, "Discrete", {true}) 582s ***** error ... 582s plot (GammaDistribution, "Parent", 12) 582s ***** error ... 582s plot (GammaDistribution, "Parent", "hax") 582s ***** error ... 582s plot (GammaDistribution, "invalidNAME", "pdf") 582s ***** error ... 582s plot (GammaDistribution, "PlotType", "probability") 582s ***** error ... 582s proflik (GammaDistribution, 2) 582s ***** error ... 582s proflik (GammaDistribution.fit (x), 3) 582s ***** error ... 582s proflik (GammaDistribution.fit (x), [1, 2]) 582s ***** error ... 582s proflik (GammaDistribution.fit (x), {1}) 582s ***** error ... 582s proflik (GammaDistribution.fit (x), 1, ones (2)) 582s ***** error ... 582s proflik (GammaDistribution.fit (x), 1, "Display") 582s ***** error ... 582s proflik (GammaDistribution.fit (x), 1, "Display", 1) 583s ***** error ... 583s proflik (GammaDistribution.fit (x), 1, "Display", {1}) 583s ***** error ... 583s proflik (GammaDistribution.fit (x), 1, "Display", {"on"}) 583s ***** error ... 583s proflik (GammaDistribution.fit (x), 1, "Display", ["on"; "on"]) 583s ***** error ... 583s proflik (GammaDistribution.fit (x), 1, "Display", "onnn") 583s ***** error ... 583s proflik (GammaDistribution.fit (x), 1, "NAME", "on") 583s ***** error ... 583s proflik (GammaDistribution.fit (x), 1, {"NAME"}, "on") 583s ***** error ... 583s proflik (GammaDistribution.fit (x), 1, {[1 2 3 4]}, "Display", "on") 583s ***** error ... 583s truncate (GammaDistribution) 583s ***** error ... 583s truncate (GammaDistribution, 2) 583s ***** error ... 583s truncate (GammaDistribution, 4, 2) 583s ***** shared pd 583s pd = GammaDistribution(1, 1); 583s pd(2) = GammaDistribution(1, 3); 583s ***** error cdf (pd, 1) 583s ***** error icdf (pd, 0.5) 583s ***** error iqr (pd) 583s ***** error mean (pd) 583s ***** error median (pd) 583s ***** error negloglik (pd) 583s ***** error paramci (pd) 583s ***** error pdf (pd, 1) 583s ***** error plot (pd) 583s ***** error proflik (pd, 2) 583s ***** error random (pd) 583s ***** error std (pd) 583s ***** error ... 583s truncate (pd, 2, 4) 583s ***** error var (pd) 583s 96 tests, 96 passed, 0 known failure, 0 skipped 583s [inst/dist_obj/BinomialDistribution.m] 583s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_obj/BinomialDistribution.m 583s ***** shared pd, t, t_inf 583s pd = BinomialDistribution (5, 0.5); 583s t = truncate (pd, 2, 4); 583s t_inf = truncate (pd, 2, Inf); 583s ***** assert (cdf (pd, [0:5]), [0.0312, 0.1875, 0.5, 0.8125, 0.9688, 1], 1e-4); 583s ***** assert (cdf (t, [0:5]), [0, 0, 0.4, 0.8, 1, 1], 1e-4); 583s ***** assert (cdf (t_inf, [0:5]), [0, 0, 0.3846, 0.7692, 0.9615, 1], 1e-4); 583s ***** assert (cdf (pd, [1.5, 2, 3, 4, NaN]), [0.1875, 0.5, 0.8125, 0.9688, NaN], 1e-4); 583s ***** assert (cdf (t, [1.5, 2, 3, 4, NaN]), [0, 0.4, 0.8, 1, NaN], 1e-4); 583s ***** assert (icdf (pd, [0:0.2:1]), [0, 2, 2, 3, 3, 5], 1e-4); 583s ***** assert (icdf (t, [0:0.2:1]), [2, 2, 2, 3, 3, 4], 1e-4); 583s ***** assert (icdf (t_inf, [0:0.2:1]), [2, 2, 3, 3, 4, 5], 1e-4); 583s ***** assert (icdf (pd, [-1, 0.4:0.2:1, NaN]), [NaN, 2, 3, 3, 5, NaN], 1e-4); 583s ***** assert (icdf (t, [-1, 0.4:0.2:1, NaN]), [NaN, 2, 3, 3, 4, NaN], 1e-4); 583s ***** assert (iqr (pd), 1); 583s ***** assert (iqr (t), 1); 583s ***** assert (mean (pd), 2.5, 1e-10); 583s ***** assert (mean (t), 2.8, 1e-10); 583s ***** assert (mean (t_inf), 2.8846, 1e-4); 583s ***** assert (median (pd), 2.5); 583s ***** assert (median (t), 3); 583s ***** assert (pdf (pd, [0:5]), [0.0312, 0.1562, 0.3125, 0.3125, 0.1562, 0.0312], 1e-4); 583s ***** assert (pdf (t, [0:5]), [0, 0, 0.4, 0.4, 0.2, 0], 1e-4); 583s ***** assert (pdf (t_inf, [0:5]), [0, 0, 0.3846, 0.3846, 0.1923, 0.0385], 1e-4); 583s ***** assert (pdf (pd, [-1, 1.5, NaN]), [0, 0, NaN], 1e-4); 583s ***** assert (pdf (t, [-1, 1.5, NaN]), [0, 0, NaN], 1e-4); 583s ***** assert (isequal (size (random (pd, 100, 50)), [100, 50])) 583s ***** assert (any (random (t, 1000, 1) < 2), false); 583s ***** assert (any (random (t, 1000, 1) > 4), false); 583s ***** assert (std (pd), 1.1180, 1e-4); 583s ***** assert (std (t), 0.7483, 1e-4); 583s ***** assert (std (t_inf), 0.8470, 1e-4); 583s ***** assert (var (pd), 1.2500, 1e-4); 583s ***** assert (var (t), 0.5600, 1e-4); 583s ***** assert (var (t_inf), 0.7175, 1e-4); 583s ***** error ... 583s BinomialDistribution(Inf, 0.5) 583s ***** error ... 583s BinomialDistribution(i, 0.5) 583s ***** error ... 583s BinomialDistribution("a", 0.5) 583s ***** error ... 583s BinomialDistribution([1, 2], 0.5) 583s ***** error ... 583s BinomialDistribution(NaN, 0.5) 583s ***** error ... 583s BinomialDistribution(1, 1.01) 583s ***** error ... 583s BinomialDistribution(1, -0.01) 583s ***** error ... 583s BinomialDistribution(1, Inf) 583s ***** error ... 583s BinomialDistribution(1, i) 583s ***** error ... 583s BinomialDistribution(1, "a") 583s ***** error ... 583s BinomialDistribution(1, [1, 2]) 583s ***** error ... 583s BinomialDistribution(1, NaN) 583s ***** error ... 583s cdf (BinomialDistribution, 2, "uper") 583s ***** error ... 583s cdf (BinomialDistribution, 2, 3) 583s ***** shared x 583s rand ("seed", 2); 583s x = binornd (5, 0.5, [1, 100]); 583s ***** error ... 583s paramci (BinomialDistribution.fit (x, 6), "alpha") 583s ***** error ... 583s paramci (BinomialDistribution.fit (x, 6), "alpha", 0) 583s ***** error ... 583s paramci (BinomialDistribution.fit (x, 6), "alpha", 1) 583s ***** error ... 583s paramci (BinomialDistribution.fit (x, 6), "alpha", [0.5 2]) 583s ***** error ... 583s paramci (BinomialDistribution.fit (x, 6), "alpha", "") 583s ***** error ... 583s paramci (BinomialDistribution.fit (x, 6), "alpha", {0.05}) 583s ***** error ... 583s paramci (BinomialDistribution.fit (x, 6), "parameter", "p", ... 583s "alpha", {0.05}) 583s ***** error ... 583s paramci (BinomialDistribution.fit (x, 6), ... 583s "parameter", {"N", "p", "param"}) 583s ***** error ... 583s paramci (BinomialDistribution.fit (x, 6), "alpha", 0.01, ... 583s "parameter", {"N", "p", "param"}) 583s ***** error ... 583s paramci (BinomialDistribution.fit (x, 6), "parameter", "param") 583s ***** error ... 583s paramci (BinomialDistribution.fit (x, 6), "parameter", "N") 584s ***** error ... 584s paramci (BinomialDistribution.fit (x, 6), "alpha", 0.01, ... 584s "parameter", "param") 584s ***** error ... 584s paramci (BinomialDistribution.fit (x, 6), "NAME", "value") 584s ***** error ... 584s paramci (BinomialDistribution.fit (x, 6), "alpha", 0.01, ... 584s "NAME", "value") 584s ***** error ... 584s paramci (BinomialDistribution.fit (x, 6), "alpha", 0.01, ... 584s "parameter", "p", "NAME", "value") 584s ***** error ... 584s plot (BinomialDistribution, "Parent") 584s ***** error ... 584s plot (BinomialDistribution, "PlotType", 12) 584s ***** error ... 584s plot (BinomialDistribution, "PlotType", {"pdf", "cdf"}) 584s ***** error ... 584s plot (BinomialDistribution, "PlotType", "pdfcdf") 584s ***** error ... 584s plot (BinomialDistribution, "Discrete", "pdfcdf") 584s ***** error ... 584s plot (BinomialDistribution, "Discrete", [1, 0]) 584s ***** error ... 584s plot (BinomialDistribution, "Discrete", {true}) 584s ***** error ... 584s plot (BinomialDistribution, "Parent", 12) 584s ***** error ... 584s plot (BinomialDistribution, "Parent", "hax") 584s ***** error ... 584s plot (BinomialDistribution, "invalidNAME", "pdf") 584s ***** error ... 584s plot (BinomialDistribution, "PlotType", "probability") 584s ***** error ... 584s proflik (BinomialDistribution, 2) 584s ***** error ... 584s proflik (BinomialDistribution.fit (x, 6), 3) 584s ***** error ... 584s proflik (BinomialDistribution.fit (x, 6), [1, 2]) 584s ***** error ... 584s proflik (BinomialDistribution.fit (x, 6), {1}) 584s ***** error ... 584s proflik (BinomialDistribution.fit (x, 6), 2, ones (2)) 584s ***** error ... 584s proflik (BinomialDistribution.fit (x, 6), 2, "Display") 584s ***** error ... 584s proflik (BinomialDistribution.fit (x, 6), 2, "Display", 1) 584s ***** error ... 584s proflik (BinomialDistribution.fit (x, 6), 2, "Display", {1}) 584s ***** error ... 584s proflik (BinomialDistribution.fit (x, 6), 2, "Display", {"on"}) 584s ***** error ... 584s proflik (BinomialDistribution.fit (x, 6), 2, "Display", ["on"; "on"]) 584s ***** error ... 584s proflik (BinomialDistribution.fit (x, 6), 2, "Display", "onnn") 584s ***** error ... 584s proflik (BinomialDistribution.fit (x, 6), 2, "NAME", "on") 584s ***** error ... 584s proflik (BinomialDistribution.fit (x, 6), 2, {"NAME"}, "on") 584s ***** error ... 584s proflik (BinomialDistribution.fit (x, 6), 2, {[1 2 3]}, "Display", "on") 584s ***** error ... 584s truncate (BinomialDistribution) 584s ***** error ... 584s truncate (BinomialDistribution, 2) 584s ***** error ... 584s truncate (BinomialDistribution, 4, 2) 584s ***** shared pd 584s pd = BinomialDistribution(1, 0.5); 584s pd(2) = BinomialDistribution(1, 0.6); 584s ***** error cdf (pd, 1) 584s ***** error icdf (pd, 0.5) 584s ***** error iqr (pd) 584s ***** error mean (pd) 584s ***** error median (pd) 584s ***** error negloglik (pd) 584s ***** error paramci (pd) 584s ***** error pdf (pd, 1) 584s ***** error plot (pd) 584s ***** error proflik (pd, 2) 584s ***** error random (pd) 584s ***** error std (pd) 584s ***** error ... 584s truncate (pd, 2, 4) 584s ***** error var (pd) 584s 102 tests, 102 passed, 0 known failure, 0 skipped 584s [inst/dist_obj/ExtremeValueDistribution.m] 584s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_obj/ExtremeValueDistribution.m 584s ***** shared pd, t 584s pd = ExtremeValueDistribution (0, 1); 584s t = truncate (pd, 2, 4); 584s ***** assert (cdf (pd, [0:5]), [0.6321, 0.9340, 0.9994, 1, 1, 1], 1e-4); 584s ***** assert (cdf (t, [0:5]), [0, 0, 0, 1, 1, 1], 1e-4); 584s ***** assert (cdf (pd, [1.5, 2, 3, 4]), [0.9887, 0.9994, 1, 1], 1e-4); 584s ***** assert (cdf (t, [1.5, 2, 3, 4]), [0, 0, 1, 1], 1e-4); 584s ***** assert (icdf (pd, [0:0.2:1]), [-Inf, -1.4999, -0.6717, -0.0874, 0.4759, Inf], 1e-4); 584s ***** assert (icdf (t, [0:0.2:1]), [2, 2.0298, 2.0668, 2.1169, 2.1971, 4], 1e-4); 584s ***** assert (icdf (pd, [-1, 0.4:0.2:1, NaN]), [NaN, -0.6717, -0.0874, 0.4759, Inf, NaN], 1e-4); 584s ***** assert (icdf (t, [-1, 0.4:0.2:1, NaN]), [NaN, 2.0668, 2.1169, 2.1971, 4, NaN], 1e-4); 584s ***** assert (iqr (pd), 1.5725, 1e-4); 584s ***** assert (iqr (t), 0.1338, 1e-4); 584s ***** assert (mean (pd), -0.5772, 1e-4); 584s ***** assert (mean (t), 2.1206, 1e-4); 584s ***** assert (median (pd), -0.3665, 1e-4); 584s ***** assert (median (t), 2.0897, 1e-4); 584s ***** assert (pdf (pd, [0:5]), [0.3679, 0.1794, 0.0046, 0, 0, 0], 1e-4); 584s ***** assert (pdf (t, [0:5]), [0, 0, 7.3891, 0.0001, 0, 0], 1e-4); 584s ***** assert (pdf (pd, [-1, 1:4, NaN]), [0.2546, 0.1794, 0.0046, 0, 0, NaN], 1e-4); 584s ***** assert (pdf (t, [-1, 1:4, NaN]), [0, 0, 7.3891, 0.0001, 0, NaN], 1e-4); 584s ***** assert (isequal (size (random (pd, 100, 50)), [100, 50])) 584s ***** assert (any (random (t, 1000, 1) < 2), false); 585s ***** assert (any (random (t, 1000, 1) > 4), false); 585s ***** assert (std (pd), 1.2825, 1e-4); 585s ***** assert (std (t), 0.1091, 1e-4); 586s ***** assert (var (pd), 1.6449, 1e-4); 586s ***** assert (var (t), 0.0119, 1e-4); 586s ***** error ... 586s ExtremeValueDistribution(Inf, 1) 586s ***** error ... 586s ExtremeValueDistribution(i, 1) 586s ***** error ... 586s ExtremeValueDistribution("a", 1) 586s ***** error ... 586s ExtremeValueDistribution([1, 2], 1) 586s ***** error ... 586s ExtremeValueDistribution(NaN, 1) 586s ***** error ... 586s ExtremeValueDistribution(1, 0) 586s ***** error ... 586s ExtremeValueDistribution(1, -1) 586s ***** error ... 586s ExtremeValueDistribution(1, Inf) 586s ***** error ... 586s ExtremeValueDistribution(1, i) 586s ***** error ... 586s ExtremeValueDistribution(1, "a") 586s ***** error ... 586s ExtremeValueDistribution(1, [1, 2]) 586s ***** error ... 586s ExtremeValueDistribution(1, NaN) 586s ***** error ... 586s cdf (ExtremeValueDistribution, 2, "uper") 586s ***** error ... 586s cdf (ExtremeValueDistribution, 2, 3) 586s ***** shared x 586s rand ("seed", 1); 586s x = evrnd (1, 1, [1000, 1]); 586s ***** error ... 586s paramci (ExtremeValueDistribution.fit (x), "alpha") 586s ***** error ... 586s paramci (ExtremeValueDistribution.fit (x), "alpha", 0) 586s ***** error ... 586s paramci (ExtremeValueDistribution.fit (x), "alpha", 1) 586s ***** error ... 586s paramci (ExtremeValueDistribution.fit (x), "alpha", [0.5 2]) 586s ***** error ... 586s paramci (ExtremeValueDistribution.fit (x), "alpha", "") 586s ***** error ... 586s paramci (ExtremeValueDistribution.fit (x), "alpha", {0.05}) 586s ***** error ... 586s paramci (ExtremeValueDistribution.fit (x), ... 586s "parameter", "mu", "alpha", {0.05}) 586s ***** error ... 586s paramci (ExtremeValueDistribution.fit (x), ... 586s "parameter", {"mu", "sigma", "param"}) 586s ***** error ... 586s paramci (ExtremeValueDistribution.fit (x), "alpha", 0.01, ... 586s "parameter", {"mu", "sigma", "param"}) 586s ***** error ... 586s paramci (ExtremeValueDistribution.fit (x), "parameter", "param") 586s ***** error ... 586s paramci (ExtremeValueDistribution.fit (x), "alpha", 0.01, ... 586s "parameter", "param") 586s ***** error ... 586s paramci (ExtremeValueDistribution.fit (x), "NAME", "value") 586s ***** error ... 586s paramci (ExtremeValueDistribution.fit (x), "alpha", 0.01, "NAME", "value") 586s ***** error ... 586s paramci (ExtremeValueDistribution.fit (x), "alpha", 0.01, ... 586s "parameter", "mu", "NAME", "value") 586s ***** error ... 586s plot (ExtremeValueDistribution, "Parent") 586s ***** error ... 586s plot (ExtremeValueDistribution, "PlotType", 12) 586s ***** error ... 586s plot (ExtremeValueDistribution, "PlotType", {"pdf", "cdf"}) 586s ***** error ... 586s plot (ExtremeValueDistribution, "PlotType", "pdfcdf") 586s ***** error ... 586s plot (ExtremeValueDistribution, "Discrete", "pdfcdf") 586s ***** error ... 586s plot (ExtremeValueDistribution, "Discrete", [1, 0]) 586s ***** error ... 586s plot (ExtremeValueDistribution, "Discrete", {true}) 586s ***** error ... 586s plot (ExtremeValueDistribution, "Parent", 12) 586s ***** error ... 586s plot (ExtremeValueDistribution, "Parent", "hax") 586s ***** error ... 586s plot (ExtremeValueDistribution, "invalidNAME", "pdf") 586s ***** error ... 586s plot (ExtremeValueDistribution, "PlotType", "probability") 586s ***** error ... 586s proflik (ExtremeValueDistribution, 2) 586s ***** error ... 586s proflik (ExtremeValueDistribution.fit (x), 3) 586s ***** error ... 586s proflik (ExtremeValueDistribution.fit (x), [1, 2]) 586s ***** error ... 586s proflik (ExtremeValueDistribution.fit (x), {1}) 586s ***** error ... 586s proflik (ExtremeValueDistribution.fit (x), 1, ones (2)) 586s ***** error ... 586s proflik (ExtremeValueDistribution.fit (x), 1, "Display") 586s ***** error ... 586s proflik (ExtremeValueDistribution.fit (x), 1, "Display", 1) 586s ***** error ... 586s proflik (ExtremeValueDistribution.fit (x), 1, "Display", {1}) 586s ***** error ... 586s proflik (ExtremeValueDistribution.fit (x), 1, "Display", {"on"}) 586s ***** error ... 586s proflik (ExtremeValueDistribution.fit (x), 1, "Display", ["on"; "on"]) 586s ***** error ... 586s proflik (ExtremeValueDistribution.fit (x), 1, "Display", "onnn") 586s ***** error ... 586s proflik (ExtremeValueDistribution.fit (x), 1, "NAME", "on") 586s ***** error ... 586s proflik (ExtremeValueDistribution.fit (x), 1, {"NAME"}, "on") 587s ***** error ... 587s proflik (ExtremeValueDistribution.fit (x), 1, {[1 2 3 4]}, "Display", "on") 587s ***** error ... 587s truncate (ExtremeValueDistribution) 587s ***** error ... 587s truncate (ExtremeValueDistribution, 2) 587s ***** error ... 587s truncate (ExtremeValueDistribution, 4, 2) 587s ***** shared pd 587s pd = ExtremeValueDistribution(1, 1); 587s pd(2) = ExtremeValueDistribution(1, 3); 587s ***** error cdf (pd, 1) 587s ***** error icdf (pd, 0.5) 587s ***** error iqr (pd) 587s ***** error mean (pd) 587s ***** error median (pd) 587s ***** error negloglik (pd) 587s ***** error paramci (pd) 587s ***** error pdf (pd, 1) 587s ***** error plot (pd) 587s ***** error proflik (pd, 2) 587s ***** error random (pd) 587s ***** error std (pd) 587s ***** error ... 587s truncate (pd, 2, 4) 587s ***** error var (pd) 587s 95 tests, 95 passed, 0 known failure, 0 skipped 587s [inst/dist_obj/LoguniformDistribution.m] 587s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_obj/LoguniformDistribution.m 587s ***** shared pd, t 587s pd = LoguniformDistribution (1, 4); 587s t = truncate (pd, 2, 4); 587s ***** assert (cdf (pd, [0, 1, 2, 3, 4, 5]), [0, 0, 0.5, 0.7925, 1, 1], 1e-4); 587s ***** assert (cdf (t, [0, 1, 2, 3, 4, 5]), [0, 0, 0, 0.5850, 1, 1], 1e-4); 587s ***** assert (cdf (pd, [1.5, 2, 3, 4]), [0.2925, 0.5, 0.7925, 1], 1e-4); 587s ***** assert (cdf (t, [1.5, 2, 3, 4]), [0, 0, 0.5850, 1], 1e-4); 587s ***** assert (icdf (pd, [0:0.2:1]), [1, 1.3195, 1.7411, 2.2974, 3.0314, 4], 1e-4); 587s ***** assert (icdf (t, [0:0.2:1]), [2, 2.2974, 2.6390, 3.0314, 3.4822, 4], 1e-4); 587s ***** assert (icdf (pd, [-1, 0.4:0.2:1, NaN]), [NaN, 1.7411, 2.2974, 3.0314, 4, NaN], 1e-4); 587s ***** assert (icdf (t, [-1, 0.4:0.2:1, NaN]), [NaN, 2.6390, 3.0314, 3.4822, 4, NaN], 1e-4); 587s ***** assert (iqr (pd), 1.4142, 1e-4); 587s ***** assert (iqr (t), 0.9852, 1e-4); 587s ***** assert (mean (pd), 2.1640, 1e-4); 587s ***** assert (mean (t), 2.8854, 1e-4); 587s ***** assert (median (pd), 2); 587s ***** assert (median (t), 2.8284, 1e-4); 587s ***** assert (pdf (pd, [0, 1, 2, 3, 4, 5]), [0, 0.7213, 0.3607, 0.2404, 0.1803, 0], 1e-4); 587s ***** assert (pdf (t, [0, 1, 2, 3, 4, 5]), [0, 0, 0.7213, 0.4809, 0.3607, 0], 1e-4); 587s ***** assert (pdf (pd, [-1, 1, 2, 3, 4, NaN]), [0, 0.7213, 0.3607, 0.2404, 0.1803, NaN], 1e-4); 587s ***** assert (pdf (t, [-1, 1, 2, 3, 4, NaN]), [0, 0, 0.7213, 0.4809, 0.3607, NaN], 1e-4); 587s ***** assert (isequal (size (random (pd, 100, 50)), [100, 50])) 587s ***** assert (any (random (pd, 1000, 1) < 1), false); 587s ***** assert (any (random (pd, 1000, 1) > 4), false); 587s ***** assert (any (random (t, 1000, 1) < 2), false); 587s ***** assert (any (random (t, 1000, 1) > 4), false); 587s ***** assert (std (pd), 0.8527, 1e-4); 587s ***** assert (std (t), 0.5751, 1e-4); 587s ***** assert (var (pd), 0.7270, 1e-4); 587s ***** assert (var (t), 0.3307, 1e-4); 587s ***** error ... 587s LoguniformDistribution (i, 1) 587s ***** error ... 587s LoguniformDistribution (Inf, 1) 587s ***** error ... 587s LoguniformDistribution ([1, 2], 1) 587s ***** error ... 587s LoguniformDistribution ("a", 1) 587s ***** error ... 587s LoguniformDistribution (NaN, 1) 587s ***** error ... 587s LoguniformDistribution (1, i) 587s ***** error ... 587s LoguniformDistribution (1, Inf) 587s ***** error ... 587s LoguniformDistribution (1, [1, 2]) 587s ***** error ... 587s LoguniformDistribution (1, "a") 587s ***** error ... 587s LoguniformDistribution (1, NaN) 587s ***** error ... 587s LoguniformDistribution (2, 1) 587s ***** error ... 587s cdf (LoguniformDistribution, 2, "uper") 587s ***** error ... 587s cdf (LoguniformDistribution, 2, 3) 587s ***** error ... 587s plot (LoguniformDistribution, "Parent") 587s ***** error ... 587s plot (LoguniformDistribution, "PlotType", 12) 587s ***** error ... 587s plot (LoguniformDistribution, "PlotType", {"pdf", "cdf"}) 587s ***** error ... 587s plot (LoguniformDistribution, "PlotType", "pdfcdf") 587s ***** error ... 587s plot (LoguniformDistribution, "Discrete", "pdfcdf") 587s ***** error ... 587s plot (LoguniformDistribution, "Discrete", [1, 0]) 587s ***** error ... 587s plot (LoguniformDistribution, "Discrete", {true}) 587s ***** error ... 587s plot (LoguniformDistribution, "Parent", 12) 587s ***** error ... 587s plot (LoguniformDistribution, "Parent", "hax") 587s ***** error ... 587s plot (LoguniformDistribution, "invalidNAME", "pdf") 587s ***** error ... 587s plot (LoguniformDistribution, "PlotType", "probability") 587s ***** error ... 587s truncate (LoguniformDistribution) 587s ***** error ... 587s truncate (LoguniformDistribution, 2) 587s ***** error ... 587s truncate (LoguniformDistribution, 4, 2) 587s ***** shared pd 587s pd = LoguniformDistribution(1, 4); 587s pd(2) = LoguniformDistribution(2, 5); 587s ***** error cdf (pd, 1) 587s ***** error icdf (pd, 0.5) 587s ***** error iqr (pd) 587s ***** error mean (pd) 587s ***** error median (pd) 587s ***** error pdf (pd, 1) 587s ***** error plot (pd) 587s ***** error random (pd) 587s ***** error std (pd) 587s ***** error ... 587s truncate (pd, 2, 4) 587s ***** error var (pd) 587s 65 tests, 65 passed, 0 known failure, 0 skipped 587s [inst/dist_obj/RicianDistribution.m] 587s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_obj/RicianDistribution.m 587s ***** shared pd, t 587s pd = RicianDistribution; 587s t = truncate (pd, 2, 4); 587s ***** assert (cdf (pd, [0:5]), [0, 0.2671, 0.7310, 0.9563, 0.9971, 0.9999], 1e-4); 587s ***** assert (cdf (t, [0:5]), [0, 0, 0, 0.8466, 1, 1], 1e-4); 587s ***** assert (cdf (pd, [1.5, 2, 3, 4, NaN]), [0.5120, 0.7310, 0.9563, 0.9971, NaN], 1e-4); 587s ***** assert (cdf (t, [1.5, 2, 3, 4, NaN]), [0, 0, 0.8466, 1, NaN], 1e-4); 587s ***** assert (icdf (pd, [0:0.2:1]), [0, 0.8501, 1.2736, 1.6863, 2.2011, Inf], 1e-4); 588s ***** assert (icdf (t, [0:0.2:1]), [2, 2.1517, 2.3296, 2.5545, 2.8868, 4], 1e-4); 588s ***** assert (icdf (pd, [-1, 0.4:0.2:1, NaN]), [NaN, 1.2736, 1.6863, 2.2011, Inf, NaN], 1e-4); 588s ***** assert (icdf (t, [-1, 0.4:0.2:1, NaN]), [NaN, 2.3296, 2.5545, 2.8868, 4, NaN], 1e-4); 588s ***** assert (iqr (pd), 1.0890, 1e-4); 588s ***** assert (iqr (t), 0.5928, 1e-4); 588s ***** assert (mean (pd), 1.5486, 1e-4); 588s ***** assert (mean (t), 2.5380, 1e-4); 588s ***** assert (median (pd), 1.4755, 1e-4); 589s ***** assert (median (t), 2.4341, 1e-4); 589s ***** assert (pdf (pd, [0:5]), [0, 0.4658, 0.3742, 0.0987, 0.0092, 0.0003], 1e-4); 589s ***** assert (pdf (t, [0:5]), [0, 0, 1.4063, 0.3707, 0.0346, 0], 1e-4); 589s ***** assert (pdf (pd, [-1, 1.5, NaN]), [0, 0.4864, NaN], 1e-4); 589s ***** assert (pdf (t, [-1, 1.5, NaN]), [0, 0, NaN], 1e-4); 589s ***** assert (isequal (size (random (pd, 100, 50)), [100, 50])) 589s ***** assert (any (random (t, 1000, 1) < 2), false); 589s ***** assert (any (random (t, 1000, 1) > 4), false); 589s ***** assert (std (pd), 0.7758, 1e-4); 589s ***** assert (std (t), 0.4294, 1e-4); 589s ***** assert (var (pd), 0.6019, 1e-4); 589s ***** assert (var (t), 0.1844, 1e-4); 589s ***** error ... 589s RicianDistribution(-eps, 1) 589s ***** error ... 589s RicianDistribution(-1, 1) 589s ***** error ... 589s RicianDistribution(Inf, 1) 589s ***** error ... 589s RicianDistribution(i, 1) 589s ***** error ... 589s RicianDistribution("a", 1) 589s ***** error ... 589s RicianDistribution([1, 2], 1) 589s ***** error ... 589s RicianDistribution(NaN, 1) 589s ***** error ... 589s RicianDistribution(1, 0) 589s ***** error ... 589s RicianDistribution(1, -1) 589s ***** error ... 589s RicianDistribution(1, Inf) 589s ***** error ... 589s RicianDistribution(1, i) 589s ***** error ... 589s RicianDistribution(1, "a") 589s ***** error ... 589s RicianDistribution(1, [1, 2]) 589s ***** error ... 589s RicianDistribution(1, NaN) 589s ***** error ... 589s cdf (RicianDistribution, 2, "uper") 589s ***** error ... 589s cdf (RicianDistribution, 2, 3) 589s ***** shared x 589s x = gevrnd (1, 1, 1, [1, 100]); 589s ***** error ... 589s paramci (RicianDistribution.fit (x), "alpha") 589s ***** error ... 589s paramci (RicianDistribution.fit (x), "alpha", 0) 589s ***** error ... 589s paramci (RicianDistribution.fit (x), "alpha", 1) 589s ***** error ... 589s paramci (RicianDistribution.fit (x), "alpha", [0.5 2]) 589s ***** error ... 589s paramci (RicianDistribution.fit (x), "alpha", "") 590s ***** error ... 590s paramci (RicianDistribution.fit (x), "alpha", {0.05}) 590s ***** error ... 590s paramci (RicianDistribution.fit (x), "parameter", "s", "alpha", {0.05}) 590s ***** error ... 590s paramci (RicianDistribution.fit (x), "parameter", {"s", "sigma", "param"}) 590s ***** error ... 590s paramci (RicianDistribution.fit (x), "alpha", 0.01, ... 590s "parameter", {"s", "sigma", "param"}) 590s ***** error ... 590s paramci (RicianDistribution.fit (x), "parameter", "param") 590s ***** error ... 590s paramci (RicianDistribution.fit (x), "alpha", 0.01, "parameter", "param") 590s ***** error ... 590s paramci (RicianDistribution.fit (x), "NAME", "value") 591s ***** error ... 591s paramci (RicianDistribution.fit (x), "alpha", 0.01, "NAME", "value") 591s ***** error ... 591s paramci (RicianDistribution.fit (x), "alpha", 0.01, "parameter", "s", ... 591s "NAME", "value") 591s ***** error ... 591s plot (RicianDistribution, "Parent") 591s ***** error ... 591s plot (RicianDistribution, "PlotType", 12) 591s ***** error ... 591s plot (RicianDistribution, "PlotType", {"pdf", "cdf"}) 591s ***** error ... 591s plot (RicianDistribution, "PlotType", "pdfcdf") 591s ***** error ... 591s plot (RicianDistribution, "Discrete", "pdfcdf") 591s ***** error ... 591s plot (RicianDistribution, "Discrete", [1, 0]) 591s ***** error ... 591s plot (RicianDistribution, "Discrete", {true}) 591s ***** error ... 591s plot (RicianDistribution, "Parent", 12) 591s ***** error ... 591s plot (RicianDistribution, "Parent", "hax") 591s ***** error ... 591s plot (RicianDistribution, "invalidNAME", "pdf") 591s ***** error ... 591s plot (RicianDistribution, "PlotType", "probability") 591s ***** error ... 591s proflik (RicianDistribution, 2) 591s ***** error ... 591s proflik (RicianDistribution.fit (x), 3) 591s ***** error ... 591s proflik (RicianDistribution.fit (x), [1, 2]) 591s ***** error ... 591s proflik (RicianDistribution.fit (x), {1}) 591s ***** error ... 591s proflik (RicianDistribution.fit (x), 1, ones (2)) 591s ***** error ... 591s proflik (RicianDistribution.fit (x), 1, "Display") 591s ***** error ... 591s proflik (RicianDistribution.fit (x), 1, "Display", 1) 592s ***** error ... 592s proflik (RicianDistribution.fit (x), 1, "Display", {1}) 592s ***** error ... 592s proflik (RicianDistribution.fit (x), 1, "Display", {"on"}) 592s ***** error ... 592s proflik (RicianDistribution.fit (x), 1, "Display", ["on"; "on"]) 592s ***** error ... 592s proflik (RicianDistribution.fit (x), 1, "Display", "onnn") 592s ***** error ... 592s proflik (RicianDistribution.fit (x), 1, "NAME", "on") 593s ***** error ... 593s proflik (RicianDistribution.fit (x), 1, {"NAME"}, "on") 593s ***** error ... 593s proflik (RicianDistribution.fit (x), 1, {[1 2 3 4]}, "Display", "on") 593s ***** error ... 593s truncate (RicianDistribution) 593s ***** error ... 593s truncate (RicianDistribution, 2) 593s ***** error ... 593s truncate (RicianDistribution, 4, 2) 593s ***** shared pd 593s pd = RicianDistribution(1, 1); 593s pd(2) = RicianDistribution(1, 3); 593s ***** error cdf (pd, 1) 593s ***** error icdf (pd, 0.5) 593s ***** error iqr (pd) 593s ***** error mean (pd) 593s ***** error median (pd) 593s ***** error negloglik (pd) 593s ***** error paramci (pd) 593s ***** error pdf (pd, 1) 593s ***** error plot (pd) 593s ***** error proflik (pd, 2) 593s ***** error random (pd) 593s ***** error std (pd) 593s ***** error ... 593s truncate (pd, 2, 4) 593s ***** error var (pd) 593s 97 tests, 97 passed, 0 known failure, 0 skipped 593s [inst/dist_obj/tLocationScaleDistribution.m] 593s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_obj/tLocationScaleDistribution.m 593s ***** shared pd, t 593s pd = tLocationScaleDistribution; 593s t = truncate (pd, 2, 4); 593s ***** assert (cdf (pd, [0:5]), [0.5, 0.8184, 0.9490, 0.9850, 0.9948, 0.9979], 1e-4); 593s ***** assert (cdf (t, [0:5]), [0, 0, 0, 0.7841, 1, 1], 1e-4); 593s ***** assert (cdf (pd, [1.5, 2, 3, 4, NaN]), [0.9030, 0.9490, 0.9850, 0.9948, NaN], 1e-4); 593s ***** assert (cdf (t, [1.5, 2, 3, 4, NaN]), [0, 0, 0.7841, 1, NaN], 1e-4); 593s ***** assert (icdf (pd, [0:0.2:1]), [-Inf, -0.9195, -0.2672, 0.2672, 0.9195, Inf], 1e-4); 593s ***** assert (icdf (t, [0:0.2:1]), [2, 2.1559, 2.3533, 2.6223, 3.0432, 4], 1e-4); 593s ***** assert (icdf (pd, [-1, 0.4:0.2:1, NaN]), [NaN, -0.2672, 0.2672, 0.9195, Inf, NaN], 1e-4); 593s ***** assert (icdf (t, [-1, 0.4:0.2:1, NaN]), [NaN, 2.3533, 2.6223, 3.0432, 4, NaN], 1e-4); 593s ***** assert (iqr (pd), 1.4534, 1e-4); 593s ***** assert (iqr (t), 0.7139, 1e-4); 593s ***** assert (mean (pd), 0, eps); 593s ***** assert (mean (t), 2.6099, 1e-4); 593s ***** assert (median (pd), 0, eps); 593s ***** assert (median (t), 2.4758, 1e-4); 593s ***** assert (pdf (pd, [0:5]), [0.3796, 0.2197, 0.0651, 0.0173, 0.0051, 0.0018], 1e-4); 594s ***** assert (pdf (t, [0:5]), [0, 0, 1.4209, 0.3775, 0.1119, 0], 1e-4); 594s ***** assert (pdf (pd, [-1, 1.5, NaN]), [0.2197, 0.1245, NaN], 1e-4); 594s ***** assert (pdf (t, [-1, 1.5, NaN]), [0, 0, NaN], 1e-4); 594s ***** assert (isequal (size (random (pd, 100, 50)), [100, 50])) 594s ***** assert (any (random (t, 1000, 1) < 2), false); 594s ***** assert (any (random (t, 1000, 1) > 4), false); 594s ***** assert (std (pd), 1.2910, 1e-4); 594s ***** assert (std (t), 0.4989, 1e-4); 594s ***** assert (var (pd), 1.6667, 1e-4); 594s ***** assert (var (t), 0.2489, 1e-4); 594s ***** error ... 594s tLocationScaleDistribution(i, 1, 1) 594s ***** error ... 594s tLocationScaleDistribution(Inf, 1, 1) 594s ***** error ... 594s tLocationScaleDistribution([1, 2], 1, 1) 594s ***** error ... 594s tLocationScaleDistribution("a", 1, 1) 594s ***** error ... 594s tLocationScaleDistribution(NaN, 1, 1) 594s ***** error ... 594s tLocationScaleDistribution(0, 0, 1) 594s ***** error ... 594s tLocationScaleDistribution(0, -1, 1) 594s ***** error ... 594s tLocationScaleDistribution(0, Inf, 1) 594s ***** error ... 594s tLocationScaleDistribution(0, i, 1) 594s ***** error ... 594s tLocationScaleDistribution(0, "a", 1) 594s ***** error ... 594s tLocationScaleDistribution(0, [1, 2], 1) 594s ***** error ... 594s tLocationScaleDistribution(0, NaN, 1) 594s ***** error ... 594s tLocationScaleDistribution(0, 1, 0) 594s ***** error ... 594s tLocationScaleDistribution(0, 1, -1) 594s ***** error ... 594s tLocationScaleDistribution(0, 1, Inf) 594s ***** error ... 594s tLocationScaleDistribution(0, 1, i) 594s ***** error ... 594s tLocationScaleDistribution(0, 1, "a") 594s ***** error ... 594s tLocationScaleDistribution(0, 1, [1, 2]) 594s ***** error ... 594s tLocationScaleDistribution(0, 1, NaN) 594s ***** error ... 594s cdf (tLocationScaleDistribution, 2, "uper") 594s ***** error ... 594s cdf (tLocationScaleDistribution, 2, 3) 594s ***** shared x 594s x = tlsrnd (0, 1, 1, [1, 100]); 594s ***** error ... 594s paramci (tLocationScaleDistribution.fit (x), "alpha") 594s ***** error ... 594s paramci (tLocationScaleDistribution.fit (x), "alpha", 0) 594s ***** error ... 594s paramci (tLocationScaleDistribution.fit (x), "alpha", 1) 595s ***** error ... 595s paramci (tLocationScaleDistribution.fit (x), "alpha", [0.5 2]) 595s ***** error ... 595s paramci (tLocationScaleDistribution.fit (x), "alpha", "") 595s ***** error ... 595s paramci (tLocationScaleDistribution.fit (x), "alpha", {0.05}) 595s ***** error ... 595s paramci (tLocationScaleDistribution.fit (x), "parameter", "mu", ... 595s "alpha", {0.05}) 595s ***** error ... 595s paramci (tLocationScaleDistribution.fit (x), ... 595s "parameter", {"mu", "sigma", "nu", "param"}) 595s ***** error ... 595s paramci (tLocationScaleDistribution.fit (x), "alpha", 0.01, ... 595s "parameter", {"mu", "sigma", "nu", "param"}) 596s ***** error ... 596s paramci (tLocationScaleDistribution.fit (x), "parameter", "param") 596s ***** error ... 596s paramci (tLocationScaleDistribution.fit (x), "alpha", 0.01, ... 596s "parameter", "param") 596s ***** error ... 596s paramci (tLocationScaleDistribution.fit (x), "NAME", "value") 596s ***** error ... 596s paramci (tLocationScaleDistribution.fit (x), "alpha", 0.01, "NAME", "value") 596s ***** error ... 596s paramci (tLocationScaleDistribution.fit (x), "alpha", 0.01, ... 596s "parameter", "mu", "NAME", "value") 597s ***** error ... 597s plot (tLocationScaleDistribution, "Parent") 597s ***** error ... 597s plot (tLocationScaleDistribution, "PlotType", 12) 597s ***** error ... 597s plot (tLocationScaleDistribution, "PlotType", {"pdf", "cdf"}) 597s ***** error ... 597s plot (tLocationScaleDistribution, "PlotType", "pdfcdf") 597s ***** error ... 597s plot (tLocationScaleDistribution, "Discrete", "pdfcdf") 597s ***** error ... 597s plot (tLocationScaleDistribution, "Discrete", [1, 0]) 597s ***** error ... 597s plot (tLocationScaleDistribution, "Discrete", {true}) 597s ***** error ... 597s plot (tLocationScaleDistribution, "Parent", 12) 597s ***** error ... 597s plot (tLocationScaleDistribution, "Parent", "hax") 597s ***** error ... 597s plot (tLocationScaleDistribution, "invalidNAME", "pdf") 597s ***** error ... 597s plot (tLocationScaleDistribution, "PlotType", "probability") 597s ***** error ... 597s proflik (tLocationScaleDistribution, 2) 597s ***** error ... 597s proflik (tLocationScaleDistribution.fit (x), 4) 597s ***** error ... 597s proflik (tLocationScaleDistribution.fit (x), [1, 2]) 597s ***** error ... 597s proflik (tLocationScaleDistribution.fit (x), {1}) 597s ***** error ... 597s proflik (tLocationScaleDistribution.fit (x), 1, ones (2)) 597s ***** error ... 597s proflik (tLocationScaleDistribution.fit (x), 1, "Display") 598s ***** error ... 598s proflik (tLocationScaleDistribution.fit (x), 1, "Display", 1) 598s ***** error ... 598s proflik (tLocationScaleDistribution.fit (x), 1, "Display", {1}) 598s ***** error ... 598s proflik (tLocationScaleDistribution.fit (x), 1, "Display", {"on"}) 598s ***** error ... 598s proflik (tLocationScaleDistribution.fit (x), 1, "Display", ["on"; "on"]) 598s ***** error ... 598s proflik (tLocationScaleDistribution.fit (x), 1, "Display", "onnn") 598s ***** error ... 598s proflik (tLocationScaleDistribution.fit (x), 1, "NAME", "on") 599s ***** error ... 599s proflik (tLocationScaleDistribution.fit (x), 1, {"NAME"}, "on") 599s ***** error ... 599s proflik (tLocationScaleDistribution.fit (x), 1, {[1 2 3 4]}, "Display", "on") 599s ***** error ... 599s truncate (tLocationScaleDistribution) 599s ***** error ... 599s truncate (tLocationScaleDistribution, 2) 599s ***** error ... 599s truncate (tLocationScaleDistribution, 4, 2) 599s ***** shared pd 599s pd = tLocationScaleDistribution (0, 1, 1); 599s pd(2) = tLocationScaleDistribution (0, 1, 3); 599s ***** error cdf (pd, 1) 599s ***** error icdf (pd, 0.5) 599s ***** error iqr (pd) 599s ***** error mean (pd) 599s ***** error median (pd) 599s ***** error negloglik (pd) 599s ***** error paramci (pd) 599s ***** error pdf (pd, 1) 599s ***** error plot (pd) 599s ***** error proflik (pd, 2) 599s ***** error random (pd) 599s ***** error std (pd) 599s ***** error ... 599s truncate (pd, 2, 4) 599s ***** error var (pd) 599s 102 tests, 102 passed, 0 known failure, 0 skipped 599s [inst/dist_obj/GeneralizedParetoDistribution.m] 599s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_obj/GeneralizedParetoDistribution.m 599s ***** shared pd, t 599s pd = GeneralizedParetoDistribution (1, 1, 1); 599s t = truncate (pd, 2, 4); 599s ***** assert (cdf (pd, [0:5]), [0, 0, 0.5, 0.6667, 0.75, 0.8], 1e-4); 599s ***** assert (cdf (t, [0:5]), [0, 0, 0, 0.6667, 1, 1], 1e-4); 599s ***** assert (cdf (pd, [1.5, 2, 3, 4]), [0.3333, 0.5, 0.6667, 0.75], 1e-4); 599s ***** assert (cdf (t, [1.5, 2, 3, 4]), [0, 0, 0.6667, 1], 1e-4); 599s ***** assert (icdf (pd, [0:0.2:1]), [1, 1.25, 1.6667, 2.5, 5, Inf], 1e-4); 599s ***** assert (icdf (t, [0:0.2:1]), [2, 2.2222, 2.5, 2.8571, 3.3333, 4], 1e-4); 599s ***** assert (icdf (pd, [-1, 0.4:0.2:1, NaN]), [NaN, 1.6667, 2.5, 5, Inf, NaN], 1e-4); 599s ***** assert (icdf (t, [-1, 0.4:0.2:1, NaN]), [NaN, 2.5, 2.8571, 3.3333, 4, NaN], 1e-4); 599s ***** assert (iqr (pd), 2.6667, 1e-4); 599s ***** assert (iqr (t), 0.9143, 1e-4); 599s ***** assert (mean (pd), Inf); 599s ***** assert (mean (t), 2.7726, 1e-4); 599s ***** assert (median (pd), 2); 599s ***** assert (median (t), 2.6667, 1e-4); 599s ***** assert (pdf (pd, [0:5]), [0, 1, 0.25, 0.1111, 0.0625, 0.04], 1e-4); 599s ***** assert (pdf (t, [0:5]), [0, 0, 1, 0.4444, 0.25, 0], 1e-4); 599s ***** assert (pdf (pd, [-1, 1:4, NaN]), [0, 1, 0.25, 0.1111, 0.0625, NaN], 1e-4); 599s ***** assert (pdf (t, [-1, 1:4, NaN]), [0, 0, 1, 0.4444, 0.25, NaN], 1e-4); 599s ***** assert (isequal (size (random (pd, 100, 50)), [100, 50])) 599s ***** assert (any (random (t, 1000, 1) < 2), false); 599s ***** assert (any (random (t, 1000, 1) > 4), false); 599s ***** assert (std (pd), Inf); 599s ***** assert (std (t), 0.5592, 1e-4); 599s ***** assert (var (pd), Inf); 599s ***** assert (var (t), 0.3128, 1e-4); 599s ***** error ... 599s GeneralizedParetoDistribution(Inf, 1, 1) 599s ***** error ... 599s GeneralizedParetoDistribution(i, 1, 1) 599s ***** error ... 599s GeneralizedParetoDistribution("a", 1, 1) 599s ***** error ... 599s GeneralizedParetoDistribution([1, 2], 1, 1) 599s ***** error ... 599s GeneralizedParetoDistribution(NaN, 1, 1) 599s ***** error ... 599s GeneralizedParetoDistribution(1, 0, 1) 599s ***** error ... 599s GeneralizedParetoDistribution(1, -1, 1) 599s ***** error ... 599s GeneralizedParetoDistribution(1, Inf, 1) 599s ***** error ... 599s GeneralizedParetoDistribution(1, i, 1) 599s ***** error ... 599s GeneralizedParetoDistribution(1, "a", 1) 599s ***** error ... 599s GeneralizedParetoDistribution(1, [1, 2], 1) 599s ***** error ... 599s GeneralizedParetoDistribution(1, NaN, 1) 599s ***** error ... 599s GeneralizedParetoDistribution(1, 1, Inf) 599s ***** error ... 599s GeneralizedParetoDistribution(1, 1, i) 599s ***** error ... 599s GeneralizedParetoDistribution(1, 1, "a") 599s ***** error ... 599s GeneralizedParetoDistribution(1, 1, [1, 2]) 599s ***** error ... 599s GeneralizedParetoDistribution(1, 1, NaN) 599s ***** error ... 599s cdf (GeneralizedParetoDistribution, 2, "uper") 599s ***** error ... 599s cdf (GeneralizedParetoDistribution, 2, 3) 599s ***** shared x 599s x = gprnd (1, 1, 1, [1, 100]); 599s ***** error ... 599s paramci (GeneralizedParetoDistribution.fit (x, 1), "alpha") 599s ***** error ... 599s paramci (GeneralizedParetoDistribution.fit (x, 1), "alpha", 0) 599s ***** error ... 599s paramci (GeneralizedParetoDistribution.fit (x, 1), "alpha", 1) 600s ***** error ... 600s paramci (GeneralizedParetoDistribution.fit (x, 1), "alpha", [0.5 2]) 600s ***** error ... 600s paramci (GeneralizedParetoDistribution.fit (x, 1), "alpha", "") 600s ***** error ... 600s paramci (GeneralizedParetoDistribution.fit (x, 1), "alpha", {0.05}) 600s ***** error ... 600s paramci (GeneralizedParetoDistribution.fit (x, 1), ... 600s "parameter", "sigma", "alpha", {0.05}) 600s ***** error ... 600s paramci (GeneralizedParetoDistribution.fit (x, 1), ... 600s "parameter", {"k", "sigma", "param"}) 600s ***** error ... 600s paramci (GeneralizedParetoDistribution.fit (x, 1), "alpha", 0.01, ... 600s "parameter", {"k", "sigma", "param"}) 600s ***** error ... 600s paramci (GeneralizedParetoDistribution.fit (x, 1), "parameter", "param") 600s ***** error ... 600s paramci (GeneralizedParetoDistribution.fit (x, 1), "alpha", 0.01, ... 600s "parameter", "param") 600s ***** error ... 600s paramci (GeneralizedParetoDistribution.fit (x, 1), "NAME", "value") 600s ***** error ... 600s paramci (GeneralizedParetoDistribution.fit (x, 1), "alpha", 0.01, ... 600s "NAME", "value") 600s ***** error ... 600s paramci (GeneralizedParetoDistribution.fit (x, 1), "alpha", 0.01, ... 600s "parameter", "sigma", "NAME", "value") 600s ***** error ... 600s plot (GeneralizedParetoDistribution, "Parent") 600s ***** error ... 600s plot (GeneralizedParetoDistribution, "PlotType", 12) 600s ***** error ... 600s plot (GeneralizedParetoDistribution, "PlotType", {"pdf", "cdf"}) 600s ***** error ... 600s plot (GeneralizedParetoDistribution, "PlotType", "pdfcdf") 600s ***** error ... 600s plot (GeneralizedParetoDistribution, "Discrete", "pdfcdf") 600s ***** error ... 600s plot (GeneralizedParetoDistribution, "Discrete", [1, 0]) 600s ***** error ... 600s plot (GeneralizedParetoDistribution, "Discrete", {true}) 600s ***** error ... 600s plot (GeneralizedParetoDistribution, "Parent", 12) 600s ***** error ... 600s plot (GeneralizedParetoDistribution, "Parent", "hax") 600s ***** error ... 600s plot (GeneralizedParetoDistribution, "invalidNAME", "pdf") 600s ***** error ... 600s plot (GeneralizedParetoDistribution, "PlotType", "probability") 600s ***** error ... 600s proflik (GeneralizedParetoDistribution, 2) 600s ***** error ... 600s proflik (GeneralizedParetoDistribution.fit (x, 1), 3) 600s ***** error ... 600s proflik (GeneralizedParetoDistribution.fit (x, 1), [1, 2]) 600s ***** error ... 600s proflik (GeneralizedParetoDistribution.fit (x, 1), {1}) 600s ***** error ... 600s proflik (GeneralizedParetoDistribution.fit (x, 1), 1, ones (2)) 600s ***** error ... 600s proflik (GeneralizedParetoDistribution.fit (x, 1), 1, "Display") 600s ***** error ... 600s proflik (GeneralizedParetoDistribution.fit (x, 1), 1, "Display", 1) 600s ***** error ... 600s proflik (GeneralizedParetoDistribution.fit (x, 1), 1, "Display", {1}) 600s ***** error ... 600s proflik (GeneralizedParetoDistribution.fit (x, 1), 1, "Display", {"on"}) 600s ***** error ... 600s proflik (GeneralizedParetoDistribution.fit (x, 1), 1, ... 600s "Display", ["on"; "on"]) 600s ***** error ... 600s proflik (GeneralizedParetoDistribution.fit (x, 1), 1, "Display", "onnn") 600s ***** error ... 600s proflik (GeneralizedParetoDistribution.fit (x, 1), 1, "NAME", "on") 600s ***** error ... 600s proflik (GeneralizedParetoDistribution.fit (x, 1), 1, {"NAME"}, "on") 601s ***** error ... 601s proflik (GeneralizedParetoDistribution.fit (x, 1), 1, {[1 2 3 4]}, ... 601s "Display", "on") 601s ***** error ... 601s truncate (GeneralizedParetoDistribution) 601s ***** error ... 601s truncate (GeneralizedParetoDistribution, 2) 601s ***** error ... 601s truncate (GeneralizedParetoDistribution, 4, 2) 601s ***** shared pd 601s pd = GeneralizedParetoDistribution(1, 1, 1); 601s pd(2) = GeneralizedParetoDistribution(1, 3, 1); 601s ***** error cdf (pd, 1) 601s ***** error icdf (pd, 0.5) 601s ***** error iqr (pd) 601s ***** error mean (pd) 601s ***** error median (pd) 601s ***** error negloglik (pd) 601s ***** error paramci (pd) 601s ***** error pdf (pd, 1) 601s ***** error plot (pd) 601s ***** error proflik (pd, 2) 601s ***** error random (pd) 601s ***** error std (pd) 601s ***** error ... 601s truncate (pd, 2, 4) 601s ***** error var (pd) 601s 100 tests, 100 passed, 0 known failure, 0 skipped 601s [inst/dist_obj/HalfNormalDistribution.m] 601s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_obj/HalfNormalDistribution.m 601s ***** shared pd, t 601s pd = HalfNormalDistribution (0, 1); 601s t = truncate (pd, 2, 4); 601s ***** assert (cdf (pd, [0:5]), [0, 0.6827, 0.9545, 0.9973, 0.9999, 1], 1e-4); 601s ***** assert (cdf (t, [0:5]), [0, 0, 0, 0.9420, 1, 1], 1e-4); 601s ***** assert (cdf (pd, [1.5, 2, 3, 4]), [0.8664, 0.9545, 0.9973, 0.9999], 1e-4); 601s ***** assert (cdf (t, [1.5, 2, 3, 4]), [0, 0, 0.9420, 1], 1e-4); 601s ***** assert (icdf (pd, [0:0.2:1]), [0, 0.2533, 0.5244, 0.8416, 1.2816, Inf], 1e-4); 601s ***** assert (icdf (t, [0:0.2:1]), [2, 2.0923, 2.2068, 2.3607, 2.6064, 4], 1e-4); 601s ***** assert (icdf (pd, [-1, 0.4:0.2:1, NaN]), [NaN, 0.5244, 0.8416, 1.2816, Inf, NaN], 1e-4); 601s ***** assert (icdf (t, [-1, 0.4:0.2:1, NaN]), [NaN, 2.2068, 2.3607, 2.6064, 4, NaN], 1e-4); 601s ***** assert (iqr (pd), 0.8317, 1e-4); 601s ***** assert (iqr (t), 0.4111, 1e-4); 601s ***** assert (mean (pd), 0.7979, 1e-4); 601s ***** assert (mean (t), 2.3706, 1e-4); 601s ***** assert (median (pd), 0.6745, 1e-4); 601s ***** assert (median (t), 2.2771, 1e-4); 601s ***** assert (pdf (pd, [0:5]), [0.7979, 0.4839, 0.1080, 0.0089, 0.0003, 0], 1e-4); 601s ***** assert (pdf (t, [0:5]), [0, 0, 2.3765, 0.1951, 0.0059, 0], 1e-4); 601s ***** assert (pdf (pd, [-1, 1:4, NaN]), [0, 0.4839, 0.1080, 0.0089, 0.0003, NaN], 1e-4); 601s ***** assert (pdf (t, [-1, 1:4, NaN]), [0, 0, 2.3765, 0.1951, 0.0059, NaN], 1e-4); 601s ***** assert (isequal (size (random (pd, 100, 50)), [100, 50])) 601s ***** assert (any (random (t, 1000, 1) < 2), false); 601s ***** assert (any (random (t, 1000, 1) > 4), false); 601s ***** assert (std (pd), 0.6028, 1e-4); 601s ***** assert (std (t), 0.3310, 1e-4); 601s ***** assert (var (pd), 0.3634, 1e-4); 601s ***** assert (var (t), 0.1096, 1e-4); 601s ***** error ... 601s HalfNormalDistribution(Inf, 1) 601s ***** error ... 601s HalfNormalDistribution(i, 1) 601s ***** error ... 601s HalfNormalDistribution("a", 1) 601s ***** error ... 601s HalfNormalDistribution([1, 2], 1) 601s ***** error ... 601s HalfNormalDistribution(NaN, 1) 601s ***** error ... 601s HalfNormalDistribution(1, 0) 601s ***** error ... 601s HalfNormalDistribution(1, -1) 601s ***** error ... 601s HalfNormalDistribution(1, Inf) 601s ***** error ... 601s HalfNormalDistribution(1, i) 601s ***** error ... 601s HalfNormalDistribution(1, "a") 601s ***** error ... 601s HalfNormalDistribution(1, [1, 2]) 601s ***** error ... 601s HalfNormalDistribution(1, NaN) 601s ***** error ... 601s cdf (HalfNormalDistribution, 2, "uper") 601s ***** error ... 601s cdf (HalfNormalDistribution, 2, 3) 601s ***** shared x 601s x = hnrnd (1, 1, [1, 100]); 601s ***** error ... 601s paramci (HalfNormalDistribution.fit (x, 1), "alpha") 601s ***** error ... 601s paramci (HalfNormalDistribution.fit (x, 1), "alpha", 0) 601s ***** error ... 601s paramci (HalfNormalDistribution.fit (x, 1), "alpha", 1) 601s ***** error ... 601s paramci (HalfNormalDistribution.fit (x, 1), "alpha", [0.5 2]) 601s ***** error ... 601s paramci (HalfNormalDistribution.fit (x, 1), "alpha", "") 601s ***** error ... 601s paramci (HalfNormalDistribution.fit (x, 1), "alpha", {0.05}) 601s ***** error ... 601s paramci (HalfNormalDistribution.fit (x, 1), "parameter", "sigma", ... 601s "alpha", {0.05}) 601s ***** error ... 601s paramci (HalfNormalDistribution.fit (x, 1), ... 601s "parameter", {"mu", "sigma", "param"}) 601s ***** error ... 601s paramci (HalfNormalDistribution.fit (x, 1), "alpha", 0.01, ... 601s "parameter", {"mu", "sigma", "param"}) 601s ***** error ... 601s paramci (HalfNormalDistribution.fit (x, 1), "parameter", "param") 602s ***** error ... 602s paramci (HalfNormalDistribution.fit (x, 1), "alpha", 0.01, ... 602s "parameter", "param") 602s ***** error ... 602s paramci (HalfNormalDistribution.fit (x, 1),"NAME", "value") 602s ***** error ... 602s paramci (HalfNormalDistribution.fit (x, 1), "alpha", 0.01, ... 602s "NAME", "value") 602s ***** error ... 602s paramci (HalfNormalDistribution.fit (x, 1), "alpha", 0.01, ... 602s "parameter", "sigma", "NAME", "value") 602s ***** error ... 602s plot (HalfNormalDistribution, "Parent") 602s ***** error ... 602s plot (HalfNormalDistribution, "PlotType", 12) 602s ***** error ... 602s plot (HalfNormalDistribution, "PlotType", {"pdf", "cdf"}) 602s ***** error ... 602s plot (HalfNormalDistribution, "PlotType", "pdfcdf") 602s ***** error ... 602s plot (HalfNormalDistribution, "Discrete", "pdfcdf") 602s ***** error ... 602s plot (HalfNormalDistribution, "Discrete", [1, 0]) 602s ***** error ... 602s plot (HalfNormalDistribution, "Discrete", {true}) 602s ***** error ... 602s plot (HalfNormalDistribution, "Parent", 12) 602s ***** error ... 602s plot (HalfNormalDistribution, "Parent", "hax") 602s ***** error ... 602s plot (HalfNormalDistribution, "invalidNAME", "pdf") 602s ***** error ... 602s plot (HalfNormalDistribution, "PlotType", "probability") 602s ***** error ... 602s proflik (HalfNormalDistribution, 2) 602s ***** error ... 602s proflik (HalfNormalDistribution.fit (x, 1), 3) 602s ***** error ... 602s proflik (HalfNormalDistribution.fit (x, 1), [1, 2]) 602s ***** error ... 602s proflik (HalfNormalDistribution.fit (x, 1), {1}) 602s ***** error ... 602s proflik (HalfNormalDistribution.fit (x, 1), 1) 602s ***** error ... 602s proflik (HalfNormalDistribution.fit (x, 1), 2, ones (2)) 602s ***** error ... 602s proflik (HalfNormalDistribution.fit (x, 1), 2, "Display") 602s ***** error ... 602s proflik (HalfNormalDistribution.fit (x, 1), 2, "Display", 1) 602s ***** error ... 602s proflik (HalfNormalDistribution.fit (x, 1), 2, "Display", {1}) 603s ***** error ... 603s proflik (HalfNormalDistribution.fit (x, 1), 2, "Display", {"on"}) 603s ***** error ... 603s proflik (HalfNormalDistribution.fit (x, 1), 2, "Display", ["on"; "on"]) 603s ***** error ... 603s proflik (HalfNormalDistribution.fit (x, 1), 2, "Display", "onnn") 603s ***** error ... 603s proflik (HalfNormalDistribution.fit (x, 1), 2, "NAME", "on") 603s ***** error ... 603s proflik (HalfNormalDistribution.fit (x, 1), 2, {"NAME"}, "on") 603s ***** error ... 603s proflik (HalfNormalDistribution.fit (x, 1), 2, {[1 2 3 4]}, ... 603s "Display", "on") 603s ***** error ... 603s truncate (HalfNormalDistribution) 603s ***** error ... 603s truncate (HalfNormalDistribution, 2) 603s ***** error ... 603s truncate (HalfNormalDistribution, 4, 2) 603s ***** shared pd 603s pd = HalfNormalDistribution(1, 1); 603s pd(2) = HalfNormalDistribution(1, 3); 603s ***** error cdf (pd, 1) 603s ***** error icdf (pd, 0.5) 603s ***** error iqr (pd) 603s ***** error mean (pd) 603s ***** error median (pd) 603s ***** error negloglik (pd) 603s ***** error paramci (pd) 603s ***** error pdf (pd, 1) 603s ***** error plot (pd) 603s ***** error proflik (pd, 2) 603s ***** error random (pd) 603s ***** error std (pd) 603s ***** error ... 603s truncate (pd, 2, 4) 603s ***** error var (pd) 603s 96 tests, 96 passed, 0 known failure, 0 skipped 603s [inst/dist_obj/LognormalDistribution.m] 603s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_obj/LognormalDistribution.m 603s ***** shared pd, t 603s pd = LognormalDistribution; 603s t = truncate (pd, 2, 4); 603s ***** assert (cdf (pd, [0:5]), [0, 0.5, 0.7559, 0.8640, 0.9172, 0.9462], 1e-4); 603s ***** assert (cdf (t, [0:5]), [0, 0, 0, 0.6705, 1, 1], 1e-4); 603s ***** assert (cdf (pd, [1.5, 2, 3, 4]), [0.6574, 0.7559, 0.8640, 0.9172], 1e-4); 603s ***** assert (cdf (t, [1.5, 2, 3, 4]), [0, 0, 0.6705, 1], 1e-4); 603s ***** assert (icdf (pd, [0:0.2:1]), [0, 0.4310, 0.7762, 1.2883, 2.3201, Inf], 1e-4); 603s ***** assert (icdf (t, [0:0.2:1]), [2, 2.2256, 2.5015, 2.8517, 3.3199, 4], 1e-4); 603s ***** assert (icdf (pd, [-1, 0.4:0.2:1, NaN]), [NaN, 0.7762, 1.2883, 2.3201, Inf, NaN], 1e-4); 603s ***** assert (icdf (t, [-1, 0.4:0.2:1, NaN]), [NaN, 2.5015, 2.8517, 3.3199, 4, NaN], 1e-4); 603s ***** assert (iqr (pd), 1.4536, 1e-4); 603s ***** assert (iqr (t), 0.8989, 1e-4); 603s ***** assert (mean (pd), 1.6487, 1e-4); 603s ***** assert (mean (t), 2.7692, 1e-4); 603s ***** assert (median (pd), 1, 1e-4); 603s ***** assert (median (t), 2.6653, 1e-4); 603s ***** assert (pdf (pd, [0:5]), [0, 0.3989, 0.1569, 0.0727, 0.0382, 0.0219], 1e-4); 603s ***** assert (pdf (t, [0:5]), [0, 0, 0.9727, 0.4509, 0.2366, 0], 1e-4); 603s ***** assert (pdf (pd, [-1, 1:4, NaN]), [0, 0.3989, 0.1569, 0.0727, 0.0382, NaN], 1e-4); 603s ***** assert (pdf (t, [-1, 1:4, NaN]), [0, 0, 0.9727, 0.4509, 0.2366, NaN], 1e-4); 603s ***** assert (isequal (size (random (pd, 100, 50)), [100, 50])) 603s ***** assert (any (random (t, 1000, 1) < 2), false); 603s ***** assert (any (random (t, 1000, 1) > 4), false); 603s ***** assert (std (pd), 2.1612, 1e-4); 603s ***** assert (std (t), 0.5540, 1e-4); 603s ***** assert (var (pd), 4.6708, 1e-4); 603s ***** assert (var (t), 0.3069, 1e-4); 603s ***** error ... 603s LognormalDistribution(Inf, 1) 603s ***** error ... 603s LognormalDistribution(i, 1) 603s ***** error ... 603s LognormalDistribution("a", 1) 603s ***** error ... 603s LognormalDistribution([1, 2], 1) 603s ***** error ... 603s LognormalDistribution(NaN, 1) 603s ***** error ... 603s LognormalDistribution(1, 0) 603s ***** error ... 603s LognormalDistribution(1, -1) 603s ***** error ... 603s LognormalDistribution(1, Inf) 603s ***** error ... 603s LognormalDistribution(1, i) 603s ***** error ... 603s LognormalDistribution(1, "a") 603s ***** error ... 603s LognormalDistribution(1, [1, 2]) 603s ***** error ... 603s LognormalDistribution(1, NaN) 603s ***** error ... 603s cdf (LognormalDistribution, 2, "uper") 603s ***** error ... 603s cdf (LognormalDistribution, 2, 3) 603s ***** shared x 603s randn ("seed", 1); 603s x = lognrnd (1, 1, [1, 100]); 603s ***** error ... 603s paramci (LognormalDistribution.fit (x), "alpha") 603s ***** error ... 603s paramci (LognormalDistribution.fit (x), "alpha", 0) 604s ***** error ... 604s paramci (LognormalDistribution.fit (x), "alpha", 1) 604s ***** error ... 604s paramci (LognormalDistribution.fit (x), "alpha", [0.5 2]) 604s ***** error ... 604s paramci (LognormalDistribution.fit (x), "alpha", "") 604s ***** error ... 604s paramci (LognormalDistribution.fit (x), "alpha", {0.05}) 604s ***** error ... 604s paramci (LognormalDistribution.fit (x), "parameter", "mu", "alpha", {0.05}) 604s ***** error ... 604s paramci (LognormalDistribution.fit (x), "parameter", {"mu", "sigma", "parm"}) 605s ***** error ... 605s paramci (LognormalDistribution.fit (x), "alpha", 0.01, ... 605s "parameter", {"mu", "sigma", "param"}) 605s ***** error ... 605s paramci (LognormalDistribution.fit (x), "parameter", "param") 605s ***** error ... 605s paramci (LognormalDistribution.fit (x), "alpha", 0.01, "parameter", "param") 605s ***** error ... 605s paramci (LognormalDistribution.fit (x), "NAME", "value") 605s ***** error ... 605s paramci (LognormalDistribution.fit (x), "alpha", 0.01, "NAME", "value") 605s ***** error ... 605s paramci (LognormalDistribution.fit (x), "alpha", 0.01, "parameter", "mu", ... 605s "NAME", "value") 606s ***** error ... 606s plot (LognormalDistribution, "Parent") 606s ***** error ... 606s plot (LognormalDistribution, "PlotType", 12) 606s ***** error ... 606s plot (LognormalDistribution, "PlotType", {"pdf", "cdf"}) 606s ***** error ... 606s plot (LognormalDistribution, "PlotType", "pdfcdf") 606s ***** error ... 606s plot (LognormalDistribution, "Discrete", "pdfcdf") 606s ***** error ... 606s plot (LognormalDistribution, "Discrete", [1, 0]) 606s ***** error ... 606s plot (LognormalDistribution, "Discrete", {true}) 606s ***** error ... 606s plot (LognormalDistribution, "Parent", 12) 606s ***** error ... 606s plot (LognormalDistribution, "Parent", "hax") 606s ***** error ... 606s plot (LognormalDistribution, "invalidNAME", "pdf") 606s ***** error ... 606s plot (LognormalDistribution, "PlotType", "probability") 606s ***** error ... 606s proflik (LognormalDistribution, 2) 606s ***** error ... 606s proflik (LognormalDistribution.fit (x), 3) 606s ***** error ... 606s proflik (LognormalDistribution.fit (x), [1, 2]) 606s ***** error ... 606s proflik (LognormalDistribution.fit (x), {1}) 606s ***** error ... 606s proflik (LognormalDistribution.fit (x), 1, ones (2)) 606s ***** error ... 606s proflik (LognormalDistribution.fit (x), 1, "Display") 607s ***** error ... 607s proflik (LognormalDistribution.fit (x), 1, "Display", 1) 607s ***** error ... 607s proflik (LognormalDistribution.fit (x), 1, "Display", {1}) 607s ***** error ... 607s proflik (LognormalDistribution.fit (x), 1, "Display", {"on"}) 607s ***** error ... 607s proflik (LognormalDistribution.fit (x), 1, "Display", ["on"; "on"]) 607s ***** error ... 607s proflik (LognormalDistribution.fit (x), 1, "Display", "onnn") 607s ***** error ... 607s proflik (LognormalDistribution.fit (x), 1, "NAME", "on") 608s ***** error ... 608s proflik (LognormalDistribution.fit (x), 1, {"NAME"}, "on") 608s ***** error ... 608s proflik (LognormalDistribution.fit (x), 1, {[1 2 3 4]}, "Display", "on") 608s ***** error ... 608s truncate (LognormalDistribution) 608s ***** error ... 608s truncate (LognormalDistribution, 2) 608s ***** error ... 608s truncate (LognormalDistribution, 4, 2) 608s ***** shared pd 608s pd = LognormalDistribution(1, 1); 608s pd(2) = LognormalDistribution(1, 3); 608s ***** error cdf (pd, 1) 608s ***** error icdf (pd, 0.5) 608s ***** error iqr (pd) 608s ***** error mean (pd) 608s ***** error median (pd) 608s ***** error negloglik (pd) 608s ***** error paramci (pd) 608s ***** error pdf (pd, 1) 608s ***** error plot (pd) 608s ***** error proflik (pd, 2) 608s ***** error random (pd) 608s ***** error std (pd) 608s ***** error ... 608s truncate (pd, 2, 4) 608s ***** error var (pd) 608s 95 tests, 95 passed, 0 known failure, 0 skipped 608s [inst/dist_obj/InverseGaussianDistribution.m] 608s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_obj/InverseGaussianDistribution.m 608s ***** shared pd, t 608s pd = InverseGaussianDistribution (1, 1); 608s t = truncate (pd, 2, 4); 608s ***** assert (cdf (pd, [0:5]), [0, 0.6681, 0.8855, 0.9532, 0.9791, 0.9901], 1e-4); 608s ***** assert (cdf (t, [0:5]), [0, 0, 0, 0.7234, 1, 1], 1e-4); 608s ***** assert (cdf (pd, [1.5, 2, 3, 4]), [0.8108, 0.8855, 0.9532, 0.9791], 1e-4); 608s ***** assert (cdf (t, [1.5, 2, 3, 4]), [0, 0, 0.7234, 1], 1e-4); 608s ***** assert (icdf (pd, [0:0.2:1]), [0, 0.3320, 0.5411, 0.8483, 1.4479, Inf], 1e-4); 608s ***** assert (icdf (t, [0:0.2:1]), [2, 2.1889, 2.4264, 2.7417, 3.1993, 4], 1e-4); 608s ***** assert (icdf (pd, [-1, 0.4:0.2:1, NaN]), [NaN, 0.5411, 0.8483, 1.4479, Inf, NaN], 1e-4); 608s ***** assert (icdf (t, [-1, 0.4:0.2:1, NaN]), [NaN, 2.4264, 2.7417, 3.1993, 4, NaN], 1e-4); 608s ***** assert (iqr (pd), 0.8643, 1e-4); 608s ***** assert (iqr (t), 0.8222, 1e-4); 608s ***** assert (mean (pd), 1); 608s ***** assert (mean (t), 2.6953, 1e-4); 608s ***** assert (median (pd), 0.6758, 1e-4); 608s ***** assert (median (t), 2.5716, 1e-4); 608s ***** assert (pdf (pd, [0:5]), [0, 0.3989, 0.1098, 0.0394, 0.0162, 0.0072], 1e-4); 608s ***** assert (pdf (t, [0:5]), [0, 0, 1.1736, 0.4211, 0.1730, 0], 1e-4); 608s ***** assert (pdf (pd, [-1, 1:4, NaN]), [0, 0.3989, 0.1098, 0.0394, 0.0162, NaN], 1e-4); 608s ***** assert (pdf (t, [-1, 1:4, NaN]), [0, 0, 1.1736, 0.4211, 0.1730, NaN], 1e-4); 608s ***** assert (isequal (size (random (pd, 100, 50)), [100, 50])) 608s ***** assert (any (random (t, 1000, 1) < 2), false); 608s ***** assert (any (random (t, 1000, 1) > 4), false); 608s ***** assert (std (pd), 1); 608s ***** assert (std (t), 0.5332, 1e-4); 608s ***** assert (var (pd), 1); 608s ***** assert (var (t), 0.2843, 1e-4); 608s ***** error ... 608s InverseGaussianDistribution(0, 1) 608s ***** error ... 608s InverseGaussianDistribution(Inf, 1) 608s ***** error ... 608s InverseGaussianDistribution(i, 1) 608s ***** error ... 608s InverseGaussianDistribution("a", 1) 608s ***** error ... 608s InverseGaussianDistribution([1, 2], 1) 608s ***** error ... 608s InverseGaussianDistribution(NaN, 1) 608s ***** error ... 608s InverseGaussianDistribution(1, 0) 608s ***** error ... 608s InverseGaussianDistribution(1, -1) 608s ***** error ... 608s InverseGaussianDistribution(1, Inf) 608s ***** error ... 608s InverseGaussianDistribution(1, i) 608s ***** error ... 608s InverseGaussianDistribution(1, "a") 608s ***** error ... 608s InverseGaussianDistribution(1, [1, 2]) 608s ***** error ... 608s InverseGaussianDistribution(1, NaN) 608s ***** error ... 608s cdf (InverseGaussianDistribution, 2, "uper") 608s ***** error ... 608s cdf (InverseGaussianDistribution, 2, 3) 608s ***** shared x 608s x = invgrnd (1, 1, [1, 100]); 608s ***** error ... 608s paramci (InverseGaussianDistribution.fit (x), "alpha") 608s ***** error ... 608s paramci (InverseGaussianDistribution.fit (x), "alpha", 0) 608s ***** error ... 608s paramci (InverseGaussianDistribution.fit (x), "alpha", 1) 608s ***** error ... 608s paramci (InverseGaussianDistribution.fit (x), "alpha", [0.5 2]) 608s ***** error ... 608s paramci (InverseGaussianDistribution.fit (x), "alpha", "") 608s ***** error ... 608s paramci (InverseGaussianDistribution.fit (x), "alpha", {0.05}) 608s ***** error ... 608s paramci (InverseGaussianDistribution.fit (x), "parameter", "mu", ... 608s "alpha", {0.05}) 608s ***** error ... 608s paramci (InverseGaussianDistribution.fit (x), ... 608s "parameter", {"mu", "lambda", "param"}) 609s ***** error ... 609s paramci (InverseGaussianDistribution.fit (x), "alpha", 0.01, ... 609s "parameter", {"mu", "lambda", "param"}) 609s ***** error ... 609s paramci (InverseGaussianDistribution.fit (x), "parameter", "param") 609s ***** error ... 609s paramci (InverseGaussianDistribution.fit (x), "alpha", 0.01, ... 609s "parameter", "param") 609s ***** error ... 609s paramci (InverseGaussianDistribution.fit (x), "NAME", "value") 609s ***** error ... 609s paramci (InverseGaussianDistribution.fit (x), "alpha", 0.01, "NAME", "value") 609s ***** error ... 609s paramci (InverseGaussianDistribution.fit (x), "alpha", 0.01, ... 609s "parameter", "mu", "NAME", "value") 609s ***** error ... 609s plot (InverseGaussianDistribution, "Parent") 609s ***** error ... 609s plot (InverseGaussianDistribution, "PlotType", 12) 609s ***** error ... 609s plot (InverseGaussianDistribution, "PlotType", {"pdf", "cdf"}) 609s ***** error ... 609s plot (InverseGaussianDistribution, "PlotType", "pdfcdf") 609s ***** error ... 609s plot (InverseGaussianDistribution, "Discrete", "pdfcdf") 609s ***** error ... 609s plot (InverseGaussianDistribution, "Discrete", [1, 0]) 609s ***** error ... 609s plot (InverseGaussianDistribution, "Discrete", {true}) 609s ***** error ... 609s plot (InverseGaussianDistribution, "Parent", 12) 609s ***** error ... 609s plot (InverseGaussianDistribution, "Parent", "hax") 609s ***** error ... 609s plot (InverseGaussianDistribution, "invalidNAME", "pdf") 609s ***** error ... 609s plot (InverseGaussianDistribution, "PlotType", "probability") 609s ***** error ... 609s proflik (InverseGaussianDistribution, 2) 609s ***** error ... 609s proflik (InverseGaussianDistribution.fit (x), 3) 609s ***** error ... 609s proflik (InverseGaussianDistribution.fit (x), [1, 2]) 609s ***** error ... 609s proflik (InverseGaussianDistribution.fit (x), {1}) 609s ***** error ... 609s proflik (InverseGaussianDistribution.fit (x), 1, ones (2)) 609s ***** error ... 609s proflik (InverseGaussianDistribution.fit (x), 1, "Display") 609s ***** error ... 609s proflik (InverseGaussianDistribution.fit (x), 1, "Display", 1) 609s ***** error ... 609s proflik (InverseGaussianDistribution.fit (x), 1, "Display", {1}) 609s ***** error ... 609s proflik (InverseGaussianDistribution.fit (x), 1, "Display", {"on"}) 609s ***** error ... 609s proflik (InverseGaussianDistribution.fit (x), 1, "Display", ["on"; "on"]) 609s ***** error ... 609s proflik (InverseGaussianDistribution.fit (x), 1, "Display", "onnn") 609s ***** error ... 609s proflik (InverseGaussianDistribution.fit (x), 1, "NAME", "on") 609s ***** error ... 609s proflik (InverseGaussianDistribution.fit (x), 1, {"NAME"}, "on") 609s ***** error ... 609s proflik (InverseGaussianDistribution.fit (x), 1, {[1 2 3]}, "Display", "on") 609s ***** error ... 609s truncate (InverseGaussianDistribution) 609s ***** error ... 609s truncate (InverseGaussianDistribution, 2) 609s ***** error ... 609s truncate (InverseGaussianDistribution, 4, 2) 609s ***** shared pd 609s pd = InverseGaussianDistribution(1, 1); 609s pd(2) = InverseGaussianDistribution(1, 3); 609s ***** error cdf (pd, 1) 609s ***** error icdf (pd, 0.5) 609s ***** error iqr (pd) 609s ***** error mean (pd) 609s ***** error median (pd) 609s ***** error negloglik (pd) 609s ***** error paramci (pd) 609s ***** error pdf (pd, 1) 609s ***** error plot (pd) 609s ***** error proflik (pd, 2) 609s ***** error random (pd) 609s ***** error std (pd) 609s ***** error ... 609s truncate (pd, 2, 4) 609s ***** error var (pd) 609s 96 tests, 96 passed, 0 known failure, 0 skipped 609s [inst/dist_obj/BetaDistribution.m] 609s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_obj/BetaDistribution.m 609s ***** demo 609s ## Generate a data set of 5000 random samples from a Beta distribution with 609s ## parameters a = 2 and b = 4. Fit a Beta distribution to this data and plot 609s ## a PDF of the fitted distribution superimposed on a histogram of the data 609s 609s pd = makedist ("Beta", "a", 2, "b", 4) 609s randg ("seed", 21); 609s data = random (pd, 5000, 1); 609s pd = fitdist (data, "Beta") 609s plot (pd) 609s title (sprintf ("Fitted Beta distribution with a = %0.2f and b = %0.2f", ... 609s pd.a, pd.b)) 609s ***** demo 609s ## Plot the PDF of a Beta distribution, with parameters a = 2 and b = 4, 609s ## truncated at [0.1, 0.8] intervals. Generate 10000 random samples from 609s ## this truncated distribution and superimpose a histogram with 100 bins 609s ## scaled accordingly 609s 609s pd = makedist ("Beta", "a", 2, "b", 4) 609s t = truncate (pd, 0.1, 0.8) 609s randg ("seed", 21); 609s data = random (t, 10000, 1); 609s plot (t) 609s title ("Beta distribution (a = 2, b = 4) truncated at [0.1, 0.8]") 609s hold on 609s hist (data, 100, 140) 609s hold off 609s ***** demo 609s ## Generate a data set of 100 random samples from a Beta distribution with 609s ## parameters a = 2 and b = 4. Fit a Beta distribution to this data and plot 609s ## its CDF superimposed over an empirical CDF of the data 609s 609s pd = makedist ("Beta", "a", 2, "b", 4) 609s randg ("seed", 21); 609s data = random (pd, 100, 1); 609s pd = fitdist (data, "Beta") 609s plot (pd, "plottype", "cdf") 609s title (sprintf ("Fitted Beta distribution with a = %0.2f and b = %0.2f", ... 609s pd.a, pd.b)) 609s legend ({"empirical CDF", "fitted CDF"}, "location", "east") 609s ***** demo 609s ## Generate a data set of 200 random samples from a Beta distribution with 609s ## parameters a = 2 and b = 4. Display a probability plot for the Beta 609s ## distribution fit to the data. 609s 609s pd = makedist ("Beta", "a", 2, "b", 4) 609s randg ("seed", 21); 609s data = random (pd, 200, 1); 609s pd = fitdist (data, "Beta") 609s plot (pd, "plottype", "probability") 609s title (sprintf ("Probability plot of a fitted Beta distribution with a = %0.2f and b = %0.2f", ... 609s pd.a, pd.b)) 609s legend ({"empirical CDF", "fitted CDF"}, "location", "southeast") 609s ***** shared pd, t 609s pd = BetaDistribution; 609s t = truncate (pd, 0.2, 0.8); 609s ***** assert (cdf (pd, [0:0.2:1]), [0, 0.2, 0.4, 0.6, 0.8, 1], 1e-4); 609s ***** assert (cdf (t, [0:0.2:1]), [0, 0, 0.3333, 0.6667, 1, 1], 1e-4); 609s ***** assert (cdf (pd, [-1, 1, NaN]), [0, 1, NaN], 1e-4); 609s ***** assert (cdf (t, [-1, 1, NaN]), [0, 1, NaN], 1e-4); 609s ***** assert (icdf (pd, [0:0.2:1]), [0, 0.2, 0.4, 0.6, 0.8, 1], 1e-4); 609s ***** assert (icdf (t, [0:0.2:1]), [0.2, 0.32, 0.44, 0.56, 0.68, 0.8], 1e-4); 609s ***** assert (icdf (pd, [-1, 0.4:0.2:1, NaN]), [NaN, 0.4, 0.6, 0.8, 1, NaN], 1e-4); 609s ***** assert (icdf (t, [-1, 0.4:0.2:1, NaN]), [NaN, 0.44, 0.56, 0.68, 0.8, NaN], 1e-4); 609s ***** assert (iqr (pd), 0.5, 1e-4); 609s ***** assert (iqr (t), 0.3, 1e-4); 609s ***** assert (mean (pd), 0.5); 609s ***** assert (mean (t), 0.5, 1e-6); 609s ***** assert (median (pd), 0.5); 609s ***** assert (median (t), 0.5, 1e-6); 609s ***** assert (pdf (pd, [0:0.2:1]), [1, 1, 1, 1, 1, 1], 1e-4); 609s ***** assert (pdf (t, [0:0.2:1]), [0, 1.6667, 1.6667, 1.6667, 1.6667, 0], 1e-4); 609s ***** assert (pdf (pd, [-1, 1, NaN]), [0, 1, NaN], 1e-4); 609s ***** assert (pdf (t, [-1, 1, NaN]), [0, 0, NaN], 1e-4); 609s ***** assert (isequal (size (random (pd, 100, 50)), [100, 50])) 609s ***** assert (any (random (t, 1000, 1) < 0.2), false); 610s ***** assert (any (random (t, 1000, 1) > 0.8), false); 610s ***** assert (std (pd), 0.2887, 1e-4); 610s ***** assert (std (t), 0.1732, 1e-4); 610s ***** assert (var (pd), 0.0833, 1e-4); 610s ***** assert (var (t), 0.0300, 1e-4); 610s ***** error ... 610s BetaDistribution(0, 1) 610s ***** error ... 610s BetaDistribution(Inf, 1) 610s ***** error ... 610s BetaDistribution(i, 1) 610s ***** error ... 610s BetaDistribution("a", 1) 610s ***** error ... 610s BetaDistribution([1, 2], 1) 610s ***** error ... 610s BetaDistribution(NaN, 1) 610s ***** error ... 610s BetaDistribution(1, 0) 610s ***** error ... 610s BetaDistribution(1, -1) 610s ***** error ... 610s BetaDistribution(1, Inf) 610s ***** error ... 610s BetaDistribution(1, i) 610s ***** error ... 610s BetaDistribution(1, "a") 610s ***** error ... 610s BetaDistribution(1, [1, 2]) 610s ***** error ... 610s BetaDistribution(1, NaN) 610s ***** error ... 610s cdf (BetaDistribution, 2, "uper") 610s ***** error ... 610s cdf (BetaDistribution, 2, 3) 610s ***** shared x 610s randg ("seed", 1); 610s x = betarnd (1, 1, [100, 1]); 610s ***** error ... 610s paramci (BetaDistribution.fit (x), "alpha") 610s ***** error ... 610s paramci (BetaDistribution.fit (x), "alpha", 0) 610s ***** error ... 610s paramci (BetaDistribution.fit (x), "alpha", 1) 610s ***** error ... 610s paramci (BetaDistribution.fit (x), "alpha", [0.5 2]) 610s ***** error ... 610s paramci (BetaDistribution.fit (x), "alpha", "") 611s ***** error ... 611s paramci (BetaDistribution.fit (x), "alpha", {0.05}) 611s ***** error ... 611s paramci (BetaDistribution.fit (x), "parameter", "a", "alpha", {0.05}) 611s ***** error ... 611s paramci (BetaDistribution.fit (x), "parameter", {"a", "b", "param"}) 611s ***** error ... 611s paramci (BetaDistribution.fit (x), "alpha", 0.01, ... 611s "parameter", {"a", "b", "param"}) 611s ***** error ... 611s paramci (BetaDistribution.fit (x), "parameter", "param") 611s ***** error ... 611s paramci (BetaDistribution.fit (x), "alpha", 0.01, "parameter", "param") 611s ***** error ... 611s paramci (BetaDistribution.fit (x), "NAME", "value") 611s ***** error ... 611s paramci (BetaDistribution.fit (x), "alpha", 0.01, "NAME", "value") 611s ***** error ... 611s paramci (BetaDistribution.fit (x), "alpha", 0.01, "parameter", "a", ... 611s "NAME", "value") 611s ***** error ... 611s plot (BetaDistribution, "Parent") 611s ***** error ... 611s plot (BetaDistribution, "PlotType", 12) 611s ***** error ... 611s plot (BetaDistribution, "PlotType", {"pdf", "cdf"}) 611s ***** error ... 611s plot (BetaDistribution, "PlotType", "pdfcdf") 611s ***** error ... 611s plot (BetaDistribution, "Discrete", "pdfcdf") 611s ***** error ... 611s plot (BetaDistribution, "Discrete", [1, 0]) 611s ***** error ... 611s plot (BetaDistribution, "Discrete", {true}) 611s ***** error ... 611s plot (BetaDistribution, "Parent", 12) 611s ***** error ... 611s plot (BetaDistribution, "Parent", "hax") 611s ***** error ... 611s plot (BetaDistribution, "invalidNAME", "pdf") 611s ***** error ... 611s plot (BetaDistribution, "PlotType", "probability") 611s ***** error ... 611s proflik (BetaDistribution, 2) 611s ***** error ... 611s proflik (BetaDistribution.fit (x), 3) 611s ***** error ... 611s proflik (BetaDistribution.fit (x), [1, 2]) 611s ***** error ... 611s proflik (BetaDistribution.fit (x), {1}) 611s ***** error ... 611s proflik (BetaDistribution.fit (x), 1, ones (2)) 611s ***** error ... 611s proflik (BetaDistribution.fit (x), 1, "Display") 611s ***** error ... 611s proflik (BetaDistribution.fit (x), 1, "Display", 1) 611s ***** error ... 611s proflik (BetaDistribution.fit (x), 1, "Display", {1}) 611s ***** error ... 611s proflik (BetaDistribution.fit (x), 1, "Display", {"on"}) 611s ***** error ... 611s proflik (BetaDistribution.fit (x), 1, "Display", ["on"; "on"]) 611s ***** error ... 611s proflik (BetaDistribution.fit (x), 1, "Display", "onnn") 611s ***** error ... 611s proflik (BetaDistribution.fit (x), 1, "NAME", "on") 611s ***** error ... 611s proflik (BetaDistribution.fit (x), 1, {"NAME"}, "on") 611s ***** error ... 611s proflik (BetaDistribution.fit (x), 1, {[1 2 3 4]}, "Display", "on") 611s ***** error ... 611s truncate (BetaDistribution) 611s ***** error ... 611s truncate (BetaDistribution, 2) 611s ***** error ... 611s truncate (BetaDistribution, 4, 2) 611s ***** shared pd 611s pd = BetaDistribution(1, 1); 611s pd(2) = BetaDistribution(1, 3); 611s ***** error cdf (pd, 1) 611s ***** error icdf (pd, 0.5) 611s ***** error iqr (pd) 611s ***** error mean (pd) 611s ***** error median (pd) 611s ***** error negloglik (pd) 611s ***** error paramci (pd) 611s ***** error pdf (pd, 1) 611s ***** error plot (pd) 611s ***** error proflik (pd, 2) 611s ***** error random (pd) 611s ***** error std (pd) 611s ***** error ... 611s truncate (pd, 2, 4) 611s ***** error var (pd) 611s 96 tests, 96 passed, 0 known failure, 0 skipped 611s [inst/dist_obj/BurrDistribution.m] 611s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_obj/BurrDistribution.m 611s ***** demo 611s ## Generate a data set of 5000 random samples from a Burr type XII 611s ## distribution with parameters alpha = 1, c = 2, and k = 1. Fit a Burr type 611s ## XII distribution to this data and plot a PDF of the fitted distribution 611s ## superimposed on a histogram of the data 611s 611s pd = makedist ("Burr", "alpha", 1, "c", 2, "k", 1) 611s rand ("seed", 21); 611s data = random (pd, 5000, 1); 611s pd = fitdist (data, "Burr") 611s plot (pd) 611s msg = strcat (["Fitted Burr type XII distribution with"], ... 611s [" alpha = %0.2f, c = %0.2f, and k = %0.2f"]); 611s title (sprintf (msg, pd.alpha, pd.c, pd.k)) 611s ***** demo 611s ## Plot the PDF of a Burr type XII distribution, with parameters alpha = 1, 611s ## c = 2, and k = 1, truncated at [0, 2] intervals. Generate 10000 random 611s ## samples from this truncated distribution and superimpose a histogram with 611s ## 100 bins scaled accordingly 611s 611s pd = makedist ("Burr", "alpha", 1, "c", 2, "k", 1) 611s t = truncate (pd, 0.5, 2.5) 611s rand ("seed", 21); 611s data = random (t, 10000, 1); 611s plot (t) 611s title ("Burr type XII distribution (alpha = 1, c = 2, k = 1) truncated at [0.5, 2.5]") 611s hold on 611s hist (data, 100, 50) 611s hold off 611s ***** demo 611s ## Generate a data set of 100 random samples from a Burr type XII 611s ## distribution with parameters alpha = 1, c = 2, and k = 1. Fit a Burr type 611s ## XII distribution to this data and plot its CDF superimposed over an 611s ## empirical CDF of the data 611s 611s pd = makedist ("Burr", "alpha", 1, "c", 2, "k", 1) 611s rand ("seed", 21); 611s data = random (pd, 100, 1); 611s pd = fitdist (data, "Burr") 611s plot (pd, "plottype", "cdf") 611s msg = strcat (["Fitted Burr type XII distribution with"], ... 611s [" alpha = %0.2f, c = %0.2f, and k = %0.2f"]); 611s title (sprintf (msg, pd.alpha, pd.c, pd.k)) 611s legend ({"empirical CDF", "fitted CDF"}, "location", "east") 611s ***** shared pd, t 611s pd = BurrDistribution; 611s t = truncate (pd, 2, 4); 611s ***** assert (cdf (pd, [0:5]), [0, 0.5, 0.6667, 0.75, 0.8, 0.8333], 1e-4); 611s ***** assert (cdf (t, [0:5]), [0, 0, 0, 0.625, 1, 1], 1e-4); 611s ***** assert (cdf (pd, [1.5, 2, 3, 4]), [0.6, 0.6667, 0.75, 0.8], 1e-4); 611s ***** assert (cdf (t, [1.5, 2, 3, 4]), [0, 0, 0.625, 1], 1e-4); 611s ***** assert (icdf (pd, [0:0.2:1]), [0, 0.25, 0.6667, 1.5, 4, Inf], 1e-4); 612s ***** assert (icdf (t, [0:0.2:1]), [2, 2.2609, 2.5714, 2.9474, 3.4118, 4], 1e-4); 612s ***** assert (icdf (pd, [-1, 0.4:0.2:1, NaN]), [NaN, 0.6667, 1.5, 4, Inf, NaN], 1e-4); 612s ***** assert (icdf (t, [-1, 0.4:0.2:1, NaN]), [NaN, 2.5714, 2.9474, 3.4118, 4, NaN], 1e-4); 612s ***** assert (iqr (pd), 2.6667, 1e-4); 612s ***** assert (iqr (t), 0.9524, 1e-4); 612s ***** assert (mean (pd), Inf); 612s ***** assert (mean (t), 2.8312, 1e-4); 612s ***** assert (median (pd), 1, 1e-4); 612s ***** assert (median (t), 2.75, 1e-4); 612s ***** assert (pdf (pd, [0:5]), [1, 0.25, 0.1111, 0.0625, 0.04, 0.0278], 1e-4); 612s ***** assert (pdf (t, [0:5]), [0, 0, 0.8333, 0.4687, 0.3, 0], 1e-4); 612s ***** assert (pdf (pd, [-1, 1:4, NaN]), [0, 0.25, 0.1111, 0.0625, 0.04, NaN], 1e-4); 612s ***** assert (pdf (t, [-1, 1:4, NaN]), [0, 0, 0.8333, 0.4687, 0.3, NaN], 1e-4); 612s ***** assert (isequal (size (random (pd, 100, 50)), [100, 50])) 612s ***** assert (any (random (t, 1000, 1) < 2), false); 612s ***** assert (any (random (t, 1000, 1) > 4), false); 612s ***** assert (std (pd), Inf); 612s ***** assert (std (t), 0.5674, 1e-4); 612s ***** assert (var (pd), Inf); 612s ***** assert (var (t), 0.3220, 1e-4); 612s ***** error ... 612s BurrDistribution(0, 1, 1) 612s ***** error ... 612s BurrDistribution(-1, 1, 1) 612s ***** error ... 612s BurrDistribution(Inf, 1, 1) 612s ***** error ... 612s BurrDistribution(i, 1, 1) 612s ***** error ... 612s BurrDistribution("a", 1, 1) 612s ***** error ... 612s BurrDistribution([1, 2], 1, 1) 612s ***** error ... 612s BurrDistribution(NaN, 1, 1) 612s ***** error ... 612s BurrDistribution(1, 0, 1) 612s ***** error ... 612s BurrDistribution(1, -1, 1) 612s ***** error ... 612s BurrDistribution(1, Inf, 1) 612s ***** error ... 612s BurrDistribution(1, i, 1) 612s ***** error ... 612s BurrDistribution(1, "a", 1) 612s ***** error ... 612s BurrDistribution(1, [1, 2], 1) 612s ***** error ... 612s BurrDistribution(1, NaN, 1) 612s ***** error ... 612s BurrDistribution(1, 1, 0) 612s ***** error ... 612s BurrDistribution(1, 1, -1) 612s ***** error ... 612s BurrDistribution(1, 1, Inf) 612s ***** error ... 612s BurrDistribution(1, 1, i) 612s ***** error ... 612s BurrDistribution(1, 1, "a") 612s ***** error ... 612s BurrDistribution(1, 1, [1, 2]) 612s ***** error ... 612s BurrDistribution(1, 1, NaN) 612s ***** error ... 612s cdf (BurrDistribution, 2, "uper") 612s ***** error ... 612s cdf (BurrDistribution, 2, 3) 612s ***** shared x 612s rand ("seed", 4); 612s x = burrrnd (1, 1, 1, [1, 100]); 612s ***** error ... 612s paramci (BurrDistribution.fit (x), "alpha") 612s ***** error ... 612s paramci (BurrDistribution.fit (x), "alpha", 0) 612s ***** error ... 612s paramci (BurrDistribution.fit (x), "alpha", 1) 612s ***** error ... 612s paramci (BurrDistribution.fit (x), "alpha", [0.5 2]) 612s ***** error ... 612s paramci (BurrDistribution.fit (x), "alpha", "") 613s ***** error ... 613s paramci (BurrDistribution.fit (x), "alpha", {0.05}) 613s ***** error ... 613s paramci (BurrDistribution.fit (x), "parameter", "c", "alpha", {0.05}) 613s ***** error ... 613s paramci (BurrDistribution.fit (x), "parameter", {"alpha", "c", "k", "param"}) 613s ***** error ... 613s paramci (BurrDistribution.fit (x), "alpha", 0.01, ... 613s "parameter", {"alpha", "c", "k", "param"}) 613s ***** error ... 613s paramci (BurrDistribution.fit (x), "parameter", "param") 613s ***** error ... 613s paramci (BurrDistribution.fit (x), "alpha", 0.01, "parameter", "param") 614s ***** error ... 614s paramci (BurrDistribution.fit (x), "NAME", "value") 614s ***** error ... 614s paramci (BurrDistribution.fit (x), "alpha", 0.01, "NAME", "value") 614s ***** error ... 614s paramci (BurrDistribution.fit (x), "alpha", 0.01, "parameter", "c", ... 614s "NAME", "value") 614s ***** error ... 614s plot (BurrDistribution, "Parent") 614s ***** error ... 614s plot (BurrDistribution, "PlotType", 12) 614s ***** error ... 614s plot (BurrDistribution, "PlotType", {"pdf", "cdf"}) 614s ***** error ... 614s plot (BurrDistribution, "PlotType", "pdfcdf") 614s ***** error ... 614s plot (BurrDistribution, "Discrete", "pdfcdf") 614s ***** error ... 614s plot (BurrDistribution, "Discrete", [1, 0]) 614s ***** error ... 614s plot (BurrDistribution, "Discrete", {true}) 614s ***** error ... 614s plot (BurrDistribution, "Parent", 12) 614s ***** error ... 614s plot (BurrDistribution, "Parent", "hax") 614s ***** error ... 614s plot (BurrDistribution, "invalidNAME", "pdf") 614s ***** error ... 614s plot (BurrDistribution, "PlotType", "probability") 614s ***** error ... 614s proflik (BurrDistribution, 2) 614s ***** error ... 614s proflik (BurrDistribution.fit (x), 4) 614s ***** error ... 614s proflik (BurrDistribution.fit (x), [1, 2]) 614s ***** error ... 614s proflik (BurrDistribution.fit (x), {1}) 615s ***** error ... 615s proflik (BurrDistribution.fit (x), 1, ones (2)) 615s ***** error ... 615s proflik (BurrDistribution.fit (x), 1, "Display") 615s ***** error ... 615s proflik (BurrDistribution.fit (x), 1, "Display", 1) 615s ***** error ... 615s proflik (BurrDistribution.fit (x), 1, "Display", {1}) 615s ***** error ... 615s proflik (BurrDistribution.fit (x), 1, "Display", {"on"}) 615s ***** error ... 615s proflik (BurrDistribution.fit (x), 1, "Display", ["on"; "on"]) 616s ***** error ... 616s proflik (BurrDistribution.fit (x), 1, "Display", "onnn") 616s ***** error ... 616s proflik (BurrDistribution.fit (x), 1, "NAME", "on") 616s ***** error ... 616s proflik (BurrDistribution.fit (x), 1, {"NAME"}, "on") 616s ***** error ... 616s proflik (BurrDistribution.fit (x), 1, {[1 2 3 4]}, "Display", "on") 616s ***** error ... 616s truncate (BurrDistribution) 616s ***** error ... 616s truncate (BurrDistribution, 2) 616s ***** error ... 616s truncate (BurrDistribution, 4, 2) 616s ***** shared pd 616s pd = BurrDistribution(1, 1, 1); 616s pd(2) = BurrDistribution(1, 3, 1); 616s ***** error cdf (pd, 1) 616s ***** error icdf (pd, 0.5) 616s ***** error iqr (pd) 616s ***** error mean (pd) 616s ***** error median (pd) 616s ***** error negloglik (pd) 616s ***** error paramci (pd) 616s ***** error pdf (pd, 1) 616s ***** error plot (pd) 616s ***** error proflik (pd, 2) 616s ***** error random (pd) 616s ***** error std (pd) 616s ***** error ... 616s truncate (pd, 2, 4) 616s ***** error var (pd) 616s 104 tests, 104 passed, 0 known failure, 0 skipped 616s [inst/dist_obj/LoglogisticDistribution.m] 616s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_obj/LoglogisticDistribution.m 616s ***** shared pd, t 616s pd = LoglogisticDistribution; 616s t = truncate (pd, 2, 4); 616s ***** assert (cdf (pd, [0:5]), [0, 0.5, 0.6667, 0.75, 0.8, 0.8333], 1e-4); 616s ***** assert (cdf (t, [0:5]), [0, 0, 0, 0.625, 1, 1], 1e-4); 616s ***** assert (cdf (pd, [1.5, 2, 3, 4]), [0.6, 0.6667, 0.75, 0.8], 1e-4); 616s ***** assert (cdf (t, [1.5, 2, 3, 4]), [0, 0, 0.625, 1], 1e-4); 616s ***** assert (icdf (pd, [0:0.2:1]), [0, 0.25, 0.6667, 1.5, 4, Inf], 1e-4); 616s ***** assert (icdf (t, [0:0.2:1]), [2, 2.2609, 2.5714, 2.9474, 3.4118, 4], 1e-4); 616s ***** assert (icdf (pd, [-1, 0.4:0.2:1, NaN]), [NaN, 0.6667, 1.5, 4, Inf, NaN], 1e-4); 616s ***** assert (icdf (t, [-1, 0.4:0.2:1, NaN]), [NaN, 2.5714, 2.9474, 3.4118, 4, NaN], 1e-4); 616s ***** assert (iqr (pd), 2.6667, 1e-4); 616s ***** assert (iqr (t), 0.9524, 1e-4); 616s ***** assert (mean (pd), Inf); 616s ***** assert (mean (t), 2.8312, 1e-4); 616s ***** assert (median (pd), 1, 1e-4); 616s ***** assert (median (t), 2.75, 1e-4); 616s ***** assert (pdf (pd, [0:5]), [0, 0.25, 0.1111, 0.0625, 0.04, 0.0278], 1e-4); 616s ***** assert (pdf (t, [0:5]), [0, 0, 0.8333, 0.4687, 0.3, 0], 1e-4); 616s ***** assert (pdf (pd, [-1, 1:4, NaN]), [0, 0.25, 0.1111, 0.0625, 0.04, NaN], 1e-4); 616s ***** assert (pdf (t, [-1, 1:4, NaN]), [0, 0, 0.8333, 0.4687, 0.3, NaN], 1e-4); 616s ***** assert (isequal (size (random (pd, 100, 50)), [100, 50])) 616s ***** assert (any (random (t, 1000, 1) < 2), false); 616s ***** assert (any (random (t, 1000, 1) > 4), false); 617s ***** assert (std (pd), Inf); 617s ***** assert (std (t), 0.5674, 1e-4); 617s ***** assert (var (pd), Inf); 617s ***** assert (var (t), 0.3220, 1e-4); 617s ***** error ... 617s LoglogisticDistribution(Inf, 1) 617s ***** error ... 617s LoglogisticDistribution(i, 1) 617s ***** error ... 617s LoglogisticDistribution("a", 1) 617s ***** error ... 617s LoglogisticDistribution([1, 2], 1) 617s ***** error ... 617s LoglogisticDistribution(NaN, 1) 617s ***** error ... 617s LoglogisticDistribution(1, 0) 617s ***** error ... 617s LoglogisticDistribution(1, -1) 617s ***** error ... 617s LoglogisticDistribution(1, Inf) 617s ***** error ... 617s LoglogisticDistribution(1, i) 617s ***** error ... 617s LoglogisticDistribution(1, "a") 617s ***** error ... 617s LoglogisticDistribution(1, [1, 2]) 617s ***** error ... 617s LoglogisticDistribution(1, NaN) 617s ***** error ... 617s cdf (LoglogisticDistribution, 2, "uper") 617s ***** error ... 617s cdf (LoglogisticDistribution, 2, 3) 617s ***** shared x 617s x = loglrnd (1, 1, [1, 100]); 617s ***** error ... 617s paramci (LoglogisticDistribution.fit (x), "alpha") 617s ***** error ... 617s paramci (LoglogisticDistribution.fit (x), "alpha", 0) 617s ***** error ... 617s paramci (LoglogisticDistribution.fit (x), "alpha", 1) 617s ***** error ... 617s paramci (LoglogisticDistribution.fit (x), "alpha", [0.5 2]) 617s ***** error ... 617s paramci (LoglogisticDistribution.fit (x), "alpha", "") 617s ***** error ... 617s paramci (LoglogisticDistribution.fit (x), "alpha", {0.05}) 617s ***** error ... 617s paramci (LoglogisticDistribution.fit (x), "parameter", "mu", "alpha", {0.05}) 617s ***** error ... 617s paramci (LoglogisticDistribution.fit (x), "parameter", {"mu", "sigma", "pa"}) 617s ***** error ... 617s paramci (LoglogisticDistribution.fit (x), "alpha", 0.01, ... 617s "parameter", {"mu", "sigma", "param"}) 617s ***** error ... 617s paramci (LoglogisticDistribution.fit (x), "parameter", "param") 617s ***** error ... 617s paramci (LoglogisticDistribution.fit (x), "alpha", 0.01, "parameter", "parm") 618s ***** error ... 618s paramci (LoglogisticDistribution.fit (x), "NAME", "value") 618s ***** error ... 618s paramci (LoglogisticDistribution.fit (x), "alpha", 0.01, "NAME", "value") 618s ***** error ... 618s paramci (LoglogisticDistribution.fit (x), "alpha", 0.01, ... 618s "parameter", "mu", "NAME", "value") 618s ***** error ... 618s plot (LoglogisticDistribution, "Parent") 618s ***** error ... 618s plot (LoglogisticDistribution, "PlotType", 12) 618s ***** error ... 618s plot (LoglogisticDistribution, "PlotType", {"pdf", "cdf"}) 618s ***** error ... 618s plot (LoglogisticDistribution, "PlotType", "pdfcdf") 618s ***** error ... 618s plot (LoglogisticDistribution, "Discrete", "pdfcdf") 618s ***** error ... 618s plot (LoglogisticDistribution, "Discrete", [1, 0]) 618s ***** error ... 618s plot (LoglogisticDistribution, "Discrete", {true}) 618s ***** error ... 618s plot (LoglogisticDistribution, "Parent", 12) 618s ***** error ... 618s plot (LoglogisticDistribution, "Parent", "hax") 618s ***** error ... 618s plot (LoglogisticDistribution, "invalidNAME", "pdf") 618s ***** error ... 618s plot (LoglogisticDistribution, "PlotType", "probability") 618s ***** error ... 618s proflik (LoglogisticDistribution, 2) 618s ***** error ... 618s proflik (LoglogisticDistribution.fit (x), 3) 618s ***** error ... 618s proflik (LoglogisticDistribution.fit (x), [1, 2]) 618s ***** error ... 618s proflik (LoglogisticDistribution.fit (x), {1}) 618s ***** error ... 618s proflik (LoglogisticDistribution.fit (x), 1, ones (2)) 618s ***** error ... 618s proflik (LoglogisticDistribution.fit (x), 1, "Display") 618s ***** error ... 618s proflik (LoglogisticDistribution.fit (x), 1, "Display", 1) 618s ***** error ... 618s proflik (LoglogisticDistribution.fit (x), 1, "Display", {1}) 619s ***** error ... 619s proflik (LoglogisticDistribution.fit (x), 1, "Display", {"on"}) 619s ***** error ... 619s proflik (LoglogisticDistribution.fit (x), 1, "Display", ["on"; "on"]) 619s ***** error ... 619s proflik (LoglogisticDistribution.fit (x), 1, "Display", "onnn") 619s ***** error ... 619s proflik (LoglogisticDistribution.fit (x), 1, "NAME", "on") 619s ***** error ... 619s proflik (LoglogisticDistribution.fit (x), 1, {"NAME"}, "on") 619s ***** error ... 619s proflik (LoglogisticDistribution.fit (x), 1, {[1 2 3 4]}, "Display", "on") 619s ***** error ... 619s truncate (LoglogisticDistribution) 619s ***** error ... 619s truncate (LoglogisticDistribution, 2) 619s ***** error ... 619s truncate (LoglogisticDistribution, 4, 2) 619s ***** shared pd 619s pd = LoglogisticDistribution(1, 1); 619s pd(2) = LoglogisticDistribution(1, 3); 619s ***** error cdf (pd, 1) 619s ***** error icdf (pd, 0.5) 619s ***** error iqr (pd) 619s ***** error mean (pd) 619s ***** error median (pd) 619s ***** error negloglik (pd) 619s ***** error paramci (pd) 619s ***** error pdf (pd, 1) 619s ***** error plot (pd) 619s ***** error proflik (pd, 2) 619s ***** error random (pd) 619s ***** error std (pd) 619s ***** error ... 619s truncate (pd, 2, 4) 619s ***** error var (pd) 619s 95 tests, 95 passed, 0 known failure, 0 skipped 619s [inst/dist_obj/WeibullDistribution.m] 619s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_obj/WeibullDistribution.m 619s ***** shared pd, t 619s pd = WeibullDistribution; 619s t = truncate (pd, 2, 4); 619s ***** assert (cdf (pd, [0:5]), [0, 0.6321, 0.8647, 0.9502, 0.9817, 0.9933], 1e-4); 619s ***** assert (cdf (t, [0:5]), [0, 0, 0, 0.7311, 1, 1], 1e-4); 619s ***** assert (cdf (pd, [1.5, 2, 3, 4, NaN]), [0.7769, 0.8647, 0.9502, 0.9817, NaN], 1e-4); 619s ***** assert (cdf (t, [1.5, 2, 3, 4, NaN]), [0, 0, 0.7311, 1, NaN], 1e-4); 619s ***** assert (icdf (pd, [0:0.2:1]), [0, 0.2231, 0.5108, 0.9163, 1.6094, Inf], 1e-4); 619s ***** assert (icdf (t, [0:0.2:1]), [2, 2.1899, 2.4244, 2.7315, 3.1768, 4], 1e-4); 619s ***** assert (icdf (pd, [-1, 0.4:0.2:1, NaN]), [NaN, 0.5108, 0.9163, 1.6094, Inf, NaN], 1e-4); 619s ***** assert (icdf (t, [-1, 0.4:0.2:1, NaN]), [NaN, 2.4244, 2.7315, 3.1768, 4, NaN], 1e-4); 619s ***** assert (iqr (pd), 1.0986, 1e-4); 619s ***** assert (iqr (t), 0.8020, 1e-4); 619s ***** assert (mean (pd), 1, 1e-14); 619s ***** assert (mean (t), 2.6870, 1e-4); 619s ***** assert (median (pd), 0.6931, 1e-4); 619s ***** assert (median (t), 2.5662, 1e-4); 619s ***** assert (pdf (pd, [0:5]), [1, 0.3679, 0.1353, 0.0498, 0.0183, 0.0067], 1e-4); 619s ***** assert (pdf (t, [0:5]), [0, 0, 1.1565, 0.4255, 0.1565, 0], 1e-4); 619s ***** assert (pdf (pd, [-1, 1.5, NaN]), [0, 0.2231, NaN], 1e-4); 619s ***** assert (pdf (t, [-1, 1.5, NaN]), [0, 0, NaN], 1e-4); 619s ***** assert (isequal (size (random (pd, 100, 50)), [100, 50])) 619s ***** assert (any (random (t, 1000, 1) < 2), false); 619s ***** assert (any (random (t, 1000, 1) > 4), false); 619s ***** assert (std (pd), 1, 1e-14); 619s ***** assert (std (t), 0.5253, 1e-4); 619s ***** assert (var (pd), 1, 1e-14); 619s ***** assert (var (t), 0.2759, 1e-4); 619s ***** error ... 619s WeibullDistribution(0, 1) 619s ***** error ... 619s WeibullDistribution(-1, 1) 619s ***** error ... 619s WeibullDistribution(Inf, 1) 619s ***** error ... 619s WeibullDistribution(i, 1) 619s ***** error ... 619s WeibullDistribution("a", 1) 619s ***** error ... 619s WeibullDistribution([1, 2], 1) 619s ***** error ... 619s WeibullDistribution(NaN, 1) 619s ***** error ... 619s WeibullDistribution(1, 0) 619s ***** error ... 619s WeibullDistribution(1, -1) 619s ***** error ... 619s WeibullDistribution(1, Inf) 619s ***** error ... 619s WeibullDistribution(1, i) 619s ***** error ... 619s WeibullDistribution(1, "a") 619s ***** error ... 619s WeibullDistribution(1, [1, 2]) 619s ***** error ... 619s WeibullDistribution(1, NaN) 619s ***** error ... 619s cdf (WeibullDistribution, 2, "uper") 619s ***** error ... 619s cdf (WeibullDistribution, 2, 3) 619s ***** shared x 619s x = wblrnd (1, 1, [1, 100]); 619s ***** error ... 619s paramci (WeibullDistribution.fit (x), "alpha") 619s ***** error ... 619s paramci (WeibullDistribution.fit (x), "alpha", 0) 619s ***** error ... 619s paramci (WeibullDistribution.fit (x), "alpha", 1) 619s ***** error ... 619s paramci (WeibullDistribution.fit (x), "alpha", [0.5 2]) 619s ***** error ... 619s paramci (WeibullDistribution.fit (x), "alpha", "") 619s ***** error ... 619s paramci (WeibullDistribution.fit (x), "alpha", {0.05}) 619s ***** error ... 619s paramci (WeibullDistribution.fit (x), "parameter", "k", "alpha", {0.05}) 619s ***** error ... 619s paramci (WeibullDistribution.fit (x), "parameter", {"lambda", "k", "param"}) 619s ***** error ... 619s paramci (WeibullDistribution.fit (x), "alpha", 0.01, ... 619s "parameter", {"lambda", "k", "param"}) 619s ***** error ... 619s paramci (WeibullDistribution.fit (x), "parameter", "param") 619s ***** error ... 619s paramci (WeibullDistribution.fit (x), "alpha", 0.01, "parameter", "param") 620s ***** error ... 620s paramci (WeibullDistribution.fit (x), "NAME", "value") 620s ***** error ... 620s paramci (WeibullDistribution.fit (x), "alpha", 0.01, "NAME", "value") 620s ***** error ... 620s paramci (WeibullDistribution.fit (x), "alpha", 0.01, "parameter", "k", ... 620s "NAME", "value") 620s ***** error ... 620s plot (WeibullDistribution, "Parent") 620s ***** error ... 620s plot (WeibullDistribution, "PlotType", 12) 620s ***** error ... 620s plot (WeibullDistribution, "PlotType", {"pdf", "cdf"}) 620s ***** error ... 620s plot (WeibullDistribution, "PlotType", "pdfcdf") 620s ***** error ... 620s plot (WeibullDistribution, "Discrete", "pdfcdf") 620s ***** error ... 620s plot (WeibullDistribution, "Discrete", [1, 0]) 620s ***** error ... 620s plot (WeibullDistribution, "Discrete", {true}) 620s ***** error ... 620s plot (WeibullDistribution, "Parent", 12) 620s ***** error ... 620s plot (WeibullDistribution, "Parent", "hax") 620s ***** error ... 620s plot (WeibullDistribution, "invalidNAME", "pdf") 620s ***** error ... 620s plot (WeibullDistribution, "PlotType", "probability") 620s ***** error ... 620s proflik (WeibullDistribution, 2) 620s ***** error ... 620s proflik (WeibullDistribution.fit (x), 3) 620s ***** error ... 620s proflik (WeibullDistribution.fit (x), [1, 2]) 620s ***** error ... 620s proflik (WeibullDistribution.fit (x), {1}) 620s ***** error ... 620s proflik (WeibullDistribution.fit (x), 1, ones (2)) 620s ***** error ... 620s proflik (WeibullDistribution.fit (x), 1, "Display") 620s ***** error ... 620s proflik (WeibullDistribution.fit (x), 1, "Display", 1) 620s ***** error ... 620s proflik (WeibullDistribution.fit (x), 1, "Display", {1}) 620s ***** error ... 620s proflik (WeibullDistribution.fit (x), 1, "Display", {"on"}) 620s ***** error ... 620s proflik (WeibullDistribution.fit (x), 1, "Display", ["on"; "on"]) 620s ***** error ... 620s proflik (WeibullDistribution.fit (x), 1, "Display", "onnn") 620s ***** error ... 620s proflik (WeibullDistribution.fit (x), 1, "NAME", "on") 620s ***** error ... 620s proflik (WeibullDistribution.fit (x), 1, {"NAME"}, "on") 620s ***** error ... 620s proflik (WeibullDistribution.fit (x), 1, {[1 2 3 4]}, "Display", "on") 620s ***** error ... 620s truncate (WeibullDistribution) 620s ***** error ... 620s truncate (WeibullDistribution, 2) 620s ***** error ... 620s truncate (WeibullDistribution, 4, 2) 620s ***** shared pd 620s pd = WeibullDistribution(1, 1); 620s pd(2) = WeibullDistribution(1, 3); 620s ***** error cdf (pd, 1) 620s ***** error icdf (pd, 0.5) 620s ***** error iqr (pd) 620s ***** error mean (pd) 620s ***** error median (pd) 620s ***** error negloglik (pd) 620s ***** error paramci (pd) 620s ***** error pdf (pd, 1) 620s ***** error plot (pd) 620s ***** error proflik (pd, 2) 620s ***** error random (pd) 620s ***** error std (pd) 620s ***** error ... 620s truncate (pd, 2, 4) 620s ***** error var (pd) 620s 97 tests, 97 passed, 0 known failure, 0 skipped 620s [inst/dist_obj/LogisticDistribution.m] 620s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_obj/LogisticDistribution.m 620s ***** shared pd, t 620s pd = LogisticDistribution (0, 1); 620s t = truncate (pd, 2, 4); 620s ***** assert (cdf (pd, [0:5]), [0.5, 0.7311, 0.8808, 0.9526, 0.9820, 0.9933], 1e-4); 620s ***** assert (cdf (t, [0:5]), [0, 0, 0, 0.7091, 1, 1], 1e-4); 620s ***** assert (cdf (pd, [1.5, 2, 3, 4]), [0.8176, 0.8808, 0.9526, 0.9820], 1e-4); 620s ***** assert (cdf (t, [1.5, 2, 3, 4]), [0, 0, 0.7091, 1], 1e-4); 620s ***** assert (icdf (pd, [0:0.2:1]), [-Inf, -1.3863, -0.4055, 0.4055, 1.3863, Inf], 1e-4); 620s ***** assert (icdf (t, [0:0.2:1]), [2, 2.2088, 2.4599, 2.7789, 3.2252, 4], 1e-4); 620s ***** assert (icdf (pd, [-1, 0.4:0.2:1, NaN]), [NaN, -0.4055, 0.4055, 1.3863, Inf, NaN], 1e-4); 620s ***** assert (icdf (t, [-1, 0.4:0.2:1, NaN]), [NaN, 2.4599, 2.7789, 3.2252, 4, NaN], 1e-4); 620s ***** assert (iqr (pd), 2.1972, 1e-4); 620s ***** assert (iqr (t), 0.8286, 1e-4); 620s ***** assert (mean (pd), 0, 1e-4); 620s ***** assert (mean (t), 2.7193, 1e-4); 620s ***** assert (median (pd), 0); 620s ***** assert (median (t), 2.6085, 1e-4); 620s ***** assert (pdf (pd, [0:5]), [0.25, 0.1966, 0.1050, 0.0452, 0.0177, 0.0066], 1e-4); 620s ***** assert (pdf (t, [0:5]), [0, 0, 1.0373, 0.4463, 0.1745, 0], 1e-4); 620s ***** assert (pdf (pd, [-1, 1:4, NaN]), [0.1966, 0.1966, 0.1050, 0.0452, 0.0177, NaN], 1e-4); 620s ***** assert (pdf (t, [-1, 1:4, NaN]), [0, 0, 1.0373, 0.4463, 0.1745, NaN], 1e-4); 620s ***** assert (isequal (size (random (pd, 100, 50)), [100, 50])) 620s ***** assert (any (random (t, 1000, 1) < 2), false); 620s ***** assert (any (random (t, 1000, 1) > 4), false); 620s ***** assert (std (pd), 1.8138, 1e-4); 620s ***** assert (std (t), 0.5320, 1e-4); 620s ***** assert (var (pd), 3.2899, 1e-4); 620s ***** assert (var (t), 0.2830, 1e-4); 620s ***** error ... 620s LogisticDistribution(Inf, 1) 620s ***** error ... 620s LogisticDistribution(i, 1) 620s ***** error ... 620s LogisticDistribution("a", 1) 620s ***** error ... 620s LogisticDistribution([1, 2], 1) 620s ***** error ... 620s LogisticDistribution(NaN, 1) 620s ***** error ... 620s LogisticDistribution(1, 0) 620s ***** error ... 620s LogisticDistribution(1, -1) 620s ***** error ... 620s LogisticDistribution(1, Inf) 620s ***** error ... 620s LogisticDistribution(1, i) 620s ***** error ... 620s LogisticDistribution(1, "a") 620s ***** error ... 620s LogisticDistribution(1, [1, 2]) 620s ***** error ... 620s LogisticDistribution(1, NaN) 620s ***** error ... 620s cdf (LogisticDistribution, 2, "uper") 620s ***** error ... 620s cdf (LogisticDistribution, 2, 3) 620s ***** shared x 620s x = logirnd (1, 1, [1, 100]); 620s ***** error ... 620s paramci (LogisticDistribution.fit (x), "alpha") 620s ***** error ... 620s paramci (LogisticDistribution.fit (x), "alpha", 0) 620s ***** error ... 620s paramci (LogisticDistribution.fit (x), "alpha", 1) 620s ***** error ... 620s paramci (LogisticDistribution.fit (x), "alpha", [0.5 2]) 620s ***** error ... 620s paramci (LogisticDistribution.fit (x), "alpha", "") 620s ***** error ... 620s paramci (LogisticDistribution.fit (x), "alpha", {0.05}) 621s ***** error ... 621s paramci (LogisticDistribution.fit (x), "parameter", "mu", "alpha", {0.05}) 621s ***** error ... 621s paramci (LogisticDistribution.fit (x), "parameter", {"mu", "sigma", "param"}) 621s ***** error ... 621s paramci (LogisticDistribution.fit (x), "alpha", 0.01, ... 621s "parameter", {"mu", "sigma", "param"}) 621s ***** error ... 621s paramci (LogisticDistribution.fit (x), "parameter", "param") 621s ***** error ... 621s paramci (LogisticDistribution.fit (x), "alpha", 0.01, "parameter", "param") 621s ***** error ... 621s paramci (LogisticDistribution.fit (x), "NAME", "value") 621s ***** error ... 621s paramci (LogisticDistribution.fit (x), "alpha", 0.01, "NAME", "value") 621s ***** error ... 621s paramci (LogisticDistribution.fit (x), "alpha", 0.01, "parameter", "mu", ... 621s "NAME", "value") 621s ***** error ... 621s plot (LogisticDistribution, "Parent") 621s ***** error ... 621s plot (LogisticDistribution, "PlotType", 12) 621s ***** error ... 621s plot (LogisticDistribution, "PlotType", {"pdf", "cdf"}) 621s ***** error ... 621s plot (LogisticDistribution, "PlotType", "pdfcdf") 621s ***** error ... 621s plot (LogisticDistribution, "Discrete", "pdfcdf") 621s ***** error ... 621s plot (LogisticDistribution, "Discrete", [1, 0]) 621s ***** error ... 621s plot (LogisticDistribution, "Discrete", {true}) 621s ***** error ... 621s plot (LogisticDistribution, "Parent", 12) 621s ***** error ... 621s plot (LogisticDistribution, "Parent", "hax") 621s ***** error ... 621s plot (LogisticDistribution, "invalidNAME", "pdf") 621s ***** error ... 621s plot (LogisticDistribution, "PlotType", "probability") 621s ***** error ... 621s proflik (LogisticDistribution, 2) 621s ***** error ... 621s proflik (LogisticDistribution.fit (x), 3) 621s ***** error ... 621s proflik (LogisticDistribution.fit (x), [1, 2]) 621s ***** error ... 621s proflik (LogisticDistribution.fit (x), {1}) 622s ***** error ... 622s proflik (LogisticDistribution.fit (x), 1, ones (2)) 622s ***** error ... 622s proflik (LogisticDistribution.fit (x), 1, "Display") 622s ***** error ... 622s proflik (LogisticDistribution.fit (x), 1, "Display", 1) 622s ***** error ... 622s proflik (LogisticDistribution.fit (x), 1, "Display", {1}) 622s ***** error ... 622s proflik (LogisticDistribution.fit (x), 1, "Display", {"on"}) 622s ***** error ... 622s proflik (LogisticDistribution.fit (x), 1, "Display", ["on"; "on"]) 622s ***** error ... 622s proflik (LogisticDistribution.fit (x), 1, "Display", "onnn") 622s ***** error ... 622s proflik (LogisticDistribution.fit (x), 1, "NAME", "on") 622s ***** error ... 622s proflik (LogisticDistribution.fit (x), 1, {"NAME"}, "on") 623s ***** error ... 623s proflik (LogisticDistribution.fit (x), 1, {[1 2 3 4]}, "Display", "on") 623s ***** error ... 623s truncate (LogisticDistribution) 623s ***** error ... 623s truncate (LogisticDistribution, 2) 623s ***** error ... 623s truncate (LogisticDistribution, 4, 2) 623s ***** shared pd 623s pd = LogisticDistribution(1, 1); 623s pd(2) = LogisticDistribution(1, 3); 623s ***** error cdf (pd, 1) 623s ***** error icdf (pd, 0.5) 623s ***** error iqr (pd) 623s ***** error mean (pd) 623s ***** error median (pd) 623s ***** error negloglik (pd) 623s ***** error paramci (pd) 623s ***** error pdf (pd, 1) 623s ***** error plot (pd) 623s ***** error proflik (pd, 2) 623s ***** error random (pd) 623s ***** error std (pd) 623s ***** error ... 623s truncate (pd, 2, 4) 623s ***** error var (pd) 623s 95 tests, 95 passed, 0 known failure, 0 skipped 623s [inst/dist_obj/TriangularDistribution.m] 623s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_obj/TriangularDistribution.m 623s ***** shared pd, t 623s pd = TriangularDistribution (0, 3, 5); 623s t = truncate (pd, 2, 4); 623s ***** assert (cdf (pd, [0:5]), [0, 0.0667, 0.2667, 0.6000, 0.9000, 1], 1e-4); 623s ***** assert (cdf (t, [0:5]), [0, 0, 0, 0.5263, 1, 1], 1e-4); 623s ***** assert (cdf (pd, [1.5, 2, 3, 4, NaN]), [0.1500, 0.2667, 0.6, 0.9, NaN], 1e-4); 623s ***** assert (cdf (t, [1.5, 2, 3, 4, NaN]), [0, 0, 0.5263, 1, NaN], 1e-4); 623s ***** assert (icdf (pd, [0:0.2:1]), [0, 1.7321, 2.4495, 3, 3.5858, 5], 1e-4); 623s ***** assert (icdf (t, [0:0.2:1]), [2, 2.4290, 2.7928, 3.1203, 3.4945, 4], 1e-4); 623s ***** assert (icdf (pd, [-1, 0.4:0.2:1, NaN]), [NaN, 2.4495, 3, 3.5858, 5, NaN], 1e-4); 623s ***** assert (icdf (t, [-1, 0.4:0.2:1, NaN]), [NaN, 2.7928, 3.1203, 3.4945, 4, NaN], 1e-4); 623s ***** assert (iqr (pd), 1.4824, 1e-4); 623s ***** assert (iqr (t), 0.8678, 1e-4); 623s ***** assert (mean (pd), 2.6667, 1e-4); 623s ***** assert (mean (t), 2.9649, 1e-4); 623s ***** assert (median (pd), 2.7386, 1e-4); 623s ***** assert (median (t), 2.9580, 1e-4); 623s ***** assert (pdf (pd, [0:5]), [0, 0.1333, 0.2667, 0.4, 0.2, 0], 1e-4); 623s ***** assert (pdf (t, [0:5]), [0, 0, 0.4211, 0.6316, 0.3158, 0], 1e-4); 623s ***** assert (pdf (pd, [-1, 1.5, NaN]), [0, 0.2, NaN], 1e-4); 623s ***** assert (pdf (t, [-1, 1.5, NaN]), [0, 0, NaN], 1e-4); 623s ***** assert (isequal (size (random (pd, 100, 50)), [100, 50])) 623s ***** assert (any (random (t, 1000, 1) < 2), false); 623s ***** assert (any (random (t, 1000, 1) > 4), false); 623s ***** assert (std (pd), 1.0274, 1e-4); 623s ***** assert (std (t), 0.5369, 1e-4); 623s ***** assert (var (pd), 1.0556, 1e-4); 623s ***** assert (var (t), 0.2882, 1e-4); 623s ***** error ... 623s TriangularDistribution (i, 1, 2) 623s ***** error ... 623s TriangularDistribution (Inf, 1, 2) 623s ***** error ... 623s TriangularDistribution ([1, 2], 1, 2) 623s ***** error ... 623s TriangularDistribution ("a", 1, 2) 623s ***** error ... 623s TriangularDistribution (NaN, 1, 2) 623s ***** error ... 623s TriangularDistribution (1, i, 2) 623s ***** error ... 623s TriangularDistribution (1, Inf, 2) 623s ***** error ... 623s TriangularDistribution (1, [1, 2], 2) 623s ***** error ... 623s TriangularDistribution (1, "a", 2) 623s ***** error ... 623s TriangularDistribution (1, NaN, 2) 623s ***** error ... 623s TriangularDistribution (1, 2, i) 623s ***** error ... 623s TriangularDistribution (1, 2, Inf) 623s ***** error ... 623s TriangularDistribution (1, 2, [1, 2]) 623s ***** error ... 623s TriangularDistribution (1, 2, "a") 623s ***** error ... 623s TriangularDistribution (1, 2, NaN) 623s ***** error ... 623s TriangularDistribution (1, 1, 1) 623s ***** error ... 623s TriangularDistribution (1, 0.5, 2) 623s ***** error ... 623s cdf (TriangularDistribution, 2, "uper") 623s ***** error ... 623s cdf (TriangularDistribution, 2, 3) 623s ***** error ... 623s plot (TriangularDistribution, "Parent") 623s ***** error ... 623s plot (TriangularDistribution, "PlotType", 12) 623s ***** error ... 623s plot (TriangularDistribution, "PlotType", {"pdf", "cdf"}) 623s ***** error ... 623s plot (TriangularDistribution, "PlotType", "pdfcdf") 623s ***** error ... 623s plot (TriangularDistribution, "Discrete", "pdfcdf") 623s ***** error ... 623s plot (TriangularDistribution, "Discrete", [1, 0]) 623s ***** error ... 623s plot (TriangularDistribution, "Discrete", {true}) 623s ***** error ... 623s plot (TriangularDistribution, "Parent", 12) 623s ***** error ... 623s plot (TriangularDistribution, "Parent", "hax") 623s ***** error ... 623s plot (TriangularDistribution, "invalidNAME", "pdf") 623s ***** error <'probability' PlotType is not supported for 'TriangularDistribution'.> ... 623s plot (TriangularDistribution, "PlotType", "probability") 623s ***** error ... 623s truncate (TriangularDistribution) 623s ***** error ... 623s truncate (TriangularDistribution, 2) 623s ***** error ... 623s truncate (TriangularDistribution, 4, 2) 623s ***** shared pd 623s pd = TriangularDistribution (0, 1, 2); 623s pd(2) = TriangularDistribution (0, 1, 2); 623s ***** error cdf (pd, 1) 623s ***** error icdf (pd, 0.5) 623s ***** error iqr (pd) 623s ***** error mean (pd) 623s ***** error median (pd) 623s ***** error pdf (pd, 1) 623s ***** error plot (pd) 623s ***** error random (pd) 623s ***** error std (pd) 623s ***** error ... 623s truncate (pd, 2, 4) 623s ***** error var (pd) 623s 69 tests, 69 passed, 0 known failure, 0 skipped 623s [inst/dist_obj/GeneralizedExtremeValueDistribution.m] 623s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_obj/GeneralizedExtremeValueDistribution.m 623s ***** shared pd, t 623s pd = GeneralizedExtremeValueDistribution; 623s t = truncate (pd, 2, 4); 623s ***** assert (cdf (pd, [0:5]), [0.3679, 0.6922, 0.8734, 0.9514, 0.9819, 0.9933], 1e-4); 623s ***** assert (cdf (t, [0:5]), [0, 0, 0, 0.7195, 1, 1], 1e-4); 623s ***** assert (cdf (pd, [1.5, 2, 3, 4]), [0.8, 0.8734, 0.9514, 0.9819], 1e-4); 623s ***** assert (cdf (t, [1.5, 2, 3, 4]), [0, 0, 0.7195, 1], 1e-4); 623s ***** assert (icdf (pd, [0:0.2:1]), [-Inf, -0.4759, 0.0874, 0.6717, 1.4999, Inf], 1e-4); 623s ***** assert (icdf (t, [0:0.2:1]), [2, 2.1999, 2.4433, 2.7568, 3.2028, 4], 1e-4); 623s ***** assert (icdf (pd, [-1, 0.4:0.2:1, NaN]), [NaN, 0.0874, 0.6717, 1.4999, Inf, NaN], 1e-4); 623s ***** assert (icdf (t, [-1, 0.4:0.2:1, NaN]), [NaN, 2.4433, 2.7568, 3.2028, 4, NaN], 1e-4); 623s ***** assert (iqr (pd), 1.5725, 1e-4); 623s ***** assert (iqr (t), 0.8164, 1e-4); 623s ***** assert (mean (pd), 0.5772, 1e-4); 623s ***** assert (mean (t), 2.7043, 1e-4); 623s ***** assert (median (pd), 0.3665, 1e-4); 623s ***** assert (median (t), 2.5887, 1e-4); 623s ***** assert (pdf (pd, [0:5]), [0.3679, 0.2546, 0.1182, 0.0474, 0.0180, 0.0067], 1e-4); 623s ***** assert (pdf (t, [0:5]), [0, 0, 1.0902, 0.4369, 0.1659, 0], 1e-4); 623s ***** assert (pdf (pd, [-1, 1:4, NaN]), [0.1794, 0.2546, 0.1182, 0.0474, 0.0180, NaN], 1e-4); 623s ***** assert (pdf (t, [-1, 1:4, NaN]), [0, 0, 1.0902, 0.4369, 0.1659, NaN], 1e-4); 623s ***** assert (isequal (size (random (pd, 100, 50)), [100, 50])) 623s ***** assert (any (random (t, 1000, 1) < 2), false); 623s ***** assert (any (random (t, 1000, 1) > 4), false); 623s ***** assert (std (pd), 1.2825, 1e-4); 623s ***** assert (std (t), 0.5289, 1e-4); 623s ***** assert (var (pd), 1.6449, 1e-4); 623s ***** assert (var (t), 0.2798, 1e-4); 623s ***** error ... 623s GeneralizedExtremeValueDistribution(Inf, 1, 1) 623s ***** error ... 623s GeneralizedExtremeValueDistribution(i, 1, 1) 623s ***** error ... 623s GeneralizedExtremeValueDistribution("a", 1, 1) 623s ***** error ... 623s GeneralizedExtremeValueDistribution([1, 2], 1, 1) 623s ***** error ... 623s GeneralizedExtremeValueDistribution(NaN, 1, 1) 623s ***** error ... 623s GeneralizedExtremeValueDistribution(1, 0, 1) 623s ***** error ... 623s GeneralizedExtremeValueDistribution(1, -1, 1) 623s ***** error ... 623s GeneralizedExtremeValueDistribution(1, Inf, 1) 623s ***** error ... 623s GeneralizedExtremeValueDistribution(1, i, 1) 623s ***** error ... 623s GeneralizedExtremeValueDistribution(1, "a", 1) 623s ***** error ... 623s GeneralizedExtremeValueDistribution(1, [1, 2], 1) 623s ***** error ... 623s GeneralizedExtremeValueDistribution(1, NaN, 1) 623s ***** error ... 623s GeneralizedExtremeValueDistribution(1, 1, Inf) 623s ***** error ... 623s GeneralizedExtremeValueDistribution(1, 1, i) 623s ***** error ... 623s GeneralizedExtremeValueDistribution(1, 1, "a") 623s ***** error ... 623s GeneralizedExtremeValueDistribution(1, 1, [1, 2]) 623s ***** error ... 623s GeneralizedExtremeValueDistribution(1, 1, NaN) 623s ***** error ... 623s cdf (GeneralizedExtremeValueDistribution, 2, "uper") 623s ***** error ... 623s cdf (GeneralizedExtremeValueDistribution, 2, 3) 623s ***** shared x 623s x = gevrnd (1, 1, 1, [1, 100]); 623s ***** error ... 623s paramci (GeneralizedExtremeValueDistribution.fit (x), "alpha") 624s ***** error ... 624s paramci (GeneralizedExtremeValueDistribution.fit (x), "alpha", 0) 624s ***** error ... 624s paramci (GeneralizedExtremeValueDistribution.fit (x), "alpha", 1) 624s ***** error ... 624s paramci (GeneralizedExtremeValueDistribution.fit (x), "alpha", [0.5 2]) 625s ***** error ... 625s paramci (GeneralizedExtremeValueDistribution.fit (x), "alpha", "") 625s ***** error ... 625s paramci (GeneralizedExtremeValueDistribution.fit (x), "alpha", {0.05}) 625s ***** error ... 625s paramci (GeneralizedExtremeValueDistribution.fit (x), ... 625s "parameter", "sigma", "alpha", {0.05}) 625s ***** error ... 625s paramci (GeneralizedExtremeValueDistribution.fit (x), ... 625s "parameter", {"k", "sigma", "mu", "param"}) 626s ***** error ... 626s paramci (GeneralizedExtremeValueDistribution.fit (x), "alpha", 0.01, ... 626s "parameter", {"k", "sigma", "mu", "param"}) 626s ***** error ... 626s paramci (GeneralizedExtremeValueDistribution.fit (x), "parameter", "param") 626s ***** error ... 626s paramci (GeneralizedExtremeValueDistribution.fit (x), "alpha", 0.01, ... 626s "parameter", "param") 626s ***** error ... 626s paramci (GeneralizedExtremeValueDistribution.fit (x), "NAME", "value") 627s ***** error ... 627s paramci (GeneralizedExtremeValueDistribution.fit (x), "alpha", 0.01, ... 627s "NAME", "value") 627s ***** error ... 627s paramci (GeneralizedExtremeValueDistribution.fit (x), "alpha", 0.01, ... 627s "parameter", "sigma", "NAME", "value") 627s ***** error ... 627s plot (GeneralizedExtremeValueDistribution, "Parent") 627s ***** error ... 627s plot (GeneralizedExtremeValueDistribution, "PlotType", 12) 627s ***** error ... 627s plot (GeneralizedExtremeValueDistribution, "PlotType", {"pdf", "cdf"}) 627s ***** error ... 627s plot (GeneralizedExtremeValueDistribution, "PlotType", "pdfcdf") 627s ***** error ... 627s plot (GeneralizedExtremeValueDistribution, "Discrete", "pdfcdf") 627s ***** error ... 627s plot (GeneralizedExtremeValueDistribution, "Discrete", [1, 0]) 627s ***** error ... 627s plot (GeneralizedExtremeValueDistribution, "Discrete", {true}) 627s ***** error ... 627s plot (GeneralizedExtremeValueDistribution, "Parent", 12) 627s ***** error ... 627s plot (GeneralizedExtremeValueDistribution, "Parent", "hax") 627s ***** error ... 627s plot (GeneralizedExtremeValueDistribution, "invalidNAME", "pdf") 627s ***** error ... 627s plot (GeneralizedExtremeValueDistribution, "PlotType", "probability") 627s ***** error ... 627s proflik (GeneralizedExtremeValueDistribution, 2) 627s ***** error ... 627s proflik (GeneralizedExtremeValueDistribution.fit (x), 4) 628s ***** error ... 628s proflik (GeneralizedExtremeValueDistribution.fit (x), [1, 2]) 628s ***** error ... 628s proflik (GeneralizedExtremeValueDistribution.fit (x), {1}) 628s ***** error ... 628s proflik (GeneralizedExtremeValueDistribution.fit (x), 1, ones (2)) 628s ***** error ... 628s proflik (GeneralizedExtremeValueDistribution.fit (x), 1, "Display") 629s ***** error ... 629s proflik (GeneralizedExtremeValueDistribution.fit (x), 1, "Display", 1) 629s ***** error ... 629s proflik (GeneralizedExtremeValueDistribution.fit (x), 1, "Display", {1}) 629s ***** error ... 629s proflik (GeneralizedExtremeValueDistribution.fit (x), 1, "Display", {"on"}) 630s ***** error ... 630s proflik (GeneralizedExtremeValueDistribution.fit (x), 1, ... 630s "Display", ["on"; "on"]) 630s ***** error ... 630s proflik (GeneralizedExtremeValueDistribution.fit (x), 1, "Display", "onnn") 630s ***** error ... 630s proflik (GeneralizedExtremeValueDistribution.fit (x), 1, "NAME", "on") 631s ***** error ... 631s proflik (GeneralizedExtremeValueDistribution.fit (x), 1, {"NAME"}, "on") 631s ***** error ... 631s proflik (GeneralizedExtremeValueDistribution.fit (x), 1, {[1 2 3 4]}, ... 631s "Display", "on") 631s ***** error ... 631s truncate (GeneralizedExtremeValueDistribution) 631s ***** error ... 631s truncate (GeneralizedExtremeValueDistribution, 2) 631s ***** error ... 631s truncate (GeneralizedExtremeValueDistribution, 4, 2) 631s ***** shared pd 631s pd = GeneralizedExtremeValueDistribution(1, 1, 1); 631s pd(2) = GeneralizedExtremeValueDistribution(1, 3, 1); 631s ***** error cdf (pd, 1) 631s ***** error icdf (pd, 0.5) 631s ***** error iqr (pd) 631s ***** error mean (pd) 631s ***** error median (pd) 631s ***** error negloglik (pd) 631s ***** error paramci (pd) 631s ***** error pdf (pd, 1) 631s ***** error plot (pd) 631s ***** error proflik (pd, 2) 631s ***** error random (pd) 631s ***** error std (pd) 631s ***** error ... 631s truncate (pd, 2, 4) 631s ***** error var (pd) 631s 100 tests, 100 passed, 0 known failure, 0 skipped 631s [inst/dist_obj/PiecewiseLinearDistribution.m] 631s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_obj/PiecewiseLinearDistribution.m 631s ***** shared pd, t 631s load patients 631s [f, x] = ecdf (Weight); 631s f = f(1:5:end); 631s x = x(1:5:end); 631s pd = PiecewiseLinearDistribution (x, f); 631s t = truncate (pd, 130, 180); 631s ***** assert (cdf (pd, [120, 130, 140, 150, 200]), [0.0767, 0.25, 0.4629, 0.5190, 0.9908], 1e-4); 631s ***** assert (cdf (t, [120, 130, 140, 150, 200]), [0, 0, 0.4274, 0.5403, 1], 1e-4); 631s ***** assert (cdf (pd, [100, 250, NaN]), [0, 1, NaN], 1e-4); 631s ***** assert (cdf (t, [115, 290, NaN]), [0, 1, NaN], 1e-4); 631s ***** assert (icdf (pd, [0:0.2:1]), [111, 127.5, 136.62, 169.67, 182.17, 202], 1e-2); 631s ***** assert (icdf (t, [0:0.2:1]), [130, 134.15, 139.26, 162.5, 173.99, 180], 1e-2); 631s ***** assert (icdf (pd, [-1, 0.4:0.2:1, NaN]), [NA, 136.62, 169.67, 182.17, 202, NA], 1e-2); 631s ***** assert (icdf (t, [-1, 0.4:0.2:1, NaN]), [NA, 139.26, 162.5, 173.99, 180, NA], 1e-2); 631s ***** assert (iqr (pd), 50.0833, 1e-4); 631s ***** assert (iqr (t), 36.8077, 1e-4); 631s ***** assert (mean (pd), 153.61, 1e-10); 631s ***** assert (mean (t), 152.311, 1e-3); 640s ***** assert (median (pd), 142, 1e-10); 640s ***** assert (median (t), 141.9462, 1e-4); 640s ***** assert (pdf (pd, [120, 130, 140, 150, 200]), [0.0133, 0.0240, 0.0186, 0.0024, 0.0046], 1e-4); 640s ***** assert (pdf (t, [120, 130, 140, 150, 200]), [0, 0.0482, 0.0373, 0.0048, 0], 1e-4); 640s ***** assert (pdf (pd, [100, 250, NaN]), [0, 0, NaN], 1e-4); 640s ***** assert (pdf (t, [100, 250, NaN]), [0, 0, NaN], 1e-4); 640s ***** assert (isequal (size (random (pd, 100, 50)), [100, 50])) 640s ***** assert (any (random (t, 1000, 1) < 130), false); 640s ***** assert (any (random (t, 1000, 1) > 180), false); 640s ***** assert (std (pd), 26.5196, 1e-4); 640s ***** assert (std (t), 18.2941, 1e-4); 657s ***** assert (var (pd), 703.2879, 1e-4); 657s ***** assert (var (t), 334.6757, 1e-4); 674s ***** error ... 674s PiecewiseLinearDistribution ([0, i], [0, 1]) 674s ***** error ... 674s PiecewiseLinearDistribution ([0, Inf], [0, 1]) 674s ***** error ... 674s PiecewiseLinearDistribution (["a", "c"], [0, 1]) 674s ***** error ... 674s PiecewiseLinearDistribution ([NaN, 1], [0, 1]) 674s ***** error ... 674s PiecewiseLinearDistribution ([0, 1], [0, i]) 674s ***** error ... 674s PiecewiseLinearDistribution ([0, 1], [0, Inf]) 674s ***** error ... 674s PiecewiseLinearDistribution ([0, 1], ["a", "c"]) 674s ***** error ... 674s PiecewiseLinearDistribution ([0, 1], [NaN, 1]) 674s ***** error ... 674s PiecewiseLinearDistribution ([0, 1], [0, 0.5, 1]) 674s ***** error ... 674s PiecewiseLinearDistribution ([0], [1]) 674s ***** error ... 674s PiecewiseLinearDistribution ([0, 0.5, 1], [0, 1, 1.5]) 674s ***** error ... 674s cdf (PiecewiseLinearDistribution, 2, "uper") 674s ***** error ... 674s cdf (PiecewiseLinearDistribution, 2, 3) 674s ***** error ... 674s plot (PiecewiseLinearDistribution, "Parent") 674s ***** error ... 674s plot (PiecewiseLinearDistribution, "PlotType", 12) 674s ***** error ... 674s plot (PiecewiseLinearDistribution, "PlotType", {"pdf", "cdf"}) 674s ***** error ... 674s plot (PiecewiseLinearDistribution, "PlotType", "pdfcdf") 674s ***** error ... 674s plot (PiecewiseLinearDistribution, "Discrete", "pdfcdf") 674s ***** error ... 674s plot (PiecewiseLinearDistribution, "Discrete", [1, 0]) 674s ***** error ... 674s plot (PiecewiseLinearDistribution, "Discrete", {true}) 674s ***** error ... 674s plot (PiecewiseLinearDistribution, "Parent", 12) 674s ***** error ... 674s plot (PiecewiseLinearDistribution, "Parent", "hax") 674s ***** error ... 674s plot (PiecewiseLinearDistribution, "invalidNAME", "pdf") 674s ***** error ... 674s plot (PiecewiseLinearDistribution, "PlotType", "probability") 674s ***** error ... 674s truncate (PiecewiseLinearDistribution) 674s ***** error ... 674s truncate (PiecewiseLinearDistribution, 2) 674s ***** error ... 674s truncate (PiecewiseLinearDistribution, 4, 2) 674s ***** shared pd 674s pd = PiecewiseLinearDistribution (); 674s pd(2) = PiecewiseLinearDistribution (); 674s ***** error cdf (pd, 1) 674s ***** error icdf (pd, 0.5) 674s ***** error iqr (pd) 674s ***** error mean (pd) 674s ***** error median (pd) 674s ***** error pdf (pd, 1) 674s ***** error plot (pd) 674s ***** error random (pd) 674s ***** error std (pd) 674s ***** error ... 674s truncate (pd, 2, 4) 674s ***** error var (pd) 674s 63 tests, 63 passed, 0 known failure, 0 skipped 674s [inst/dist_obj/BirnbaumSaundersDistribution.m] 674s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dist_obj/BirnbaumSaundersDistribution.m 674s ***** demo 674s ## Generate a data set of 5000 random samples from a Birnbaum-Saunders 674s ## distribution with parameters β = 1 and γ = 0.5. Fit a Birnbaum-Saunders 674s ## distribution to this data and plot a PDF of the fitted distribution 674s ## superimposed on a histogram of the data 674s 674s pd = makedist ("BirnbaumSaunders", "beta", 1, "gamma", 0.5) 674s randg ("seed", 21); 674s data = random (pd, 5000, 1); 674s pd = fitdist (data, "BirnbaumSaunders") 674s plot (pd) 674s msg = "Fitted Birnbaum-Saunders distribution with a = %0.2f and b = %0.2f"; 674s title (sprintf (msg, pd.beta, pd.gamma)) 674s ***** demo 674s ## Plot the PDF of a Birnbaum-Saunders distribution, with parameters beta = 1 674s ## and gamma = 0.5, truncated at [0, 2] intervals. Generate 10000 random 674s ## samples from this truncated distribution and superimpose a histogram with 674s ## 100 bins scaled accordingly 674s 674s pd = makedist ("BirnbaumSaunders", "beta", 1, "gamma", 0.5) 674s t = truncate (pd, 0, 2) 674s randg ("seed", 21); 674s data = random (t, 10000, 1); 674s plot (t) 674s title ("Birnbaum-Saunders distribution (a = 2, b = 4) truncated at [0.1, 0.8]") 674s hold on 674s hist (data, 100, 50) 674s hold off 674s ***** demo 674s ## Generate a data set of 100 random samples from a Birnbaum-Saunders 674s ## distribution with parameters β = 1 and γ = 0.5. Fit a Birnbaum-Saunders 674s ## distribution to this data and plot its CDF superimposed over an empirical 674s ## CDF of the data 674s 674s pd = makedist ("BirnbaumSaunders", "beta", 1, "gamma", 0.5) 674s randg ("seed", 21); 674s data = random (pd, 100, 1); 674s pd = fitdist (data, "BirnbaumSaunders") 674s plot (pd, "plottype", "cdf") 674s title (sprintf ("Fitted Beta distribution with a = %0.2f and b = %0.2f", ... 674s pd.beta, pd.gamma)) 674s legend ({"empirical CDF", "fitted CDF"}, "location", "east") 674s ***** shared pd, t 674s pd = BirnbaumSaundersDistribution; 674s t = truncate (pd, 2, 4); 674s ***** assert (cdf (pd, [0:5]), [0, 0.5, 0.7602, 0.8759, 0.9332, 0.9632], 1e-4); 674s ***** assert (cdf (t, [0:5]), [0, 0, 0, 0.6687, 1, 1], 1e-4); 674s ***** assert (cdf (pd, [1.5, 2, 3, 4, NaN]), [0.6585, 0.7602, 0.8759, 0.9332, NaN], 1e-4); 674s ***** assert (cdf (t, [1.5, 2, 3, 4, NaN]), [0, 0, 0.6687, 1, NaN], 1e-4); 674s ***** assert (icdf (pd, [0:0.2:1]), [0, 0.4411, 0.7767, 1.2875, 2.2673, Inf], 1e-4); 674s ***** assert (icdf (t, [0:0.2:1]), [2, 2.2293, 2.5073, 2.8567, 3.3210, 4], 1e-4); 674s ***** assert (icdf (pd, [-1, 0.4:0.2:1, NaN]), [NaN, 0.7767, 1.2875, 2.2673, Inf, NaN], 1e-4); 674s ***** assert (icdf (t, [-1, 0.4:0.2:1, NaN]), [NaN, 2.5073, 2.8567, 3.3210, 4, NaN], 1e-4); 674s ***** assert (iqr (pd), 1.4236, 1e-4); 674s ***** assert (iqr (t), 0.8968, 1e-4); 674s ***** assert (mean (pd), 1.5, eps); 674s ***** assert (mean (t), 2.7723, 1e-4); 674s ***** assert (median (pd), 1, 1e-4); 674s ***** assert (median (t), 2.6711, 1e-4); 674s ***** assert (pdf (pd, [0:5]), [0, 0.3989, 0.1648, 0.0788, 0.0405, 0.0216], 1e-4); 674s ***** assert (pdf (t, [0:5]), [0, 0, 0.9528, 0.4559, 0.2340, 0], 1e-4); 674s ***** assert (pdf (pd, [-1, 1.5, NaN]), [0, 0.2497, NaN], 1e-4); 674s ***** assert (pdf (t, [-1, 1.5, NaN]), [0, 0, NaN], 1e-4); 674s ***** assert (isequal (size (random (pd, 100, 50)), [100, 50])) 674s ***** assert (any (random (t, 1000, 1) < 2), false); 674s ***** assert (any (random (t, 1000, 1) > 4), false); 674s ***** assert (std (pd), 1.5, eps); 674s ***** assert (std (t), 0.5528, 1e-4); 675s ***** assert (var (pd), 2.25, eps); 675s ***** assert (var (t), 0.3056, 1e-4); 675s ***** error ... 675s BirnbaumSaundersDistribution(0, 1) 675s ***** error ... 675s BirnbaumSaundersDistribution(Inf, 1) 675s ***** error ... 675s BirnbaumSaundersDistribution(i, 1) 675s ***** error ... 675s BirnbaumSaundersDistribution("beta", 1) 675s ***** error ... 675s BirnbaumSaundersDistribution([1, 2], 1) 675s ***** error ... 675s BirnbaumSaundersDistribution(NaN, 1) 675s ***** error ... 675s BirnbaumSaundersDistribution(1, 0) 675s ***** error ... 675s BirnbaumSaundersDistribution(1, -1) 675s ***** error ... 675s BirnbaumSaundersDistribution(1, Inf) 675s ***** error ... 675s BirnbaumSaundersDistribution(1, i) 675s ***** error ... 675s BirnbaumSaundersDistribution(1, "beta") 675s ***** error ... 675s BirnbaumSaundersDistribution(1, [1, 2]) 675s ***** error ... 675s BirnbaumSaundersDistribution(1, NaN) 675s ***** error ... 675s cdf (BirnbaumSaundersDistribution, 2, "uper") 675s ***** error ... 675s cdf (BirnbaumSaundersDistribution, 2, 3) 675s ***** shared x 675s rand ("seed", 5); 675s x = bisarnd (1, 1, [100, 1]); 675s ***** error ... 675s paramci (BirnbaumSaundersDistribution.fit (x), "alpha") 675s ***** error ... 675s paramci (BirnbaumSaundersDistribution.fit (x), "alpha", 0) 675s ***** error ... 675s paramci (BirnbaumSaundersDistribution.fit (x), "alpha", 1) 675s ***** error ... 675s paramci (BirnbaumSaundersDistribution.fit (x), "alpha", [0.5 2]) 675s ***** error ... 675s paramci (BirnbaumSaundersDistribution.fit (x), "alpha", "") 675s ***** error ... 675s paramci (BirnbaumSaundersDistribution.fit (x), "alpha", {0.05}) 675s ***** error ... 675s paramci (BirnbaumSaundersDistribution.fit (x), "parameter", ... 675s "beta", "alpha", {0.05}) 675s ***** error ... 675s paramci (BirnbaumSaundersDistribution.fit (x), ... 675s "parameter", {"beta", "gamma", "param"}) 675s ***** error ... 675s paramci (BirnbaumSaundersDistribution.fit (x), "alpha", 0.01, ... 675s "parameter", {"beta", "gamma", "param"}) 675s ***** error ... 675s paramci (BirnbaumSaundersDistribution.fit (x), "parameter", "param") 675s ***** error ... 675s paramci (BirnbaumSaundersDistribution.fit (x), "alpha", 0.01, ... 675s "parameter", "param") 676s ***** error ... 676s paramci (BirnbaumSaundersDistribution.fit (x), "NAME", "value") 676s ***** error ... 676s paramci (BirnbaumSaundersDistribution.fit (x), "alpha", 0.01, ... 676s "NAME", "value") 676s ***** error ... 676s paramci (BirnbaumSaundersDistribution.fit (x), "alpha", 0.01, ... 676s "parameter", "beta", "NAME", "value") 676s ***** error ... 676s plot (BirnbaumSaundersDistribution, "Parent") 676s ***** error ... 676s plot (BirnbaumSaundersDistribution, "PlotType", 12) 676s ***** error ... 676s plot (BirnbaumSaundersDistribution, "PlotType", {"pdf", "cdf"}) 676s ***** error ... 676s plot (BirnbaumSaundersDistribution, "PlotType", "pdfcdf") 676s ***** error ... 676s plot (BirnbaumSaundersDistribution, "Discrete", "pdfcdf") 676s ***** error ... 676s plot (BirnbaumSaundersDistribution, "Discrete", [1, 0]) 676s ***** error ... 676s plot (BirnbaumSaundersDistribution, "Discrete", {true}) 676s ***** error ... 676s plot (BirnbaumSaundersDistribution, "Parent", 12) 676s ***** error ... 676s plot (BirnbaumSaundersDistribution, "Parent", "hax") 676s ***** error ... 676s plot (BirnbaumSaundersDistribution, "invalidNAME", "pdf") 676s ***** error ... 676s plot (BirnbaumSaundersDistribution, "PlotType", "probability") 676s ***** error ... 676s proflik (BirnbaumSaundersDistribution, 2) 676s ***** error ... 676s proflik (BirnbaumSaundersDistribution.fit (x), 3) 676s ***** error ... 676s proflik (BirnbaumSaundersDistribution.fit (x), [1, 2]) 676s ***** error ... 676s proflik (BirnbaumSaundersDistribution.fit (x), {1}) 676s ***** error ... 676s proflik (BirnbaumSaundersDistribution.fit (x), 1, ones (2)) 676s ***** error ... 676s proflik (BirnbaumSaundersDistribution.fit (x), 1, "Display") 676s ***** error ... 676s proflik (BirnbaumSaundersDistribution.fit (x), 1, "Display", 1) 676s ***** error ... 676s proflik (BirnbaumSaundersDistribution.fit (x), 1, "Display", {1}) 676s ***** error ... 676s proflik (BirnbaumSaundersDistribution.fit (x), 1, "Display", {"on"}) 677s ***** error ... 677s proflik (BirnbaumSaundersDistribution.fit (x), 1, "Display", ["on"; "on"]) 677s ***** error ... 677s proflik (BirnbaumSaundersDistribution.fit (x), 1, "Display", "onnn") 677s ***** error ... 677s proflik (BirnbaumSaundersDistribution.fit (x), 1, "NAME", "on") 677s ***** error ... 677s proflik (BirnbaumSaundersDistribution.fit (x), 1, {"NAME"}, "on") 677s ***** error ... 677s proflik (BirnbaumSaundersDistribution.fit (x), 1, {[1 2 3 4]}, "Display", "on") 677s ***** error ... 677s truncate (BirnbaumSaundersDistribution) 677s ***** error ... 677s truncate (BirnbaumSaundersDistribution, 2) 677s ***** error ... 677s truncate (BirnbaumSaundersDistribution, 4, 2) 677s ***** shared pd 677s pd = BirnbaumSaundersDistribution(1, 1); 677s pd(2) = BirnbaumSaundersDistribution(1, 3); 677s ***** error cdf (pd, 1) 677s ***** error icdf (pd, 0.5) 677s ***** error iqr (pd) 677s ***** error mean (pd) 677s ***** error median (pd) 677s ***** error negloglik (pd) 677s ***** error paramci (pd) 677s ***** error pdf (pd, 1) 677s ***** error plot (pd) 677s ***** error proflik (pd, 2) 677s ***** error random (pd) 677s ***** error std (pd) 677s ***** error ... 677s truncate (pd, 2, 4) 677s ***** error var (pd) 677s 96 tests, 96 passed, 0 known failure, 0 skipped 677s [inst/harmmean.m] 677s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/harmmean.m 677s ***** test 677s x = [0:10]; 677s y = [x;x+5;x+10]; 677s assert (harmmean (x), 0); 677s m = [0 8.907635160795225 14.30854471766802]; 677s assert (harmmean (y, 2), m', 4e-14); 677s assert (harmmean (y, "all"), 0); 677s y(2,4) = NaN; 677s m(2) = 9.009855936313949; 677s assert (harmmean (y, 2), [0 NaN m(3)]', 4e-14); 677s assert (harmmean (y', "omitnan"), m, 4e-14); 677s z = y + 20; 677s assert (harmmean (z, "all"), NaN); 677s assert (harmmean (z, "all", "includenan"), NaN); 677s assert (harmmean (z, "all", "omitnan"), 29.1108719858295, 4e-14); 677s m = [24.59488458841874 NaN 34.71244385944397]; 677s assert (harmmean (z'), m, 4e-14); 677s assert (harmmean (z', "includenan"), m, 4e-14); 677s m(2) = 29.84104075528277; 677s assert (harmmean (z', "omitnan"), m, 4e-14); 677s assert (harmmean (z, 2, "omitnan"), m', 4e-14); 677s ***** test 677s x = repmat ([1:20;6:25], [5 2 6 3]); 677s assert (size (harmmean (x, [3 2])), [10 1 1 3]); 677s assert (size (harmmean (x, [1 2])), [1 1 6 3]); 677s assert (size (harmmean (x, [1 2 4])), [1 1 6]); 677s assert (size (harmmean (x, [1 4 3])), [1 40]); 677s assert (size (harmmean (x, [1 2 3 4])), [1 1]); 677s ***** test 677s x = repmat ([1:20;6:25], [5 2 6 3]); 677s m = repmat ([5.559045930488016;13.04950789021461], [5 1 1 3]); 677s assert (harmmean (x, [3 2]), m, 4e-14); 677s x(2,5,6,3) = NaN; 677s m(2,3) = NaN; 677s assert (harmmean (x, [3 2]), m, 4e-14); 677s m(2,3) = 13.06617961315406; 677s assert (harmmean (x, [3 2], "omitnan"), m, 4e-14); 677s ***** error harmmean ("char") 677s ***** error harmmean ([1 -1 3]) 677s ***** error ... 677s harmmean (repmat ([1:20;6:25], [5 2 6 3 5]), -1) 677s ***** error ... 677s harmmean (repmat ([1:20;6:25], [5 2 6 3 5]), 0) 677s ***** error ... 677s harmmean (repmat ([1:20;6:25], [5 2 6 3 5]), [1 1]) 677s 8 tests, 8 passed, 0 known failure, 0 skipped 677s [inst/dendrogram.m] 677s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/dendrogram.m 677s ***** demo 677s ## simple dendrogram 677s y = [4, 5; 2, 6; 3, 7; 8, 9; 1, 10]; 677s y(:,3) = 1:5; 677s dendrogram (y); 677s title ("simple dendrogram"); 677s ***** demo 677s ## another simple dendrogram 677s v = 2 * rand (30, 1) - 1; 677s d = abs (bsxfun (@minus, v(:, 1), v(:, 1)')); 677s y = linkage (squareform (d, "tovector")); 677s dendrogram (y); 677s title ("another simple dendrogram"); 677s ***** demo 677s ## collapsed tree, find all the leaves of node 5 677s X = randn (60, 2); 677s D = pdist (X); 677s y = linkage (D, "average"); 677s subplot (2, 1, 1); 677s title ("original tree"); 677s dendrogram (y, 0); 677s subplot (2, 1, 2); 677s title ("collapsed tree"); 677s [~, t] = dendrogram (y, 20); 677s find(t == 5) 677s ***** demo 677s ## optimal leaf order 677s X = randn (30, 2); 677s D = pdist (X); 677s y = linkage (D, "average"); 677s order = optimalleaforder (y, D); 677s subplot (2, 1, 1); 677s title ("original leaf order"); 677s dendrogram (y); 677s subplot (2, 1, 2); 677s title ("optimal leaf order"); 677s dendrogram (y, "Reorder", order); 677s ***** demo 677s ## horizontal orientation and labels 677s X = randn (8, 2); 677s D = pdist (X); 677s L = ["Snow White"; "Doc"; "Grumpy"; "Happy"; "Sleepy"; "Bashful"; ... 677s "Sneezy"; "Dopey"]; 677s y = linkage (D, "average"); 677s dendrogram (y, "Orientation", "left", "Labels", L); 677s title ("horizontal orientation and labels"); 677s ***** shared visibility_setting 677s visibility_setting = get (0, "DefaultFigureVisible"); 677s ***** test 677s hf = figure ("visible", "off"); 677s unwind_protect 677s y = [4, 5; 2, 6; 3, 7; 8, 9; 1, 10]; 677s y(:,3) = 1:5; 677s dendrogram (y); 677s unwind_protect_cleanup 677s close (hf); 677s end_unwind_protect 677s ***** test 677s hf = figure ("visible", "off"); 677s unwind_protect 677s y = [4, 5; 2, 6; 3, 7; 8, 9; 1, 10]; 677s y(:,3) = 1:5; 677s dendrogram (y); 677s unwind_protect_cleanup 677s close (hf); 677s end_unwind_protect 677s ***** test 677s hf = figure ("visible", "off"); 677s unwind_protect 677s v = 2 * rand (30, 1) - 1; 677s d = abs (bsxfun (@minus, v(:, 1), v(:, 1)')); 677s y = linkage (squareform (d, "tovector")); 677s dendrogram (y); 677s unwind_protect_cleanup 677s close (hf); 677s end_unwind_protect 678s ***** test 678s hf = figure ("visible", "off"); 678s unwind_protect 678s X = randn (30, 2); 678s D = pdist (X); 678s y = linkage (D, "average"); 678s order = optimalleaforder (y, D); 678s subplot (2, 1, 1); 678s title ("original leaf order"); 678s dendrogram (y); 678s subplot (2, 1, 2); 678s title ("optimal leaf order"); 678s dendrogram (y, "Reorder", order); 678s unwind_protect_cleanup 678s close (hf); 678s end_unwind_protect 681s ***** error dendrogram (); 681s ***** error dendrogram (ones (2, 2), 1); 681s ***** error dendrogram ([1 2 1], 1, "xxx", "xxx"); 681s ***** error dendrogram ([1 2 1], "Reorder", "xxx"); 681s ***** error dendrogram ([1 2 1], "Reorder", [1 2 3 4]); 681s fail ('dendrogram ([1 2 1], "Orientation", "north")', "invalid orientation .*") 681s 9 tests, 9 passed, 0 known failure, 0 skipped 681s [inst/normplot.m] 681s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/normplot.m 681s ***** demo 681s h = normplot([1:20]); 681s ***** demo 681s h = normplot([1:20;5:2:44]'); 681s ***** demo 681s ax = newplot(); 681s h = normplot(ax, [1:20]); 681s ax = gca; 681s h = normplot(ax, [-10:10]); 681s set (ax, "xlim", [-11, 21]); 681s ***** error normplot (); 681s ***** error normplot (23); 681s ***** error normplot (23, [1:20]); 681s ***** error normplot (ones(3,4,5)); 681s ***** test 681s hf = figure ("visible", "off"); 681s unwind_protect 681s ax = newplot (hf); 681s h = normplot (ax, [1:20]); 681s ax = gca; 681s h = normplot(ax, [-10:10]); 681s set (ax, "xlim", [-11, 21]); 681s unwind_protect_cleanup 681s close (hf); 681s end_unwind_protect 681s ***** test 681s hf = figure ("visible", "off"); 681s unwind_protect 681s h = normplot([1:20;5:2:44]'); 681s unwind_protect_cleanup 681s close (hf); 681s end_unwind_protect 681s 6 tests, 6 passed, 0 known failure, 0 skipped 681s [inst/plsregress.m] 681s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/plsregress.m 681s ***** demo 681s ## Perform Partial Least-Squares Regression 681s 681s ## Load the spectra data set and use the near infrared (NIR) spectral 681s ## intensities (NIR) as the predictor and the corresponding octave 681s ## ratings (octave) as the response. 681s load spectra 681s 681s ## Perform PLS regression with 10 components 681s [xload, yload, xscore, yscore, coef, ptcVar] = plsregress (NIR, octane, 10); 681s 681s ## Plot the percentage of explained variance in the response variable 681s ## (PCTVAR) as a function of the number of components. 681s plot (1:10, cumsum (100 * ptcVar(2,:)), "-ro"); 681s xlim ([1, 10]); 681s xlabel ("Number of PLS components"); 681s ylabel ("Percentage of Explained Variance in octane"); 681s title ("Explained Variance per PLS components"); 681s 681s ## Compute the fitted response and display the residuals. 681s octane_fitted = [ones(size(NIR,1),1), NIR] * coef; 681s residuals = octane - octane_fitted; 681s figure 681s stem (residuals, "color", "r", "markersize", 4, "markeredgecolor", "r") 681s xlabel ("Observations"); 681s ylabel ("Residuals"); 681s title ("Residuals in octane's fitted responce"); 681s ***** demo 681s ## Calculate Variable Importance in Projection (VIP) for PLS Regression 681s 681s ## Load the spectra data set and use the near infrared (NIR) spectral 681s ## intensities (NIR) as the predictor and the corresponding octave 681s ## ratings (octave) as the response. Variables with a VIP score greater than 681s ## 1 are considered important for the projection of the PLS regression model. 681s load spectra 681s 681s ## Perform PLS regression with 10 components 681s [xload, yload, xscore, yscore, coef, pctVar, mse, stats] = ... 681s plsregress (NIR, octane, 10); 681s 681s ## Calculate the normalized PLS weights 681s W0 = stats.W ./ sqrt(sum(stats.W.^2,1)); 681s 681s ## Calculate the VIP scores for 10 components 681s nobs = size (xload, 1); 681s SS = sum (xscore .^ 2, 1) .* sum (yload .^ 2, 1); 681s VIPscore = sqrt (nobs * sum (SS .* (W0 .^ 2), 2) ./ sum (SS, 2)); 681s 681s ## Find variables with a VIP score greater than or equal to 1 681s VIPidx = find (VIPscore >= 1); 681s 681s ## Plot the VIP scores 681s scatter (1:length (VIPscore), VIPscore, "xb"); 681s hold on 681s scatter (VIPidx, VIPscore (VIPidx), "xr"); 681s plot ([1, length(VIPscore)], [1, 1], "--k"); 681s hold off 681s axis ("tight"); 681s xlabel ("Predictor Variables"); 681s ylabel ("VIP scores"); 681s title ("VIP scores for each predictror variable with 10 components"); 681s ***** test 681s load spectra 681s [xload, yload, xscore, yscore, coef, pctVar] = plsregress (NIR, octane, 10); 681s xload1_out = [-0.0170, 0.0039, 0.0095, 0.0258, 0.0025, ... 681s -0.0075, 0.0000, 0.0018, -0.0027, 0.0020]; 681s yload_out = [6.6384, 9.3106, 2.0505, 0.6471, 0.9625, ... 681s 0.5905, 0.4244, 0.2437, 0.3516, 0.2548]; 681s xscore1_out = [-0.0401, -0.1764, -0.0340, 0.1669, 0.1041, ... 681s -0.2067, 0.0457, 0.1565, 0.0706, -0.1471]; 681s yscore1_out = [-12.4635, -15.0003, 0.0638, 0.0652, -0.0070, ... 681s -0.0634, 0.0062, -0.0012, -0.0151, -0.0173]; 681s assert (xload(1,:), xload1_out, 1e-4); 681s assert (yload, yload_out, 1e-4); 681s assert (xscore(1,:), xscore1_out, 1e-4); 681s assert (yscore(1,:), yscore1_out, 1e-4); 681s ***** test 681s load spectra 681s [xload, yload, xscore, yscore, coef, pctVar] = plsregress (NIR, octane, 5); 681s xload1_out = [-0.0170, 0.0039, 0.0095, 0.0258, 0.0025]; 681s yload_out = [6.6384, 9.3106, 2.0505, 0.6471, 0.9625]; 681s xscore1_out = [-0.0401, -0.1764, -0.0340, 0.1669, 0.1041]; 681s yscore1_out = [-12.4635, -15.0003, 0.0638, 0.0652, -0.0070]; 681s assert (xload(1,:), xload1_out, 1e-4); 681s assert (yload, yload_out, 1e-4); 681s assert (xscore(1,:), xscore1_out, 1e-4); 681s assert (yscore(1,:), yscore1_out, 1e-4); 681s ***** error 681s plsregress (1) 681s ***** error plsregress (1, "asd") 681s ***** error plsregress (1, {1,2,3}) 681s ***** error plsregress ("asd", 1) 681s ***** error plsregress ({1,2,3}, 1) 681s ***** error ... 681s plsregress (ones (20,3), ones (15,1)) 681s ***** error ... 681s plsregress (ones (20,3), ones (20,1), 0) 681s ***** error ... 681s plsregress (ones (20,3), ones (20,1), -5) 681s ***** error ... 681s plsregress (ones (20,3), ones (20,1), 3.2) 681s ***** error ... 681s plsregress (ones (20,3), ones (20,1), [2, 3]) 681s ***** error ... 681s plsregress (ones (20,3), ones (20,1), 4) 681s ***** error ... 681s plsregress (ones (20,3), ones (20,1), 3, "cv", 4.5) 681s ***** error ... 681s plsregress (ones (20,3), ones (20,1), 3, "cv", -1) 681s ***** error ... 681s plsregress (ones (20,3), ones (20,1), 3, "cv", "somestring") 681s ***** error ... 681s plsregress (ones (20,3), ones (20,1), 3, "cv", 3, "mcreps", 2.2) 681s ***** error ... 681s plsregress (ones (20,3), ones (20,1), 3, "cv", 3, "mcreps", -2) 681s ***** error ... 681s plsregress (ones (20,3), ones (20,1), 3, "cv", 3, "mcreps", [1, 2]) 681s ***** error ... 681s plsregress (ones (20,3), ones (20,1), 3, "Name", 3, "mcreps", 1) 681s ***** error ... 681s plsregress (ones (20,3), ones (20,1), 3, "cv", 3, "Name", 1) 681s ***** error ... 681s plsregress (ones (20,3), ones (20,1), 3, "mcreps", 2) 681s ***** error ... 681s plsregress (ones (20,3), ones (20,1), 3, "cv", "resubstitution", "mcreps", 2) 681s ***** error plsregress (1, 2) 682s 24 tests, 24 passed, 0 known failure, 0 skipped 682s [inst/fillmissing.m] 682s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/fillmissing.m 682s ***** assert (fillmissing ([1, 2, 3], "constant", 99), [1, 2, 3]) 682s ***** assert (fillmissing ([1, 2, NaN], "constant", 99), [1, 2, 99]) 682s ***** assert (fillmissing ([NaN, 2, NaN], "constant", 99), [99, 2, 99]) 682s ***** assert (fillmissing ([1, 2, 3]', "constant", 99), [1, 2, 3]') 682s ***** assert (fillmissing ([1, 2, NaN]', "constant", 99), [1, 2, 99]') 682s ***** assert (fillmissing ([1, 2, 3; 4, 5, 6], "constant", 99), [1, 2, 3; 4, 5, 6]) 682s ***** assert (fillmissing ([1, 2, NaN; 4, NaN, 6], "constant", 99), [1, 2, 99; 4, 99, 6]) 682s ***** assert (fillmissing ([NaN, 2, NaN; 4, NaN, 6], "constant", [97, 98, 99]), [97, 2, 99; 4, 98, 6]) 682s ***** test 682s x = cat (3, [1, 2, NaN; 4, NaN, 6], [NaN, 2, 3; 4, 5, NaN]); 682s y = cat (3, [1, 2, 99; 4, 99, 6], [99, 2, 3; 4, 5, 99]); 682s assert (fillmissing (x, "constant", 99), y); 682s y = cat (3, [1, 2, 96; 4, 95, 6], [97, 2, 3; 4, 5, 99]); 682s assert (fillmissing (x, "constant", [94:99]), y); 682s assert (fillmissing (x, "constant", [94:99]'), y); 682s assert (fillmissing (x, "constant", permute ([94:99], [1 3 2])), y); 682s assert (fillmissing (x, "constant", [94, 96, 98; 95, 97, 99]), y); 682s assert (fillmissing (x, "constant", [94:99], 1), y); 682s y = cat (3, [1, 2, 96; 4, 97, 6], [98, 2, 3; 4, 5, 99]); 682s assert (fillmissing (x, "constant", [96:99], 2), y); 682s y = cat (3, [1, 2, 98; 4, 97, 6], [94, 2, 3; 4, 5, 99]); 682s assert (fillmissing (x, "constant", [94:99], 3), y); 682s y = cat (3, [1, 2, 92; 4, 91, 6], [94, 2, 3; 4, 5, 99]); 682s assert (fillmissing (x, "constant", [88:99], 99), y); 682s ***** test 682s x = reshape ([1:24], 4, 3, 2); 682s x([1, 6, 7, 9, 12, 14, 16, 19, 22, 23]) = NaN; 682s y = x; 682s y([1, 6, 7, 9, 12, 14, 16, 19, 22, 23]) = [94, 95, 95, 96, 96, 97, 97, 98, 99, 99]; 682s assert (fillmissing (x, "constant", [94:99], 1), y); 682s y([1, 6, 7, 9, 12, 14, 16, 19, 22, 23]) = [92, 93, 94, 92, 95, 97, 99, 98, 97, 98]; 682s assert (fillmissing (x, "constant", [92:99], 2), y); 682s y([1, 6, 7, 9, 12, 14, 16, 19, 22, 23]) = [88, 93, 94, 96, 99, 89, 91, 94, 97, 98]; 682s assert (fillmissing (x, "constant", [88:99], 3), y); 682s y([1, 6, 7, 9, 12, 14, 16, 19, 22, 23]) = [76, 81, 82, 84, 87, 89, 91, 94, 97, 98]; 682s assert (fillmissing (x, "constant", [76:99], 99), y); 682s ***** assert (fillmissing ([1, 2, 3], "constant", 99, "endvalues", 88), [1, 2, 3]) 682s ***** assert (fillmissing ([1, NaN, 3], "constant", 99, "endvalues", 88), [1, 99, 3]) 682s ***** assert (fillmissing ([1, 2, NaN], "constant", 99, "endvalues", 88), [1, 2, 88]) 682s ***** assert (fillmissing ([NaN, 2, 3], "constant", 99, "endvalues", 88), [88, 2, 3]) 682s ***** assert (fillmissing ([NaN, NaN, 3], "constant", 99, "endvalues", 88), [88, 88, 3]) 682s ***** assert (fillmissing ([1, NaN, NaN], "constant", 99, "endvalues", 88), [1, 88, 88]) 682s ***** assert (fillmissing ([NaN, 2, NaN], "constant", 99, "endvalues", 88), [88, 2, 88]) 682s ***** assert (fillmissing ([NaN, 2, NaN]', "constant", 99, "endvalues", 88), [88, 2, 88]') 682s ***** assert (fillmissing ([1, NaN, 3, NaN, 5], "constant", 99, "endvalues", 88), [1, 99, 3, 99, 5]) 682s ***** assert (fillmissing ([1, NaN, NaN, NaN, 5], "constant", 99, "endvalues", 88), [1, 99, 99, 99, 5]) 682s ***** assert (fillmissing ([NaN, NaN, NaN, NaN, 5], "constant", 99, "endvalues", 88), [88, 88, 88, 88, 5]) 682s ***** assert (fillmissing ([1, NaN, 3, 4, NaN], "constant", 99, "endvalues", 88), [1, 99, 3, 4, 88]) 682s ***** assert (fillmissing ([1, NaN, 3, 4, NaN], "constant", 99, 1, "endvalues", 88), [1, 88, 3, 4, 88]) 682s ***** assert (fillmissing ([1, NaN, 3, 4, NaN], "constant", 99, 1, "endvalues", "extrap"), [1, 99, 3, 4, 99]) 682s ***** test 682s x = reshape ([1:24], 3, 4, 2); 682s y = x; 682s x([1, 2, 5, 6, 8, 10, 13, 16, 18, 19, 20, 21, 22]) = NaN; 682s y([1, 2, 5, 6, 10, 13, 16, 18, 19, 20, 21, 22]) = 88; 682s y([8]) = 99; 682s assert (fillmissing (x, "constant", 99, "endvalues", 88), y); 682s assert (fillmissing (x, "constant", 99, 1, "endvalues", 88), y); 682s y = x; 682s y([1, 2, 5, 8, 10, 13, 16, 19, 22]) = 88; 682s y([6, 18, 20, 21]) = 99; 682s assert (fillmissing (x, "constant", 99, 2, "endvalues", 88), y); 682s y(y == 99) = 88; 682s assert (fillmissing (x, "constant", 99, 3, "endvalues", 88), y); 682s assert (fillmissing (x, "constant", 99, 4, "endvalues", 88), y); 682s assert (fillmissing (x, "constant", 99, 99, "endvalues", 88), y); 682s y([8]) = 94; 682s assert (fillmissing (x, "constant", [92:99], 1, "endvalues", 88), y); 682s y([6, 8, 18, 20, 21]) = [96, 88, 99, 98, 99]; 682s assert (fillmissing (x, "constant", [94:99], 2, "endvalues", 88), y); 682s y = x; 682s y(isnan (y)) = 88; 682s assert (fillmissing (x, "constant", [88:99], 3, "endvalues", 88), y); 682s y = x; 682s y(isnan (y)) = [82, 82, 83, 83, 94, 85, 86, 87, 87, 88, 88, 88, 89]; 682s assert (fillmissing (x, "constant", [92:99], 1, "endvalues", [82:89]), y); 682s y = x; 682s y(isnan (y)) = [84, 85, 85, 96, 85, 84, 87, 87, 99, 87, 98, 99, 87]; 682s assert (fillmissing (x, "constant", [94:99], 2, "endvalues", [84:89]), y); 682s y = x; 682s y(isnan (y)) = [68, 69, 72, 73, 75, 77, 68, 71, 73, 74, 75, 76, 77]; 682s assert (fillmissing (x, "constant", [88:99], 3, "endvalues", [68:79]), y); 682s assert (fillmissing (x, "constant", [88:93; 94:99]', 3, "endvalues", [68:73; 74:79]'), y) 682s ***** test 682s x = reshape ([1:24],4,3,2); 682s x([1, 6, 7, 9, 12, 14, 16, 19, 22, 23]) = NaN; 682s y = x; 682s y([1, 6, 7, 9, 12, 14, 16, 19, 22, 23]) = [94, 95, 95, 96, 96, 97, 97, 98, 99, 99]; 682s assert (fillmissing (x, "constant", [94:99], 1), y); 682s y([1, 6, 7, 9, 12, 14, 16, 19, 22, 23]) = [92, 93, 94, 92, 95, 97, 99, 98, 97, 98]; 682s assert (fillmissing (x, "constant", [92:99], 2), y); 682s y([1, 6, 7, 9, 12, 14, 16, 19, 22, 23]) = [88, 93, 94, 96, 99, 89, 91, 94, 97, 98]; 682s assert (fillmissing (x, "constant", [88:99], 3), y); 682s y([1, 6, 7, 9, 12, 14, 16, 19, 22, 23]) = [76, 81, 82, 84, 87, 89, 91, 94, 97, 98]; 682s assert (fillmissing (x, "constant", [76:99], 99), y); 682s ***** assert (fillmissing ([1, 2, 3], "previous"), [1, 2, 3]) 682s ***** assert (fillmissing ([1, 2, 3], "next"), [1, 2, 3]) 682s ***** assert (fillmissing ([1, 2, 3]', "previous"), [1, 2, 3]') 682s ***** assert (fillmissing ([1, 2, 3]', "next"), [1, 2, 3]') 682s ***** assert (fillmissing ([1, 2, NaN], "previous"), [1, 2, 2]) 682s ***** assert (fillmissing ([1, 2, NaN], "next"), [1, 2, NaN]) 682s ***** assert (fillmissing ([NaN, 2, NaN], "previous"), [NaN, 2, 2]) 682s ***** assert (fillmissing ([NaN, 2, NaN], "next"), [2, 2, NaN]) 682s ***** assert (fillmissing ([1, NaN, 3], "previous"), [1, 1, 3]) 682s ***** assert (fillmissing ([1, NaN, 3], "next"), [1, 3, 3]) 682s ***** assert (fillmissing ([1, 2, NaN; 4, NaN, 6], "previous", 1), [1, 2, NaN; 4, 2, 6]) 682s ***** assert (fillmissing ([1, 2, NaN; 4, NaN, 6], "previous", 2), [1, 2, 2; 4, 4, 6]) 682s ***** assert (fillmissing ([1, 2, NaN; 4, NaN, 6], "previous", 3), [1, 2, NaN; 4, NaN, 6]) 682s ***** assert (fillmissing ([1, 2, NaN; 4, NaN, 6], "next", 1), [1, 2, 6; 4, NaN, 6]) 682s ***** assert (fillmissing ([1, 2, NaN; 4, NaN, 6], "next", 2), [1, 2, NaN; 4, 6, 6]) 682s ***** assert (fillmissing ([1, 2, NaN; 4, NaN, 6], "next", 3), [1, 2, NaN; 4, NaN, 6]) 682s ***** test 682s x = reshape ([1:24], 4, 3, 2); 682s x([1, 6, 7, 9, 12, 14, 16, 19, 22, 23]) = NaN; 682s y = x; 682s y([1, 6, 7, 9, 14, 19, 22, 23]) = [2, 8, 8, 10, 15, 20, 24, 24]; 682s assert (fillmissing (x, "next", 1), y); 682s y = x; 682s y([1, 6, 7, 14, 16]) = [5, 10, 11, 18, 20]; 682s assert (fillmissing (x, "next", 2), y); 682s y = x; 682s y([1, 6, 9, 12]) = [13, 18, 21, 24]; 682s assert (fillmissing (x, "next", 3), y); 682s assert (fillmissing (x, "next", 99), x); 682s y = x; 682s y([6, 7, 12, 14, 16, 19, 22, 23]) = [5, 5, 11, 13, 15, 18, 21, 21]; 682s assert (fillmissing (x, "previous", 1), y); 682s y = x; 682s y([6, 7, 9, 12, 19, 22, 23]) = [2, 3, 5, 8, 15, 18, 15]; 682s assert (fillmissing (x, "previous", 2), y); 682s y = x; 682s y([14, 16, 22, 23]) = [2, 4, 10, 11]; 682s assert (fillmissing (x, "previous", 3), y); 682s assert (fillmissing (x, "previous", 99), x); 682s ***** assert (fillmissing ([1, 2, 3], "constant", 0, "endvalues", "previous"), [1, 2, 3]) 682s ***** assert (fillmissing ([1, 2, 3], "constant", 0, "endvalues", "next"), [1, 2, 3]) 682s ***** assert (fillmissing ([1, NaN, 3], "constant", 0, "endvalues", "previous"), [1, 0, 3]) 682s ***** assert (fillmissing ([1, NaN, 3], "constant", 0, "endvalues", "next"), [1, 0, 3]) 682s ***** assert (fillmissing ([1, 2, NaN], "constant", 0, "endvalues", "previous"), [1, 2, 2]) 682s ***** assert (fillmissing ([1, 2, NaN], "constant", 0, "endvalues", "next"), [1, 2, NaN]) 682s ***** assert (fillmissing ([1, NaN, NaN], "constant", 0, "endvalues", "previous"), [1, 1, 1]) 682s ***** assert (fillmissing ([1, NaN, NaN], "constant", 0, "endvalues", "next"), [1, NaN, NaN]) 682s ***** assert (fillmissing ([NaN, 2, 3], "constant", 0, "endvalues", "previous"), [NaN, 2, 3]) 682s ***** assert (fillmissing ([NaN, 2, 3], "constant", 0, "endvalues", "next"), [2, 2, 3]) 682s ***** assert (fillmissing ([NaN, NaN, 3], "constant", 0, "endvalues", "previous"), [NaN, NaN, 3]) 682s ***** assert (fillmissing ([NaN, NaN, 3], "constant", 0, "endvalues", "next"), [3, 3, 3]) 682s ***** assert (fillmissing ([NaN, NaN, NaN], "constant", 0, "endvalues", "previous"), [NaN, NaN, NaN]) 682s ***** assert (fillmissing ([NaN, NaN, NaN], "constant", 0, "endvalues", "next"), [NaN, NaN, NaN]) 682s ***** assert (fillmissing ([NaN, 2, NaN, 4, NaN], "constant", 0, "endvalues", "previous"), [NaN, 2, 0, 4, 4]) 682s ***** assert (fillmissing ([NaN, 2, NaN, 4, NaN], "constant", 0, "endvalues", "next"), [2, 2, 0, 4, NaN]) 682s ***** assert (fillmissing ([NaN, 2, NaN, 4, NaN], "constant", 0, 1, "endvalues", "previous"), [NaN, 2, NaN, 4, NaN]) 682s ***** assert (fillmissing ([NaN, 2, NaN, 4, NaN], "constant", 0, 1, "endvalues", "next"), [NaN, 2, NaN, 4, NaN]) 682s ***** assert (fillmissing ([NaN, 2, NaN, 4, NaN], "constant", 0, 2, "endvalues", "previous"), [NaN, 2, 0, 4, 4]) 682s ***** assert (fillmissing ([NaN, 2, NaN, 4, NaN], "constant", 0, 2, "endvalues", "next"), [2, 2, 0, 4, NaN]) 682s ***** assert (fillmissing ([NaN, 2, NaN, 4, NaN], "constant", 0, 3, "endvalues", "previous"), [NaN, 2, NaN, 4, NaN]) 682s ***** assert (fillmissing ([NaN, 2, NaN, 4, NaN], "constant", 0, 3, "endvalues", "next"), [NaN, 2, NaN, 4, NaN]) 682s ***** test 682s x = reshape ([1:24], 3, 4, 2); 682s x([1, 2, 5, 6, 8, 10, 13, 16, 18, 19, 20, 21, 22]) = NaN; 682s y = x; 682s y([5, 6, 8, 18]) = [4, 4, 0, 17]; 682s assert (fillmissing (x, "constant", 0, "endvalues", "previous"), y); 682s assert (fillmissing (x, "constant", 0, 1, "endvalues", "previous"), y); 682s y = x; 682s y([6, 10, 18, 20, 21]) = [0, 7, 0, 0, 0]; 682s assert (fillmissing (x, "constant", 0, 2, "endvalues", "previous"), y); 682s y = x; 682s y([16, 19, 21]) = [4, 7, 9]; 682s assert (fillmissing (x, "constant", 0, 3, "endvalues", "previous"), y); 682s assert (fillmissing (x, "constant", 0, 4, "endvalues", "previous"), x); 682s assert (fillmissing (x, "constant", 0, 99, "endvalues", "previous"), x); 682s y = x; 682s y([1, 2, 8, 10, 13, 16, 22]) = [3, 3, 0, 11, 14, 17, 23]; 682s assert (fillmissing (x, "constant", 0, "endvalues", "next"), y); 682s assert (fillmissing (x, "constant", 0, 1, "endvalues", "next"), y); 682s y = x; 682s y([1, 2, 5, 6, 8, 18, 20, 21]) = [4, 11, 11, 0, 11, 0, 0, 0]; 682s assert (fillmissing (x, "constant", 0, 2, "endvalues", "next"), y); 682s y = x; 682s y([2, 5]) = [14, 17]; 682s assert (fillmissing (x, "constant", 0, 3, "endvalues", "next"), y); 682s assert (fillmissing (x, "constant", 0, 4, "endvalues", "next"), x); 682s assert (fillmissing (x, "constant", 0, 99, "endvalues", "next"), x); 682s ***** assert (fillmissing ([1, 2, 3], "nearest"), [1, 2, 3]) 682s ***** assert (fillmissing ([1, 2, 3]', "nearest"), [1, 2, 3]') 682s ***** assert (fillmissing ([1, 2, NaN], "nearest"), [1, 2, 2]) 682s ***** assert (fillmissing ([NaN, 2, NaN], "nearest"), [2, 2, 2]) 682s ***** assert (fillmissing ([1, NaN, 3], "nearest"), [1, 3, 3]) 682s ***** assert (fillmissing ([1, 2, NaN; 4, NaN, 6], "nearest", 1), [1, 2, 6; 4, 2, 6]) 682s ***** assert (fillmissing ([1, 2, NaN; 4, NaN, 6], "nearest", 2), [1, 2, 2; 4, 6, 6]) 682s ***** assert (fillmissing ([1, 2, NaN; 4, NaN, 6], "nearest", 3), [1, 2, NaN; 4, NaN, 6]) 682s ***** assert (fillmissing ([1, NaN, 3, NaN, 5], "nearest"), [1, 3, 3, 5, 5]) 682s ***** assert (fillmissing ([1, NaN, 3, NaN, 5], "nearest", "samplepoints", [0, 1, 2, 3, 4]), [1, 3, 3, 5, 5]) 682s ***** assert (fillmissing ([1, NaN, 3, NaN, 5], "nearest", "samplepoints", [0.5, 1, 2, 3, 5]), [1, 1, 3, 3, 5]) 682s ***** test 682s x = reshape ([1:24], 4, 3, 2); 682s x([1, 6, 7, 9, 12, 14, 16, 19, 22, 23]) = NaN; 682s y = x; 682s y([1, 6, 7, 9, 12, 14, 16, 19, 22, 23]) = [2, 5, 8, 10, 11, 15, 15, 20, 21, 24]; 682s assert (fillmissing (x, "nearest", 1), y); 682s y = x; 682s y([1, 6, 7, 9, 12, 14, 16, 19, 22, 23]) = [5, 10, 11, 5, 8, 18, 20, 15, 18, 15]; 682s assert (fillmissing (x, "nearest", 2), y); 682s y = x; 682s y([1, 6, 9, 12, 14, 16, 22, 23]) = [13, 18, 21, 24, 2, 4, 10, 11]; 682s assert (fillmissing (x, "nearest", 3), y); 682s assert (fillmissing (x, "nearest", 99), x); 682s ***** assert (fillmissing ([1, 2, 3], "constant", 0, "endvalues", "nearest"), [1, 2, 3]) 682s ***** assert (fillmissing ([1, NaN, 3], "constant", 0, "endvalues", "nearest"), [1 0 3]) 682s ***** assert (fillmissing ([1, 2, NaN], "constant", 0, "endvalues", "nearest"), [1, 2, 2]) 682s ***** assert (fillmissing ([1, NaN, NaN], "constant", 0, "endvalues", "nearest"), [1, 1, 1]) 682s ***** assert (fillmissing ([NaN, 2, 3], "constant", 0, "endvalues", "nearest"), [2, 2, 3]) 682s ***** assert (fillmissing ([NaN, NaN, 3], "constant", 0, "endvalues", "nearest"), [3, 3, 3]) 682s ***** assert (fillmissing ([NaN, NaN, NaN], "constant", 0, "endvalues", "nearest"), [NaN, NaN, NaN]) 682s ***** assert (fillmissing ([NaN, 2, NaN, 4, NaN], "constant", 0, "endvalues", "nearest"), [2, 2, 0, 4, 4]) 682s ***** assert (fillmissing ([NaN, 2, NaN, 4, NaN], "constant", 0, 1, "endvalues", "nearest"), [NaN, 2, NaN, 4, NaN]) 682s ***** assert (fillmissing ([NaN, 2, NaN, 4, NaN], "constant", 0, 2, "endvalues", "nearest"), [2, 2, 0, 4, 4]) 682s ***** assert (fillmissing ([NaN, 2, NaN, 4, NaN], "constant", 0, 3, "endvalues", "nearest"), [NaN, 2, NaN, 4, NaN]) 682s ***** test 682s x = reshape ([1:24], 3, 4, 2); 682s x([1, 2, 5, 6, 8, 10, 13, 16, 18, 19, 20, 21, 22]) = NaN; 682s y = x; 682s y([1, 2, 5, 6, 8, 10, 13, 16, 18, 22]) = [3, 3, 4, 4, 0, 11, 14, 17, 17, 23]; 682s assert (fillmissing (x, "constant", 0, "endvalues", "nearest"), y); 682s assert (fillmissing (x, "constant", 0, 1, "endvalues", "nearest"), y); 682s y = x; 682s y([1, 2, 5, 6, 8, 10, 18, 20, 21]) = [4, 11, 11, 0, 11, 7, 0, 0, 0]; 682s assert (fillmissing (x, "constant", 0, 2, "endvalues", "nearest"), y); 682s y = x; 682s y([2, 5, 16, 19, 21]) = [14, 17, 4, 7, 9]; 682s assert (fillmissing (x, "constant", 0, 3, "endvalues", "nearest"), y); 682s assert (fillmissing (x, "constant", 0, 99, "endvalues", "nearest"), x); 682s ***** assert (fillmissing ([1, 2, 3], "linear"), [1, 2, 3]) 682s ***** assert (fillmissing ([1, 2, 3]', "linear"), [1, 2, 3]') 682s ***** assert (fillmissing ([1, 2, NaN], "linear"), [1, 2, 3]) 682s ***** assert (fillmissing ([NaN, 2, NaN], "linear"), [NaN, 2, NaN]) 682s ***** assert (fillmissing ([1, NaN, 3], "linear"), [1, 2, 3]) 682s ***** assert (fillmissing ([1, 2, NaN; 4, NaN, 6], "linear", 1), [1, 2, NaN; 4, NaN, 6]) 682s ***** assert (fillmissing ([1, 2, NaN; 4, NaN, 6], "linear", 2), [1, 2, 3; 4, 5, 6]) 682s ***** assert (fillmissing ([1, 2, NaN; 4, NaN, 6], "linear", 3), [1, 2, NaN; 4, NaN, 6]) 682s ***** assert (fillmissing ([1, NaN, 3, NaN, 5], "linear"), [1, 2, 3, 4, 5]) 682s ***** assert (fillmissing ([1, NaN, 3, NaN, 5], "linear", "samplepoints", [0, 1, 2, 3, 4]), [1, 2, 3, 4, 5]) 682s ***** assert (fillmissing ([1, NaN, 3, NaN, 5], "linear", "samplepoints", [0, 1.5, 2, 5, 14]), [1, 2.5, 3, 3.5, 5], eps) 682s ***** test 682s x = reshape ([1:24], 4, 3, 2); 682s x([1, 6, 7, 9, 12, 14, 16, 19, 22, 23]) = NaN; 682s assert (fillmissing (x, "linear", 1), reshape ([1:24], 4, 3, 2)); 682s y = reshape ([1:24], 4, 3, 2); 682s y([1, 9, 14, 19, 22, 23]) = NaN; 682s assert (fillmissing (x, "linear", 2), y); 682s y = reshape ([1:24], 4, 3, 2); 682s y([1, 6, 7, 9, 12, 14, 16, 19, 22, 23]) = NaN; 682s assert (fillmissing (x, "linear", 3), y); 682s assert (fillmissing (x, "linear", 99), x); 682s ***** assert (fillmissing ([1, 2, 3], "linear", "endvalues", 0), [1, 2, 3]) 682s ***** assert (fillmissing ([1, NaN, 3], "linear", "endvalues", 0), [1, 2, 3]) 682s ***** assert (fillmissing ([1, 2, NaN], "linear", "endvalues", 0), [1, 2, 0]) 682s ***** assert (fillmissing ([1, NaN, NaN], "linear", "endvalues", 0), [1, 0, 0]) 682s ***** assert (fillmissing ([NaN, 2, 3], "linear", "endvalues", 0), [0, 2, 3]) 682s ***** assert (fillmissing ([NaN, NaN, 3], "linear", "endvalues", 0), [0, 0, 3]) 683s ***** assert (fillmissing ([NaN, NaN, NaN], "linear", "endvalues", 0), [0, 0, 0]) 683s ***** assert (fillmissing ([NaN, 2, NaN, 4, NaN], "linear", "endvalues", 0), [0, 2, 3, 4, 0]) 683s ***** assert (fillmissing ([NaN, 2, NaN, 4, NaN], "linear", 1, "endvalues", 0), [0, 2, 0, 4, 0]) 683s ***** assert (fillmissing ([NaN, 2, NaN, 4, NaN], "linear", 2, "endvalues", 0), [0, 2, 3, 4, 0]) 683s ***** assert (fillmissing ([NaN, 2, NaN, 4, NaN], "linear", 3, "endvalues", 0), [0, 2, 0, 4, 0]) 683s ***** test 683s x = reshape ([1:24], 3, 4, 2); 683s x([1, 2, 5, 6, 8, 10, 13, 16, 18, 19, 20, 21, 22]) = NaN; 683s y = x; 683s y([1, 2, 5, 6, 10, 13, 16, 18, 19, 20, 21, 22]) = 0; 683s y(8) = 8; 683s assert (fillmissing (x, "linear", "endvalues", 0), y); 683s assert (fillmissing (x, "linear", 1, "endvalues", 0), y); 683s y = x; 683s y([1, 2, 5, 8, 10, 13, 16, 19, 22]) = 0; 683s y([6, 18, 20, 21]) = [6, 18, 20, 21]; 683s assert (fillmissing (x, "linear", 2, "endvalues", 0), y); 683s y = x; 683s y(isnan(y)) = 0; 683s assert (fillmissing (x, "linear", 3, "endvalues", 0), y); 683s assert (fillmissing (x, "linear", 99, "endvalues", 0), y); 683s ***** assert (fillmissing ([1, 2, 3], "constant", 99, "endvalues", "linear"), [1, 2, 3]) 683s ***** assert (fillmissing ([1, NaN, 3], "constant", 99, "endvalues", "linear"), [1, 99, 3]) 683s ***** assert (fillmissing ([1, NaN, 3, NaN], "constant", 99, "endvalues", "linear"), [1, 99, 3, 4]) 683s ***** assert (fillmissing ([NaN, 2, NaN, 4, NaN], "constant", 99, "endvalues", "linear"), [1, 2, 99, 4, 5]) 683s ***** assert (fillmissing ([NaN, 2, NaN, NaN], "constant", 99, "endvalues", "linear"), [NaN, 2, NaN, NaN]) 683s ***** assert (fillmissing ([NaN, 2, NaN, 4, NaN], "constant", 99, "endvalues", "linear", "samplepoints", [1, 2, 3, 4, 5]), [1, 2, 99, 4, 5]) 683s ***** assert (fillmissing ([NaN, 2, NaN, 4, NaN], "constant", 99, "endvalues", "linear", "samplepoints", [0, 2, 3, 4, 10]), [0, 2, 99, 4, 10]) 683s ***** test 683s x = reshape ([1:24], 3, 4, 2); 683s x([1, 2, 5, 6, 8, 10, 13, 16, 18, 19, 20, 21, 22]) = NaN; 683s y = x; 683s y([1, 6, 10, 18, 20, 21]) = [2.5, 5, 8.5, 17.25, 21, 21.75]; 683s assert (fillmissing (x, "linear", 2, "samplepoints", [2 4 8 10]), y, eps); 683s y([1, 6, 10, 18, 20, 21]) = [2.5, 4.5, 8.5, 17.25, 21.5, 21.75]; 683s assert (fillmissing (x, "spline", 2, "samplepoints", [2, 4, 8, 10]), y, eps); 683s y([1, 6, 10, 18, 20, 21]) = [2.5, 4.559386973180077, 8.5, 17.25, 21.440613026819925, 21.75]; 683s assert (fillmissing (x, "pchip", 2, "samplepoints", [2, 4, 8, 10]), y, 10*eps); 683s ***** test <60965> 683s x = reshape ([1:24], 3, 4, 2); 683s x([1, 2, 5, 6, 8, 10, 13, 16, 18, 19, 20, 21, 22]) = NaN; 683s y = x; 683s y([1, 6, 10, 18, 20, 21]) = [2.5, 4.609523809523809, 8.5, 17.25, 21.390476190476186, 21.75]; 683s assert (fillmissing (x, "makima", 2, "samplepoints", [2, 4, 8, 10]), y, 10*eps); 683s !!!!! known bug: https://octave.org/testfailure/?60965 683s interp1: invalid METHOD 'makima' 683s ***** assert (fillmissing ([1, 2, 3], "constant", 99, "endvalues", "spline"), [1, 2, 3]) 683s ***** assert (fillmissing ([1, NaN, 3], "constant", 99, "endvalues", "spline"), [1, 99, 3]) 683s ***** assert (fillmissing ([1, NaN, 3, NaN], "constant", 99, "endvalues", "spline"), [1, 99, 3, 4]) 683s ***** assert (fillmissing ([NaN, 2, NaN, 4, NaN], "constant", 99, "endvalues", "spline"), [1, 2, 99, 4, 5]) 683s ***** assert (fillmissing ([NaN, 2, NaN, NaN], "constant", 99, "endvalues", "spline"), [NaN, 2, NaN, NaN]) 683s ***** assert (fillmissing ([NaN, 2, NaN, 4, NaN], "constant", 99, "endvalues", "spline", "samplepoints", [1, 2, 3, 4, 5]), [1, 2, 99, 4, 5]) 683s ***** assert (fillmissing ([NaN, 2, NaN, 4, NaN], "constant", 99, "endvalues", "spline", "samplepoints", [0, 2, 3, 4, 10]), [0, 2, 99, 4, 10]) 683s ***** assert (fillmissing ([1, 2, 3], "movmean", 1), [1, 2, 3]) 683s ***** assert (fillmissing ([1, 2, NaN], "movmean", 1), [1, 2, NaN]) 683s ***** assert (fillmissing ([1, 2, 3], "movmean", 2), [1, 2, 3]) 683s ***** assert (fillmissing ([1, 2, 3], "movmean", [1, 0]), [1, 2, 3]) 683s ***** assert (fillmissing ([1, 2, 3]', "movmean", 2), [1, 2, 3]') 683s ***** assert (fillmissing ([1, 2, NaN], "movmean", 2), [1, 2, 2]) 683s ***** assert (fillmissing ([1, 2, NaN], "movmean", [1, 0]), [1, 2, 2]) 683s ***** assert (fillmissing ([1, 2, NaN], "movmean", [1, 0]'), [1, 2, 2]) 683s ***** assert (fillmissing ([NaN, 2, NaN], "movmean", 2), [NaN, 2, 2]) 683s ***** assert (fillmissing ([NaN, 2, NaN], "movmean", [1, 0]), [NaN, 2, 2]) 683s ***** assert (fillmissing ([NaN, 2, NaN], "movmean", [0, 1]), [2, 2, NaN]) 683s ***** assert (fillmissing ([NaN, 2, NaN], "movmean", [0, 1.1]), [2, 2, NaN]) 683s ***** assert (fillmissing ([1, NaN, 3, NaN, 5], "movmean", [3, 0]), [1, 1, 3, 2, 5]) 683s ***** assert (fillmissing ([1, 2, NaN; 4, NaN, 6], "movmean", 3, 1), [1, 2, 6; 4, 2, 6]) 683s ***** assert (fillmissing ([1, 2, NaN; 4, NaN, 6], "movmean", 3, 2), [1, 2, 2; 4, 5, 6]) 683s ***** assert (fillmissing ([1, 2, NaN; 4, NaN, 6], "movmean", 3, 3), [1, 2, NaN; 4, NaN, 6]) 683s ***** assert (fillmissing ([1, NaN, 3, NaN, 5], "movmean", 99), [1, 3, 3, 3, 5]) 683s ***** assert (fillmissing ([1, NaN, 3, NaN, 5], "movmean", 99, 1), [1, NaN, 3, NaN, 5]) 683s ***** assert (fillmissing ([1, NaN, 3, NaN, 5]', "movmean", 99, 1), [1, 3, 3, 3, 5]') 683s ***** assert (fillmissing ([1, NaN, 3, NaN, 5], "movmean", 99, 2), [1, 3, 3, 3, 5]) 683s ***** assert (fillmissing ([1, NaN, 3, NaN, 5]', "movmean", 99, 2), [1, NaN, 3, NaN, 5]') 683s ***** assert (fillmissing ([1, NaN, NaN, NaN, 5], "movmean", 3, "samplepoints", [1, 2, 3, 4, 5]), [1, 1, NaN, 5, 5]) 683s ***** assert (fillmissing ([1, NaN, NaN, NaN, 5], "movmean", [1, 1], "samplepoints", [1, 2, 3, 4, 5]), [1, 1, NaN, 5, 5]) 683s ***** assert (fillmissing ([1, NaN, NaN, NaN, 5], "movmean", [1.5, 1.5], "samplepoints", [1, 2, 3, 4, 5]), [1, 1, NaN, 5, 5]) 683s ***** assert (fillmissing ([1, NaN, NaN, NaN, 5], "movmean", 4, "samplepoints", [1, 2, 3, 4, 5]), [1, 1, 1, 5, 5]) 683s ***** assert (fillmissing ([1, NaN, NaN, NaN, 5], "movmean", [2, 2], "samplepoints", [1, 2, 3, 4, 5]), [1, 1, 3, 5, 5]) 683s ***** assert (fillmissing ([1, NaN, NaN, NaN, 5], "movmean", 4.0001, "samplepoints", [1, 2, 3, 4, 5]), [1, 1, 3, 5, 5]) 683s ***** assert (fillmissing ([1, NaN, NaN, NaN, 5], "movmean", 3, "samplepoints", [1.5, 2, 3, 4, 5]), [1, 1, 1, 5, 5]) 683s ***** assert (fillmissing ([1, NaN, NaN, NaN, 5], "movmean", 3, "samplepoints", [1 2, 3, 4, 4.5]), [1, 1, NaN, 5, 5]) 683s ***** assert (fillmissing ([1, NaN, NaN, NaN, 5], "movmean", 3, "samplepoints", [1.5, 2, 3, 4, 4.5]), [1, 1, 1, 5, 5]) 683s ***** assert (fillmissing ([1, NaN, NaN, NaN, 5], "movmean", [1.5, 1.5], "samplepoints", [1.5, 2, 3, 4, 5]), [1, 1, 1, 5, 5]) 683s ***** assert (fillmissing ([1, NaN, NaN, NaN, 5], "movmean", [1.5, 1.5], "samplepoints", [1, 2, 3, 4, 4.5]), [1, 1, 5, 5, 5]) 683s ***** assert (fillmissing ([1, NaN, NaN, NaN, 5], "movmean", [1.5, 1.5], "samplepoints", [1.5, 2 3, 4, 4.5]), [1, 1, 3, 5, 5]) 683s ***** test 683s x = reshape ([1:24], 3, 4, 2); 683s x([1, 2, 5, 6, 8, 10, 13, 16, 18, 19, 20, 21, 22]) = NaN; 683s y = x; 683s y([2, 5, 8, 10, 13, 16, 18, 22]) = [3, 4, 8, 11, 14, 17, 17, 23]; 683s assert (fillmissing (x, "movmean", 3), y); 683s assert (fillmissing (x, "movmean", [1, 1]), y); 683s assert (fillmissing (x, "movmean", 3, "endvalues", "extrap"), y); 683s assert (fillmissing (x, "movmean", 3, "samplepoints", [1, 2, 3]), y); 683s y = x; 683s y([1, 6, 8, 10, 18, 20, 21]) = [4, 6, 11, 7, 15, 20, 24]; 683s assert (fillmissing (x, "movmean", 3, 2), y); 683s assert (fillmissing (x, "movmean", [1, 1], 2), y); 683s assert (fillmissing (x, "movmean", 3, 2, "endvalues", "extrap"), y); 683s assert (fillmissing (x, "movmean", 3, 2, "samplepoints", [1, 2, 3, 4]), y); 683s y([1, 18]) = NaN; 683s y(6) = 9; 683s assert (fillmissing (x, "movmean", 3, 2, "samplepoints", [0, 2, 3, 4]), y); 683s y = x; 683s y([1, 2, 5, 6, 10, 13, 16, 18, 19, 20, 21, 22]) = 99; 683s y(8) = 8; 683s assert (fillmissing (x, "movmean", 3, "endvalues", 99), y); 683s y = x; 683s y([1, 2, 5, 8, 10, 13, 16, 19, 22]) = 99; 683s y([6, 18, 20, 21]) = [6, 15, 20, 24]; 683s assert (fillmissing (x, "movmean", 3, 2, "endvalues", 99), y); 683s ***** assert (fillmissing ([1, 2, 3], "movmedian", 1), [1, 2, 3]) 683s ***** assert (fillmissing ([1, 2, NaN], "movmedian", 1), [1, 2, NaN]) 683s ***** assert (fillmissing ([1, 2, 3], "movmedian", 2), [1, 2, 3]) 683s ***** assert (fillmissing ([1, 2, 3], "movmedian", [1, 0]), [1, 2, 3]) 683s ***** assert (fillmissing ([1, 2, 3]', "movmedian", 2), [1, 2, 3]') 683s ***** assert (fillmissing ([1, 2, NaN], "movmedian", 2), [1, 2, 2]) 683s ***** assert (fillmissing ([1, 2, NaN], "movmedian", [1, 0]), [1, 2, 2]) 683s ***** assert (fillmissing ([1, 2, NaN], "movmedian", [1, 0]'), [1, 2, 2]) 683s ***** assert (fillmissing ([NaN, 2, NaN], "movmedian", 2), [NaN, 2, 2]) 683s ***** assert (fillmissing ([NaN, 2, NaN], "movmedian", [1, 0]), [NaN, 2, 2]) 683s ***** assert (fillmissing ([NaN, 2, NaN], "movmedian", [0, 1]), [2, 2, NaN]) 683s ***** assert (fillmissing ([NaN, 2, NaN], "movmedian", [0, 1.1]), [2, 2, NaN]) 683s ***** assert (fillmissing ([1, NaN, 3, NaN, 5], "movmedian", [3, 0]), [1, 1, 3, 2, 5]) 683s ***** assert (fillmissing ([1, 2, NaN; 4, NaN, 6], "movmedian", 3, 1), [1, 2, 6; 4, 2, 6]) 683s ***** assert (fillmissing ([1, 2, NaN; 4, NaN, 6], "movmedian", 3, 2), [1, 2, 2; 4, 5, 6]) 683s ***** assert (fillmissing ([1, 2, NaN; 4, NaN, 6], "movmedian", 3, 3), [1, 2, NaN; 4, NaN, 6]) 683s ***** assert (fillmissing ([1, NaN, 3, NaN, 5], "movmedian", 99), [1, 3, 3, 3, 5]) 683s ***** assert (fillmissing ([1, NaN, 3, NaN, 5], "movmedian", 99, 1), [1, NaN, 3, NaN, 5]) 683s ***** assert (fillmissing ([1, NaN, 3, NaN, 5]', "movmedian", 99, 1), [1, 3, 3, 3, 5]') 683s ***** assert (fillmissing ([1, NaN, 3, NaN, 5], "movmedian", 99, 2), [1, 3, 3, 3, 5]) 683s ***** assert (fillmissing ([1, NaN, 3, NaN, 5]', "movmedian", 99, 2), [1, NaN, 3, NaN, 5]') 683s ***** assert (fillmissing ([1, NaN, NaN, NaN, 5], "movmedian", 3, "samplepoints", [1, 2, 3, 4, 5]), [1, 1, NaN, 5, 5]) 683s ***** assert (fillmissing ([1, NaN, NaN, NaN, 5], "movmedian", [1, 1], "samplepoints", [1, 2, 3, 4, 5]), [1, 1, NaN, 5, 5]) 683s ***** assert (fillmissing ([1, NaN, NaN, NaN, 5], "movmedian", [1.5, 1.5], "samplepoints", [1, 2, 3, 4, 5]), [1, 1, NaN, 5, 5]) 683s ***** assert (fillmissing ([1, NaN, NaN, NaN, 5], "movmedian", 4, "samplepoints", [1, 2, 3, 4, 5]), [1, 1, 1, 5, 5]) 683s ***** assert (fillmissing ([1, NaN, NaN, NaN, 5], "movmedian", [2, 2], "samplepoints", [1, 2, 3, 4, 5]), [1, 1, 3, 5, 5]) 683s ***** assert (fillmissing ([1, NaN, NaN, NaN, 5], "movmedian", 4.0001, "samplepoints", [1, 2, 3, 4, 5]), [1, 1, 3, 5, 5]) 683s ***** assert (fillmissing ([1, NaN, NaN, NaN, 5], "movmedian", 3, "samplepoints", [1.5 2 3 4 5]), [1, 1, 1, 5, 5]) 683s ***** assert (fillmissing ([1, NaN, NaN, NaN, 5], "movmedian", 3, "samplepoints", [1 2 3 4 4.5]), [1, 1, NaN, 5, 5]) 683s ***** assert (fillmissing ([1, NaN, NaN, NaN, 5], "movmedian", 3, "samplepoints", [1.5 2 3 4 4.5]), [1, 1, 1, 5, 5]) 683s ***** assert (fillmissing ([1, NaN, NaN, NaN, 5], "movmedian", [1.5, 1.5], "samplepoints", [1.5 2 3 4 5]), [1, 1, 1, 5, 5]) 683s ***** assert (fillmissing ([1, NaN, NaN, NaN, 5], "movmedian", [1.5, 1.5], "samplepoints", [1 2 3 4 4.5]), [1, 1, 5, 5, 5]) 683s ***** assert (fillmissing ([1, NaN, NaN, NaN, 5], "movmedian", [1.5, 1.5], "samplepoints", [1.5 2 3 4 4.5]), [1, 1, 3, 5, 5]) 683s ***** test 683s x = reshape ([1:24], 3, 4, 2); 683s x([1, 2, 5, 6, 8, 10, 13, 16, 18, 19, 20, 21, 22]) = NaN; 683s y = x; 683s y([2, 5, 8, 10, 13, 16, 18, 22]) = [3, 4, 8, 11, 14, 17, 17, 23]; 683s assert (fillmissing (x, "movmedian", 3), y); 683s assert (fillmissing (x, "movmedian", [1, 1]), y); 683s assert (fillmissing (x, "movmedian", 3, "endvalues", "extrap"), y); 683s assert (fillmissing (x, "movmedian", 3, "samplepoints", [1, 2, 3]), y); 683s y = x; 683s y([1, 6, 8, 10, 18, 20, 21]) = [4, 6, 11, 7, 15, 20, 24]; 683s assert (fillmissing (x, "movmedian", 3, 2), y); 683s assert (fillmissing (x, "movmedian", [1, 1], 2), y); 683s assert (fillmissing (x, "movmedian", 3, 2, "endvalues", "extrap"), y); 683s assert (fillmissing (x, "movmedian", 3, 2, "samplepoints", [1, 2, 3, 4]), y); 683s y([1,18]) = NaN; 683s y(6) = 9; 683s assert (fillmissing (x, "movmedian", 3, 2, "samplepoints", [0, 2, 3, 4]), y); 683s y = x; 683s y([1, 2, 5, 6, 10, 13, 16, 18, 19, 20, 21, 22]) = 99; 683s y(8) = 8; 683s assert (fillmissing (x, "movmedian", 3, "endvalues", 99), y); 683s y = x; 683s y([1, 2, 5, 8, 10, 13, 16, 19, 22]) = 99; 683s y([6, 18, 20, 21]) = [6, 15, 20, 24]; 683s assert (fillmissing (x, "movmedian", 3, 2, "endvalues", 99), y); 683s ***** assert (fillmissing ([1, 2, 3], @(x,y,z) x+y+z, 2), [1, 2, 3]) 683s ***** assert (fillmissing ([1, 2, NaN], @(x,y,z) x+y+z, 1), [1, 2, NaN]) 683s ***** assert (fillmissing ([1, 2, 3], @(x,y,z) x+y+z, 2), [1, 2, 3]) 683s ***** assert (fillmissing ([1, 2, 3], @(x,y,z) x+y+z, [1, 0]), [1, 2, 3]) 683s ***** assert (fillmissing ([1, 2, 3]', @(x,y,z) x+y+z, 2), [1, 2, 3]') 683s ***** assert (fillmissing ([1, 2, NaN], @(x,y,z) x+y+z, 2), [1, 2, 7]) 683s ***** assert (fillmissing ([1, 2, NaN], @(x,y,z) x+y+z, [1, 0]), [1, 2, 7]) 683s ***** assert (fillmissing ([1, 2, NaN], @(x,y,z) x+y+z, [1, 0]'), [1, 2, 7]) 683s ***** assert (fillmissing ([NaN, 2, NaN], @(x,y,z) x+y+z, 2), [5, 2, 7]) 683s ***** assert (fillmissing ([NaN, 2, NaN], @(x,y,z) x+y+z, [1, 0]), [NaN, 2, 7]) 683s ***** assert (fillmissing ([NaN, 2, NaN], @(x,y,z) x+y+z, [0, 1]), [5, 2, NaN]) 683s ***** assert (fillmissing ([NaN, 2, NaN], @(x,y,z) x+y+z, [0, 1.1]), [5, 2, NaN]) 683s ***** assert (fillmissing ([1, 2, NaN, NaN, 3, 4], @(x,y,z) x+y+z, 2), [1, 2, 7, 12, 3, 4]) 683s ***** assert (fillmissing ([1, 2, NaN, NaN, 3, 4], @(x,y,z) x+y+z, 0.5), [1, 2, NaN, NaN, 3, 4]) 683s ***** function A = testfcn (x, y, z) 683s if (isempty (y)) 683s A = z; 683s elseif (numel (y) == 1) 683s A = repelem (x(1), numel(z)); 683s else 683s A = interp1 (y, x, z, "linear", "extrap"); 683s endif 683s ***** endfunction 683s ***** assert (fillmissing ([1, NaN, 3, NaN, 5], @testfcn, [3, 0]), [1, 1, 3, NaN, 5]) 683s ***** assert (fillmissing ([1, 2, NaN; 4, NaN, 6], @testfcn, 3, 1), [1, 2, 6; 4, 2, 6]) 683s ***** assert (fillmissing ([1, 2, NaN; 4, NaN, 6], @testfcn, 3, 2), [1, 2, 2; 4, 5, 6]) 683s ***** assert (fillmissing ([1, 2, NaN; 4, NaN, 6], @testfcn, 3, 3), [1, 2, NaN; 4, NaN, 6]) 683s ***** assert (fillmissing ([1, NaN, 3, NaN, 5], @testfcn, 99), [1, 2, 3, 4, 5]) 683s ***** assert (fillmissing ([1, NaN, 3, NaN, 5], @testfcn, 99, 1), [1, NaN, 3, NaN, 5]) ##known not-compatible. matlab bug ML2022a: [1, 1, 3, 1, 5] 683s ***** assert (fillmissing ([1, NaN, 3, NaN, 5]', @testfcn, 99, 1), [1, 2, 3, 4, 5]') 683s ***** assert (fillmissing ([1, NaN, 3, NaN, 5], @testfcn, 99, 2), [1, 2, 3, 4, 5]) 683s ***** assert (fillmissing ([1, NaN, 3, NaN, 5]', @testfcn, 99, 2), [1, NaN, 3, NaN, 5]') ##known not-compatible. matlab bug ML2022a: [1, 1, 3, 1, 5]' 683s ***** assert (fillmissing ([1, NaN, 3, NaN, 5], @testfcn, 99, 3), [1, NaN, 3, NaN, 5]) 683s ***** assert (fillmissing ([1, NaN, 3, NaN, 5]', @testfcn, 99, 3), [1, NaN, 3, NaN, 5]') 683s ***** assert (fillmissing ([1, NaN, NaN, NaN, 5], @testfcn, 3, "samplepoints", [1, 2, 3, 4, 5]), [1, 2, 3, 4, 5]) 683s ***** assert (fillmissing ([1, NaN, NaN, NaN, 5], @testfcn, [1, 1], "samplepoints", [1, 2, 3, 4, 5]), [1, 2, 3, 4, 5]) 683s ***** assert (fillmissing ([1, NaN, NaN, NaN, 5], @testfcn, [1.5, 1.5], "samplepoints", [1, 2, 3, 4, 5]), [1, 2, 3, 4, 5]) 683s ***** assert (fillmissing ([1, NaN, NaN, NaN, 5], @testfcn, 4, "samplepoints", [1, 2, 3, 4, 5]), [1, 2, 3, 4, 5]) 683s ***** assert (fillmissing ([1, NaN, NaN, NaN, 5], @testfcn, [2, 2], "samplepoints", [1, 2, 3, 4, 5]), [1, 2, 3, 4, 5]) 683s ***** assert (fillmissing ([1, NaN, NaN, NaN, 5], @testfcn, 3, "samplepoints", [1, 2, 2.5, 3, 3.5]), [1, 2.6, 3.4, 4.2, 5], 10*eps) 683s ***** assert (fillmissing ([NaN, NaN, 3, NaN, 5], @testfcn, 99, 1), [NaN, NaN, 3, NaN, 5]) ##known not-compatible. matlab bug ML2022a: [1, 1, 3, 1, 5] 683s ***** test 683s ***** function A = testfcn (x, y, z) 683s if (isempty (y)) 683s A = z; 683s elseif (numel (y) == 1) 683s A = repelem (x(1), numel(z)); 683s else 683s A = interp1 (y, x, z, "linear", "extrap"); 683s endif 683s ***** endfunction 683s x = reshape ([1:24], 3, 4, 2); 683s x([1, 2, 5, 6, 8, 10, 13, 16, 18, 19, 20, 21, 22]) = NaN; 683s y = x; 683s y([1, 2, 5, 6, 8, 10, 13, 16, 18, 22]) = [3, 3, 4, 4, 8, 11, 14, 17, 17, 23]; 683s assert (fillmissing (x, @testfcn, 3), y); 683s assert (fillmissing (x, @testfcn, [1, 1]), y); 683s assert (fillmissing (x, @testfcn, 3, "endvalues", "extrap"), y); 683s assert (fillmissing (x, @testfcn, 3, "samplepoints", [1, 2, 3]), y); 683s y= x; 683s y(isnan (x)) = 99; 683s y(8) = 8; 683s assert (fillmissing (x, @testfcn, 3, "endvalues", 99), y) 683s y = x; 683s y([1, 2, 5, 6, 8, 10, 18, 20, 21]) = [4, 11, 11, 6, 11, 7, 18, 20, 21]; 683s assert (fillmissing (x, @testfcn, 3, 2), y); 683s assert (fillmissing (x, @testfcn, [1, 1], 2), y); 683s assert (fillmissing (x, @testfcn, 3, 2, "endvalues", "extrap"), y); 683s assert (fillmissing (x, @testfcn, 3, 2, "samplepoints", [1, 2, 3, 4]), y); 683s y(1) = NaN; 683s y([6, 18, 21]) = [9, 24, 24]; 683s assert (fillmissing (x, @testfcn, 3, 2, "samplepoints", [0, 2, 3, 4]), y); 683s y = x; 683s y([1, 2, 5, 6, 10, 13, 16, 18, 19, 20, 21, 22]) = 99; 683s y(8) = 8; 683s assert (fillmissing (x, @testfcn, 3, "endvalues", 99), y); 683s y([6, 18, 20, 21]) = [6, 18, 20, 21]; 683s y(8) = 99; 683s assert (fillmissing (x, @testfcn, 3, 2, "endvalues", 99), y); 683s y([6, 18, 20, 21]) = 99; 683s assert (fillmissing (x, @testfcn, 3, 3, "endvalues", 99), y); 683s ***** assert (fillmissing ([1, 2, 3], "constant", 0, "maxgap", 1), [1, 2, 3]) 683s ***** assert (fillmissing ([1, 2, 3], "constant", 0, "maxgap", 99), [1, 2, 3]) 683s ***** assert (fillmissing ([1, NaN, 3], "constant", 0, "maxgap", 1), [1, NaN, 3]) 683s ***** assert (fillmissing ([1, NaN, 3], "constant", 0, "maxgap", 1.999), [1, NaN, 3]) 684s ***** assert (fillmissing ([1, NaN, 3], "constant", 0, "maxgap", 2), [1, 0, 3]) 684s ***** assert (fillmissing ([1, NaN, NaN, 4], "constant", 0, "maxgap", 2), [1, NaN, NaN, 4]) 684s ***** assert (fillmissing ([1, NaN, NaN, 4], "constant", 0, "maxgap", 3), [1, 0, 0, 4]) 684s ***** assert (fillmissing ([1, NaN, 3, NaN, 5], "constant", 0, "maxgap", 2), [1, 0, 3, 0, 5]) 684s ***** assert (fillmissing ([NaN, 2, NaN], "constant", 0, "maxgap", 0.999), [NaN, 2, NaN]) 684s ***** assert (fillmissing ([NaN, 2, NaN], "constant", 0, "maxgap", 1), [0, 2, 0]) 684s ***** assert (fillmissing ([NaN, 2, NaN, NaN], "constant", 0, "maxgap", 1), [0, 2, NaN, NaN]) 684s ***** assert (fillmissing ([NaN, 2, NaN, NaN], "constant", 0, "maxgap", 2), [0, 2, 0, 0]) 684s ***** assert (fillmissing ([NaN, NaN, NaN], "constant", 0, "maxgap", 1), [NaN, NaN, NaN]) 684s ***** assert (fillmissing ([NaN, NaN, NaN], "constant", 0, "maxgap", 3), [NaN, NaN, NaN]) 684s ***** assert (fillmissing ([NaN, NaN, NaN], "constant", 0, "maxgap", 999), [NaN, NaN, NaN]) 684s ***** assert (fillmissing ([1, NaN, 3, NaN, 5], "constant", 0, "maxgap", 2, "samplepoints", [0, 1, 2, 3, 5]), [1, 0, 3, NaN, 5]) 684s ***** assert (fillmissing ([1, NaN, 3, NaN, 5]', "constant", 0, "maxgap", 2, "samplepoints", [0, 1, 2, 3, 5]), [1, 0, 3, NaN, 5]') 684s ***** assert (fillmissing ([1, NaN, 3, NaN, 5], "constant", 0, "maxgap", 2, "samplepoints", [0, 2, 3, 4, 5]), [1, NaN, 3, 0, 5]) 684s ***** assert (fillmissing ([1, NaN, 3, NaN, 5; 1, NaN, 3, NaN, 5], "constant", 0, 2, "maxgap", 2, "samplepoints", [0, 2, 3, 4, 5]), [1, NaN, 3, 0, 5; 1, NaN, 3, 0, 5]) 684s ***** test 684s x = cat (3, [1, 2, NaN; 4, NaN, NaN], [NaN, 2, 3; 4, 5, NaN]); 684s assert (fillmissing (x, "constant", 0, "maxgap", 0.1), x); 684s y = x; 684s y([4, 7, 12]) = 0; 684s assert (fillmissing (x, "constant", 0, "maxgap", 1), y); 684s assert (fillmissing (x, "constant", 0, 1, "maxgap", 1), y); 684s y = x; 684s y([5, 7, 12]) = 0; 684s assert (fillmissing (x, "constant", 0, 2, "maxgap", 1), y); 684s y = x; 684s y([4, 5, 7]) = 0; 684s assert (fillmissing (x, "constant", 0, 3, "maxgap", 1), y); 684s ***** test 684s x = cat (3, [1, 2, NaN; 4, NaN, NaN], [NaN, 2, 3; 4, 5, NaN]); 684s [~, idx] = fillmissing (x, "constant", 0, "maxgap", 1); 684s assert (idx, logical (cat (3, [0, 0, 0; 0, 1, 0], [1, 0, 0; 0, 0, 1]))); 684s [~, idx] = fillmissing (x, "constant", 0, 1, "maxgap", 1); 684s assert (idx, logical (cat (3, [0, 0, 0; 0, 1, 0], [1, 0, 0; 0, 0, 1]))); 684s [~, idx] = fillmissing (x, "constant", 0, 2, "maxgap", 1); 684s assert (idx, logical (cat (3, [0, 0, 1; 0, 0, 0], [1, 0, 0; 0, 0, 1]))); 684s [~, idx] = fillmissing (x, "constant", 0, 3, "maxgap", 1); 684s assert (idx, logical (cat (3, [0, 0, 1; 0, 1, 0], [1, 0, 0; 0, 0, 0]))); 684s ***** test 684s x = [NaN, 2, 3]; 684s [~, idx] = fillmissing (x, "previous"); 684s assert (idx, logical ([0, 0, 0])); 684s [~, idx] = fillmissing (x, "movmean", 1); 684s assert (idx, logical ([0, 0, 0])); 684s x = [1:3; 4:6; 7:9]; 684s x([2, 4, 7, 9]) = NaN; 684s [~, idx] = fillmissing (x, "linear"); 684s assert (idx, logical ([0, 1, 0; 1, 0, 0; 0, 0, 0])); 684s [~, idx] = fillmissing (x, "movmean", 2); 684s assert (idx, logical ([0, 0, 0; 1, 0, 0; 0, 0, 1])); 684s [A, idx] = fillmissing ([1, 2, 3, NaN, NaN], "movmean",2); 684s assert (A, [1, 2, 3, 3, NaN]); 684s assert (idx, logical ([0, 0, 0, 1, 0])); 684s [A, idx] = fillmissing ([1, 2, 3, NaN, NaN], "movmean",3); 684s assert (A, [1, 2, 3, 3, NaN]); 684s assert (idx, logical ([0, 0, 0, 1, 0])); 684s [A, idx] = fillmissing ([1, 2, NaN, NaN, NaN], "movmedian", 2); 684s assert (A, [1, 2, 2, NaN, NaN]); 684s assert (idx, logical ([0, 0, 1, 0, 0])); 684s [A, idx] = fillmissing ([1, 2, 3, NaN, NaN], "movmedian", 3); 684s assert (A, [1, 2, 3, 3, NaN]); 684s assert (idx, logical ([0, 0, 0, 1, 0])); 684s [A, idx] = fillmissing ([1, NaN, 1, NaN, 1], @(x,y,z) z, 3); 684s assert (A, [1, 2, 1, 4, 1]); 684s assert (idx, logical ([0, 1, 0, 1, 0])); 684s [A, idx] = fillmissing ([1, NaN, 1, NaN, 1], @(x,y,z) NaN (size (z)), 3); 684s assert (A, [1, NaN, 1, NaN, 1]); 684s assert (idx, logical ([0, 0, 0, 0, 0])); 684s ***** assert (fillmissing ([1, 2, 3], "constant", 99, "missinglocations", logical ([0, 0, 0])), [1, 2, 3]) 684s ***** assert (fillmissing ([1, 2, 3], "constant", 99, "missinglocations", logical ([1, 1, 1])), [99, 99, 99]) 684s ***** assert (fillmissing ([1, NaN, 2, 3, NaN], "constant", 99, "missinglocations", logical ([1, 0, 1, 0, 1])), [99, NaN, 99, 3, 99]) 684s ***** assert (fillmissing ([1, NaN, 3, NaN, 5], "constant", NaN, "missinglocations", logical ([0, 1, 1, 1, 0])), [1, NaN, NaN, NaN, 5]) 684s ***** assert (fillmissing (["foo "; " bar"], "constant", "X", "missinglocations", logical ([0, 0, 0, 0; 0, 0, 0, 0])), ["foo "; " bar"]) 684s ***** assert (fillmissing (["foo "; " bar"], "constant", "X", "missinglocations", logical ([1, 0, 1, 0; 0, 1, 1, 0])), ["XoX "; " XXr"]) 684s ***** assert (fillmissing ({"foo", "", "bar"}, "constant", "X", "missinglocations", logical ([0, 0, 0])), {"foo", "", "bar"}) 684s ***** assert (fillmissing ({"foo", "", "bar"}, "constant", "X", "missinglocations", logical ([1, 1, 0])), {"X", "X", "bar"}) 684s ***** test 684s [~, idx] = fillmissing ([1, NaN, 3, NaN, 5], "constant", NaN); 684s assert (idx, logical ([0, 0, 0, 0, 0])); 684s [~, idx] = fillmissing ([1 NaN 3 NaN 5], "constant", NaN, "missinglocations", logical ([0, 1, 1, 1, 0])); 684s assert (idx, logical ([0, 1, 1, 1, 0])); 684s [A, idx] = fillmissing ([1, 2, NaN, 1, NaN], "movmean", 3.1, "missinglocations", logical ([0, 0, 1, 1, 0])); 684s assert (A, [1, 2, 2, NaN, NaN]); 684s assert (idx, logical ([0, 0, 1, 0, 0])); 684s [A, idx] = fillmissing ([1, 2, NaN, NaN, NaN], "movmean", 2, "missinglocations", logical ([0, 0, 1, 1, 0])); 684s assert (A, [1, 2, 2, NaN, NaN]); 684s assert (idx, logical ([0, 0, 1, 0, 0])); 684s [A, idx] = fillmissing ([1, 2, NaN, 1, NaN], "movmean", 3, "missinglocations", logical ([0, 0, 1, 1, 0])); 684s assert (A, [1, 2, 2, NaN, NaN]); 684s assert (idx, logical ([0, 0, 1, 0, 0])); 684s [A, idx] = fillmissing ([1, 2, NaN, NaN, NaN], "movmean", 3, "missinglocations", logical ([0, 0, 1, 1, 0])); 684s assert (A, [1, 2, 2, NaN, NaN]); 684s assert (idx, logical ([0, 0, 1, 0, 0])); 684s [A, idx] = fillmissing ([1, 2, NaN, NaN, NaN], "movmedian", 2, "missinglocations", logical ([0, 0, 1, 1, 0])); 684s assert (A, [1, 2, 2, NaN, NaN]); 684s assert (idx, logical ([0, 0, 1, 0, 0])); 684s [A, idx] = fillmissing ([1, 2, NaN, NaN, NaN], "movmedian", 3, "missinglocations", logical ([0, 0, 1, 1, 0])); 684s assert (A, [1, 2, 2, NaN, NaN]); 684s assert (idx, logical ([0, 0, 1, 0, 0])); 684s [A, idx] = fillmissing ([1, 2, NaN, NaN, NaN], "movmedian", 3.1, "missinglocations", logical ([0, 0, 1, 1, 0])); 684s assert (A, [1, 2, 2, NaN, NaN]); 684s assert (idx, logical ([0, 0, 1, 0, 0])); 684s [A, idx] = fillmissing ([1, NaN, 1, NaN, 1], @(x,y,z) ones (size (z)), 3, "missinglocations", logical ([0, 1, 0, 1, 1])); 684s assert (A, [1, 1, 1, 1, 1]); 684s assert (idx, logical ([0, 1, 0, 1, 1])); 684s [A, idx] = fillmissing ([1, NaN, 1, NaN, 1], @(x,y,z) NaN (size (z)), 3, "missinglocations", logical ([0, 1, 0, 1, 1])); 684s assert (A, [1, NaN, 1, NaN, NaN]); 684s assert (idx, logical ([0, 0, 0, 0, 0])); 684s ***** test 684s [A, idx] = fillmissing ([1, 2, 5], "movmedian", 3, "missinglocations", logical ([0, 1, 0])); 684s assert (A, [1, 3, 5]); 684s assert (idx, logical ([0, 1, 0])); 684s ***** assert (fillmissing (" foo bar ", "constant", "X"), "XfooXbarX") 684s ***** assert (fillmissing ([" foo"; "bar "], "constant", "X"), ["Xfoo"; "barX"]) 684s ***** assert (fillmissing ([" foo"; "bar "], "next"), ["bfoo"; "bar "]) 684s ***** assert (fillmissing ([" foo"; "bar "], "next", 1), ["bfoo"; "bar "]) 684s ***** assert (fillmissing ([" foo"; "bar "], "previous"), [" foo"; "baro"]) 684s ***** assert (fillmissing ([" foo"; "bar "], "previous", 1), [" foo"; "baro"]) 684s ***** assert (fillmissing ([" foo"; "bar "], "nearest"), ["bfoo"; "baro"]) 684s ***** assert (fillmissing ([" foo"; "bar "], "nearest", 1), ["bfoo"; "baro"]) 684s ***** assert (fillmissing ([" foo"; "bar "], "next", 2), ["ffoo"; "bar "]) 684s ***** assert (fillmissing ([" foo"; "bar "], "previous", 2), [" foo"; "barr"]) 684s ***** assert (fillmissing ([" foo"; "bar "], "nearest", 2), ["ffoo"; "barr"]) 684s ***** assert (fillmissing ([" foo"; "bar "], "next", 3), [" foo"; "bar "]) 684s ***** assert (fillmissing ([" foo"; "bar "], "previous", 3), [" foo"; "bar "]) 684s ***** assert (fillmissing ([" foo"; "bar "], "nearest", 3), [" foo"; "bar "]) 684s ***** assert (fillmissing ({"foo", "bar"}, "constant", "a"), {"foo", "bar"}) 684s ***** assert (fillmissing ({"foo", "bar"}, "constant", {"a"}), {"foo", "bar"}) 684s ***** assert (fillmissing ({"foo", "", "bar"}, "constant", "a"), {"foo", "a", "bar"}) 684s ***** assert (fillmissing ({"foo", "", "bar"}, "constant", {"a"}), {"foo", "a", "bar"}) 684s ***** assert (fillmissing ({"foo", "", "bar"}, "previous"), {"foo", "foo", "bar"}) 684s ***** assert (fillmissing ({"foo", "", "bar"}, "next"), {"foo", "bar", "bar"}) 684s ***** assert (fillmissing ({"foo", "", "bar"}, "nearest"), {"foo", "bar", "bar"}) 684s ***** assert (fillmissing ({"foo", "", "bar"}, "previous", 2), {"foo", "foo", "bar"}) 684s ***** assert (fillmissing ({"foo", "", "bar"}, "next", 2), {"foo", "bar", "bar"}) 684s ***** assert (fillmissing ({"foo", "", "bar"}, "nearest", 2), {"foo", "bar", "bar"}) 684s ***** assert (fillmissing ({"foo", "", "bar"}, "previous", 1), {"foo", "", "bar"}) 684s ***** assert (fillmissing ({"foo", "", "bar"}, "previous", 1), {"foo", "", "bar"}) 684s ***** assert (fillmissing ({"foo", "", "bar"}, "next", 1), {"foo", "", "bar"}) 684s ***** assert (fillmissing ({"foo", "", "bar"}, "nearest", 1), {"foo", "", "bar"}) 684s ***** assert (fillmissing ("abc ", @(x,y,z) x+y+z, 2), "abcj") 684s ***** assert (fillmissing ({"foo", "", "bar"}, @(x,y,z) x(1), 3), {"foo", "foo", "bar"}) 684s ***** test 684s [A, idx] = fillmissing (" a b c", "constant", " "); 684s assert (A, " a b c"); 684s assert (idx, logical ([0, 0, 0, 0, 0, 0])); 684s [A, idx] = fillmissing ({"foo", "", "bar", ""}, "constant", ""); 684s assert (A, {"foo", "", "bar", ""}); 684s assert (idx, logical ([0, 0, 0, 0])); 684s [A, idx] = fillmissing ({"foo", "", "bar", ""}, "constant", {""}); 684s assert (A, {"foo", "", "bar", ""}); 684s assert (idx, logical ([0, 0, 0, 0])); 684s [A,idx] = fillmissing (" f o o ", @(x,y,z) repelem ("a", numel (z)), 3); 684s assert (A, "afaoaoa"); 684s assert (idx, logical ([1, 0, 1, 0, 1, 0, 1])); 684s [A,idx] = fillmissing (" f o o ", @(x,y,z) repelem (" ", numel (z)), 3); 684s assert (A, " f o o "); 684s assert (idx, logical ([0, 0, 0, 0, 0, 0, 0])); 684s [A,idx] = fillmissing ({"", "foo", ""}, @(x,y,z) repelem ({"a"}, numel (z)), 3); 684s assert (A, {"a", "foo", "a"}); 684s assert (idx, logical ([1, 0, 1])); 684s [A,idx] = fillmissing ({"", "foo", ""}, @(x,y,z) repelem ({""}, numel (z)), 3); 684s assert (A, {"", "foo", ""}); 684s assert (idx, logical ([0, 0, 0])); 684s ***** assert (fillmissing (logical ([1, 0, 1, 0, 1]), "constant", true), logical ([1, 0, 1, 0, 1])) 684s ***** assert (fillmissing (logical ([1, 0, 1, 0, 1]), "constant", false, "missinglocations", logical ([1, 0, 1, 0, 1])), logical ([0, 0, 0, 0, 0])) 684s ***** assert (fillmissing (logical ([1, 0, 1, 0, 1]), "previous", "missinglocations", logical ([1, 0, 1, 0, 1])), logical ([1, 0, 0, 0, 0])) 684s ***** assert (fillmissing (logical ([1, 0, 1, 0, 1]), "next", "missinglocations", logical ([1, 0, 1, 0, 1])), logical ([0, 0, 0, 0, 1])) 684s ***** assert (fillmissing (logical ([1, 0, 1, 0, 1]), "nearest", "missinglocations", logical ([1, 0, 1, 0, 1])), logical ([0, 0, 0, 0, 0])) 684s ***** assert (fillmissing (logical ([1, 0, 1, 0, 1]), @(x,y,z) false(size(z)), 3), logical ([1, 0, 1, 0, 1])) 684s ***** assert (fillmissing (logical ([1, 0, 1, 0, 1]), @(x,y,z) false(size(z)), 3, "missinglocations", logical ([1, 0, 1, 0, 1])), logical ([0, 0, 0, 0, 0])) 684s ***** assert (fillmissing (logical ([1, 0, 1, 0, 1]), @(x,y,z) false(size(z)), [2, 0], "missinglocations", logical ([1, 0, 1, 0, 1])), logical ([1, 0, 0, 0, 0])) 684s ***** test 684s x = logical ([1, 0, 1, 0, 1]); 684s [~, idx] = fillmissing (x, "constant", true); 684s assert (idx, logical ([0, 0, 0, 0, 0])); 684s [~, idx] = fillmissing (x, "constant", false, "missinglocations", logical ([1, 0, 1, 0, 1])); 684s assert (idx, logical ([1, 0, 1, 0, 1])); 684s [~, idx] = fillmissing (x, "constant", true, "missinglocations", logical ([1, 0, 1, 0, 1])); 684s assert (idx, logical ([1, 0, 1, 0, 1])); 684s [~, idx] = fillmissing (x, "previous", "missinglocations", logical ([1, 0, 1, 0, 1])); 684s assert (idx, logical ([0, 0, 1, 0, 1])); 684s [~, idx] = fillmissing (x, "next", "missinglocations", logical ([1, 0, 1, 0, 1])); 684s assert (idx, logical ([1, 0, 1, 0, 0])); 684s [~, idx] = fillmissing (x, "nearest", "missinglocations", logical ([1, 0, 1, 0, 1])); 684s assert (idx, logical ([1, 0, 1, 0, 1])); 684s [~, idx] = fillmissing (x, @(x,y,z) false(size(z)), 3); 684s assert (idx, logical ([0, 0, 0, 0, 0])) 684s [~, idx] = fillmissing (x, @(x,y,z) false(size(z)), 3, "missinglocations", logical ([1, 0, 1, 0, 1])); 684s assert (idx, logical ([1, 0, 1, 0, 1])) 684s [~, idx] = fillmissing (x, @(x,y,z) false(size(z)), [2 0], "missinglocations", logical ([1, 0, 1, 0, 1])); 684s assert (idx, logical ([0, 0, 1, 0, 1])) 684s ***** assert (fillmissing (int32 ([1, 2, 3, 4, 5]), "constant", 0), int32 ([1, 2, 3, 4, 5])) 684s ***** assert (fillmissing (int32 ([1, 2, 3, 4, 5]), "constant", 0, "missinglocations", logical ([1, 0, 1, 0, 1])), int32 ([0, 2, 0, 4, 0])) 684s ***** assert (fillmissing (int32 ([1, 2, 3, 4, 5]), "previous", "missinglocations", logical ([1, 0, 1, 0, 1])), int32 ([1, 2, 2, 4, 4])) 684s ***** assert (fillmissing (int32 ([1, 2, 3, 4, 5]), "next", "missinglocations", logical ([1, 0, 1, 0, 1])), int32 ([2, 2, 4, 4, 5])) 684s ***** assert (fillmissing (int32 ([1, 2, 3, 4, 5]), "nearest", "missinglocations", logical ([1, 0, 1, 0, 1])), int32 ([2, 2, 4, 4, 4])) 684s ***** assert (fillmissing (int32 ([1, 2, 3, 4, 5]), @(x,y,z) z+10, 3), int32 ([1, 2, 3, 4, 5])) 684s ***** assert (fillmissing (int32 ([1, 2, 3, 4, 5]), @(x,y,z) z+10, 3, "missinglocations", logical ([1, 0, 1, 0, 1])), int32 ([11, 2, 13, 4, 15])) 684s ***** assert (fillmissing (int32 ([1, 2, 3, 4, 5]), @(x,y,z) z+10, [2, 0], "missinglocations", logical ([1, 0, 1, 0, 1])), int32 ([1, 2, 13, 4, 15])) 684s ***** test 684s x = int32 ([1, 2, 3, 4, 5]); 684s [~, idx] = fillmissing (x, "constant", 0); 684s assert (idx, logical ([0, 0, 0, 0, 0])); 684s [~, idx] = fillmissing (x, "constant", 0, "missinglocations", logical ([1, 0, 1, 0, 1])); 684s assert (idx, logical ([1, 0, 1, 0, 1])); 684s [~, idx] = fillmissing (x, "constant", 3, "missinglocations", logical ([0, 0, 1, 0, 0])); 684s assert (idx, logical ([0, 0, 1, 0, 0])); 684s [~, idx] = fillmissing (x, "previous", "missinglocations", logical ([1, 0, 1, 0, 1])); 684s assert (idx, logical ([0, 0, 1, 0, 1])); 684s [~, idx] = fillmissing (x, "next", "missinglocations", logical ([1, 0, 1, 0, 1])); 684s assert (idx, logical ([1, 0, 1, 0, 0])); 684s [~, idx] = fillmissing (x, "nearest", "missinglocations", logical ([1, 0, 1, 0, 1])); 684s assert (idx, logical ([1, 0, 1, 0, 1])); 684s [~, idx] = fillmissing (x, @(x,y,z) z+10, 3); 684s assert (idx, logical ([0, 0, 0, 0, 0])); 684s [~, idx] = fillmissing (x, @(x,y,z) z+10, 3, "missinglocations", logical ([1, 0, 1, 0, 1])); 684s assert (idx, logical ([1, 0, 1, 0, 1])); 684s [~, idx] = fillmissing (x, @(x,y,z) z+10, [2 0], "missinglocations", logical ([1, 0, 1, 0, 1])); 684s assert (idx, logical ([0, 0, 1, 0, 1])); 684s ***** test 684s [A, idx] = fillmissing ([struct, struct], "constant", 1); 684s assert (A, [struct, struct]) 684s assert (idx, [false, false]) 684s ***** error fillmissing () 684s ***** error fillmissing (1) 685s ***** error fillmissing (1, 2, 3, 4, 5, 6, 7, 8, 9, 10, 11, 12, 13) 685s ***** error fillmissing (1, 2) 685s ***** error fillmissing (1, "foo") 685s ***** error fillmissing (1, @(x) x, 1) 685s ***** error fillmissing (1, @(x,y) x+y, 1) 685s ***** error fillmissing ("a b c", "linear") 685s ***** error fillmissing ({"a", "b"}, "linear") 685s ***** error <'movmean' and 'movmedian' methods only valid for numeric> fillmissing ("a b c", "movmean", 2) 685s ***** error <'movmean' and 'movmedian' methods only valid for numeric> fillmissing ({"a", "b"}, "movmean", 2) 685s ***** error <'constant' method must be followed by> fillmissing (1, "constant") 685s ***** error fillmissing (1, "constant", []) 685s ***** error fillmissing (1, "constant", "a") 685s ***** error fillmissing ("a", "constant", 1) 685s ***** error fillmissing ("a", "constant", {"foo"}) 685s ***** error fillmissing ({"foo"}, "constant", 1) 685s ***** error fillmissing (1, "movmean") 685s ***** error fillmissing (1, "movmedian") 685s ***** error fillmissing (1, "constant", 1, 0) 685s ***** error fillmissing (1, "constant", 1, -1) 685s ***** error fillmissing (1, "constant", 1, [1, 2]) 685s ***** error fillmissing (1, "constant", 1, "samplepoints") 685s ***** error fillmissing (1, "constant", 1, "foo") 685s ***** error fillmissing (1, "constant", 1, 1, "foo") 685s ***** error fillmissing (1, "constant", 1, 2, {1}, 4) 685s ***** error fillmissing ([1, 2, 3], "constant", 1, 2, "samplepoints", [1, 2]) 685s ***** error fillmissing ([1, 2, 3], "constant", 1, 2, "samplepoints", [3, 1, 2]) 685s ***** error fillmissing ([1, 2, 3], "constant", 1, 2, "samplepoints", [1, 1, 2]) 685s ***** error fillmissing ([1, 2, 3], "constant", 1, 2, "samplepoints", "abc") 685s ***** error fillmissing ([1, 2, 3], "constant", 1, 2, "samplepoints", logical ([1, 1, 1])) 685s ***** error fillmissing ([1, 2, 3], "constant", 1, 1, "samplepoints", [1, 2, 3]) 685s ***** error fillmissing ("foo", "next", "endvalues", 1) 685s ***** error fillmissing (1, "constant", 1, 1, "endvalues", "foo") 685s ***** error fillmissing ([1, 2, 3], "constant", 1, 2, "endvalues", [1, 2, 3]) 685s ***** error fillmissing ([1, 2, 3], "constant", 1, 1, "endvalues", [1, 2]) 685s ***** error fillmissing (randi(5,4,3,2), "constant", 1, 3, "endvalues", [1, 2]) 685s ***** error fillmissing (1, "constant", 1, 1, "endvalues", {1}) 685s ***** error fillmissing (1, "constant", 1, 2, "foo", 4) 685s ***** error fillmissing (struct, "constant", 1, "missinglocations", false) 685s ***** error fillmissing (1, "constant", 1, 2, "maxgap", 1, "missinglocations", false) 685s ***** error fillmissing (1, "constant", 1, 2, "missinglocations", false, "maxgap", 1) 685s ***** error fillmissing (1, "constant", 1, "replacevalues", true) 685s ***** error fillmissing (1, "constant", 1, "datavariables", "Varname") 685s ***** error fillmissing (1, "constant", 1, 2, "missinglocations", 1) 685s ***** error fillmissing (1, "constant", 1, 2, "missinglocations", "a") 685s ***** error fillmissing (1, "constant", 1, 2, "missinglocations", [true, false]) 685s ***** error fillmissing (true, "linear", "missinglocations", true) 685s ***** error fillmissing (int8 (1), "linear", "missinglocations", true) 685s ***** error fillmissing (true, "next", "missinglocations", true, "EndValues", "linear") 685s ***** error fillmissing (true, "next", "EndValues", "linear", "missinglocations", true) 685s ***** error fillmissing (int8 (1), "next", "missinglocations", true, "EndValues", "linear") 685s ***** error fillmissing (int8 (1), "next", "EndValues", "linear", "missinglocations", true) 685s ***** error fillmissing (1, "constant", 1, 2, "maxgap", true) 685s ***** error fillmissing (1, "constant", 1, 2, "maxgap", "a") 685s ***** error fillmissing (1, "constant", 1, 2, "maxgap", [1, 2]) 685s ***** error fillmissing (1, "constant", 1, 2, "maxgap", 0) 685s ***** error fillmissing (1, "constant", 1, 2, "maxgap", -1) 685s ***** error fillmissing ([1, 2, 3], "constant", [1, 2, 3]) 685s ***** error fillmissing ([1, 2, 3]', "constant", [1, 2, 3]) 685s ***** error fillmissing ([1, 2, 3]', "constant", [1, 2, 3], 1) 685s ***** error fillmissing ([1, 2, 3], "constant", [1, 2, 3], 2) 685s ***** error fillmissing (randi (5, 4, 3, 2), "constant", [1, 2], 1) 685s ***** error fillmissing (randi (5, 4, 3, 2), "constant", [1, 2], 2) 685s ***** error fillmissing (randi (5, 4, 3, 2), "constant", [1, 2], 3) 685s ***** error fillmissing (1, @(x,y,z) x+y+z) 685s ***** error fillmissing ([1, NaN, 2], @(x,y,z) [1, 2], 2) 685s 380 tests, 379 passed, 0 known failure, 1 skipped 685s [inst/runstest.m] 685s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/runstest.m 685s ***** test 685s ## NIST beam deflection data 685s ## http://www.itl.nist.gov/div898/handbook/eda/section4/eda425.htm 685s data = [-213, -564, -35, -15, 141, 115, -420, -360, 203, -338, -431, ... 685s 194, -220, -513, 154, -125, -559, 92, -21, -579, -52, 99, -543, ... 685s -175, 162, -457, -346, 204, -300, -474, 164, -107, -572, -8, 83, ... 685s -541, -224, 180, -420, -374, 201, -236, -531, 83, 27, -564, -112, ... 685s 131, -507, -254, 199, -311, -495, 143, -46, -579, -90, 136, ... 685s -472, -338, 202, -287, -477, 169, -124, -568, 17, 48, -568, -135, ... 685s 162, -430, -422, 172, -74, -577, -13, 92, -534, -243, 194, -355, ... 685s -465, 156, -81, -578, -64, 139, -449, -384, 193, -198, -538, 110, ... 685s -44, -577, -6, 66, -552, -164, 161, -460, -344, 205, -281, -504, ... 685s 134, -28, -576, -118, 156, -437, -381, 200, -220, -540, 83, 11, ... 685s -568, -160, 172, -414, -408, 188, -125, -572, -32, 139, -492, ... 685s -321, 205, -262, -504, 142, -83, -574, 0, 48, -571, -106, 137, ... 685s -501, -266, 190, -391, -406, 194, -186, -553, 83, -13, -577, -49, ... 685s 103, -515, -280, 201, 300, -506, 131, -45, -578, -80, 138, -462, ... 685s -361, 201, -211, -554, 32, 74, -533, -235, 187, -372, -442, 182, ... 685s -147, -566, 25, 68, -535, -244, 194, -351, -463, 174, -125, -570, ... 685s 15, 72, -550, -190, 172, -424, -385, 198, -218, -536, 96]; 685s [h, p, stats] = runstest (data, median (data)); 685s expected_h = 1; 685s expected_p = 0.008562; 685s expected_z = 2.6229; 685s assert (h, expected_h); 685s assert (p, expected_p, 1E-6); 685s assert (stats.z, expected_z, 1E-4); 685s ***** shared x 685s x = [45, -60, 1.225, 55.4, -9 27]; 685s ***** test 685s [h, p, stats] = runstest (x); 685s assert (h, 0); 685s assert (p, 0.6, 1e-14); 685s assert (stats.nruns, 5); 685s assert (stats.n1, 3); 685s assert (stats.n0, 3); 685s assert (stats.z, 0.456435464587638, 1e-14); 685s ***** test 685s [h, p, stats] = runstest (x, [], "method", "approximate"); 685s assert (h, 0); 685s assert (p, 0.6481, 1e-4); 685s assert (stats.z, 0.456435464587638, 1e-14); 685s ***** test 685s [h, p, stats] = runstest (x, [], "tail", "left"); 685s assert (h, 0); 685s assert (p, 0.9, 1e-14); 685s assert (stats.z, 1.369306393762915, 1e-14); 685s ***** error runstest (ones (2,20)) 685s ***** error runstest (["asdasda"]) 685s ***** error ... 685s runstest ([2 3 4 3 2 3 4], "updown") 685s ***** error ... 685s runstest ([2 3 4 3 2 3 4], [], "alpha", 0) 685s ***** error ... 685s runstest ([2 3 4 3 2 3 4], [], "alpha", [0.02 0.2]) 685s ***** error ... 685s runstest ([2 3 4 3 2 3 4], [], "alpha", 1.2) 685s ***** error ... 685s runstest ([2 3 4 3 2 3 4], [], "alpha", -0.05) 685s ***** error ... 685s runstest ([2 3 4 3 2 3 4], [], "method", "some") 685s ***** error ... 685s runstest ([2 3 4 3 2 3 4], [], "tail", "some") 685s ***** error ... 685s runstest ([2 3 4 3 2 3 4], [], "option", "some") 685s 14 tests, 14 passed, 0 known failure, 0 skipped 685s [inst/confusionchart.m] 685s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/confusionchart.m 685s ***** demo 685s ## Setting the chart properties 685s Yt = [8 5 6 8 5 3 1 6 4 2 5 3 1 4]'; 685s Yp = [8 5 6 8 5 2 3 4 4 5 5 7 2 6]'; 685s confusionchart (Yt, Yp, "Title", ... 685s "Demonstration with summaries","Normalization",... 685s "absolute","ColumnSummary", "column-normalized","RowSummary",... 685s "row-normalized") 685s ***** demo 685s ## Cellstr as inputs 685s Yt = {"Positive", "Positive", "Positive", "Negative", "Negative"}; 685s Yp = {"Positive", "Positive", "Negative", "Negative", "Negative"}; 685s m = confusionmat (Yt, Yp); 685s confusionchart (m, {"Positive", "Negative"}); 685s ***** demo 685s ## Editing the object properties 685s Yt = {"Positive", "Positive", "Positive", "Negative", "Negative"}; 685s Yp = {"Positive", "Positive", "Negative", "Negative", "Negative"}; 685s cm = confusionchart (Yt, Yp); 685s cm.Title = "This is an example with a green diagonal"; 685s cm.DiagonalColor = [0.4660, 0.6740, 0.1880]; 685s ***** demo 685s ## Confusion chart in a uipanel 685s h = uipanel (); 685s Yt = {"Positive", "Positive", "Positive", "Negative", "Negative"}; 685s Yp = {"Positive", "Positive", "Negative", "Negative", "Negative"}; 685s cm = confusionchart (h, Yt, Yp); 685s ***** demo 685s ## Sorting classes 685s Yt = [8 5 6 8 5 3 1 6 4 2 5 3 1 4]'; 685s Yp = [8 5 6 8 5 2 3 4 4 5 5 7 2 6]'; 685s cm = confusionchart (Yt, Yp, "Title", ... 685s "Classes are sorted in ascending order"); 685s cm = confusionchart (Yt, Yp, "Title", ... 685s "Classes are sorted according to clusters"); 685s sortClasses (cm, "cluster"); 685s ***** shared visibility_setting 685s visibility_setting = get (0, "DefaultFigureVisible"); 685s ***** test 685s set (0, "DefaultFigureVisible", "off"); 685s fail ("confusionchart ()", "Invalid call"); 685s set (0, "DefaultFigureVisible", visibility_setting); 685s ***** test 685s set (0, "DefaultFigureVisible", "off"); 685s fail ("confusionchart ([1 1; 2 2; 3 3])", "invalid argument"); 685s set (0, "DefaultFigureVisible", visibility_setting); 685s ***** test 685s set (0, "DefaultFigureVisible", "off"); 685s fail ("confusionchart ([1 2], [0 1], 'xxx', 1)", "invalid property"); 685s set (0, "DefaultFigureVisible", visibility_setting); 685s ***** test 685s set (0, "DefaultFigureVisible", "off"); 685s fail ("confusionchart ([1 2], [0 1], 'XLabel', 1)", "XLabel .* string"); 685s set (0, "DefaultFigureVisible", visibility_setting); 686s ***** test 686s set (0, "DefaultFigureVisible", "off"); 686s fail ("confusionchart ([1 2], [0 1], 'YLabel', [1 0])", ... 686s ".* YLabel .* string"); 686s set (0, "DefaultFigureVisible", visibility_setting); 686s ***** test 686s set (0, "DefaultFigureVisible", "off"); 686s fail ("confusionchart ([1 2], [0 1], 'Title', .5)", ".* Title .* string"); 686s set (0, "DefaultFigureVisible", visibility_setting); 686s ***** test 686s set (0, "DefaultFigureVisible", "off"); 686s fail ("confusionchart ([1 2], [0 1], 'FontName', [])", ... 686s ".* FontName .* string"); 686s set (0, "DefaultFigureVisible", visibility_setting); 686s ***** test 686s set (0, "DefaultFigureVisible", "off"); 686s fail ("confusionchart ([1 2], [0 1], 'FontSize', 'b')", ... 686s ".* FontSize .* numeric"); 686s set (0, "DefaultFigureVisible", visibility_setting); 686s ***** test 686s set (0, "DefaultFigureVisible", "off"); 686s fail ("confusionchart ([1 2], [0 1], 'DiagonalColor', 'h')", ... 686s ".* DiagonalColor .* color"); 686s set (0, "DefaultFigureVisible", visibility_setting); 686s ***** test 686s set (0, "DefaultFigureVisible", "off"); 686s fail ("confusionchart ([1 2], [0 1], 'OffDiagonalColor', [])", ... 686s ".* OffDiagonalColor .* color"); 686s set (0, "DefaultFigureVisible", visibility_setting); 686s ***** test 686s set (0, "DefaultFigureVisible", "off"); 686s fail ("confusionchart ([1 2], [0 1], 'Normalization', '')", ... 686s ".* invalid .* Normalization"); 686s set (0, "DefaultFigureVisible", visibility_setting); 687s ***** test 687s set (0, "DefaultFigureVisible", "off"); 687s fail ("confusionchart ([1 2], [0 1], 'ColumnSummary', [])", ... 687s ".* invalid .* ColumnSummary"); 687s set (0, "DefaultFigureVisible", visibility_setting); 687s ***** test 687s set (0, "DefaultFigureVisible", "off"); 687s fail ("confusionchart ([1 2], [0 1], 'RowSummary', 1)", ... 687s ".* invalid .* RowSummary"); 687s set (0, "DefaultFigureVisible", visibility_setting); 687s ***** test 687s set (0, "DefaultFigureVisible", "off"); 687s fail ("confusionchart ([1 2], [0 1], 'GridVisible', .1)", ... 687s ".* invalid .* GridVisible"); 687s set (0, "DefaultFigureVisible", visibility_setting); 687s ***** test 687s set (0, "DefaultFigureVisible", "off"); 687s fail ("confusionchart ([1 2], [0 1], 'HandleVisibility', .1)", ... 687s ".* invalid .* HandleVisibility"); 687s set (0, "DefaultFigureVisible", visibility_setting); 687s ***** test 687s set (0, "DefaultFigureVisible", "off"); 687s fail ("confusionchart ([1 2], [0 1], 'OuterPosition', .1)", ... 687s ".* invalid .* OuterPosition"); 687s set (0, "DefaultFigureVisible", visibility_setting); 687s ***** test 687s set (0, "DefaultFigureVisible", "off"); 687s fail ("confusionchart ([1 2], [0 1], 'Position', .1)", ... 687s ".* invalid .* Position"); 687s set (0, "DefaultFigureVisible", visibility_setting); 688s ***** test 688s set (0, "DefaultFigureVisible", "off"); 688s fail ("confusionchart ([1 2], [0 1], 'Units', .1)", ".* invalid .* Units"); 688s set (0, "DefaultFigureVisible", visibility_setting); 688s 18 tests, 18 passed, 0 known failure, 0 skipped 688s [inst/sampsizepwr.m] 688s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/sampsizepwr.m 688s ***** demo 688s ## Compute the mean closest to 100 that can be determined to be 688s ## significantly different from 100 using a t-test with a sample size 688s ## of 60 and a power of 0.8. 688s mu1 = sampsizepwr ("t", [100, 10], [], 0.8, 60); 688s disp (mu1); 688s ***** demo 688s ## Compute the sample sizes required to distinguish mu0 = 100 from 688s ## mu1 = 110 by a two-sample t-test with a ratio of the larger and the 688s ## smaller sample sizes of 1.5 and a power of 0.6. 688s [N1,N2] = sampsizepwr ("t2", [100, 10], 110, 0.6, [], "ratio", 1.5) 688s ***** demo 688s ## Compute the sample size N required to distinguish p=.26 from p=.2 688s ## with a binomial test. The result is approximate, so make a plot to 688s ## see if any smaller N values also have the required power of 0.6. 688s Napprox = sampsizepwr ("p", 0.2, 0.26, 0.6); 688s nn = 1:250; 688s pwr = sampsizepwr ("p", 0.2, 0.26, [], nn); 688s Nexact = min (nn(pwr >= 0.6)); 688s plot(nn,pwr,'b-', [Napprox Nexact],pwr([Napprox Nexact]),'ro'); 688s grid on 688s ***** demo 688s ## The company must test 52 bottles to detect the difference between a mean 688s ## volume of 100 mL and 102 mL with a power of 0.80. Generate a power curve 688s ## to visualize how the sample size affects the power of the test. 688s 688s nout = sampsizepwr('t',[100 5],102,0.80); 688s nn = 1:100; 688s pwrout = sampsizepwr('t',[100 5],102,[],nn); 688s 688s figure; 688s plot (nn, pwrout, "b-", nout, 0.8, "ro") 688s title ("Power versus Sample Size") 688s xlabel ("Sample Size") 688s ylabel ("Power") 688s ***** error ... 688s out = sampsizepwr ([], [100, 10], [], 0.8, 60); 688s ***** error ... 688s out = sampsizepwr (3, [100, 10], [], 0.8, 60); 688s ***** error ... 688s out = sampsizepwr ({"t", "t2"}, [100, 10], [], 0.8, 60); 688s ***** error ... 688s out = sampsizepwr ("reg", [100, 10], [], 0.8, 60); 688s ***** error ... 688s out = sampsizepwr ("t", ["a", "e"], [], 0.8, 60); 688s ***** error ... 688s out = sampsizepwr ("z", 100, [], 0.8, 60); 688s ***** error ... 688s out = sampsizepwr ("t", 100, [], 0.8, 60); 688s ***** error ... 688s out = sampsizepwr ("t2", 60, [], 0.8, 60); 688s ***** error ... 688s out = sampsizepwr ("var", [100, 10], [], 0.8, 60); 688s ***** error ... 688s out = sampsizepwr ("p", [100, 10], [], 0.8, 60); 688s ***** error ... 688s out = sampsizepwr ("r", [100, 10], [], 0.8, 60); 688s ***** error ... 688s [out, N1] = sampsizepwr ("z", [100, 10], [], 0.8, 60); 688s ***** error ... 688s [out, N1] = sampsizepwr ("t", [100, 10], [], 0.8, 60); 688s ***** error ... 688s [out, N1] = sampsizepwr ("var", 2, [], 0.8, 60); 688s ***** error ... 688s [out, N1] = sampsizepwr ("p", 0.1, [], 0.8, 60); 688s ***** error ... 688s [out, N1] = sampsizepwr ("r", 0.5, [], 0.8, 60); 688s ***** error ... 688s out = sampsizepwr ("z", [100, 0], [], 0.8, 60); 688s ***** error ... 688s out = sampsizepwr ("z", [100, -5], [], 0.8, 60); 688s ***** error ... 688s out = sampsizepwr ("t", [100, 0], [], 0.8, 60); 688s ***** error ... 688s out = sampsizepwr ("t", [100, -5], [], 0.8, 60); 688s ***** error ... 688s [out, N1] = sampsizepwr ("t2", [100, 0], [], 0.8, 60); 688s ***** error ... 688s [out, N1] = sampsizepwr ("t2", [100, -5], [], 0.8, 60); 688s ***** error ... 688s out = sampsizepwr ("var", 0, [], 0.8, 60); 688s ***** error ... 688s out = sampsizepwr ("var", -5, [], 0.8, 60); 688s ***** error ... 688s out = sampsizepwr ("p", 0, [], 0.8, 60); 688s ***** error ... 688s out = sampsizepwr ("p", 1.2, [], 0.8, 60); 688s ***** error ... 688s out = sampsizepwr ("r", -1.5, [], 0.8, 60); 688s ***** error ... 688s out = sampsizepwr ("r", -1, [], 0.8, 60); 688s ***** error ... 688s out = sampsizepwr ("r", 1.2, [], 0.8, 60); 688s ***** error ... 688s out = sampsizepwr ("r", 0, [], 0.8, 60); 688s ***** error ... 688s out = sampsizepwr ("r", 0.2, [], 0.8, 60, "alpha", -0.2); 688s ***** error ... 688s out = sampsizepwr ("r", 0.2, [], 0.8, 60, "alpha", 0); 688s ***** error ... 688s out = sampsizepwr ("r", 0.2, [], 0.8, 60, "alpha", 1.5); 688s ***** error ... 688s out = sampsizepwr ("r", 0.2, [], 0.8, 60, "alpha", "zero"); 688s ***** error ... 688s out = sampsizepwr ("r", 0.2, [], 0.8, 60, "tail", 1.5); 688s ***** error ... 688s out = sampsizepwr ("r", 0.2, [], 0.8, 60, "tail", {"both", "left"}); 688s ***** error ... 688s out = sampsizepwr ("r", 0.2, [], 0.8, 60, "tail", "other"); 688s ***** error ... 688s out = sampsizepwr ("r", 0.2, [], 0.8, 60, "ratio", "some"); 688s ***** error ... 688s out = sampsizepwr ("r", 0.2, [], 0.8, 60, "ratio", 0.5); 688s ***** error ... 688s out = sampsizepwr ("r", 0.2, [], 0.8, 60, "ratio", [2, 1.3, 0.3]); 688s ***** error ... 688s out = sampsizepwr ("z", [100, 5], [], [], 60); 688s ***** error ... 688s out = sampsizepwr ("z", [100, 5], 110, [], []); 688s ***** error ... 688s out = sampsizepwr ("z", [100, 5], [], 0.8, []); 688s ***** error ... 688s out = sampsizepwr ("z", [100, 5], 110, 0.8, 60); 688s ***** error ... 688s out = sampsizepwr ("z", [100, 5], "mu", [], 60); 688s ***** error ... 688s out = sampsizepwr ("var", 5, -1, [], 60); 688s ***** error ... 688s out = sampsizepwr ("p", 0.8, 1.2, [], 60, "tail", "right"); 688s ***** error ... 688s out = sampsizepwr ("r", 0.8, 1.2, [], 60); 688s ***** error ... 688s out = sampsizepwr ("r", 0.8, -1.2, [], 60); 688s ***** error ... 688s out = sampsizepwr ("z", [100, 5], 110, 1.2); 688s ***** error ... 688s out = sampsizepwr ("z", [100, 5], 110, 0); 688s ***** error ... 688s out = sampsizepwr ("z", [100, 5], 110, 0.05, [], "alpha", 0.1); 688s ***** error ... 688s out = sampsizepwr ("z", [100, 5], [], [0.8, 0.7], [60, 80, 100]); 688s ***** error ... 688s out = sampsizepwr ("t", [100, 5], 100, 0.8, []); 688s ***** error ... 688s out = sampsizepwr ("t", [100, 5], 110, 0.8, [], "tail", "left"); 688s ***** error ... 688s out = sampsizepwr ("t", [100, 5], 90, 0.8, [], "tail", "right"); 688s ***** warning ... 688s Napprox = sampsizepwr ("p", 0.2, 0.26, 0.6); 688s ***** warning ... 688s Napprox = sampsizepwr ("p", 0.30, 0.36, 0.8); 688s ***** test 688s mu1 = sampsizepwr ("t", [100, 10], [], 0.8, 60); 688s assert (mu1, 103.67704316, 1e-8); 690s ***** test 690s [N1,N2] = sampsizepwr ("t2", [100, 10], 110, 0.6, [], "ratio", 1.5); 690s assert (N1, 9); 690s assert (N2, 14); 690s ***** test 690s nn = 1:250; 690s pwr = sampsizepwr ("p", 0.2, 0.26, [], nn); 690s pwr_out = [0, 0.0676, 0.0176, 0.0566, 0.0181, 0.0431, 0.0802, 0.0322]; 690s assert (pwr([1:8]), pwr_out, 1e-4 * ones (1,8)); 690s pwr_out = [0.59275, 0.6073, 0.62166, 0.6358, 0.6497, 0.6087, 0.6229, 0.6369]; 690s assert (pwr([243:end]), pwr_out, 1e-4 * ones (1,8)); 690s ***** test 690s nout = sampsizepwr ("t", [100, 5], 102, 0.80); 690s assert (nout, 52); 691s ***** test 691s power = sampsizepwr ("t", [20, 5], 25, [], 5, "Tail", "right"); 691s assert (power, 0.5797373588621888, 1e-14); 691s ***** test 691s nout = sampsizepwr ("t", [20, 5], 25, 0.99, [], "Tail", "right"); 691s assert (nout, 18); 691s ***** test 691s p1out = sampsizepwr ("t", [20, 5], [], 0.95, 10, "Tail", "right"); 691s assert (p1out, 25.65317979360237, 1e-14); 692s ***** test 692s pwr = sampsizepwr ("t2", [1.4, 0.2], 1.7, [], 5, "Ratio", 2); 692s assert (pwr, 0.716504004686586, 1e-14); 692s ***** test 692s n = sampsizepwr ("t2", [1.4, 0.2], 1.7, 0.9, []); 692s assert (n, 11); 693s ***** test 693s [n1, n2] = sampsizepwr ("t2", [1.4, 0.2], 1.7, 0.9, [], "Ratio", 2); 693s assert ([n1, n2], [8, 16]); 694s 68 tests, 68 passed, 0 known failure, 0 skipped 694s [inst/fitcdiscr.m] 694s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/fitcdiscr.m 694s ***** demo 694s ## Train a linear discriminant classifier for Gamma = 0.5 694s ## and plot the decision boundaries. 694s 694s load fisheriris 694s idx = ! strcmp (species, "setosa"); 694s X = meas(idx,3:4); 694s Y = cast (strcmpi (species(idx), "virginica"), "double"); 694s obj = fitcdiscr (X, Y, "Gamma", 0.5) 694s x1 = [min(X(:,1)):0.03:max(X(:,1))]; 694s x2 = [min(X(:,2)):0.02:max(X(:,2))]; 694s [x1G, x2G] = meshgrid (x1, x2); 694s XGrid = [x1G(:), x2G(:)]; 694s pred = predict (obj, XGrid); 694s gidx = logical (str2num (cell2mat (pred))); 694s 694s figure 694s scatter (XGrid(gidx,1), XGrid(gidx,2), "markerfacecolor", "magenta"); 694s hold on 694s scatter (XGrid(!gidx,1), XGrid(!gidx,2), "markerfacecolor", "red"); 694s plot (X(Y == 0, 1), X(Y == 0, 2), "ko", X(Y == 1, 1), X(Y == 1, 2), "kx"); 694s xlabel ("Petal length (cm)"); 694s ylabel ("Petal width (cm)"); 694s title ("Linear Discriminant Analysis Decision Boundary"); 694s legend ({"Versicolor Region", "Virginica Region", ... 694s "Sampled Versicolor", "Sampled Virginica"}, ... 694s "location", "northwest") 694s axis tight 694s hold off 694s ***** test 694s load fisheriris 694s Mdl = fitcdiscr (meas, species, "Gamma", 0.5); 694s [label, score, cost] = predict (Mdl, [2, 2, 2, 2]); 694s assert (label, {'versicolor'}) 694s assert (score, [0, 0.9999, 0.0001], 1e-4) 694s assert (cost, [1, 0.0001, 0.9999], 1e-4) 694s [label, score, cost] = predict (Mdl, [2.5, 2.5, 2.5, 2.5]); 694s assert (label, {'versicolor'}) 694s assert (score, [0, 0.6368, 0.3632], 1e-4) 694s assert (cost, [1, 0.3632, 0.6368], 1e-4) 694s assert (class (Mdl), "ClassificationDiscriminant"); 694s assert ({Mdl.X, Mdl.Y, Mdl.NumObservations}, {meas, species, 150}) 694s assert ({Mdl.DiscrimType, Mdl.ResponseName}, {"linear", "Y"}) 694s assert ({Mdl.Gamma, Mdl.MinGamma}, {0.5, 0}) 694s assert (Mdl.ClassNames, unique (species)) 694s sigma = [0.265008, 0.046361, 0.083757, 0.019201; ... 694s 0.046361, 0.115388, 0.027622, 0.016355; ... 694s 0.083757, 0.027622, 0.185188, 0.021333; ... 694s 0.019201, 0.016355, 0.021333, 0.041882]; 694s assert (Mdl.Sigma, sigma, 1e-6) 694s mu = [5.0060, 3.4280, 1.4620, 0.2460; ... 694s 5.9360, 2.7700, 4.2600, 1.3260; ... 694s 6.5880, 2.9740, 5.5520, 2.0260]; 694s assert (Mdl.Mu, mu, 1e-14) 694s assert (Mdl.LogDetSigma, -8.6884, 1e-4) 694s ***** error fitcdiscr () 694s ***** error fitcdiscr (ones (4,1)) 694s ***** error 694s fitcdiscr (ones (4,2), ones (4, 1), "K") 694s ***** error 694s fitcdiscr (ones (4,2), ones (3, 1)) 694s ***** error 694s fitcdiscr (ones (4,2), ones (3, 1), "K", 2) 694s 6 tests, 6 passed, 0 known failure, 0 skipped 694s [inst/optimalleaforder.m] 694s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/optimalleaforder.m 694s ***** demo 694s randn ("seed", 5) # for reproducibility 694s X = randn (10, 2); 694s D = pdist (X); 694s tree = linkage(D, 'average'); 694s optimalleaforder (tree, D, 'Transformation', 'linear') 694s ***** error optimalleaforder () 694s ***** error optimalleaforder (1) 695s ***** error optimalleaforder (ones (2, 2), 1) 695s ***** error optimalleaforder ([1 2 3], [1 2; 3 4], "criteria", 5) 695s ***** error optimalleaforder ([1 2 1], [1 2 3]) 695s ***** error optimalleaforder ([1 2 1], 1, "xxx", "xxx") 695s ***** error optimalleaforder ([1 2 1], 1, "Transformation", "xxx") 695s 7 tests, 7 passed, 0 known failure, 0 skipped 695s [inst/regress.m] 695s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/regress.m 695s ***** test 695s % Longley data from the NIST Statistical Reference Dataset 695s Z = [ 60323 83.0 234289 2356 1590 107608 1947 695s 61122 88.5 259426 2325 1456 108632 1948 695s 60171 88.2 258054 3682 1616 109773 1949 695s 61187 89.5 284599 3351 1650 110929 1950 695s 63221 96.2 328975 2099 3099 112075 1951 695s 63639 98.1 346999 1932 3594 113270 1952 695s 64989 99.0 365385 1870 3547 115094 1953 695s 63761 100.0 363112 3578 3350 116219 1954 695s 66019 101.2 397469 2904 3048 117388 1955 695s 67857 104.6 419180 2822 2857 118734 1956 695s 68169 108.4 442769 2936 2798 120445 1957 695s 66513 110.8 444546 4681 2637 121950 1958 695s 68655 112.6 482704 3813 2552 123366 1959 695s 69564 114.2 502601 3931 2514 125368 1960 695s 69331 115.7 518173 4806 2572 127852 1961 695s 70551 116.9 554894 4007 2827 130081 1962 ]; 695s % Results certified by NIST using 500 digit arithmetic 695s % b and standard error in b 695s V = [ -3482258.63459582 890420.383607373 695s 15.0618722713733 84.9149257747669 695s -0.358191792925910E-01 0.334910077722432E-01 695s -2.02022980381683 0.488399681651699 695s -1.03322686717359 0.214274163161675 695s -0.511041056535807E-01 0.226073200069370 695s 1829.15146461355 455.478499142212 ]; 695s Rsq = 0.995479004577296; 695s F = 330.285339234588; 695s y = Z(:,1); X = [ones(rows(Z),1), Z(:,2:end)]; 695s alpha = 0.05; 695s [b, bint, r, rint, stats] = regress (y, X, alpha); 695s assert(b,V(:,1),4e-6); 695s assert(stats(1),Rsq,1e-12); 695s assert(stats(2),F,3e-8); 695s assert(((bint(:,1)-bint(:,2))/2)/tinv(alpha/2,9),V(:,2),-1.e-5); 695s warning: matrix singular to machine precision, rcond = 3.50566e-20 695s warning: called from 695s regress at line 131 column 7 695s __test__ at line 33 column 28 695s test at line 682 column 11 695s /tmp/tmp.4H0keGrBC1 at line 3334 column 31 695s 695s 1 test, 1 passed, 0 known failure, 0 skipped 695s [inst/mnrfit.m] 695s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/mnrfit.m 695s ***** error mnrfit (ones (50,1)) 695s ***** error ... 695s mnrfit ({1 ;2 ;3 ;4 ;5}, ones (5,1)) 695s ***** error ... 695s mnrfit (ones (50, 4, 2), ones (50, 1)) 695s ***** error ... 695s mnrfit (ones (50, 4), ones (50, 1, 3)) 695s ***** error ... 695s mnrfit (ones (50, 4), ones (45,1)) 695s ***** error ... 695s mnrfit (ones (5, 4), {1 ;2 ;3 ;4 ;5}) 695s ***** error ... 695s mnrfit (ones (5, 4), ones (5, 1), "model") 695s ***** error ... 695s mnrfit (ones (5, 4), {"q","q";"w","w";"q","q";"w","w";"q","q"}) 695s ***** error ... 695s mnrfit (ones (5, 4), [1, 2; 1, 2; 1, 2; 1, 2; 1, 2]) 695s ***** error ... 695s mnrfit (ones (5, 4), [1; -1; 1; 2; 1]) 695s ***** error ... 695s mnrfit (ones (5, 4), [1; 2; 3; 2; 1], "model", "nominal") 695s ***** error ... 695s mnrfit (ones (5, 4), [1; 2; 3; 2; 1], "model", "hierarchical") 695s ***** error ... 695s mnrfit (ones (5, 4), [1; 2; 3; 2; 1], "model", "whatever") 695s 13 tests, 13 passed, 0 known failure, 0 skipped 695s [inst/fitcgam.m] 695s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/fitcgam.m 695s ***** demo 695s ## Train a GAM classifier for binary classification 695s ## using specific data and plot the decision boundaries. 695s 695s ## Define specific data 695s X = [1, 2; 2, 3; 3, 3; 4, 5; 5, 5; ... 695s 6, 7; 7, 8; 8, 8; 9, 9; 10, 10]; 695s Y = [0; 0; 0; 0; 0; ... 695s 1; 1; 1; 1; 1]; 695s 695s ## Train the GAM model 695s obj = fitcgam (X, Y, "Interactions", "all"); 695s 695s ## Create a grid of values for prediction 695s x1 = [min(X(:,1)):0.1:max(X(:,1))]; 695s x2 = [min(X(:,2)):0.1:max(X(:,2))]; 695s [x1G, x2G] = meshgrid (x1, x2); 695s XGrid = [x1G(:), x2G(:)]; 695s pred = predict (obj, XGrid); 695s 695s ## Plot decision boundaries and data points 695s predNumeric = str2double (pred); 695s gidx = predNumeric > 0.5; 695s 695s figure 695s scatter(XGrid(gidx,1), XGrid(gidx,2), "markerfacecolor", "magenta"); 695s hold on 695s scatter(XGrid(!gidx,1), XGrid(!gidx,2), "markerfacecolor", "red"); 695s plot(X(Y == 0, 1), X(Y == 0, 2), "ko", X(Y == 1, 1), X(Y == 1, 2), "kx"); 695s xlabel("Feature 1"); 695s ylabel("Feature 2"); 695s title("Generalized Additive Model (GAM) Decision Boundary"); 695s legend({"Class 1 Region", "Class 0 Region", ... 695s "Class 1 Samples", "Class 0 Samples"}, ... 695s "location", "northwest") 695s axis tight 695s hold off 695s ***** test 695s x = [1, 2, 3; 4, 5, 6; 7, 8, 9; 3, 2, 1]; 695s y = [0; 0; 1; 1]; 695s PredictorNames = {'Feature1', 'Feature2', 'Feature3'}; 695s a = fitcgam (x, y, "PredictorNames", PredictorNames); 695s assert (class (a), "ClassificationGAM"); 695s assert ({a.X, a.Y, a.NumObservations}, {x, y, 4}) 695s assert ({a.NumPredictors, a.ResponseName}, {3, "Y"}) 695s assert (a.ClassNames, {'0'; '1'}) 695s assert (a.PredictorNames, PredictorNames) 695s assert (a.BaseModel.Intercept, 0) 697s ***** test 697s x = [1, 2; 3, 4; 5, 6; 7, 8; 9, 10]; 697s y = [1; 0; 1; 0; 1]; 697s a = fitcgam (x, y, "interactions", "all"); 697s assert (class (a), "ClassificationGAM"); 697s assert ({a.X, a.Y, a.NumObservations}, {x, y, 5}) 697s assert ({a.NumPredictors, a.ResponseName}, {2, "Y"}) 697s assert (a.ClassNames, {'1'; '0'}) 697s assert (a.PredictorNames, {'x1', 'x2'}) 697s assert (a.ModelwInt.Intercept, 0.4055, 1e-1) 702s ***** test 702s load fisheriris 702s inds = strcmp (species,'versicolor') | strcmp (species,'virginica'); 702s X = meas(inds, :); 702s Y = species(inds, :)'; 702s Y = strcmp (Y, 'virginica')'; 702s a = fitcgam (X, Y, 'Formula', 'Y ~ x1 + x2 + x3 + x4 + x1:x2 + x2:x3'); 702s assert (class (a), "ClassificationGAM"); 702s assert ({a.X, a.Y, a.NumObservations}, {X, Y, 100}) 702s assert ({a.NumPredictors, a.ResponseName}, {4, "Y"}) 702s assert (a.ClassNames, {'0'; '1'}) 702s assert (a.Formula, 'Y ~ x1 + x2 + x3 + x4 + x1:x2 + x2:x3') 702s assert (a.PredictorNames, {'x1', 'x2', 'x3', 'x4'}) 702s assert (a.ModelwInt.Intercept, 0) 711s ***** error fitcgam () 711s ***** error fitcgam (ones (4,1)) 711s ***** error 711s fitcgam (ones (4,2), ones (4, 1), "K") 711s ***** error 711s fitcgam (ones (4,2), ones (3, 1)) 711s ***** error 711s fitcgam (ones (4,2), ones (3, 1), "K", 2) 711s 8 tests, 8 passed, 0 known failure, 0 skipped 711s [inst/wblplot.m] 711s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/wblplot.m 711s ***** demo 711s x = [16 34 53 75 93 120]; 711s wblplot (x); 711s ***** demo 711s x = [2 3 5 7 11 13 17 19 23 29 31 37 41 43 47 53 59 61 67]'; 711s c = [0 1 0 1 0 1 1 1 0 0 1 0 1 0 1 1 0 1 1]'; 711s [h, p] = wblplot (x, c); 711s p 711s ***** demo 711s x = [16, 34, 53, 75, 93, 120, 150, 191, 240 ,339]; 711s [h, p] = wblplot (x, [], [], 0.05); 711s p 711s ## Benchmark Reliasoft eta = 146.2545 beta 1.1973 rho = 0.9999 711s ***** demo 711s x = [46 64 83 105 123 150 150]; 711s c = [0 0 0 0 0 0 1]; 711s f = [1 1 1 1 1 1 4]; 711s wblplot (x, c, f, 0.05); 711s ***** demo 711s x = [46 64 83 105 123 150 150]; 711s c = [0 0 0 0 0 0 1]; 711s f = [1 1 1 1 1 1 4]; 711s ## Subtract 30.92 from x to simulate a 3 parameter wbl with gamma = 30.92 711s wblplot (x - 30.92, c, f, 0.05); 711s ***** test 711s hf = figure ("visible", "off"); 711s unwind_protect 711s x = [16, 34, 53, 75, 93, 120, 150, 191, 240 ,339]; 711s [h, p] = wblplot (x, [], [], 0.05); 711s assert (numel (h), 4) 711s assert (p(1), 146.2545, 1E-4) 711s assert (p(2), 1.1973, 1E-4) 711s assert (p(3), 0.9999, 5E-5) 711s unwind_protect_cleanup 711s close (hf); 711s end_unwind_protect 712s 1 test, 1 passed, 0 known failure, 0 skipped 712s [inst/hotelling_t2test2.m] 712s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/hotelling_t2test2.m 712s ***** error hotelling_t2test2 (); 712s ***** error ... 712s hotelling_t2test2 ([2, 3, 4, 5, 6]); 713s ***** error ... 713s hotelling_t2test2 (1, [2, 3, 4, 5, 6]); 713s ***** error ... 713s hotelling_t2test2 (ones (2,2,2), [2, 3, 4, 5, 6]); 713s ***** error ... 713s hotelling_t2test2 ([2, 3, 4, 5, 6], 2); 713s ***** error ... 713s hotelling_t2test2 ([2, 3, 4, 5, 6], ones (2,2,2)); 713s ***** error ... 713s hotelling_t2test2 (ones (20,2), ones (20,2), "alpha", 1); 713s ***** error ... 713s hotelling_t2test2 (ones (20,2), ones (20,2), "alpha", -0.2); 713s ***** error ... 713s hotelling_t2test2 (ones (20,2), ones (20,2), "alpha", "a"); 713s ***** error ... 713s hotelling_t2test2 (ones (20,2), ones (20,2), "alpha", [0.01, 0.05]); 713s ***** error ... 713s hotelling_t2test2 (ones (20,2), ones (20,2), "name", 0.01); 713s ***** error ... 713s hotelling_t2test2 (ones (20,1), ones (20,2)); 713s ***** error ... 713s hotelling_t2test2 (ones (20,2), ones (25,3)); 713s ***** test 713s randn ("seed", 1); 713s x1 = randn (60000, 5); 713s randn ("seed", 5); 713s x2 = randn (30000, 5); 713s [h, pval, stats] = hotelling_t2test2 (x1, x2); 713s assert (h, 0); 713s assert (stats.df1, 5); 713s assert (stats.df2, 89994); 713s 14 tests, 14 passed, 0 known failure, 0 skipped 713s [inst/procrustes.m] 713s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/procrustes.m 713s ***** demo 713s ## Create some random points in two dimensions 713s n = 10; 713s randn ("seed", 1); 713s X = normrnd (0, 1, [n, 2]); 713s 713s ## Those same points, rotated, scaled, translated, plus some noise 713s S = [0.5, -sqrt(3)/2; sqrt(3)/2, 0.5]; # rotate 60 degrees 713s Y = normrnd (0.5*X*S + 2, 0.05, n, 2); 713s 713s ## Conform Y to X, plot original X and Y, and transformed Y 713s [d, Z] = procrustes (X, Y); 713s plot (X(:,1), X(:,2), "rx", Y(:,1), Y(:,2), "b.", Z(:,1), Z(:,2), "bx"); 713s ***** demo 713s ## Find Procrustes distance and plot superimposed shape 713s 713s X = [40 88; 51 88; 35 78; 36 75; 39 72; 44 71; 48 71; 52 74; 55 77]; 713s Y = [36 43; 48 42; 31 26; 33 28; 37 30; 40 31; 45 30; 48 28; 51 24]; 713s plot (X(:,1),X(:,2),"x"); 713s hold on 713s plot (Y(:,1),Y(:,2),"o"); 713s xlim ([0 100]); 713s ylim ([0 100]); 713s legend ("Target shape (X)", "Source shape (Y)"); 713s [d, Z] = procrustes (X, Y) 713s plot (Z(:,1), Z(:,2), "s"); 713s legend ("Target shape (X)", "Source shape (Y)", "Transformed shape (Z)"); 713s hold off 713s ***** demo 713s ## Apply Procrustes transformation to larger set of points 713s 713s ## Create matrices with landmark points for two triangles 713s X = [5, 0; 5, 5; 8, 5]; # target 713s Y = [0, 0; 1, 0; 1, 1]; # source 713s 713s ## Create a matrix with more points on the source triangle 713s Y_mp = [linspace(Y(1,1),Y(2,1),10)', linspace(Y(1,2),Y(2,2),10)'; ... 713s linspace(Y(2,1),Y(3,1),10)', linspace(Y(2,2),Y(3,2),10)'; ... 713s linspace(Y(3,1),Y(1,1),10)', linspace(Y(3,2),Y(1,2),10)']; 713s 713s ## Plot both shapes, including the larger set of points for the source shape 713s plot ([X(:,1); X(1,1)], [X(:,2); X(1,2)], "bx-"); 713s hold on 713s plot ([Y(:,1); Y(1,1)], [Y(:,2); Y(1,2)], "ro-", "MarkerFaceColor", "r"); 713s plot (Y_mp(:,1), Y_mp(:,2), "ro"); 713s xlim ([-1 10]); 713s ylim ([-1 6]); 713s legend ("Target shape (X)", "Source shape (Y)", ... 713s "More points on Y", "Location", "northwest"); 713s hold off 713s 713s ## Obtain the Procrustes transformation 713s [d, Z, transform] = procrustes (X, Y) 713s 713s ## Use the Procrustes transformation to superimpose the more points (Y_mp) 713s ## on the source shape onto the target shape, and then visualize the results. 713s Z_mp = transform.b * Y_mp * transform.T + transform.c(1,:); 713s figure 713s plot ([X(:,1); X(1,1)], [X(:,2); X(1,2)], "bx-"); 713s hold on 713s plot ([Y(:,1); Y(1,1)], [Y(:,2); Y(1,2)], "ro-", "MarkerFaceColor", "r"); 713s plot (Y_mp(:,1), Y_mp(:,2), "ro"); 713s xlim ([-1 10]); 713s ylim ([-1 6]); 713s plot ([Z(:,1); Z(1,1)],[Z(:,2); Z(1,2)],"ks-","MarkerFaceColor","k"); 713s plot (Z_mp(:,1),Z_mp(:,2),"ks"); 713s legend ("Target shape (X)", "Source shape (Y)", ... 713s "More points on Y", "Transformed source shape (Z)", ... 713s "Transformed additional points", "Location", "northwest"); 713s hold off 713s ***** demo 713s ## Compare shapes without reflection 713s 713s T = [33, 93; 33, 87; 33, 80; 31, 72; 32, 65; 32, 58; 30, 72; ... 713s 28, 72; 25, 69; 22, 64; 23, 59; 26, 57; 30, 57]; 713s S = [48, 83; 48, 77; 48, 70; 48, 65; 49, 59; 49, 56; 50, 66; ... 713s 52, 66; 56, 65; 58, 61; 57, 57; 54, 56; 51, 55]; 713s plot (T(:,1), T(:,2), "x-"); 713s hold on 713s plot (S(:,1), S(:,2), "o-"); 713s legend ("Target shape (d)", "Source shape (b)"); 713s hold off 713s d_false = procrustes (T, S, "reflection", false); 713s printf ("Procrustes distance without reflection: %f\n", d_false); 713s d_true = procrustes (T, S, "reflection", true); 713s printf ("Procrustes distance with reflection: %f\n", d_true); 713s d_best = procrustes (T, S, "reflection", "best"); 713s printf ("Procrustes distance with best fit: %f\n", d_true); 713s ***** error procrustes (); 713s ***** error procrustes (1, 2, 3, 4, 5, 6); 713s ***** error ... 713s procrustes (ones (2, 2, 2), ones (2, 2, 2)); 713s ***** error ... 713s procrustes ([1, 2; -3, 4; 2, 3], [1, 2; -3, 4; 2, 3+i]); 713s ***** error ... 713s procrustes ([1, 2; -3, 4; 2, 3], [1, 2; -3, 4; 2, NaN]); 713s ***** error ... 713s procrustes ([1, 2; -3, 4; 2, 3], [1, 2; -3, 4; 2, Inf]); 713s ***** error ... 713s procrustes (ones (10 ,3), ones (11, 3)); 713s ***** error ... 713s procrustes (ones (10 ,3), ones (10, 4)); 713s ***** error ... 713s procrustes (ones (10 ,3), ones (10, 3), "reflection"); 713s ***** error ... 713s procrustes (ones (10 ,3), ones (10, 3), true); 713s ***** error ... 713s procrustes (ones (10 ,3), ones (10, 3), "scaling", 0); 713s ***** error ... 713s procrustes (ones (10 ,3), ones (10, 3), "scaling", [true true]); 713s ***** error ... 713s procrustes (ones (10 ,3), ones (10, 3), "reflection", 1); 713s ***** error ... 713s procrustes (ones (10 ,3), ones (10, 3), "reflection", "some"); 713s ***** error ... 713s procrustes (ones (10 ,3), ones (10, 3), "param1", "some"); 713s 15 tests, 15 passed, 0 known failure, 0 skipped 713s [inst/datasample.m] 713s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/datasample.m 713s ***** error datasample(); 713s ***** error datasample(1); 713s ***** error datasample({1, 2, 3}, 1); 713s ***** error datasample([1 2], -1); 713s ***** error datasample([1 2], 1.5); 713s ***** error datasample([1 2], [1 1]); 713s ***** error datasample([1 2], 'g', [1 1]); 713s ***** error datasample([1 2], 1, -1); 713s ***** error datasample([1 2], 1, 1.5); 713s ***** error datasample([1 2], 1, [1 1]); 713s ***** error datasample([1 2], 1, 1, "Replace", -2); 713s ***** error datasample([1 2], 1, 1, "Weights", "abc"); 713s ***** error datasample([1 2], 1, 1, "Weights", [1 -2 3]); 713s ***** error datasample([1 2], 1, 1, "Weights", ones (2)); 713s ***** error datasample([1 2], 1, 1, "Weights", [1 2 3]); 713s ***** test 713s dat = randn (10, 4); 713s assert (size (datasample (dat, 3, 1)), [3 4]); 713s ***** test 713s dat = randn (10, 4); 713s assert (size (datasample (dat, 3, 2)), [10 3]); 713s 17 tests, 17 passed, 0 known failure, 0 skipped 713s [inst/adtest.m] 713s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/adtest.m 713s ***** error adtest (); 713s ***** error adtest (ones (20,2)); 713s ***** error adtest ([1+i,0-3i]); 713s ***** error ... 713s adtest (ones (20,1), "Distribution", "normal"); 713s ***** error ... 713s adtest (rand (20,1), "Distribution", {"normal", 5, 3}); 713s ***** error ... 713s adtest (rand (20,1), "Distribution", {"norm", 5}); 713s ***** error ... 713s adtest (rand (20,1), "Distribution", {"exp", 5, 4}); 713s ***** error ... 713s adtest (rand (20,1), "Distribution", {"ev", 5}); 713s ***** error ... 713s adtest (rand (20,1), "Distribution", {"logn", 5, 3, 2}); 713s ***** error ... 713s adtest (rand (20,1), "Distribution", {"Weibull", 5}); 713s ***** error ... 713s adtest (rand (20,1), "Distribution", 35); 713s ***** error ... 713s adtest (rand (20,1), "Name", "norm"); 713s ***** error ... 713s adtest (rand (20,1), "Name", {"norm", 75, 10}); 713s ***** error ... 713s adtest (rand (20,1), "Distribution", "norm", "Asymptotic", true); 713s ***** error ... 713s adtest (rand (20,1), "MCTol", 0.001, "Asymptotic", true); 713s ***** error ... 713s adtest (rand (20,1), "Distribution", {"norm", 5, 3}, "MCTol", 0.001, ... 713s "Asymptotic", true); 713s ***** error ... 713s [h, pval, ADstat, CV] = adtest (ones (20,1), "Distribution", {"norm",5,3},... 713s "Alpha", 0.000000001); 713s ***** error ... 713s [h, pval, ADstat, CV] = adtest (ones (20,1), "Distribution", {"norm",5,3},... 713s "Alpha", 0.999999999); 713s ***** error ... 713s adtest (10); 713s ***** warning ... 713s randn ("seed", 34); 713s adtest (ones (20,1), "Alpha", 0.000001); 713s ***** warning ... 713s randn ("seed", 34); 713s adtest (normrnd(0,1,100,1), "Alpha", 0.99999); 713s ***** warning ... 713s randn ("seed", 34); 713s adtest (normrnd(0,1,100,1), "Alpha", 0.00001); 714s ***** test 714s load examgrades 714s x = grades(:,1); 714s [h, pval, adstat, cv] = adtest (x); 714s assert (h, false); 714s assert (pval, 0.1854, 1e-4); 714s assert (adstat, 0.5194, 1e-4); 714s assert (cv, 0.7470, 1e-4); 714s ***** test 714s load examgrades 714s x = grades(:,1); 714s [h, pval, adstat, cv] = adtest (x, "Distribution", "ev"); 714s assert (h, false); 714s assert (pval, 0.071363, 1e-6); 714s ***** test 714s load examgrades 714s x = grades(:,1); 714s [h, pval, adstat, cv] = adtest (x, "Distribution", {"norm", 75, 10}); 714s assert (h, false); 714s assert (pval, 0.4687, 1e-4); 714s 25 tests, 25 passed, 0 known failure, 0 skipped 714s [inst/ismissing.m] 714s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/ismissing.m 714s ***** assert (ismissing ([1,NaN,3]), [false,true,false]) 714s ***** assert (ismissing ('abcd f'), [false,false,false,false,true,false]) 714s ***** assert (ismissing ({'xxx','','xyz'}), [false,true,false]) 714s ***** assert (ismissing ({'x','','y'}), [false,true,false]) 714s ***** assert (ismissing ({'x','','y';'z','a',''}), logical([0,1,0;0,0,1])) 714s ***** assert (ismissing ([1,2;NaN,2]), [false,false;true,false]) 714s ***** assert (ismissing ([1,2;NaN,2], 2), [false,true;false,true]) 714s ***** assert (ismissing ([1,2;NaN,2], [1 2]), [true,true;false,true]) 714s ***** assert (ismissing ([1,2;NaN,2], NaN), [false,false;true,false]) 714s ***** assert (ismissing (cat(3,magic(2),magic(2))), logical (zeros (2,2,2))) 714s ***** assert (ismissing (cat(3,magic(2),[1 2;3 NaN])), logical (cat(3,[0,0;0,0],[0,0;0,1]))) 714s ***** assert (ismissing ([1 2; 3 4], [5 1; 2 0]), logical([1 1; 0 0])) 714s ***** assert (ismissing (cat(3,'f oo','ba r')), logical(cat(3,[0 1 0 0],[0 0 1 0]))) 714s ***** assert (ismissing (cat(3,{'foo'},{''},{'bar'})), logical(cat(3,0,1,0))) 714s ***** assert (ismissing (double (NaN)), true) 714s ***** assert (ismissing (single (NaN)), true) 714s ***** assert (ismissing (' '), true) 714s ***** assert (ismissing ({''}), true) 714s ***** assert (ismissing ({' '}), false) 714s ***** assert (ismissing (double (eye(3)), single (1)), logical(eye(3))) 714s ***** assert (ismissing (double (eye(3)), true), logical(eye(3))) 714s ***** assert (ismissing (double (eye(3)), int32 (1)), logical(eye(3))) 714s ***** assert (ismissing (single (eye(3)), true), logical(eye(3))) 714s ***** assert (ismissing (single (eye(3)), double (1)), logical(eye(3))) 714s ***** assert (ismissing (single(eye(3)), int32 (1)), logical(eye(3))) 714s ***** assert (ismissing ({'123', '', 123}), [false false false]) 714s ***** assert (ismissing (logical ([1 0 1])), [false false false]) 714s ***** assert (ismissing (int32 ([1 2 3])), [false false false]) 714s ***** assert (ismissing (uint32 ([1 2 3])), [false false false]) 714s ***** assert (ismissing ({1, 2, 3}), [false false false]) 714s ***** assert (ismissing ([struct struct struct]), [false false false]) 714s ***** assert (ismissing (logical (eye(3)), true), logical(eye(3))) 714s ***** assert (ismissing (logical (eye(3)), double (1)), logical(eye(3))) 714s ***** assert (ismissing (logical (eye(3)), single (1)), logical(eye(3))) 714s ***** assert (ismissing (logical (eye(3)), int32 (1)), logical(eye(3))) 714s ***** assert (ismissing (int32 (eye(3)), int32 (1)), logical(eye(3))) 714s ***** assert (ismissing (int32 (eye(3)), true), logical(eye(3))) 714s ***** assert (ismissing (int32 (eye(3)), double (1)), logical(eye(3))) 714s ***** assert (ismissing (int32 (eye(3)), single (1)), logical(eye(3))) 714s ***** assert (ismissing ([]), logical([])) 714s ***** assert (ismissing (''), logical([])) 714s ***** assert (ismissing (ones (0,1)), logical(ones(0,1))) 714s ***** assert (ismissing (ones (1,0)), logical(ones(1,0))) 714s ***** assert (ismissing (ones (1,2,0)), logical(ones(1,2,0))) 714s ***** error ismissing () 714s ***** error <'indicator' and 'A' must have the same> ismissing ([1 2; 3 4], "abc") 714s ***** error <'indicator' and 'A' must have the same> ismissing ({"", "", ""}, 1) 714s ***** error <'indicator' and 'A' must have the same> ismissing (1, struct) 714s ***** error ismissing (struct, 1) 714s 49 tests, 49 passed, 0 known failure, 0 skipped 714s [inst/grpstats.m] 714s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/grpstats.m 714s ***** demo 714s load carsmall; 714s [m,p,g] = grpstats (Weight, Model_Year, {"mean", "predci", "gname"}) 714s n = length(m); 714s errorbar((1:n)',m,p(:,2)-m); 714s set (gca, "xtick", 1:n, "xticklabel", g); 714s title ("95% prediction intervals for mean weight by year"); 714s ***** demo 714s load carsmall; 714s [m,p,g] = grpstats ([Acceleration,Weight/1000],Cylinders, ... 714s {"mean", "meanci", "gname"}, 0.05) 714s [c,r] = size (m); 714s errorbar((1:c)'.*ones(c,r),m,p(:,[(1:r)])-m); 714s set (gca, "xtick", 1:c, "xticklabel", g); 714s title ("95% prediction intervals for mean weight by year"); 714s ***** test 714s load carsmall 714s means = grpstats (Acceleration, Origin); 714s assert (means, [14.4377; 18.0500; 15.8867; 16.3778; 16.6000; 15.5000], 0.001); 714s ***** test 714s load carsmall 714s [grpMin,grpMax,grp] = grpstats (Acceleration, Origin, {"min","max","gname"}); 714s assert (grpMin, [8.0; 15.3; 13.9; 12.2; 15.7; 15.5]); 714s assert (grpMax, [22.2; 21.9; 18.2; 24.6; 17.5; 15.5]); 714s ***** test 714s load carsmall 714s [grpMin,grpMax,grp] = grpstats (Acceleration, Origin, {"min","max","gname"}); 714s assert (grp', {"USA", "France", "Japan", "Germany", "Sweden", "Italy"}); 714s ***** test 714s load carsmall 714s [m,p,g] = grpstats ([Acceleration,Weight/1000], Cylinders, ... 714s {"mean", "meanci", "gname"}, 0.05); 714s assert (p(:,1), [11.17621760075134, 16.13845847655224, 16.16222663683362]', ... 714s [1e-14, 2e-14, 1e-14]'); 714s 4 tests, 4 passed, 0 known failure, 0 skipped 714s [inst/Clustering/SilhouetteEvaluation.m] 714s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/Clustering/SilhouetteEvaluation.m 714s ***** test 714s load fisheriris 714s eva = evalclusters (meas, "kmeans", "silhouette", "KList", [1:6]); 714s assert (class (eva), "SilhouetteEvaluation"); 715s 1 test, 1 passed, 0 known failure, 0 skipped 715s [inst/Clustering/ClusterCriterion.m] 715s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/Clustering/ClusterCriterion.m 715s ***** error ... 715s ClusterCriterion ("1", "kmeans", [1:6]) 715s ***** error ... 715s ClusterCriterion ([1, 2, 1, 3, 2, 4, 3], "k", [1:6]) 715s ***** error ... 715s ClusterCriterion ([1, 2, 1; 3, 2, 4], 1, [1:6]) 715s ***** error ... 715s ClusterCriterion ([1, 2, 1; 3, 2, 4], ones (2, 2, 2), [1:6]) 715s 4 tests, 4 passed, 0 known failure, 0 skipped 715s [inst/Clustering/CalinskiHarabaszEvaluation.m] 715s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/Clustering/CalinskiHarabaszEvaluation.m 715s ***** test 715s load fisheriris 715s eva = evalclusters (meas, "kmeans", "calinskiharabasz", "KList", [1:6]); 715s assert (class (eva), "CalinskiHarabaszEvaluation"); 716s 1 test, 1 passed, 0 known failure, 0 skipped 716s [inst/Clustering/GapEvaluation.m] 716s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/Clustering/GapEvaluation.m 716s ***** test 716s load fisheriris 716s eva = evalclusters (meas([1:50],:), "kmeans", "gap", "KList", [1:3], ... 716s "referencedistribution", "uniform"); 716s assert (class (eva), "GapEvaluation"); 722s 1 test, 1 passed, 0 known failure, 0 skipped 722s [inst/Clustering/DaviesBouldinEvaluation.m] 722s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/Clustering/DaviesBouldinEvaluation.m 722s ***** test 722s load fisheriris 722s eva = evalclusters (meas, "kmeans", "DaviesBouldin", "KList", [1:6]); 722s assert (class (eva), "DaviesBouldinEvaluation"); 723s 1 test, 1 passed, 0 known failure, 0 skipped 723s [inst/cmdscale.m] 723s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/cmdscale.m 723s ***** shared m, n, X, D 723s m = randi(100) + 1; n = randi(100) + 1; X = rand(m, n); D = pdist(X); 723s ***** assert(norm(pdist(cmdscale(D))), norm(D), sqrt(eps)) 723s ***** assert(norm(pdist(cmdscale(squareform(D)))), norm(D), sqrt(eps)) 723s 2 tests, 2 passed, 0 known failure, 0 skipped 723s [inst/fitcsvm.m] 723s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/fitcsvm.m 723s ***** demo 723s ## Use a subset of Fisher's iris data set 723s 723s load fisheriris 723s inds = ! strcmp (species, 'setosa'); 723s X = meas(inds, [3,4]); 723s Y = species(inds); 723s 723s ## Train a linear SVM classifier 723s SVMModel = fitcsvm (X, Y) 723s 723s ## Plot a scatter diagram of the data and circle the support vectors. 723s sv = SVMModel.SupportVectors; 723s figure 723s gscatter (X(:,1), X(:,2), Y) 723s hold on 723s plot (sv(:,1), sv(:,2), 'ko', 'MarkerSize', 10) 723s legend ('versicolor', 'virginica', 'Support Vector') 723s hold off 723s ***** test 723s x = [1, 2, 3; 4, 5, 6; 7, 8, 9; 3, 2, 1]; 723s y = {"a"; "a"; "b"; "b"}; 723s a = fitcsvm (x, y); 723s assert (class (a), "ClassificationSVM"); 723s assert ({a.X, a.Y}, {x, y}) 723s assert (a.NumObservations, 4) 723s assert ({a.ResponseName, a.PredictorNames}, {"Y", {"x1", "x2", "x3"}}) 723s assert (a.ModelParameters.SVMtype, "c_svc") 723s assert (a.ClassNames, {"a"; "b"}) 723s ***** test 723s x = [1, 2; 2, 3; 3, 4; 4, 5; 2, 3; 3, 4; 2, 3; 3, 4; 2, 3; 3, 4]; 723s y = [1; 1; -1; -1; 1; -1; -1; -1; -1; -1]; 723s a = fitcsvm (x, y); 723s assert (class (a), "ClassificationSVM"); 723s assert ({a.X, a.Y, a.ModelParameters.KernelFunction}, {x, y, "linear"}) 723s assert (a.ModelParameters.BoxConstraint, 1) 723s assert (a.ModelParameters.KernelOffset, 0) 723s assert (a.ClassNames, [1; -1]) 723s ***** test 723s x = [1, 2; 2, 3; 3, 4; 4, 5; 2, 3; 3, 4; 2, 3; 3, 4; 2, 3; 3, 4]; 723s y = [1; 1; -1; -1; 1; -1; -1; -1; -1; -1]; 723s a = fitcsvm (x, y, "KernelFunction", "rbf", "BoxConstraint", 2, ... 723s "KernelOffset", 2); 723s assert (class (a), "ClassificationSVM"); 723s assert ({a.X, a.Y, a.ModelParameters.KernelFunction}, {x, y, "rbf"}) 723s assert (a.ModelParameters.BoxConstraint, 2) 723s assert (a.ModelParameters.KernelOffset, 2) 723s assert (isempty (a.Alpha), true) 723s assert (isempty (a.Beta), false) 723s ***** test 723s x = [1, 2; 2, 3; 3, 4; 4, 5; 2, 3; 3, 4; 2, 3; 3, 4; 2, 3; 3, 4]; 723s y = [1; 1; -1; -1; 1; -1; -1; -1; -1; -1]; 723s a = fitcsvm (x, y, "KernelFunction", "polynomial", "PolynomialOrder", 3); 723s assert (class (a), "ClassificationSVM"); 723s assert ({a.X, a.Y, a.ModelParameters.KernelFunction}, {x, y, "polynomial"}) 723s assert (a.ModelParameters.PolynomialOrder, 3) 723s assert (isempty (a.Alpha), true) 723s assert (isempty (a.Beta), false) 723s ***** test 723s x = [1, 2; 2, 3; 3, 4; 4, 5; 2, 3; 3, 4; 2, 3; 3, 4; 2, 3; 3, 4]; 723s y = [1; 1; -1; -1; 1; -1; -1; -1; -1; -1]; 723s a = fitcsvm (x, y, "KernelFunction", "linear", "PolynomialOrder", 3); 723s assert (class (a), "ClassificationSVM"); 723s assert ({a.X, a.Y, a.ModelParameters.KernelFunction}, {x, y, "linear"}) 723s assert (a.ModelParameters.PolynomialOrder, 3) 723s assert (isempty (a.Alpha), false) 723s assert (isempty (a.Beta), true) 723s ***** test 723s x = [1, 2; 2, 3; 3, 4; 4, 5; 2, 3; 3, 4; 2, 3; 3, 4; 2, 3; 3, 4]; 723s y = [1; 1; -1; -1; 1; -1; -1; -1; -1; -1]; 723s a = fitcsvm (x, y, "KernelFunction", "linear", "CrossVal", 'on'); 723s assert (class (a), "ClassificationPartitionedModel"); 723s assert ({a.X, a.Y, a.ModelParameters.KernelFunction}, {x, y, "linear"}) 723s assert (a.ModelParameters.PolynomialOrder, 3) 723s assert (isempty (a.Trained{1}.Alpha), false) 723s assert (isempty (a.Trained{1}.Beta), true) 723s ***** error fitcsvm () 723s ***** error fitcsvm (ones (4,1)) 723s ***** error 723s fitcsvm (ones (4,2), ones (4, 1), 'KFold') 723s ***** error 723s fitcsvm (ones (4,2), ones (3, 1)) 723s ***** error 723s fitcsvm (ones (4,2), ones (3, 1), 'KFold', 2) 723s ***** error 723s fitcsvm (ones (4,2), ones (4, 1), "CrossVal", 2) 723s ***** error 723s fitcsvm (ones (4,2), ones (4, 1), "CrossVal", 'a') 723s ***** error ... 723s fitcsvm (ones (4,2), ones (4, 1), "KFold", 10, "Holdout", 0.3) 723s 14 tests, 14 passed, 0 known failure, 0 skipped 723s [inst/hmmgenerate.m] 723s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/hmmgenerate.m 723s ***** test 723s len = 25; 723s transprob = [0.8, 0.2; 0.4, 0.6]; 723s outprob = [0.2, 0.4, 0.4; 0.7, 0.2, 0.1]; 723s [sequence, states] = hmmgenerate (len, transprob, outprob); 723s assert (length (sequence), len); 723s assert (length (states), len); 723s assert (min (sequence) >= 1); 723s assert (max (sequence) <= columns (outprob)); 723s assert (min (states) >= 1); 723s assert (max (states) <= rows (transprob)); 723s ***** test 723s len = 25; 723s transprob = [0.8, 0.2; 0.4, 0.6]; 723s outprob = [0.2, 0.4, 0.4; 0.7, 0.2, 0.1]; 723s symbols = {"A", "B", "C"}; 723s statenames = {"One", "Two"}; 723s [sequence, states] = hmmgenerate (len, transprob, outprob, ... 723s "symbols", symbols, "statenames", statenames); 723s assert (length (sequence), len); 723s assert (length (states), len); 723s assert (strcmp (sequence, "A") + strcmp (sequence, "B") + ... 723s strcmp (sequence, "C") == ones (1, len)); 723s assert (strcmp (states, "One") + strcmp (states, "Two") == ones (1, len)); 723s 2 tests, 2 passed, 0 known failure, 0 skipped 723s [inst/princomp.m] 723s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/princomp.m 723s ***** shared COEFF,SCORE,latent,tsquare,m,x,R,V,lambda,i,S,F 723s ***** test 723s x=[7 4 3 723s 4 1 8 723s 6 3 5 723s 8 6 1 723s 8 5 7 723s 7 2 9 723s 5 3 3 723s 9 5 8 723s 7 4 5 723s 8 2 2]; 723s R = corrcoef (x); 723s [V, lambda] = eig (R); 723s [~, i] = sort(diag(lambda), "descend"); #arrange largest PC first 723s S = V(:, i) * diag(sqrt(diag(lambda)(i))); 723s ## contribution of first 2 PCs to each original variable 723s ***** assert(diag(S(:, 1:2)*S(:, 1:2)'), [0.8662; 0.8420; 0.9876], 1E-4); 723s B = V(:, i) * diag( 1./ sqrt(diag(lambda)(i))); 723s F = zscore(x)*B; 723s [COEFF,SCORE,latent,tsquare] = princomp(zscore(x, 1)); 723s ***** assert(tsquare,sumsq(F, 2),1E4*eps); 723s ***** test 723s x=[1,2,3;2,1,3]'; 723s [COEFF,SCORE,latent,tsquare] = princomp(x); 723s m=[sqrt(2),sqrt(2);sqrt(2),-sqrt(2);-2*sqrt(2),0]/2; 723s m(:,1) = m(:,1)*sign(COEFF(1,1)); 723s m(:,2) = m(:,2)*sign(COEFF(1,2)); 723s ***** assert(COEFF,m(1:2,:),10*eps); 723s ***** assert(SCORE,-m,10*eps); 723s ***** assert(latent,[1.5;.5],10*eps); 723s ***** assert(tsquare,[4;4;4]/3,10*eps); 723s ***** test 723s x=x'; 723s [COEFF,SCORE,latent,tsquare] = princomp(x); 723s m=[sqrt(2),sqrt(2),0;-sqrt(2),sqrt(2),0;0,0,2]/2; 723s m(:,1) = m(:,1)*sign(COEFF(1,1)); 723s m(:,2) = m(:,2)*sign(COEFF(1,2)); 723s m(:,3) = m(:,3)*sign(COEFF(3,3)); 723s ***** assert(COEFF,m,10*eps); 723s ***** assert(SCORE(:,1),-m(1:2,1),10*eps); 723s ***** assert(SCORE(:,2:3),zeros(2),10*eps); 723s ***** assert(latent,[1;0;0],10*eps); 723s ***** assert(tsquare,[0.5;0.5],10*eps) 723s ***** test 723s [COEFF,SCORE,latent,tsquare] = princomp(x, "econ"); 723s ***** assert(COEFF,m(:, 1),10*eps); 723s ***** assert(SCORE,-m(1:2,1),10*eps); 723s ***** assert(latent,[1],10*eps); 723s ***** assert(tsquare,[0.5;0.5],10*eps) 723s 19 tests, 19 passed, 0 known failure, 0 skipped 723s [inst/confusionmat.m] 723s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/confusionmat.m 723s ***** test 723s Yt = [8 5 6 8 5 3 1 6 4 2 5 3 1 4]'; 723s Yp = [8 5 6 8 5 2 3 4 4 5 5 7 2 6]'; 723s C = [0 1 1 0 0 0 0 0; 0 0 0 0 1 0 0 0; 0 1 0 0 0 0 1 0; 0 0 0 1 0 1 0 0; ... 723s 0 0 0 0 3 0 0 0; 0 0 0 1 0 1 0 0; 0 0 0 0 0 0 0 0; 0 0 0 0 0 0 0 2]; 723s assert (confusionmat (Yt, Yp), C) 723s 1 test, 1 passed, 0 known failure, 0 skipped 723s [inst/tabulate.m] 723s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/tabulate.m 723s ***** demo 723s ## Generate a frequency table for a vector of data in a cell array 723s load patients 723s 723s ## Display the first seven entries of the Gender variable 723s gender = Gender(1:7) 723s 723s ## Compute the equency table that shows the number and 723s ## percentage of Male and Female patients 723s tabulate (Gender) 723s ***** demo 723s ## Create a frequency table for a vector of positive integers 723s load patients 723s 723s ## Display the first seven entries of the Gender variable 723s height = Height(1:7) 723s 723s ## Create a frequency table that shows, in its second and third columns, 723s ## the number and percentage of patients with a particular height. 723s table = tabulate (Height); 723s 723s ## Display the first and last seven entries of the frequency table 723s first = table(1:7,:) 723s 723s last = table(end-6:end,:) 723s ***** demo 723s ## Create a frequency table from a character array 723s load carsmall 723s 723s ## Tabulate the data in the Origin variable, which shows the 723s ## country of origin of each car in the data set 723s tabulate (Origin) 723s ***** demo 723s ## Create a frequency table from a numeric vector with NaN values 723s load carsmall 723s 723s ## The carsmall dataset contains measurements of 100 cars 723s total_cars = length (MPG) 723s ## For six cars, the MPG value is missing 723s missingMPG = length (MPG(isnan (MPG))) 723s 723s ## Create a frequency table using MPG 723s tabulate (MPG) 723s table = tabulate (MPG); 723s 723s ## Only 94 cars were used 723s valid_cars = sum (table(:,2)) 723s ***** test 723s load patients 723s table = tabulate (Gender); 723s assert (table{1,1}, "Male"); 723s assert (table{2,1}, "Female"); 723s assert (table{1,2}, 47); 723s assert (table{2,2}, 53); 723s ***** test 723s load patients 723s table = tabulate (Height); 723s assert (table(end-4,:), [68, 15, 15]); 723s assert (table(end-3,:), [69, 8, 8]); 723s assert (table(end-2,:), [70, 11, 11]); 723s assert (table(end-1,:), [71, 10, 10]); 723s assert (table(end,:), [72, 4, 4]); 723s ***** error tabulate (ones (3)) 723s ***** error tabulate ({1, 2, 3, 4}) 723s ***** error ... 723s tabulate ({"a", "b"; "a", "c"}) 723s 5 tests, 5 passed, 0 known failure, 0 skipped 723s [inst/friedman.m] 723s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/friedman.m 723s ***** demo 723s load popcorn; 723s friedman (popcorn, 3); 723s ***** demo 723s load popcorn; 723s [p, atab] = friedman (popcorn, 3, "off"); 723s disp (p); 723s ***** test 723s popcorn = [5.5, 4.5, 3.5; 5.5, 4.5, 4.0; 6.0, 4.0, 3.0; ... 723s 6.5, 5.0, 4.0; 7.0, 5.5, 5.0; 7.0, 5.0, 4.5]; 723s [p, atab] = friedman (popcorn, 3, "off"); 723s assert (p, 0.001028853354594794, 1e-14); 723s assert (atab{2,2}, 99.75, 1e-14); 723s assert (atab{2,3}, 2, 0); 723s assert (atab{2,4}, 49.875, 1e-14); 723s assert (atab{2,5}, 13.75862068965517, 1e-14); 723s assert (atab{2,6}, 0.001028853354594794, 1e-14); 723s assert (atab{3,2}, 0.08333333333333215, 1e-14); 723s assert (atab{3,4}, 0.04166666666666607, 1e-14); 723s assert (atab{4,3}, 12, 0); 723s ***** test 723s popcorn = [5.5, 4.5, 3.5; 5.5, 4.5, 4.0; 6.0, 4.0, 3.0; ... 723s 6.5, 5.0, 4.0; 7.0, 5.5, 5.0; 7.0, 5.0, 4.5]; 723s [p, atab, stats] = friedman (popcorn, 3, "off"); 723s assert (atab{5,2}, 116, 0); 723s assert (atab{5,3}, 17, 0); 723s assert (stats.source, "friedman"); 723s assert (stats.n, 2); 723s assert (stats.meanranks, [8, 4.75, 2.25], 0); 723s assert (stats.sigma, 2.692582403567252, 1e-14); 723s 2 tests, 2 passed, 0 known failure, 0 skipped 723s [inst/rmmissing.m] 723s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/rmmissing.m 723s ***** assert (rmmissing ([1,NaN,3]), [1,3]) 723s ***** assert (rmmissing ('abcd f'), 'abcdf') 723s ***** assert (rmmissing ({'xxx','','xyz'}), {'xxx','xyz'}) 723s ***** assert (rmmissing ({'xxx','';'xyz','yyy'}), {'xyz','yyy'}) 723s ***** assert (rmmissing ({'xxx','';'xyz','yyy'}, 2), {'xxx';'xyz'}) 723s ***** assert (rmmissing ([1,2;NaN,2]), [1,2]) 723s ***** assert (rmmissing ([1,2;NaN,2], 2), [2,2]') 723s ***** assert (rmmissing ([1,2;NaN,4;NaN,NaN],"MinNumMissing", 2), [1,2;NaN,4]) 723s ***** test 723s x = [1:6]; 723s x([2,4]) = NaN; 723s [~, idx] = rmmissing (x); 723s assert (idx, logical ([0, 1, 0, 1, 0, 0])); 723s assert (class(idx), 'logical'); 723s x = reshape (x, [2, 3]); 723s [~, idx] = rmmissing (x); 723s assert (idx, logical ([0; 1])); 723s assert (class(idx), 'logical'); 723s [~, idx] = rmmissing (x, 2); 723s assert (idx, logical ([1, 1, 0])); 723s assert (class(idx), 'logical'); 723s [~, idx] = rmmissing (x, 1, "MinNumMissing", 2); 723s assert (idx, logical ([0; 1])); 723s assert (class(idx), 'logical'); 723s [~, idx] = rmmissing (x, 2, "MinNumMissing", 2); 723s assert (idx, logical ([0, 0, 0])); 723s assert (class(idx), 'logical'); 723s ***** assert (rmmissing (single ([1 2 NaN; 3 4 5])), single ([3 4 5])) 723s ***** assert (rmmissing (logical (ones (3))), logical (ones (3))) 723s ***** assert (rmmissing (int32 (ones (3))), int32 (ones (3))) 723s ***** assert (rmmissing (uint32 (ones (3))), uint32 (ones (3))) 723s ***** assert (rmmissing ({1, 2, 3}), {1, 2, 3}) 723s ***** assert (rmmissing ([struct, struct, struct]), [struct, struct, struct]) 724s ***** assert (rmmissing ([]), []) 724s ***** assert (rmmissing (ones (1,0)), ones (1,0)) 724s ***** assert (rmmissing (ones (1,0), 1), ones (1,0)) 724s ***** assert (rmmissing (ones (1,0), 2), ones (1,0)) 724s ***** assert (rmmissing (ones (0,1)), ones (0,1)) 724s ***** assert (rmmissing (ones (0,1), 1), ones (0,1)) 724s ***** assert (rmmissing (ones (0,1), 2), ones (0,1)) 724s ***** error rmmissing (ones (0,1,2)) 724s ***** error rmmissing () 724s ***** error rmmissing (ones(2,2,2)) 724s ***** error rmmissing ([1 2; 3 4], 5) 724s ***** error rmmissing ([1 2; 3 4], "XXX", 1) 724s ***** error <'MinNumMissing'> rmmissing ([1 2; 3 4], 2, "MinNumMissing", -2) 724s ***** error <'MinNumMissing'> rmmissing ([1 2; 3 4], "MinNumMissing", 3.8) 724s ***** error <'MinNumMissing'> rmmissing ([1 2; 3 4], "MinNumMissing", [1 2 3]) 724s ***** error <'MinNumMissing'> rmmissing ([1 2; 3 4], "MinNumMissing", 'xxx') 724s 31 tests, 31 passed, 0 known failure, 0 skipped 724s [inst/pca.m] 724s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/pca.m 724s ***** shared COEFF,SCORE,latent,tsquare,m,x,R,V,lambda,i,S,F 724s ***** test 724s x=[7 4 3 724s 4 1 8 724s 6 3 5 724s 8 6 1 724s 8 5 7 724s 7 2 9 724s 5 3 3 724s 9 5 8 724s 7 4 5 724s 8 2 2]; 724s R = corrcoef (x); 724s [V, lambda] = eig (R); 724s [~, i] = sort(diag(lambda), "descend"); #arrange largest PC first 724s S = V(:, i) * diag(sqrt(diag(lambda)(i))); 724s ***** assert(diag(S(:, 1:2)*S(:, 1:2)'), [0.8662; 0.8420; 0.9876], 1E-4); #contribution of first 2 PCs to each original variable 724s B = V(:, i) * diag( 1./ sqrt(diag(lambda)(i))); 724s F = zscore(x)*B; 724s [COEFF,SCORE,latent,tsquare] = pca(zscore(x, 1)); 724s ***** assert(tsquare,sumsq(F, 2),1E4*eps); 724s ***** test 724s x=[1,2,3;2,1,3]'; 724s [COEFF,SCORE,latent,tsquare] = pca(x, "Economy", false); 724s m=[sqrt(2),sqrt(2);sqrt(2),-sqrt(2);-2*sqrt(2),0]/2; 724s m(:,1) = m(:,1)*sign(COEFF(1,1)); 724s m(:,2) = m(:,2)*sign(COEFF(1,2)); 724s ***** assert(COEFF,m(1:2,:),10*eps); 724s ***** assert(SCORE,-m,10*eps); 724s ***** assert(latent,[1.5;.5],10*eps); 724s ***** assert(tsquare,[4;4;4]/3,10*eps); 724s [COEFF,SCORE,latent,tsquare] = pca(x, "Economy", false, "weights", [1 2 1], "variableweights", "variance"); 724s ***** assert(COEFF, [0.632455532033676 -0.632455532033676; 0.741619848709566 0.741619848709566], 10*eps); 724s ***** assert(SCORE, [-0.622019449426284 0.959119380657905; -0.505649896847432 -0.505649896847431; 1.633319243121148 0.052180413036957], 10*eps); 724s ***** assert(latent, [1.783001790889027; 0.716998209110974], 10*eps); 724s ***** xtest assert(tsquare, [1.5; 0.5; 1.5], 10*eps); #currently, [4; 2; 4]/3 is actually returned; see comments above 724s !!!!! known failure 724s ASSERT errors for: assert (tsquare,[1.5; 0.5; 1.5],10 * eps) 724s 724s Location | Observed | Expected | Reason 724s (1) 1.3333 1.5 Abs err 0.16667 exceeds tol 2.2204e-15 by 0.2 724s (2) 0.66667 0.5 Abs err 0.16667 exceeds tol 2.2204e-15 by 0.2 724s (3) 1.3333 1.5 Abs err 0.16667 exceeds tol 2.2204e-15 by 0.2 724s ***** test 724s x=x'; 724s [COEFF,SCORE,latent,tsquare] = pca(x, "Economy", false); 724s m=[sqrt(2),sqrt(2),0;-sqrt(2),sqrt(2),0;0,0,2]/2; 724s m(:,1) = m(:,1)*sign(COEFF(1,1)); 724s m(:,2) = m(:,2)*sign(COEFF(1,2)); 724s m(:,3) = m(:,3)*sign(COEFF(3,3)); 724s ***** assert(COEFF,m,10*eps); 724s ***** assert(SCORE(:,1),-m(1:2,1),10*eps); 724s ***** assert(SCORE(:,2:3),zeros(2),10*eps); 724s ***** assert(latent,[1;0;0],10*eps); 724s ***** assert(tsquare,[0.5;0.5],10*eps) 724s ***** test 724s [COEFF,SCORE,latent,tsquare] = pca(x); 724s ***** assert(COEFF,m(:, 1),10*eps); 724s ***** assert(SCORE,-m(1:2,1),10*eps); 724s ***** assert(latent,[1],10*eps); 724s ***** assert(tsquare,[0.5;0.5],10*eps) 724s ***** error pca([1 2; 3 4], "Algorithm", "xxx") 724s ***** error <'centered' requires a boolean value> pca([1 2; 3 4], "Centered", "xxx") 724s ***** error pca([1 2; 3 4], "NumComponents", -4) 724s ***** error pca([1 2; 3 4], "Rows", 1) 724s ***** error pca([1 2; 3 4], "Weights", [1 2 3]) 724s ***** error pca([1 2; 3 4], "Weights", [-1 2]) 724s ***** error pca([1 2; 3 4], "VariableWeights", [-1 2]) 724s ***** error pca([1 2; 3 4], "VariableWeights", "xxx") 724s ***** error pca([1 2; 3 4], "XXX", 1) 724s 32 tests, 31 passed, 1 known failure, 0 skipped 724s [inst/manova1.m] 724s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/manova1.m 724s ***** demo 724s load carbig 724s [d,p] = manova1([MPG, Acceleration, Weight, Displacement], Origin) 724s ***** test 724s load carbig 724s [d,p] = manova1([MPG, Acceleration, Weight, Displacement], Origin); 724s assert (d, 3); 724s assert (p, [0, 3.140583347827075e-07, 0.007510999577743149, ... 724s 0.1934100745898493]', [1e-12, 1e-12, 1e-12, 1e-12]'); 724s ***** test 724s load carbig 724s [d,p] = manova1([MPG, Acceleration, Weight], Origin); 724s assert (d, 2); 724s assert (p, [0, 0.00516082975137544, 0.1206528056514453]', ... 724s [1e-12, 1e-12, 1e-12]'); 724s 2 tests, 2 passed, 0 known failure, 0 skipped 724s [inst/gmdistribution.m] 724s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/gmdistribution.m 724s ***** test 724s mu = eye(2); 724s Sigma = eye(2); 724s GM = gmdistribution (mu, Sigma); 724s density = GM.pdf ([0 0; 1 1]); 724s assert (density(1) - density(2), 0, 1e-6); 724s 724s [idx, nlogl, P, logpdf,M] = cluster (GM, eye(2)); 724s assert (idx, [1; 2]); 724s [idx2,nlogl2,P2,logpdf2] = GM.cluster (eye(2)); 724s assert (nlogl - nlogl2, 0, 1e-6); 724s [idx3,nlogl3,P3] = cluster (GM, eye(2)); 724s assert (P - P3, zeros (2), 1e-6); 724s [idx4,nlogl4] = cluster (GM, eye(2)); 724s assert (size (nlogl4), [1 1]); 724s idx5 = cluster (GM, eye(2)); 724s assert (idx - idx5, zeros (2,1)); 724s 724s D = GM.mahal ([1;0]); 724s assert (D - M(1,:), zeros (1,2), 1e-6); 724s 724s P = GM.posterior ([0 1]); 724s assert (P - P2(2,:), zeros (1,2), 1e-6); 724s 724s R = GM.random(20); 724s assert (size(R), [20, 2]); 724s 724s R = GM.random(); 724s assert (size(R), [1, 2]); 724s 1 test, 1 passed, 0 known failure, 0 skipped 724s [inst/pdist2.m] 724s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/pdist2.m 724s ***** shared x, y, xx 724s x = [1, 1, 1; 2, 2, 2; 3, 3, 3]; 724s y = [0, 0, 0; 1, 2, 3; 0, 2, 4; 4, 7, 1]; 724s xx = [1 2 3; 4 5 6; 7 8 9; 3 2 1]; 724s ***** test 724s d = sqrt([3, 5, 11, 45; 12, 2, 8, 30; 27, 5, 11, 21]); 724s assert (pdist2 (x, y), d); 724s ***** test 724s d = [5.1962, 2.2361, 3.3166, 6.7082; ... 724s 3.4641, 2.2361, 3.3166, 5.4772]; 724s i = [3, 1, 1, 1; 2, 3, 3, 2]; 724s [D, I] = pdist2 (x, y, "euclidean", "largest", 2); 724s assert ({D, I}, {d, i}, 1e-4); 724s ***** test 724s d = [1.7321, 1.4142, 2.8284, 4.5826; ... 724s 3.4641, 2.2361, 3.3166, 5.4772]; 724s i = [1, 2, 2, 3;2, 1, 1, 2]; 724s [D, I] = pdist2 (x, y, "euclidean", "smallest", 2); 724s assert ({D, I}, {d, i}, 1e-4); 724s ***** test 724s yy = [1 2 3;5 6 7;9 5 1]; 724s d = [0, 6.1644, 5.3852; 1.4142, 6.9282, 8.7750; ... 724s 3.7417, 7.0711, 9.9499; 6.1644, 10.4881, 10.3441]; 724s i = [2, 4, 4; 3, 2, 2; 1, 3, 3; 4, 1, 1]; 724s [D, I] = pdist2 (y, yy, "euclidean", "smallest", 4); 724s assert ({D, I}, {d, i}, 1e-4); 724s ***** test 724s yy = [1 2 3;5 6 7;9 5 1]; 724s d = [0, 38, 29; 2, 48, 77; 14, 50, 99; 38, 110, 107]; 724s i = [2, 4, 4; 3, 2, 2; 1, 3, 3; 4, 1, 1]; 724s [D, I] = pdist2 (y, yy, "squaredeuclidean", "smallest", 4); 724s assert ({D, I}, {d, i}, 1e-4); 724s ***** test 724s yy = [1 2 3;5 6 7;9 5 1]; 724s d = [0, 3.3256, 2.7249; 0.7610, 3.3453, 4.4799; ... 724s 1.8514, 3.3869, 5.0703; 2.5525, 5.0709, 5.1297]; 724s i = [2, 2, 4; 3, 4, 2; 1, 3, 1; 4, 1, 3]; 724s [D, I] = pdist2 (y, yy, "seuclidean", "smallest", 4); 724s assert ({D, I}, {d, i}, 1e-4); 724s ***** test 724s d = [2.1213, 4.2426, 6.3640; 1.2247, 2.4495, 4.4159; ... 724s 3.2404, 4.8990, 6.8191; 2.7386, 4.2426, 6.1237]; 724s assert (pdist2 (y, x, "mahalanobis"), d, 1e-4); 724s ***** test 724s xx = [1, 3, 4; 3, 5, 4; 8, 7, 6]; 724s d = [1.3053, 1.8257, 15.0499; 1.3053, 3.3665, 16.5680]; 724s i = [2, 2, 2; 3, 4, 4]; 724s [D, I] = pdist2 (y, xx, "mahalanobis", "smallest", 2); 724s assert ({D, I}, {d, i}, 1e-4); 724s ***** test 724s d = [2.5240, 4.1633, 17.3638; 2.0905, 3.9158, 17.0147]; 724s i = [1, 1, 3; 4, 3, 1]; 724s [D, I] = pdist2 (y, xx, "mahalanobis", "largest", 2); 724s assert ({D, I}, {d, i}, 1e-4); 724s ***** test 724s d = [3, 3, 5, 9; 6, 2, 4, 8; 9, 3, 5, 7]; 724s assert (pdist2 (x, y, "cityblock"), d); 724s ***** test 724s d = [1, 2, 3, 6; 2, 1, 2, 5; 3, 2, 3, 4]; 724s assert (pdist2 (x, y, "chebychev"), d); 724s ***** test 724s d = repmat ([NaN, 0.0742, 0.2254, 0.1472], [3, 1]); 724s assert (pdist2 (x, y, "cosine"), d, 1e-4); 724s ***** test 724s yy = [1 2 3;5 6 7;9 5 1]; 724s d = [0, 0, 0.5; 0, 0, 2; 1.5, 1.5, 2; NaN, NaN, NaN]; 724s i = [2, 2, 4; 3, 3, 2; 4, 4, 3; 1, 1, 1]; 724s [D, I] = pdist2 (y, yy, "correlation", "smallest", 4); 724s assert ({D, I}, {d, i}, eps); 724s [D, I] = pdist2 (y, yy, "spearman", "smallest", 4); 724s assert ({D, I}, {d, i}, eps); 724s ***** test 724s d = [1, 2/3, 1, 1; 1, 2/3, 1, 1; 1, 2/3, 2/3, 2/3]; 724s i = [1, 1, 1, 2; 2, 2, 3, 3; 3, 3, 2, 1]; 724s [D, I] = pdist2 (x, y, "hamming", "largest", 4); 724s assert ({D, I}, {d, i}, eps); 724s [D, I] = pdist2 (x, y, "jaccard", "largest", 4); 724s assert ({D, I}, {d, i}, eps); 724s ***** test 724s xx = [1, 2, 3, 4; 2, 3, 4, 5; 3, 4, 5, 6]; 724s yy = [1, 2, 2, 3; 2, 3, 3, 4]; 724s [D, I] = pdist2 (x, y, "euclidean", "Smallest", 4); 724s eucldist = @(v,m) sqrt(sumsq(repmat(v,rows(m),1)-m,2)); 724s [d, i] = pdist2 (x, y, eucldist, "Smallest", 4); 724s assert ({D, I}, {d, i}); 724s ***** warning ... 724s pdist2 (xx, xx, "mahalanobis"); 724s ***** error pdist2 (1) 724s ***** error ... 724s pdist2 (ones (4, 5), ones (4)) 724s ***** error ... 724s pdist2 (ones (4, 2, 3), ones (3, 2)) 724s ***** error ... 724s pdist2 (ones (3), ones (3), "euclidean", "Largest") 724s ***** error ... 724s pdist2 (ones (3), ones (3), "minkowski", 3, "Largest") 724s ***** error ... 724s pdist2 (ones (3), ones (3), "minkowski", 3, "large", 4) 724s ***** error ... 724s pdist2 (ones (3), ones (3), "minkowski", 3, "Largest", 4, "smallest", 5) 724s ***** error ... 724s [d, i] = pdist2(ones (3), ones (3), "minkowski", 3) 724s ***** error ... 724s pdist2 (ones (3), ones (3), "seuclidean", 3) 724s ***** error ... 724s pdist2 (ones (3), ones (3), "seuclidean", [1, -1, 3]) 724s ***** error ... 724s pdist2 (ones (3), eye (3), "mahalanobis", eye(2)) 724s ***** error ... 724s pdist2 (ones (3), eye (3), "mahalanobis", ones(3)) 724s ***** error ... 724s pdist2 (ones (3), eye (3), "minkowski", 0) 724s ***** error ... 724s pdist2 (ones (3), eye (3), "minkowski", -5) 724s ***** error ... 724s pdist2 (ones (3), eye (3), "minkowski", [1, 2]) 724s ***** error ... 724s pdist2 (ones (3), ones (3), @(v,m) sqrt(repmat(v,rows(m),1)-m,2)) 724s ***** error ... 724s pdist2 (ones (3), ones (3), @(v,m) sqrt(sum(sumsq(repmat(v,rows(m),1)-m,2)))) 724s 33 tests, 33 passed, 0 known failure, 0 skipped 724s [inst/boxplot.m] 724s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/boxplot.m 724s ***** demo 724s axis ([0, 3]); 724s randn ("seed", 1); # for reproducibility 724s girls = randn (10, 1) * 5 + 140; 724s randn ("seed", 2); # for reproducibility 724s boys = randn (13, 1) * 8 + 135; 724s boxplot ({girls, boys}); 724s set (gca (), "xtick", [1 2], "xticklabel", {"girls", "boys"}) 724s title ("Grade 3 heights"); 724s ***** demo 724s randn ("seed", 7); # for reproducibility 724s A = randn (10, 1) * 5 + 140; 724s randn ("seed", 8); # for reproducibility 724s B = randn (25, 1) * 8 + 135; 724s randn ("seed", 9); # for reproducibility 724s C = randn (20, 1) * 6 + 165; 724s data = [A; B; C]; 724s groups = [(ones (10, 1)); (ones (25, 1) * 2); (ones (20, 1) * 3)]; 724s labels = {"Team A", "Team B", "Team C"}; 724s pos = [2, 1, 3]; 724s boxplot (data, groups, "Notch", "on", "Labels", labels, "Positions", pos, ... 724s "OutlierTags", "on", "BoxStyle", "filled"); 724s title ("Example of Group splitting with paired vectors"); 724s ***** demo 724s randn ("seed", 1); # for reproducibility 724s data = randn (100, 9); 724s boxplot (data, "notch", "on", "boxstyle", "filled", ... 724s "colors", "ygcwkmb", "whisker", 1.2); 724s title ("Example of different colors specified with characters"); 724s ***** demo 724s randn ("seed", 5); # for reproducibility 724s data = randn (100, 13); 724s colors = [0.7 0.7 0.7; ... 724s 0.0 0.4 0.9; ... 724s 0.7 0.4 0.3; ... 724s 0.7 0.1 0.7; ... 724s 0.8 0.7 0.4; ... 724s 0.1 0.8 0.5; ... 724s 0.9 0.9 0.2]; 724s boxplot (data, "notch", "on", "boxstyle", "filled", ... 724s "colors", colors, "whisker", 1.3, "boxwidth", "proportional"); 724s title ("Example of different colors specified as RGB values"); 724s ***** error boxplot ("a") 724s ***** error boxplot ({[1 2 3], "a"}) 724s ***** error boxplot ([1 2 3], 1, {2, 3}) 724s ***** error boxplot ([1 2 3], {"a", "b"}) 724s ***** error <'Notch' input argument accepts> boxplot ([1:10], "notch", "any") 724s ***** error boxplot ([1:10], "notch", i) 724s ***** error boxplot ([1:10], "notch", {}) 724s ***** error boxplot (1, "symbol", 1) 724s ***** error <'Orientation' input argument accepts only> boxplot (1, "orientation", "diagonal") 724s ***** error boxplot (1, "orientation", {}) 724s ***** error <'Whisker' input argument accepts only> boxplot (1, "whisker", "a") 724s ***** error <'Whisker' input argument accepts only> boxplot (1, "whisker", [1 3]) 724s ***** error <'OutlierTags' input argument accepts only> boxplot (3, "OutlierTags", "maybe") 724s ***** error boxplot (3, "OutlierTags", {}) 724s ***** error <'Sample_IDs' input argument accepts only> boxplot (1, "sample_IDs", 1) 724s ***** error <'BoxWidth' input argument accepts only> boxplot (1, "boxwidth", 2) 724s ***** error <'BoxWidth' input argument accepts only> boxplot (1, "boxwidth", "anything") 724s ***** error <'Widths' input argument accepts only> boxplot (5, "widths", "a") 724s ***** error <'Widths' input argument accepts only> boxplot (5, "widths", [1:4]) 724s ***** error <'Widths' input argument accepts only> boxplot (5, "widths", []) 724s ***** error <'CapWidths' input argument accepts only> boxplot (5, "capwidths", "a") 724s ***** error <'CapWidths' input argument accepts only> boxplot (5, "capwidths", [1:4]) 724s ***** error <'CapWidths' input argument accepts only> boxplot (5, "capwidths", []) 724s ***** error <'BoxStyle' input argument accepts only> boxplot (1, "Boxstyle", 1) 724s ***** error <'BoxStyle' input argument accepts only> boxplot (1, "Boxstyle", "garbage") 724s ***** error <'Positions' input argument accepts only> boxplot (1, "positions", "aa") 724s ***** error <'Labels' input argument accepts only> boxplot (3, "labels", [1 5]) 724s ***** error <'Colors' input argument accepts only> boxplot (1, "colors", {}) 724s ***** error <'Colors' input argument accepts only> boxplot (2, "colors", [1 2 3 4]) 724s ***** error boxplot (randn (10, 3), 'Sample_IDs', {"a", "b"}) 724s ***** error boxplot (rand (3, 3), [1 2]) 724s ***** test 724s hf = figure ("visible", "off"); 724s unwind_protect 724s [a, b] = boxplot (rand (10, 3)); 724s assert (size (a), [7, 3]); 724s assert (numel (b.box), 3); 724s assert (numel (b.whisker), 12); 724s assert (numel (b.median), 3); 724s unwind_protect_cleanup 724s close (hf); 724s end_unwind_protect 725s ***** test 725s hf = figure ("visible", "off"); 725s unwind_protect 725s [~, b] = boxplot (rand (10, 3), "BoxStyle", "filled", "colors", "ybc"); 725s assert (numel (b.box_fill), 3); 725s unwind_protect_cleanup 725s close (hf); 725s end_unwind_protect 725s ***** test 725s hf = figure ("visible", "off"); 725s unwind_protect 725s hold on 725s [a, b] = boxplot (rand (10, 3)); 725s assert (ishold, true); 725s unwind_protect_cleanup 725s close (hf); 725s end_unwind_protect 725s 34 tests, 34 passed, 0 known failure, 0 skipped 725s [inst/ppplot.m] 725s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/ppplot.m 725s ***** test 725s hf = figure ("visible", "off"); 725s unwind_protect 725s ppplot ([2 3 3 4 4 5 6 5 6 7 8 9 8 7 8 9 0 8 7 6 5 4 6 13 8 15 9 9]); 725s unwind_protect_cleanup 725s close (hf); 725s end_unwind_protect 725s ***** error ppplot () 725s ***** error ppplot (ones (2,2)) 725s ***** error ppplot (1, 2) 725s ***** error ppplot ([1 2 3 4], 2) 725s 5 tests, 5 passed, 0 known failure, 0 skipped 725s [inst/kstest2.m] 725s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/kstest2.m 725s ***** error kstest2 ([1,2,3,4,5,5]) 725s ***** error kstest2 (ones(2,4), [1,2,3,4,5,5]) 726s ***** error kstest2 ([2,3,5,7,3+3i], [1,2,3,4,5,5]) 726s ***** error kstest2 ([2,3,4,5,6],[3;5;7;8;7;6;5],"tail") 726s ***** error kstest2 ([2,3,4,5,6],[3;5;7;8;7;6;5],"tail", "whatever") 726s ***** error kstest2 ([2,3,4,5,6],[3;5;7;8;7;6;5],"badoption", 0.51) 726s ***** error kstest2 ([2,3,4,5,6],[3;5;7;8;7;6;5],"tail", 0) 726s ***** error kstest2 ([2,3,4,5,6],[3;5;7;8;7;6;5],"alpha", 0) 726s ***** error kstest2 ([2,3,4,5,6],[3;5;7;8;7;6;5],"alpha", NaN) 726s ***** error kstest2 ([NaN,NaN,NaN,NaN,NaN],[3;5;7;8;7;6;5],"tail", "unequal") 726s ***** test 726s load examgrades 726s [h, p] = kstest2 (grades(:,1), grades(:,2)); 726s assert (h, false); 726s assert (p, 0.1222791870137312, 1e-14); 726s ***** test 726s load examgrades 726s [h, p] = kstest2 (grades(:,1), grades(:,2), "tail", "larger"); 726s assert (h, false); 726s assert (p, 0.1844421391011258, 1e-14); 726s ***** test 726s load examgrades 726s [h, p] = kstest2 (grades(:,1), grades(:,2), "tail", "smaller"); 726s assert (h, false); 726s assert (p, 0.06115357930171663, 1e-14); 726s ***** test 726s load examgrades 726s [h, p] = kstest2 (grades(:,1), grades(:,2), "tail", "smaller", "alpha", 0.1); 726s assert (h, true); 726s assert (p, 0.06115357930171663, 1e-14); 726s 14 tests, 14 passed, 0 known failure, 0 skipped 726s [inst/randsample.m] 726s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/randsample.m 726s ***** test 726s n = 20; 726s k = 5; 726s x = randsample(n, k); 726s assert (size(x), [1 k]); 726s x = randsample(n, k, true); 726s assert (size(x), [1 k]); 726s x = randsample(n, k, false); 726s assert (size(x), [1 k]); 726s x = randsample(n, k, true, ones(n, 1)); 726s assert (size(x), [1 k]); 726s x = randsample(1:n, k); 726s assert (size(x), [1 k]); 726s x = randsample(1:n, k, true); 726s assert (size(x), [1 k]); 726s x = randsample(1:n, k, false); 726s assert (size(x), [1 k]); 726s x = randsample(1:n, k, true, ones(n, 1)); 726s assert (size(x), [1 k]); 726s x = randsample((1:n)', k); 726s assert (size(x), [k 1]); 726s x = randsample((1:n)', k, true); 726s assert (size(x), [k 1]); 726s x = randsample((1:n)', k, false); 726s assert (size(x), [k 1]); 726s x = randsample((1:n)', k, true, ones(n, 1)); 726s assert (size(x), [k 1]); 726s n = 10; 726s k = 100; 726s x = randsample(n, k, true, 1:n); 726s assert (size(x), [1 k]); 726s x = randsample((1:n)', k, true); 726s assert (size(x), [k 1]); 726s x = randsample(k, k, false, 1:k); 726s assert (size(x), [1 k]); 726s 1 test, 1 passed, 0 known failure, 0 skipped 726s [inst/anovan.m] 726s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/anovan.m 726s ***** demo 726s 726s # Two-sample unpaired test on independent samples (equivalent to Student's 726s # t-test). Note that the absolute value of t-statistic can be obtained by 726s # taking the square root of the reported F statistic. In this example, 726s # t = sqrt (1.44) = 1.20. 726s 726s score = [54 23 45 54 45 43 34 65 77 46 65]'; 726s gender = {"male" "male" "male" "male" "male" "female" "female" "female" ... 726s "female" "female" "female"}'; 726s 726s [P, ATAB, STATS] = anovan (score, gender, "display", "on", "varnames", "gender"); 726s ***** demo 726s 726s # Two-sample paired test on dependent or matched samples equivalent to a 726s # paired t-test. As for the first example, the t-statistic can be obtained by 726s # taking the square root of the reported F statistic. Note that the interaction 726s # between treatment x subject was dropped from the full model by assigning 726s # subject as a random factor ('). 726s 726s score = [4.5 5.6; 3.7 6.4; 5.3 6.4; 5.4 6.0; 3.9 5.7]'; 726s treatment = {"before" "after"; "before" "after"; "before" "after"; 726s "before" "after"; "before" "after"}'; 726s subject = {"GS" "GS"; "JM" "JM"; "HM" "HM"; "JW" "JW"; "PS" "PS"}'; 726s 726s [P, ATAB, STATS] = anovan (score(:), {treatment(:), subject(:)}, ... 726s "model", "full", "random", 2, "sstype", 2, ... 726s "varnames", {"treatment", "subject"}, ... 726s "display", "on"); 726s ***** demo 726s 726s # One-way ANOVA on the data from a study on the strength of structural beams, 726s # in Hogg and Ledolter (1987) Engineering Statistics. New York: MacMillan 726s 726s strength = [82 86 79 83 84 85 86 87 74 82 ... 726s 78 75 76 77 79 79 77 78 82 79]'; 726s alloy = {"st","st","st","st","st","st","st","st", ... 726s "al1","al1","al1","al1","al1","al1", ... 726s "al2","al2","al2","al2","al2","al2"}'; 726s 726s [P, ATAB, STATS] = anovan (strength, alloy, "display", "on", ... 726s "varnames", "alloy"); 726s ***** demo 726s 726s # One-way repeated measures ANOVA on the data from a study on the number of 726s # words recalled by 10 subjects for three time condtions, in Loftus & Masson 726s # (1994) Psychon Bull Rev. 1(4):476-490, Table 2. Note that the interaction 726s # between seconds x subject was dropped from the full model by assigning 726s # subject as a random factor ('). 726s 726s words = [10 13 13; 6 8 8; 11 14 14; 22 23 25; 16 18 20; ... 726s 15 17 17; 1 1 4; 12 15 17; 9 12 12; 8 9 12]; 726s seconds = [1 2 5; 1 2 5; 1 2 5; 1 2 5; 1 2 5; ... 726s 1 2 5; 1 2 5; 1 2 5; 1 2 5; 1 2 5;]; 726s subject = [ 1 1 1; 2 2 2; 3 3 3; 4 4 4; 5 5 5; ... 726s 6 6 6; 7 7 7; 8 8 8; 9 9 9; 10 10 10]; 726s 726s [P, ATAB, STATS] = anovan (words(:), {seconds(:), subject(:)}, ... 726s "model", "full", "random", 2, "sstype", 2, ... 726s "display", "on", "varnames", {"seconds", "subject"}); 726s ***** demo 726s 726s # Balanced two-way ANOVA with interaction on the data from a study of popcorn 726s # brands and popper types, in Hogg and Ledolter (1987) Engineering Statistics. 726s # New York: MacMillan 726s 726s popcorn = [5.5, 4.5, 3.5; 5.5, 4.5, 4.0; 6.0, 4.0, 3.0; ... 726s 6.5, 5.0, 4.0; 7.0, 5.5, 5.0; 7.0, 5.0, 4.5]; 726s brands = {"Gourmet", "National", "Generic"; ... 726s "Gourmet", "National", "Generic"; ... 726s "Gourmet", "National", "Generic"; ... 726s "Gourmet", "National", "Generic"; ... 726s "Gourmet", "National", "Generic"; ... 726s "Gourmet", "National", "Generic"}; 726s popper = {"oil", "oil", "oil"; "oil", "oil", "oil"; "oil", "oil", "oil"; ... 726s "air", "air", "air"; "air", "air", "air"; "air", "air", "air"}; 726s 726s [P, ATAB, STATS] = anovan (popcorn(:), {brands(:), popper(:)}, ... 726s "display", "on", "model", "full", ... 726s "varnames", {"brands", "popper"}); 726s ***** demo 726s 726s # Unbalanced two-way ANOVA (2x2) on the data from a study on the effects of 726s # gender and having a college degree on salaries of company employees, 726s # in Maxwell, Delaney and Kelly (2018): Chapter 7, Table 15 726s 726s salary = [24 26 25 24 27 24 27 23 15 17 20 16, ... 726s 25 29 27 19 18 21 20 21 22 19]'; 726s gender = {"f" "f" "f" "f" "f" "f" "f" "f" "f" "f" "f" "f"... 726s "m" "m" "m" "m" "m" "m" "m" "m" "m" "m"}'; 726s degree = [1 1 1 1 1 1 1 1 0 0 0 0 1 1 1 0 0 0 0 0 0 0]'; 726s 726s [P, ATAB, STATS] = anovan (salary, {gender, degree}, "model", "full", ... 726s "sstype", 3, "display", "on", "varnames", ... 726s {"gender", "degree"}); 726s ***** demo 726s 726s # Unbalanced two-way ANOVA (3x2) on the data from a study of the effect of 726s # adding sugar and/or milk on the tendency of coffee to make people babble, 726s # in from Navarro (2019): 16.10 726s 726s sugar = {"real" "fake" "fake" "real" "real" "real" "none" "none" "none" ... 726s "fake" "fake" "fake" "real" "real" "real" "none" "none" "fake"}'; 726s milk = {"yes" "no" "no" "yes" "yes" "no" "yes" "yes" "yes" ... 726s "no" "no" "yes" "no" "no" "no" "no" "no" "yes"}'; 726s babble = [4.6 4.4 3.9 5.6 5.1 5.5 3.9 3.5 3.7... 726s 5.6 4.7 5.9 6.0 5.4 6.6 5.8 5.3 5.7]'; 726s 726s [P, ATAB, STATS] = anovan (babble, {sugar, milk}, "model", "full", ... 726s "sstype", 3, "display", "on", ... 726s "varnames", {"sugar", "milk"}); 726s ***** demo 726s 726s # Unbalanced three-way ANOVA (3x2x2) on the data from a study of the effects 726s # of three different drugs, biofeedback and diet on patient blood pressure, 726s # adapted* from Maxwell, Delaney and Kelly (2018): Chapter 8, Table 12 726s # * Missing values introduced to make the sample sizes unequal to test the 726s # calculation of different types of sums-of-squares 726s 726s drug = {"X" "X" "X" "X" "X" "X" "X" "X" "X" "X" "X" "X" ... 726s "X" "X" "X" "X" "X" "X" "X" "X" "X" "X" "X" "X"; 726s "Y" "Y" "Y" "Y" "Y" "Y" "Y" "Y" "Y" "Y" "Y" "Y" ... 726s "Y" "Y" "Y" "Y" "Y" "Y" "Y" "Y" "Y" "Y" "Y" "Y"; 726s "Z" "Z" "Z" "Z" "Z" "Z" "Z" "Z" "Z" "Z" "Z" "Z" ... 726s "Z" "Z" "Z" "Z" "Z" "Z" "Z" "Z" "Z" "Z" "Z" "Z"}; 726s feedback = [1 1 1 1 1 1 1 1 1 1 1 1 0 0 0 0 0 0 0 0 0 0 0 0; 726s 1 1 1 1 1 1 1 1 1 1 1 1 0 0 0 0 0 0 0 0 0 0 0 0; 726s 1 1 1 1 1 1 1 1 1 1 1 1 0 0 0 0 0 0 0 0 0 0 0 0]; 726s diet = [0 0 0 0 0 0 1 1 1 1 1 1 0 0 0 0 0 0 1 1 1 1 1 1; 726s 0 0 0 0 0 0 1 1 1 1 1 1 0 0 0 0 0 0 1 1 1 1 1 1; 726s 0 0 0 0 0 0 1 1 1 1 1 1 0 0 0 0 0 0 1 1 1 1 1 1]; 726s BP = [170 175 165 180 160 158 161 173 157 152 181 190 ... 726s 173 194 197 190 176 198 164 190 169 164 176 175; 726s 186 194 201 215 219 209 164 166 159 182 187 174 ... 726s 189 194 217 206 199 195 171 173 196 199 180 NaN; 726s 180 187 199 170 204 194 162 184 183 156 180 173 ... 726s 202 228 190 206 224 204 205 199 170 160 NaN NaN]; 726s 726s [P, ATAB, STATS] = anovan (BP(:), {drug(:), feedback(:), diet(:)}, ... 726s "model", "full", "sstype", 3, ... 726s "display", "on", ... 726s "varnames", {"drug", "feedback", "diet"}); 726s ***** demo 726s 726s # Balanced three-way ANOVA (2x2x2) with one of the factors being a blocking 726s # factor. The data is from a randomized block design study on the effects 726s # of antioxidant treatment on glutathione-S-transferase (GST) levels in 726s # different mouse strains, from Festing (2014), ILAR Journal, 55(3):427-476. 726s # Note that all interactions involving block were dropped from the full model 726s # by assigning block as a random factor ('). 726s 726s measurement = [444 614 423 625 408 856 447 719 ... 726s 764 831 586 782 609 1002 606 766]'; 726s strain= {"NIH","NIH","BALB/C","BALB/C","A/J","A/J","129/Ola","129/Ola", ... 726s "NIH","NIH","BALB/C","BALB/C","A/J","A/J","129/Ola","129/Ola"}'; 726s treatment={"C" "T" "C" "T" "C" "T" "C" "T" "C" "T" "C" "T" "C" "T" "C" "T"}'; 726s block = [1 1 1 1 1 1 1 1 2 2 2 2 2 2 2 2]'; 726s 726s [P, ATAB, STATS] = anovan (measurement/10, {strain, treatment, block}, ... 726s "sstype", 2, "model", "full", "random", 3, ... 726s "display", "on", ... 726s "varnames", {"strain", "treatment", "block"}); 726s ***** demo 726s 726s # One-way ANCOVA on data from a study of the additive effects of species 726s # and temperature on chirpy pulses of crickets, from Stitch, The Worst Stats 726s # Text eveR 726s 726s pulse = [67.9 65.1 77.3 78.7 79.4 80.4 85.8 86.6 87.5 89.1 ... 726s 98.6 100.8 99.3 101.7 44.3 47.2 47.6 49.6 50.3 51.8 ... 726s 60 58.5 58.9 60.7 69.8 70.9 76.2 76.1 77 77.7 84.7]'; 726s temp = [20.8 20.8 24 24 24 24 26.2 26.2 26.2 26.2 28.4 ... 726s 29 30.4 30.4 17.2 18.3 18.3 18.3 18.9 18.9 20.4 ... 726s 21 21 22.1 23.5 24.2 25.9 26.5 26.5 26.5 28.6]'; 726s species = {"ex" "ex" "ex" "ex" "ex" "ex" "ex" "ex" "ex" "ex" "ex" ... 726s "ex" "ex" "ex" "niv" "niv" "niv" "niv" "niv" "niv" "niv" ... 726s "niv" "niv" "niv" "niv" "niv" "niv" "niv" "niv" "niv" "niv"}; 726s 726s [P, ATAB, STATS] = anovan (pulse, {species, temp}, "model", "linear", ... 726s "continuous", 2, "sstype", "h", "display", "on", ... 726s "varnames", {"species", "temp"}); 726s ***** demo 726s 726s # Factorial ANCOVA on data from a study of the effects of treatment and 726s # exercise on stress reduction score after adjusting for age. Data from R 726s # datarium package). 726s 726s score = [95.6 82.2 97.2 96.4 81.4 83.6 89.4 83.8 83.3 85.7 ... 726s 97.2 78.2 78.9 91.8 86.9 84.1 88.6 89.8 87.3 85.4 ... 726s 81.8 65.8 68.1 70.0 69.9 75.1 72.3 70.9 71.5 72.5 ... 726s 84.9 96.1 94.6 82.5 90.7 87.0 86.8 93.3 87.6 92.4 ... 726s 100. 80.5 92.9 84.0 88.4 91.1 85.7 91.3 92.3 87.9 ... 726s 91.7 88.6 75.8 75.7 75.3 82.4 80.1 86.0 81.8 82.5]'; 726s treatment = {"yes" "yes" "yes" "yes" "yes" "yes" "yes" "yes" "yes" "yes" ... 726s "yes" "yes" "yes" "yes" "yes" "yes" "yes" "yes" "yes" "yes" ... 726s "yes" "yes" "yes" "yes" "yes" "yes" "yes" "yes" "yes" "yes" ... 726s "no" "no" "no" "no" "no" "no" "no" "no" "no" "no" ... 726s "no" "no" "no" "no" "no" "no" "no" "no" "no" "no" ... 726s "no" "no" "no" "no" "no" "no" "no" "no" "no" "no"}'; 726s exercise = {"lo" "lo" "lo" "lo" "lo" "lo" "lo" "lo" "lo" "lo" ... 726s "mid" "mid" "mid" "mid" "mid" "mid" "mid" "mid" "mid" "mid" ... 726s "hi" "hi" "hi" "hi" "hi" "hi" "hi" "hi" "hi" "hi" ... 726s "lo" "lo" "lo" "lo" "lo" "lo" "lo" "lo" "lo" "lo" ... 726s "mid" "mid" "mid" "mid" "mid" "mid" "mid" "mid" "mid" "mid" ... 726s "hi" "hi" "hi" "hi" "hi" "hi" "hi" "hi" "hi" "hi"}'; 726s age = [59 65 70 66 61 65 57 61 58 55 62 61 60 59 55 57 60 63 62 57 ... 726s 58 56 57 59 59 60 55 53 55 58 68 62 61 54 59 63 60 67 60 67 ... 726s 75 54 57 62 65 60 58 61 65 57 56 58 58 58 52 53 60 62 61 61]'; 726s 726s [P, ATAB, STATS] = anovan (score, {treatment, exercise, age}, ... 726s "model", [1 0 0; 0 1 0; 0 0 1; 1 1 0], ... 726s "continuous", 3, "sstype", "h", "display", "on", ... 726s "varnames", {"treatment", "exercise", "age"}); 726s ***** demo 726s 726s # Unbalanced one-way ANOVA with custom, orthogonal contrasts. The statistics 726s # relating to the contrasts are shown in the table of model parameters, and 726s # can be retrieved from the STATS.coeffs output. 726s 726s dv = [ 8.706 10.362 11.552 6.941 10.983 10.092 6.421 14.943 15.931 ... 726s 22.968 18.590 16.567 15.944 21.637 14.492 17.965 18.851 22.891 ... 726s 22.028 16.884 17.252 18.325 25.435 19.141 21.238 22.196 18.038 ... 726s 22.628 31.163 26.053 24.419 32.145 28.966 30.207 29.142 33.212 ... 726s 25.694 ]'; 726s g = [1 1 1 1 1 1 1 1 2 2 2 2 2 3 3 3 3 3 3 3 3 ... 726s 4 4 4 4 4 4 4 5 5 5 5 5 5 5 5 5]'; 726s C = [ 0.4001601 0.3333333 0.5 0.0 726s 0.4001601 0.3333333 -0.5 0.0 726s 0.4001601 -0.6666667 0.0 0.0 726s -0.6002401 0.0000000 0.0 0.5 726s -0.6002401 0.0000000 0.0 -0.5]; 726s 726s [P,ATAB, STATS] = anovan (dv, g, "contrasts", C, "varnames", "score", ... 726s "alpha", 0.05, "display", "on"); 726s ***** demo 726s 726s # One-way ANOVA with the linear model fit by weighted least squares to 726s # account for heteroskedasticity. In this example, the variance appears 726s # proportional to the outcome, so weights have been estimated by initially 726s # fitting the model without weights and regressing the absolute residuals on 726s # the fitted values. Although this data could have been analysed by Welch's 726s # ANOVA test, the approach here can generalize to ANOVA models with more than 726s # one factor. 726s 726s g = [1, 1, 1, 1, 1, 1, 1, 1, ... 726s 2, 2, 2, 2, 2, 2, 2, 2, ... 726s 3, 3, 3, 3, 3, 3, 3, 3]'; 726s y = [13, 16, 16, 7, 11, 5, 1, 9, ... 726s 10, 25, 66, 43, 47, 56, 6, 39, ... 726s 11, 39, 26, 35, 25, 14, 24, 17]'; 726s 726s [P,ATAB,STATS] = anovan(y, g, "display", "off"); 726s fitted = STATS.X * STATS.coeffs(:,1); # fitted values 726s b = polyfit (fitted, abs (STATS.resid), 1); 726s v = polyval (b, fitted); # Variance as a function of the fitted values 726s figure("Name", "Regression of the absolute residuals on the fitted values"); 726s plot (fitted, abs (STATS.resid),'ob');hold on; plot(fitted,v,'-r'); hold off; 726s xlabel("Fitted values"); ylabel("Absolute residuals"); 726s 726s [P,ATAB,STATS] = anovan (y, g, "weights", v.^-1); 726s ***** test 726s score = [54 23 45 54 45 43 34 65 77 46 65]'; 726s gender = {'male' 'male' 'male' 'male' 'male' 'female' 'female' 'female' ... 726s 'female' 'female' 'female'}'; 726s 726s [P, T, STATS] = anovan (score,gender,'display','off'); 726s assert (P(1), 0.2612876773271042, 1e-09); # compared to p calculated by MATLAB anovan 726s assert (sqrt(T{2,6}), abs(1.198608733288208), 1e-09); # compared to abs(t) calculated from sqrt(F) by MATLAB anovan 726s assert (P(1), 0.2612876773271047, 1e-09); # compared to p calculated by MATLAB ttest2 726s assert (sqrt(T{2,6}), abs(-1.198608733288208), 1e-09); # compared to abs(t) calculated by MATLAB ttest2 726s ***** test 726s score = [4.5 5.6; 3.7 6.4; 5.3 6.4; 5.4 6.0; 3.9 5.7]'; 726s treatment = {'before' 'after'; 'before' 'after'; 'before' 'after'; 726s 'before' 'after'; 'before' 'after'}'; 726s subject = {'GS' 'GS'; 'JM' 'JM'; 'HM' 'HM'; 'JW' 'JW'; 'PS' 'PS'}'; 726s 726s [P, ATAB, STATS] = anovan (score(:),{treatment(:),subject(:)},'display','off','sstype',2); 726s assert (P(1), 0.016004356735364, 1e-09); # compared to p calculated by MATLAB anovan 726s assert (sqrt(ATAB{2,6}), abs(4.00941576558195), 1e-09); # compared to abs(t) calculated from sqrt(F) by MATLAB anovan 726s assert (P(1), 0.016004356735364, 1e-09); # compared to p calculated by MATLAB ttest2 726s assert (sqrt(ATAB{2,6}), abs(-4.00941576558195), 1e-09); # compared to abs(t) calculated by MATLAB ttest2 726s ***** test 726s strength = [82 86 79 83 84 85 86 87 74 82 ... 726s 78 75 76 77 79 79 77 78 82 79]'; 726s alloy = {'st','st','st','st','st','st','st','st', ... 726s 'al1','al1','al1','al1','al1','al1', ... 726s 'al2','al2','al2','al2','al2','al2'}'; 726s 726s [P, ATAB, STATS] = anovan (strength,{alloy},'display','off'); 726s assert (P(1), 0.000152643638830491, 1e-09); 726s assert (ATAB{2,6}, 15.4, 1e-09); 726s ***** test 726s words = [10 13 13; 6 8 8; 11 14 14; 22 23 25; 16 18 20; ... 726s 15 17 17; 1 1 4; 12 15 17; 9 12 12; 8 9 12]; 726s subject = [ 1 1 1; 2 2 2; 3 3 3; 4 4 4; 5 5 5; ... 726s 6 6 6; 7 7 7; 8 8 8; 9 9 9; 10 10 10]; 726s seconds = [1 2 5; 1 2 5; 1 2 5; 1 2 5; 1 2 5; ... 726s 1 2 5; 1 2 5; 1 2 5; 1 2 5; 1 2 5;]; 726s 726s [P, ATAB, STATS] = anovan (words(:),{seconds(:),subject(:)},'model','full','random',2,'sstype',2,'display','off'); 726s assert (P(1), 1.51865926758752e-07, 1e-09); 726s assert (ATAB{2,2}, 52.2666666666667, 1e-09); 726s assert (ATAB{3,2}, 942.533333333333, 1e-09); 726s assert (ATAB{4,2}, 11.0666666666667, 1e-09); 726s ***** test 726s popcorn = [5.5, 4.5, 3.5; 5.5, 4.5, 4.0; 6.0, 4.0, 3.0; ... 726s 6.5, 5.0, 4.0; 7.0, 5.5, 5.0; 7.0, 5.0, 4.5]; 726s brands = {'Gourmet', 'National', 'Generic'; ... 726s 'Gourmet', 'National', 'Generic'; ... 726s 'Gourmet', 'National', 'Generic'; ... 726s 'Gourmet', 'National', 'Generic'; ... 726s 'Gourmet', 'National', 'Generic'; ... 726s 'Gourmet', 'National', 'Generic'}; 726s popper = {'oil', 'oil', 'oil'; 'oil', 'oil', 'oil'; 'oil', 'oil', 'oil'; ... 726s 'air', 'air', 'air'; 'air', 'air', 'air'; 'air', 'air', 'air'}; 726s 726s [P, ATAB, STATS] = anovan (popcorn(:),{brands(:),popper(:)},'display','off','model','full'); 726s assert (P(1), 7.67895738278171e-07, 1e-09); 726s assert (P(2), 0.000100373896304998, 1e-09); 726s assert (P(3), 0.746215396636649, 1e-09); 726s assert (ATAB{2,6}, 56.7, 1e-09); 726s assert (ATAB{3,6}, 32.4, 1e-09); 726s assert (ATAB{4,6}, 0.29999999999997, 1e-09); 726s ***** test 726s salary = [24 26 25 24 27 24 27 23 15 17 20 16, ... 726s 25 29 27 19 18 21 20 21 22 19]'; 726s gender = {'f' 'f' 'f' 'f' 'f' 'f' 'f' 'f' 'f' 'f' 'f' 'f'... 726s 'm' 'm' 'm' 'm' 'm' 'm' 'm' 'm' 'm' 'm'}'; 726s degree = [1 1 1 1 1 1 1 1 0 0 0 0 1 1 1 0 0 0 0 0 0 0]'; 726s 726s [P, ATAB, STATS] = anovan (salary,{gender,degree},'model','full','sstype',1,'display','off'); 726s assert (P(1), 0.747462549227232, 1e-09); 726s assert (P(2), 1.03809316857694e-08, 1e-09); 726s assert (P(3), 0.523689833702691, 1e-09); 726s assert (ATAB{2,2}, 0.296969696969699, 1e-09); 726s assert (ATAB{3,2}, 272.391841491841, 1e-09); 726s assert (ATAB{4,2}, 1.17482517482512, 1e-09); 726s assert (ATAB{5,2}, 50.0000000000001, 1e-09); 726s [P, ATAB, STATS] = anovan (salary,{degree,gender},'model','full','sstype',1,'display','off'); 726s assert (P(1), 2.53445097305047e-08, 1e-09); 726s assert (P(2), 0.00388133678528749, 1e-09); 726s assert (P(3), 0.523689833702671, 1e-09); 726s assert (ATAB{2,2}, 242.227272727273, 1e-09); 726s assert (ATAB{3,2}, 30.4615384615384, 1e-09); 726s assert (ATAB{4,2}, 1.17482517482523, 1e-09); 726s assert (ATAB{5,2}, 50.0000000000001, 1e-09); 726s [P, ATAB, STATS] = anovan (salary,{gender,degree},'model','full','sstype',2,'display','off'); 726s assert (P(1), 0.00388133678528743, 1e-09); 726s assert (P(2), 1.03809316857694e-08, 1e-09); 726s assert (P(3), 0.523689833702691, 1e-09); 726s assert (ATAB{2,2}, 30.4615384615385, 1e-09); 726s assert (ATAB{3,2}, 272.391841491841, 1e-09); 726s assert (ATAB{4,2}, 1.17482517482512, 1e-09); 726s assert (ATAB{5,2}, 50.0000000000001, 1e-09); 726s [P, ATAB, STATS] = anovan (salary,{gender,degree},'model','full','sstype',3,'display','off'); 726s assert (P(1), 0.00442898146583742, 1e-09); 726s assert (P(2), 1.30634252053587e-08, 1e-09); 726s assert (P(3), 0.523689833702691, 1e-09); 726s assert (ATAB{2,2}, 29.3706293706294, 1e-09); 726s assert (ATAB{3,2}, 264.335664335664, 1e-09); 726s assert (ATAB{4,2}, 1.17482517482512, 1e-09); 726s assert (ATAB{5,2}, 50.0000000000001, 1e-09); 726s ***** test 726s sugar = {'real' 'fake' 'fake' 'real' 'real' 'real' 'none' 'none' 'none' ... 726s 'fake' 'fake' 'fake' 'real' 'real' 'real' 'none' 'none' 'fake'}'; 726s milk = {'yes' 'no' 'no' 'yes' 'yes' 'no' 'yes' 'yes' 'yes' ... 726s 'no' 'no' 'yes' 'no' 'no' 'no' 'no' 'no' 'yes'}'; 726s babble = [4.6 4.4 3.9 5.6 5.1 5.5 3.9 3.5 3.7... 726s 5.6 4.7 5.9 6.0 5.4 6.6 5.8 5.3 5.7]'; 726s 726s [P, ATAB, STATS] = anovan (babble,{sugar,milk},'model','full','sstype',1,'display','off'); 726s assert (P(1), 0.0108632139833963, 1e-09); 726s assert (P(2), 0.0810606976703546, 1e-09); 726s assert (P(3), 0.00175433329935627, 1e-09); 726s assert (ATAB{2,2}, 3.55752380952381, 1e-09); 726s assert (ATAB{3,2}, 0.956108477471702, 1e-09); 726s assert (ATAB{4,2}, 5.94386771300448, 1e-09); 726s assert (ATAB{5,2}, 3.1625, 1e-09); 726s [P, ATAB, STATS] = anovan (babble,{milk,sugar},'model','full','sstype',1,'display','off'); 726s assert (P(1), 0.0373333189297505, 1e-09); 726s assert (P(2), 0.017075098787169, 1e-09); 726s assert (P(3), 0.00175433329935627, 1e-09); 726s assert (ATAB{2,2}, 1.444, 1e-09); 726s assert (ATAB{3,2}, 3.06963228699552, 1e-09); 726s assert (ATAB{4,2}, 5.94386771300448, 1e-09); 726s assert (ATAB{5,2}, 3.1625, 1e-09); 726s [P, ATAB, STATS] = anovan (babble,{sugar,milk},'model','full','sstype',2,'display','off'); 726s assert (P(1), 0.017075098787169, 1e-09); 726s assert (P(2), 0.0810606976703546, 1e-09); 726s assert (P(3), 0.00175433329935627, 1e-09); 726s assert (ATAB{2,2}, 3.06963228699552, 1e-09); 726s assert (ATAB{3,2}, 0.956108477471702, 1e-09); 726s assert (ATAB{4,2}, 5.94386771300448, 1e-09); 726s assert (ATAB{5,2}, 3.1625, 1e-09); 726s [P, ATAB, STATS] = anovan (babble,{sugar,milk},'model','full','sstype',3,'display','off'); 726s assert (P(1), 0.0454263063473954, 1e-09); 726s assert (P(2), 0.0746719907091438, 1e-09); 726s assert (P(3), 0.00175433329935627, 1e-09); 726s assert (ATAB{2,2}, 2.13184977578476, 1e-09); 726s assert (ATAB{3,2}, 1.00413461538462, 1e-09); 726s assert (ATAB{4,2}, 5.94386771300448, 1e-09); 726s assert (ATAB{5,2}, 3.1625, 1e-09); 726s ***** test 726s drug = {'X' 'X' 'X' 'X' 'X' 'X' 'X' 'X' 'X' 'X' 'X' 'X' ... 726s 'X' 'X' 'X' 'X' 'X' 'X' 'X' 'X' 'X' 'X' 'X' 'X'; 726s 'Y' 'Y' 'Y' 'Y' 'Y' 'Y' 'Y' 'Y' 'Y' 'Y' 'Y' 'Y' ... 726s 'Y' 'Y' 'Y' 'Y' 'Y' 'Y' 'Y' 'Y' 'Y' 'Y' 'Y' 'Y'; 726s 'Z' 'Z' 'Z' 'Z' 'Z' 'Z' 'Z' 'Z' 'Z' 'Z' 'Z' 'Z' ... 726s 'Z' 'Z' 'Z' 'Z' 'Z' 'Z' 'Z' 'Z' 'Z' 'Z' 'Z' 'Z'}; 726s feedback = [1 1 1 1 1 1 1 1 1 1 1 1 0 0 0 0 0 0 0 0 0 0 0 0; 726s 1 1 1 1 1 1 1 1 1 1 1 1 0 0 0 0 0 0 0 0 0 0 0 0; 726s 1 1 1 1 1 1 1 1 1 1 1 1 0 0 0 0 0 0 0 0 0 0 0 0]; 726s diet = [0 0 0 0 0 0 1 1 1 1 1 1 0 0 0 0 0 0 1 1 1 1 1 1; 726s 0 0 0 0 0 0 1 1 1 1 1 1 0 0 0 0 0 0 1 1 1 1 1 1; 726s 0 0 0 0 0 0 1 1 1 1 1 1 0 0 0 0 0 0 1 1 1 1 1 1]; 726s BP = [170 175 165 180 160 158 161 173 157 152 181 190 ... 726s 173 194 197 190 176 198 164 190 169 164 176 175; 726s 186 194 201 215 219 209 164 166 159 182 187 174 ... 726s 189 194 217 206 199 195 171 173 196 199 180 NaN; 726s 180 187 199 170 204 194 162 184 183 156 180 173 ... 726s 202 228 190 206 224 204 205 199 170 160 NaN NaN]; 726s 726s [P, ATAB, STATS] = anovan (BP(:),{drug(:),feedback(:),diet(:)},'model','full','sstype', 1,'display','off'); 726s assert (P(1), 7.02561843825325e-05, 1e-09); 726s assert (P(2), 0.000425806013389362, 1e-09); 726s assert (P(3), 6.16780773446401e-07, 1e-09); 726s assert (P(4), 0.261347622678438, 1e-09); 726s assert (P(5), 0.0542278432357043, 1e-09); 726s assert (P(6), 0.590353225626655, 1e-09); 726s assert (P(7), 0.0861628249564267, 1e-09); 726s assert (ATAB{2,2}, 3614.70355731226, 1e-09); 726s assert (ATAB{3,2}, 2227.46639771024, 1e-09); 726s assert (ATAB{4,2}, 5008.25614451819, 1e-09); 726s assert (ATAB{5,2}, 437.066007908781, 1e-09); 726s assert (ATAB{6,2}, 976.180770397332, 1e-09); 726s assert (ATAB{7,2}, 46.616653365254, 1e-09); 726s assert (ATAB{8,2}, 814.345251396648, 1e-09); 726s assert (ATAB{9,2}, 9065.8, 1e-09); 726s [P, ATAB, STATS] = anovan (BP(:),{drug(:),feedback(:),diet(:)},'model','full','sstype',2,'display','off'); 726s assert (P(1), 9.4879638470754e-05, 1e-09); 726s assert (P(2), 0.00124177666315809, 1e-09); 726s assert (P(3), 6.86162012732911e-07, 1e-09); 726s assert (P(4), 0.260856132341256, 1e-09); 726s assert (P(5), 0.0523758623892078, 1e-09); 726s assert (P(6), 0.590353225626655, 1e-09); 726s assert (P(7), 0.0861628249564267, 1e-09); 726s assert (ATAB{2,2}, 3481.72176560122, 1e-09); 726s assert (ATAB{3,2}, 1837.08812970469, 1e-09); 726s assert (ATAB{4,2}, 4957.20277938622, 1e-09); 726s assert (ATAB{5,2}, 437.693674777847, 1e-09); 726s assert (ATAB{6,2}, 988.431929811402, 1e-09); 726s assert (ATAB{7,2}, 46.616653365254, 1e-09); 726s assert (ATAB{8,2}, 814.345251396648, 1e-09); 726s assert (ATAB{9,2}, 9065.8, 1e-09); 726s [P, ATAB, STATS] = anovan (BP(:),{drug(:),feedback(:),diet(:)},'model','full','sstype', 3,'display','off'); 726s assert (P(1), 0.000106518678028207, 1e-09); 726s assert (P(2), 0.00125371366571508, 1e-09); 726s assert (P(3), 5.30813260778464e-07, 1e-09); 726s assert (P(4), 0.308353667232981, 1e-09); 726s assert (P(5), 0.0562901327343161, 1e-09); 726s assert (P(6), 0.599091042141092, 1e-09); 726s assert (P(7), 0.0861628249564267, 1e-09); 726s assert (ATAB{2,2}, 3430.88156424581, 1e-09); 726s assert (ATAB{3,2}, 1833.68031496063, 1e-09); 726s assert (ATAB{4,2}, 5080.48346456693, 1e-09); 726s assert (ATAB{5,2}, 382.07709497207, 1e-09); 726s assert (ATAB{6,2}, 963.037988826813, 1e-09); 726s assert (ATAB{7,2}, 44.4519685039322, 1e-09); 726s assert (ATAB{8,2}, 814.345251396648, 1e-09); 726s assert (ATAB{9,2}, 9065.8, 1e-09); 727s ***** test 727s measurement = [444 614 423 625 408 856 447 719 ... 727s 764 831 586 782 609 1002 606 766]'; 727s strain= {'NIH','NIH','BALB/C','BALB/C','A/J','A/J','129/Ola','129/Ola', ... 727s 'NIH','NIH','BALB/C','BALB/C','A/J','A/J','129/Ola','129/Ola'}'; 727s treatment={'C' 'T' 'C' 'T' 'C' 'T' 'C' 'T' 'C' 'T' 'C' 'T' 'C' 'T' 'C' 'T'}'; 727s block = [1 1 1 1 1 1 1 1 2 2 2 2 2 2 2 2]'; 727s 727s [P, ATAB, STATS] = anovan (measurement/10,{strain,treatment,block},'model','full','random',3,'display','off'); 727s assert (P(1), 0.0914352969909372, 1e-09); 727s assert (P(2), 5.04077373924908e-05, 1e-09); 727s assert (P(4), 0.0283196918836667, 1e-09); 727s assert (ATAB{2,2}, 286.132500000002, 1e-09); 727s assert (ATAB{3,2}, 2275.29, 1e-09); 727s assert (ATAB{4,2}, 1242.5625, 1e-09); 727s assert (ATAB{5,2}, 495.905000000001, 1e-09); 727s assert (ATAB{6,2}, 207.007499999999, 1e-09); 727s ***** test 727s pulse = [67.9 65.1 77.3 78.7 79.4 80.4 85.8 86.6 87.5 89.1 ... 727s 98.6 100.8 99.3 101.7 44.3 47.2 47.6 49.6 50.3 51.8 ... 727s 60 58.5 58.9 60.7 69.8 70.9 76.2 76.1 77 77.7 84.7]'; 727s temp = [20.8 20.8 24 24 24 24 26.2 26.2 26.2 26.2 28.4 ... 727s 29 30.4 30.4 17.2 18.3 18.3 18.3 18.9 18.9 20.4 ... 727s 21 21 22.1 23.5 24.2 25.9 26.5 26.5 26.5 28.6]'; 727s species = {'ex' 'ex' 'ex' 'ex' 'ex' 'ex' 'ex' 'ex' 'ex' 'ex' 'ex' ... 727s 'ex' 'ex' 'ex' 'niv' 'niv' 'niv' 'niv' 'niv' 'niv' 'niv' ... 727s 'niv' 'niv' 'niv' 'niv' 'niv' 'niv' 'niv' 'niv' 'niv' 'niv'}; 727s 727s [P, ATAB, STATS] = anovan (pulse,{species,temp},'model','linear','continuous',2,'sstype','h','display','off'); 727s assert (P(1), 6.27153318786007e-14, 1e-09); 727s assert (P(2), 2.48773241196644e-25, 1e-09); 727s assert (ATAB{2,2}, 598.003953318404, 1e-09); 727s assert (ATAB{3,2}, 4376.08256843712, 1e-09); 727s assert (ATAB{4,2}, 89.3498685376726, 1e-09); 727s assert (ATAB{2,6}, 187.399388123951, 1e-09); 727s assert (ATAB{3,6}, 1371.35413763454, 1e-09); 727s ***** test 727s score = [95.6 82.2 97.2 96.4 81.4 83.6 89.4 83.8 83.3 85.7 ... 727s 97.2 78.2 78.9 91.8 86.9 84.1 88.6 89.8 87.3 85.4 ... 727s 81.8 65.8 68.1 70.0 69.9 75.1 72.3 70.9 71.5 72.5 ... 727s 84.9 96.1 94.6 82.5 90.7 87.0 86.8 93.3 87.6 92.4 ... 727s 100. 80.5 92.9 84.0 88.4 91.1 85.7 91.3 92.3 87.9 ... 727s 91.7 88.6 75.8 75.7 75.3 82.4 80.1 86.0 81.8 82.5]'; 727s treatment = {'yes' 'yes' 'yes' 'yes' 'yes' 'yes' 'yes' 'yes' 'yes' 'yes' ... 727s 'yes' 'yes' 'yes' 'yes' 'yes' 'yes' 'yes' 'yes' 'yes' 'yes' ... 727s 'yes' 'yes' 'yes' 'yes' 'yes' 'yes' 'yes' 'yes' 'yes' 'yes' ... 727s 'no' 'no' 'no' 'no' 'no' 'no' 'no' 'no' 'no' 'no' ... 727s 'no' 'no' 'no' 'no' 'no' 'no' 'no' 'no' 'no' 'no' ... 727s 'no' 'no' 'no' 'no' 'no' 'no' 'no' 'no' 'no' 'no'}'; 727s exercise = {'lo' 'lo' 'lo' 'lo' 'lo' 'lo' 'lo' 'lo' 'lo' 'lo' ... 727s 'mid' 'mid' 'mid' 'mid' 'mid' 'mid' 'mid' 'mid' 'mid' 'mid' ... 727s 'hi' 'hi' 'hi' 'hi' 'hi' 'hi' 'hi' 'hi' 'hi' 'hi' ... 727s 'lo' 'lo' 'lo' 'lo' 'lo' 'lo' 'lo' 'lo' 'lo' 'lo' ... 727s 'mid' 'mid' 'mid' 'mid' 'mid' 'mid' 'mid' 'mid' 'mid' 'mid' ... 727s 'hi' 'hi' 'hi' 'hi' 'hi' 'hi' 'hi' 'hi' 'hi' 'hi'}'; 727s age = [59 65 70 66 61 65 57 61 58 55 62 61 60 59 55 57 60 63 62 57 ... 727s 58 56 57 59 59 60 55 53 55 58 68 62 61 54 59 63 60 67 60 67 ... 727s 75 54 57 62 65 60 58 61 65 57 56 58 58 58 52 53 60 62 61 61]'; 727s 727s [P, ATAB, STATS] = anovan (score,{treatment,exercise,age},'model','full','continuous',3,'sstype','h','display','off'); 727s assert (P(5), 0.9245630968248468, 1e-09); 727s assert (P(6), 0.791115159521822, 1e-09); 727s assert (P(7), 0.9296668751457956, 1e-09); 727s [P, ATAB, STATS] = anovan (score,{treatment,exercise,age},'model',[1 0 0; 0 1 0; 0 0 1; 1 1 0],'continuous',3,'sstype','h','display','off'); 727s assert (P(1), 0.00158132928938933, 1e-09); 727s assert (P(2), 2.12537505039986e-07, 1e-09); 727s assert (P(3), 0.00390292555160047, 1e-09); 727s assert (P(4), 0.0164086580775543, 1e-09); 727s assert (ATAB{2,6}, 11.0956027650549, 1e-09); 727s assert (ATAB{3,6}, 20.8195665467178, 1e-09); 727s assert (ATAB{4,6}, 9.10966630720186, 1e-09); 727s assert (ATAB{5,6}, 4.4457923698584, 1e-09); 727s ***** test 727s dv = [ 8.706 10.362 11.552 6.941 10.983 10.092 6.421 14.943 15.931 ... 727s 22.968 18.590 16.567 15.944 21.637 14.492 17.965 18.851 22.891 ... 727s 22.028 16.884 17.252 18.325 25.435 19.141 21.238 22.196 18.038 ... 727s 22.628 31.163 26.053 24.419 32.145 28.966 30.207 29.142 33.212 ... 727s 25.694 ]'; 727s g = [1 1 1 1 1 1 1 1 2 2 2 2 2 3 3 3 3 3 3 3 3 4 4 4 4 4 4 4 5 5 5 5 5 5 5 5 5]'; 727s C = [ 0.4001601 0.3333333 0.5 0.0 727s 0.4001601 0.3333333 -0.5 0.0 727s 0.4001601 -0.6666667 0.0 0.0 727s -0.6002401 0.0000000 0.0 0.5 727s -0.6002401 0.0000000 0.0 -0.5]; 727s 727s [P,ATAB,STATS] = anovan (dv,g,'contrasts',{C},'display','off'); 727s assert (STATS.coeffs(1,1), 19.4001, 1e-04); 727s assert (STATS.coeffs(2,1), -9.3297, 1e-04); 727s assert (STATS.coeffs(3,1), -5.0000, 1e-04); 727s assert (STATS.coeffs(4,1), -8.0000, 1e-04); 727s assert (STATS.coeffs(5,1), -8.0000, 1e-04); 727s assert (STATS.coeffs(1,2), 0.4831, 1e-04); 727s assert (STATS.coeffs(2,2), 0.9694, 1e-04); 727s assert (STATS.coeffs(3,2), 1.3073, 1e-04); 727s assert (STATS.coeffs(4,2), 1.6411, 1e-04); 727s assert (STATS.coeffs(5,2), 1.4507, 1e-04); 727s assert (STATS.coeffs(1,5), 40.161, 1e-03); 727s assert (STATS.coeffs(2,5), -9.624, 1e-03); 727s assert (STATS.coeffs(3,5), -3.825, 1e-03); 727s assert (STATS.coeffs(4,5), -4.875, 1e-03); 727s assert (STATS.coeffs(5,5), -5.515, 1e-03); 727s assert (STATS.coeffs(2,6), 5.74e-11, 1e-12); 727s assert (STATS.coeffs(3,6), 0.000572, 1e-06); 727s assert (STATS.coeffs(4,6), 2.86e-05, 1e-07); 727s assert (STATS.coeffs(5,6), 4.44e-06, 1e-08); 727s 12 tests, 12 passed, 0 known failure, 0 skipped 727s [inst/fitcknn.m] 727s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/fitcknn.m 727s ***** demo 727s ## Train a k-nearest neighbor classifier for k = 10 727s ## and plot the decision boundaries. 727s 727s load fisheriris 727s idx = ! strcmp (species, "setosa"); 727s X = meas(idx,3:4); 727s Y = cast (strcmpi (species(idx), "virginica"), "double"); 727s obj = fitcknn (X, Y, "Standardize", 1, "NumNeighbors", 10, "NSMethod", "exhaustive") 727s x1 = [min(X(:,1)):0.03:max(X(:,1))]; 727s x2 = [min(X(:,2)):0.02:max(X(:,2))]; 727s [x1G, x2G] = meshgrid (x1, x2); 727s XGrid = [x1G(:), x2G(:)]; 727s pred = predict (obj, XGrid); 727s gidx = logical (str2num (cell2mat (pred))); 727s 727s figure 727s scatter (XGrid(gidx,1), XGrid(gidx,2), "markerfacecolor", "magenta"); 727s hold on 727s scatter (XGrid(!gidx,1), XGrid(!gidx,2), "markerfacecolor", "red"); 727s plot (X(Y == 0, 1), X(Y == 0, 2), "ko", X(Y == 1, 1), X(Y == 1, 2), "kx"); 727s xlabel ("Petal length (cm)"); 727s ylabel ("Petal width (cm)"); 727s title ("5-Nearest Neighbor Classifier Decision Boundary"); 727s legend ({"Versicolor Region", "Virginica Region", ... 727s "Sampled Versicolor", "Sampled Virginica"}, ... 727s "location", "northwest") 727s axis tight 727s hold off 727s ***** test 727s x = [1, 2, 3; 4, 5, 6; 7, 8, 9; 3, 2, 1]; 727s y = ["a"; "a"; "b"; "b"]; 727s a = fitcknn (x, y); 727s assert (class (a), "ClassificationKNN"); 727s assert ({a.X, a.Y, a.NumNeighbors}, {x, y, 1}) 727s assert ({a.NSMethod, a.Distance}, {"kdtree", "euclidean"}) 727s assert ({a.BucketSize}, {50}) 727s ***** test 727s x = [1, 2, 3; 4, 5, 6; 7, 8, 9; 3, 2, 1]; 727s y = ["a"; "a"; "b"; "b"]; 727s a = fitcknn (x, y, "NSMethod", "exhaustive"); 727s assert (class (a), "ClassificationKNN"); 727s assert ({a.X, a.Y, a.NumNeighbors}, {x, y, 1}) 727s assert ({a.NSMethod, a.Distance}, {"exhaustive", "euclidean"}) 727s assert ({a.BucketSize}, {50}) 727s ***** test 727s x = [1, 2, 3; 4, 5, 6; 7, 8, 9; 3, 2, 1]; 727s y = ["a"; "a"; "b"; "b"]; 727s k = 10; 727s a = fitcknn (x, y, "NumNeighbors" ,k); 727s assert (class (a), "ClassificationKNN"); 727s assert ({a.X, a.Y, a.NumNeighbors}, {x, y, 10}) 727s assert ({a.NSMethod, a.Distance}, {"kdtree", "euclidean"}) 727s assert ({a.BucketSize}, {50}) 727s ***** test 727s x = ones (4, 11); 727s y = ["a"; "a"; "b"; "b"]; 727s k = 10; 727s a = fitcknn (x, y, "NumNeighbors" ,k); 727s assert (class (a), "ClassificationKNN"); 727s assert ({a.X, a.Y, a.NumNeighbors}, {x, y, 10}) 727s assert ({a.NSMethod, a.Distance}, {"exhaustive", "euclidean"}) 727s assert ({a.BucketSize}, {50}) 727s ***** test 727s x = [1, 2, 3; 4, 5, 6; 7, 8, 9; 3, 2, 1]; 727s y = ["a"; "a"; "b"; "b"]; 727s k = 10; 727s a = fitcknn (x, y, "NumNeighbors" ,k, "NSMethod", "exhaustive"); 727s assert (class (a), "ClassificationKNN"); 727s assert ({a.X, a.Y, a.NumNeighbors}, {x, y, 10}) 727s assert ({a.NSMethod, a.Distance}, {"exhaustive", "euclidean"}) 727s assert ({a.BucketSize}, {50}) 727s ***** test 727s x = [1, 2, 3; 4, 5, 6; 7, 8, 9; 3, 2, 1]; 727s y = ["a"; "a"; "b"; "b"]; 727s k = 10; 727s a = fitcknn (x, y, "NumNeighbors" ,k, "Distance", "hamming"); 727s assert (class (a), "ClassificationKNN"); 727s assert ({a.X, a.Y, a.NumNeighbors}, {x, y, 10}) 727s assert ({a.NSMethod, a.Distance}, {"exhaustive", "hamming"}) 727s assert ({a.BucketSize}, {50}) 727s ***** test 727s x = [1, 2, 3; 4, 5, 6; 7, 8, 9; 3, 2, 1]; 727s y = ["a"; "a"; "b"; "b"]; 727s weights = ones (4,1); 727s a = fitcknn (x, y, "Standardize", 1); 727s assert (class (a), "ClassificationKNN"); 727s assert ({a.X, a.Y, a.NumNeighbors}, {x, y, 1}) 727s assert ({a.NSMethod, a.Distance}, {"kdtree", "euclidean"}) 727s assert ({a.Standardize}, {true}) 727s assert ({a.Sigma}, {std(x, [], 1)}) 727s assert ({a.Mu}, {[3.75, 4.25, 4.75]}) 727s ***** test 727s x = [1, 2, 3; 4, 5, 6; 7, 8, 9; 3, 2, 1]; 727s y = ["a"; "a"; "b"; "b"]; 727s weights = ones (4,1); 727s a = fitcknn (x, y, "Standardize", false); 727s assert (class (a), "ClassificationKNN"); 727s assert ({a.X, a.Y, a.NumNeighbors}, {x, y, 1}) 727s assert ({a.NSMethod, a.Distance}, {"kdtree", "euclidean"}) 727s assert ({a.Standardize}, {false}) 727s assert ({a.Sigma}, {[]}) 727s assert ({a.Mu}, {[]}) 727s ***** test 727s x = [1, 2, 3; 4, 5, 6; 7, 8, 9; 3, 2, 1]; 727s y = ["a"; "a"; "b"; "b"]; 727s s = ones (1, 3); 727s a = fitcknn (x, y, "Scale" , s, "Distance", "seuclidean"); 727s assert (class (a), "ClassificationKNN"); 727s assert ({a.DistParameter}, {s}) 727s assert ({a.NSMethod, a.Distance}, {"exhaustive", "seuclidean"}) 727s assert ({a.BucketSize}, {50}) 727s ***** test 727s x = [1, 2, 3; 4, 5, 6; 7, 8, 9; 3, 2, 1]; 727s y = ["a"; "a"; "b"; "b"]; 727s a = fitcknn (x, y, "Exponent" , 5, "Distance", "minkowski"); 727s assert (class (a), "ClassificationKNN"); 727s assert (a.DistParameter, 5) 727s assert ({a.NSMethod, a.Distance}, {"kdtree", "minkowski"}) 727s ***** test 727s x = [1, 2, 3; 4, 5, 6; 7, 8, 9; 3, 2, 1]; 727s y = ["a"; "a"; "b"; "b"]; 727s a = fitcknn (x, y, "Exponent" , 5, "Distance", "minkowski", ... 727s "NSMethod", "exhaustive"); 727s assert (class (a), "ClassificationKNN"); 727s assert (a.DistParameter, 5) 727s assert ({a.NSMethod, a.Distance}, {"exhaustive", "minkowski"}) 727s ***** test 727s x = [1, 2, 3; 4, 5, 6; 7, 8, 9; 3, 2, 1]; 727s y = ["a"; "a"; "b"; "b"]; 727s a = fitcknn (x, y, "BucketSize" , 20, "distance", "mahalanobis"); 727s assert (class (a), "ClassificationKNN"); 727s assert ({a.NSMethod, a.Distance}, {"exhaustive", "mahalanobis"}) 727s assert ({a.BucketSize}, {20}) 727s ***** test 727s x = [1, 2, 3; 4, 5, 6; 7, 8, 9; 3, 2, 1]; 727s y = ["a"; "a"; "b"; "b"]; 727s a = fitcknn (x, y, "IncludeTies", true); 727s assert (class (a), "ClassificationKNN"); 727s assert (a.IncludeTies, true); 727s assert ({a.NSMethod, a.Distance}, {"kdtree", "euclidean"}) 727s ***** test 727s x = [1, 2, 3; 4, 5, 6; 7, 8, 9; 3, 2, 1]; 727s y = ["a"; "a"; "b"; "b"]; 727s a = fitcknn (x, y); 727s assert (class (a), "ClassificationKNN"); 727s assert (a.IncludeTies, false); 727s assert ({a.NSMethod, a.Distance}, {"kdtree", "euclidean"}) 727s ***** test 727s x = [1, 2, 3; 4, 5, 6; 7, 8, 9; 3, 2, 1]; 727s y = ["a"; "a"; "b"; "b"]; 727s a = fitcknn (x, y); 727s assert (class (a), "ClassificationKNN") 727s assert (a.Prior, [0.5; 0.5]) 727s assert ({a.NSMethod, a.Distance}, {"kdtree", "euclidean"}) 727s assert ({a.BucketSize}, {50}) 727s ***** test 727s x = [1, 2, 3; 4, 5, 6; 7, 8, 9; 3, 2, 1]; 727s y = ["a"; "a"; "b"; "b"]; 727s prior = [0.5; 0.5]; 727s a = fitcknn (x, y, "Prior", "empirical"); 727s assert (class (a), "ClassificationKNN") 727s assert (a.Prior, prior) 727s assert ({a.NSMethod, a.Distance}, {"kdtree", "euclidean"}) 727s assert ({a.BucketSize}, {50}) 727s ***** test 727s x = [1, 2, 3; 4, 5, 6; 7, 8, 9; 3, 2, 1]; 727s y = ["a"; "a"; "a"; "b"]; 727s prior = [0.75; 0.25]; 727s a = fitcknn (x, y, "Prior", "empirical"); 727s assert (class (a), "ClassificationKNN") 727s assert (a.Prior, prior) 727s assert ({a.NSMethod, a.Distance}, {"kdtree", "euclidean"}) 727s assert ({a.BucketSize}, {50}) 727s ***** test 727s x = [1, 2, 3; 4, 5, 6; 7, 8, 9; 3, 2, 1]; 727s y = ["a"; "a"; "a"; "b"]; 727s prior = [0.5; 0.5]; 727s a = fitcknn (x, y, "Prior", "uniform"); 727s assert (class (a), "ClassificationKNN") 727s assert (a.Prior, prior) 727s assert ({a.NSMethod, a.Distance}, {"kdtree", "euclidean"}) 727s assert ({a.BucketSize}, {50}) 727s ***** test 727s x = [1, 2, 3; 4, 5, 6; 7, 8, 9; 3, 2, 1]; 727s y = ["a"; "a"; "b"; "b"]; 727s cost = eye (2); 727s a = fitcknn (x, y, "Cost", cost); 727s assert (class (a), "ClassificationKNN") 727s assert (a.Cost, [1, 0; 0, 1]) 727s assert ({a.NSMethod, a.Distance}, {"kdtree", "euclidean"}) 727s assert ({a.BucketSize}, {50}) 727s ***** test 727s x = [1, 2, 3; 4, 5, 6; 7, 8, 9; 3, 2, 1]; 727s y = ["a"; "a"; "b"; "b"]; 727s cost = eye (2); 727s a = fitcknn (x, y, "Cost", cost, "Distance", "hamming" ); 727s assert (class (a), "ClassificationKNN") 727s assert (a.Cost, [1, 0; 0, 1]) 727s assert ({a.NSMethod, a.Distance}, {"exhaustive", "hamming"}) 727s assert ({a.BucketSize}, {50}) 727s ***** test 727s x = [1, 2, 3; 4, 5, 6; 7, 8, 9; 3, 2, 1]; 727s y = ["a"; "a"; "b"; "b"]; 727s a = fitcknn (x, y, "NSMethod", "exhaustive", "CrossVal", "on"); 727s assert (class (a), "ClassificationPartitionedModel"); 727s assert ({a.X, a.Y, a.Trained{1}.NumNeighbors}, {x, y, 1}) 727s assert (a.ModelParameters.NSMethod, "exhaustive") 727s assert (a.ModelParameters.Distance, "euclidean") 727s assert ({a.Trained{1}.BucketSize}, {50}) 727s ***** error fitcknn () 727s ***** error fitcknn (ones (4,1)) 727s ***** error 727s fitcknn (ones (4,2), ones (4, 1), "K") 727s ***** error 727s fitcknn (ones (4,2), ones (3, 1)) 727s ***** error 727s fitcknn (ones (4,2), ones (3, 1), "K", 2) 727s ***** error 727s fitcknn (ones (4,2), ones (4, 1), "CrossVal", 2) 727s ***** error 727s fitcknn (ones (4,2), ones (4, 1), "CrossVal", 'a') 727s ***** error ... 727s fitcknn (ones (4,2), ones (4, 1), "KFold", 10, "Holdout", 0.3) 727s 29 tests, 29 passed, 0 known failure, 0 skipped 727s [inst/qrandn.m] 727s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/qrandn.m 727s ***** demo 727s z = qrandn (-5, 5e6); 727s [c x] = hist (z,linspace(-1.5,1.5,200),1); 727s figure(1) 727s plot(x,c,"r."); axis tight; axis([-1.5,1.5]); 727s 727s z = qrandn (-0.14286, 5e6); 727s [c x] = hist (z,linspace(-2,2,200),1); 727s figure(2) 727s plot(x,c,"r."); axis tight; axis([-2,2]); 727s 727s z = qrandn (2.75, 5e6); 727s [c x] = hist (z,linspace(-1e3,1e3,1e3),1); 727s figure(3) 727s semilogy(x,c,"r."); axis tight; axis([-100,100]); 727s 727s # --------- 727s # Figures from the reference paper. 727s ***** error qrandn ([1 2], 1) 727s ***** error qrandn (4, 1) 727s ***** error qrandn (3, 1) 727s ***** error qrandn (2.5, 1, 2, 3) 727s ***** error qrandn (2.5) 728s ***** test 728s q = 1.5; 728s s = [2, 3]; 728s z = qrandn (q, s); 728s assert (isnumeric (z) && isequal (size (z), s)); 728s 6 tests, 6 passed, 0 known failure, 0 skipped 728s [inst/ff2n.m] 728s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/ff2n.m 728s ***** error ff2n (); 728s ***** error ff2n (2, 5); 728s ***** error ff2n (2.5); 728s ***** error ff2n (0); 728s ***** error ff2n (-3); 728s ***** error ff2n (3+2i); 728s ***** error ff2n (Inf); 728s ***** error ff2n (NaN); 728s ***** test 728s A = ff2n (3); 728s assert (A, fullfact (3)); 728s ***** test 728s A = ff2n (8); 728s assert (A, fullfact (8)); 728s 10 tests, 10 passed, 0 known failure, 0 skipped 728s [inst/hmmestimate.m] 728s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/inst/hmmestimate.m 728s ***** test 728s sequence = [1, 2, 1, 1, 1, 2, 2, 1, 2, 3, 3, ... 728s 3, 3, 2, 3, 1, 1, 1, 1, 3, 3, 2, 3, 1, 3]; 728s states = [1, 1, 2, 2, 2, 1, 1, 1, 1, 1, 1, ... 728s 1, 1, 1, 1, 2, 2, 2, 2, 1, 1, 1, 1, 1, 1]; 728s [transprobest, outprobest] = hmmestimate (sequence, states); 728s expectedtransprob = [0.88889, 0.11111; 0.28571, 0.71429]; 728s expectedoutprob = [0.16667, 0.33333, 0.50000; 1.00000, 0.00000, 0.00000]; 728s assert (transprobest, expectedtransprob, 0.001); 728s assert (outprobest, expectedoutprob, 0.001); 728s ***** test 728s sequence = {"A", "B", "A", "A", "A", "B", "B", "A", "B", "C", "C", "C", ... 728s "C", "B", "C", "A", "A", "A", "A", "C", "C", "B", "C", "A", "C"}; 728s states = {"One", "One", "Two", "Two", "Two", "One", "One", "One", "One", ... 728s "One", "One", "One", "One", "One", "One", "Two", "Two", "Two", ... 728s "Two", "One", "One", "One", "One", "One", "One"}; 728s symbols = {"A", "B", "C"}; 728s statenames = {"One", "Two"}; 728s [transprobest, outprobest] = hmmestimate (sequence, states, "symbols", ... 728s symbols, "statenames", statenames); 728s expectedtransprob = [0.88889, 0.11111; 0.28571, 0.71429]; 728s expectedoutprob = [0.16667, 0.33333, 0.50000; 1.00000, 0.00000, 0.00000]; 728s assert (transprobest, expectedtransprob, 0.001); 728s assert (outprobest, expectedoutprob, 0.001); 728s ***** test 728s sequence = [1, 2, 1, 1, 1, 2, 2, 1, 2, 3, 3, 3, ... 728s 3, 2, 3, 1, 1, 1, 1, 3, 3, 2, 3, 1, 3]; 728s states = [1, 1, 2, 2, 2, 1, 1, 1, 1, 1, 1, 1, ... 728s 1, 1, 1, 2, 2, 2, 2, 1, 1, 1, 1, 1, 1]; 728s pseudotransitions = [8, 2; 4, 6]; 728s pseudoemissions = [2, 4, 4; 7, 2, 1]; 728s [transprobest, outprobest] = hmmestimate (sequence, states, ... 728s "pseudotransitions", pseudotransitions, "pseudoemissions", pseudoemissions); 728s expectedtransprob = [0.85714, 0.14286; 0.35294, 0.64706]; 728s expectedoutprob = [0.178571, 0.357143, 0.464286; ... 728s 0.823529, 0.117647, 0.058824]; 728s assert (transprobest, expectedtransprob, 0.001); 728s assert (outprobest, expectedoutprob, 0.001); 728s 3 tests, 3 passed, 0 known failure, 0 skipped 728s Checking C++ files ... 728s [src/fcnntrain.cc] 728s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/src/fcnntrain.cc 728s ***** shared X, Y, MODEL 728s load fisheriris 728s X = meas; 728s Y = grp2idx (species); 728s ***** error ... 728s model = fcnntrain (X, Y); 728s ***** error ... 728s [Q, W] = fcnntrain (X, Y, 10, [1, 1], 1, 0.01, 0.025, 50, false); 728s ***** error ... 728s fcnntrain (complex (X), Y, 10, [1, 1], 1, 0.01, 0.025, 50, false); 728s ***** error ... 728s fcnntrain ({X}, Y, 10, [1, 1], 1, 0.01, 0.025, 50, false); 728s ***** error ... 728s fcnntrain ([], Y, 10, [1, 1], 1, 0.01, 0.025, 50, false); 728s ***** error ... 728s fcnntrain (X, complex (Y), 10, 1, 0.01, [1, 1], 0.025, 50, false); 728s ***** error ... 728s fcnntrain (X, {Y}, 10, [1, 1], 1, 0.01, 0.025, 50, false); 728s ***** error ... 728s fcnntrain (X, [], 10, [1, 1], 1, 0.01, 0.025, 50, false); 728s ***** error ... 728s fcnntrain (X, Y([1:50]), 10, [1, 1], 1, 0.01, 0.025, 50, false); 728s ***** error ... 728s fcnntrain (X, Y - 1, 10, [1, 1], 1, 0.01, 0.025, 50, false); 728s ***** error ... 728s fcnntrain (X, Y, [10; 5], [1, 1, 1], 1, 0.01, 0.025, 50, false); 728s ***** error ... 728s fcnntrain (X, Y, "10", [1, 1], 1, 0.01, 0.025, 50, false); 728s ***** error ... 728s fcnntrain (X, Y, {10}, [1, 1], 1, 0.01, 0.025, 50, false); 728s ***** error ... 728s fcnntrain (X, Y, complex (10), [1, 1], 1, 0.01, 0.025, 50, false); 728s ***** error ... 728s fcnntrain (X, Y, 10, [1; 1], 1, 0.01, 0.025, 50, false); 728s ***** error ... 728s fcnntrain (X, Y, 10, {1, 1}, 1, 0.01, 0.025, 50, false); 728s ***** error ... 728s fcnntrain (X, Y, 10, "1", 1, 0.01, 0.025, 50, false); 728s ***** error ... 728s fcnntrain (X, Y, 10, complex ([1, 1]), 1, 0.01, 0.025, 50, false); 728s ***** error ... 728s fcnntrain (X, Y, 10, [1, 1, 1], 1, 0.01, 0.025, 50, false); 728s ***** error ... 728s fcnntrain (X, Y, [10, 0, 5], [1, 1, 1, 1], 1, 0.01, 0.025, 50, false); 728s ***** error ... 728s fcnntrain (X, Y, 10, [-1, 1], 1, 0.01, 0.025, 50, false); 728s ***** error ... 728s fcnntrain (X, Y, 10, [8, 1], 1, 0.01, 0.025, 50, false); 728s ***** error ... 728s fcnntrain (X, Y, 10, [1, 1], 0, 0.01, 0.025, 50, false); 728s ***** error ... 728s fcnntrain (X, Y, 10, [1, 1], 1, -0.01, 0.025, 50, false); 728s ***** error ... 728s fcnntrain (X, Y, 10, [1, 1], 1, 0.01, -0.025, 50, false); 728s ***** error ... 728s fcnntrain (X, Y, 10, [1, 1], 1, 0.01, 0, 50, false); 728s ***** error ... 728s fcnntrain (X, Y, 10, [1, 1], 1, 0.01, [0.025, 0.001], 50, false); 728s ***** error ... 728s fcnntrain (X, Y, 10, [1, 1], 1, 0.01, {0.025}, 50, false); 728s ***** error ... 728s fcnntrain (X, Y, 10, [1, 1], 1, 0.01, 0.025, 0, false); 728s ***** error ... 728s fcnntrain (X, Y, 10, [1, 1], 1, 0.01, 0.025, [50, 25], false); 728s ***** error ... 728s fcnntrain (X, Y, 10, [1, 1], 1, 0.01, 0.025, 50, 0); 728s ***** error ... 728s fcnntrain (X, Y, 10, [1, 1], 1, 0.01, 0.025, 50, 1); 728s ***** error ... 728s fcnntrain (X, Y, 10, [1, 1], 1, 0.01, 0.025, 50, [false, false]); 728s 33 tests, 33 passed, 0 known failure, 0 skipped 728s [src/fcnnpredict.cc] 728s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/src/fcnnpredict.cc 728s ***** shared X, Y, MODEL 728s load fisheriris 728s X = meas; 728s Y = grp2idx (species); 728s MODEL = fcnntrain (X, Y, 10, [1, 1], 1, 0.01, 0.025, 100, false); 728s ***** test 728s [Y_pred, Y_scores] = fcnnpredict (MODEL, X); 728s assert (numel (Y_pred), numel (Y)); 728s assert (isequal (size (Y_pred), size (Y)), true); 728s assert (columns (Y_scores), numel (unique (Y))); 728s assert (rows (Y_scores), numel (Y)); 728s ***** error ... 728s fcnnpredict (MODEL); 728s ***** error ... 728s [Q, W, E] = fcnnpredict (MODEL, X); 728s ***** error ... 728s fcnnpredict (1, X); 728s ***** error ... 728s fcnnpredict (struct ("L", {1, 2, 3}), X); 728s ***** error ... 728s fcnnpredict (struct ("L", 1), X); 728s ***** error ... 728s fcnnpredict (struct ("LayerWeights", 1), X); 728s ***** error ... 728s fcnnpredict (struct ("LayerWeights", {1}), X); 728s ***** error ... 728s fcnnpredict (struct ("LayerWeights", {{1; 2; 3}}), X); 728s ***** error ... 728s fcnnpredict (struct ("LayerWeights", {[{ones(3)},{ones(3)}]}, "R", 2), X); 728s ***** error ... 728s fcnnpredict (struct ("LayerWeights", {[{ones(3)},{ones(3)}]}, ... 728s "Activations", [2]), X); 728s ***** error ... 728s fcnnpredict (struct ("LayerWeights", {[{ones(3)},{ones(3)}]}, ... 728s "Activations", [2; 2]), X); 728s ***** error ... 728s fcnnpredict (struct ("LayerWeights", {[{ones(3)},{ones(3)}]}, ... 728s "Activations", {{2, 2}}), X); 728s ***** error ... 728s fcnnpredict (struct ("LayerWeights", {[{ones(3)},{ones(3)}]}, ... 728s "Activations", {{"sigmoid", "softmax"}}), X); 728s ***** error ... 728s fcnnpredict (struct ("LayerWeights", {[{ones(3)},{ones(3)}]}, ... 728s "Activations", "sigmoid"), X); 728s ***** error ... 728s fcnnpredict (MODEL, complex (X)); 728s ***** error ... 728s fcnnpredict (MODEL, {1, 2, 3, 4}); 728s ***** error ... 728s fcnnpredict (MODEL, "asd"); 728s ***** error ... 728s fcnnpredict (MODEL, []); 728s ***** error ... 728s fcnnpredict (MODEL, X(:,[1:3])); 728s 20 tests, 20 passed, 0 known failure, 0 skipped 728s [src/svmtrain.cc] 728s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/src/svmtrain.cc 728s ***** test 728s [L, D] = libsvmread (file_in_loadpath ("heart_scale.dat")); 728s model = svmtrain(L, D, '-c 1 -g 0.07'); 728s [predict_label, accuracy, dec_values] = svmpredict(L, D, model); 728s assert (isstruct (model), true); 728s assert (isfield (model, "Parameters"), true); 728s assert (model.totalSV, 130); 728s assert (model.nr_class, 2); 728s assert (size (model.Label), [2, 1]); 728s ***** shared L, D 728s [L, D] = libsvmread (file_in_loadpath ("heart_scale.dat")); 728s ***** error [L, D] = svmtrain (L, D); 728s ***** error ... 728s model = svmtrain (single (L), D); 728s ***** error ... 728s model = svmtrain (L, D, "", ""); 728s 4 tests, 4 passed, 0 known failure, 0 skipped 728s [src/svmpredict.cc] 728s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/src/svmpredict.cc 728s ***** test 728s [L, D] = libsvmread (file_in_loadpath ("heart_scale.dat")); 728s model = svmtrain (L, D, '-c 1 -g 0.07'); 728s [predict_label, accuracy, dec_values] = svmpredict (L, D, model); 728s assert (size (predict_label), size (dec_values)); 728s assert (accuracy, [86.666, 0.533, 0.533]', [1e-3, 1e-3, 1e-3]'); 728s assert (dec_values(1), 1.225836001973273, 1e-14); 728s assert (dec_values(2), -0.3212992933043805, 1e-14); 728s assert (predict_label(1), 1); 728s ***** shared L, D, model 728s [L, D] = libsvmread (file_in_loadpath ("heart_scale.dat")); 728s model = svmtrain (L, D, '-c 1 -g 0.07'); 728s ***** error ... 728s [p, a] = svmpredict (L, D, model); 728s ***** error p = svmpredict (L, D); 728s ***** error ... 728s p = svmpredict (single (L), D, model); 728s ***** error p = svmpredict (L, D, 123); 728s 5 tests, 5 passed, 0 known failure, 0 skipped 728s [src/libsvmwrite.cc] 728s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/src/libsvmwrite.cc 728s ***** shared L, D 728s [L, D] = libsvmread (file_in_loadpath ("heart_scale.dat")); 728s ***** error libsvmwrite ("", L, D); 728s ***** error ... 728s libsvmwrite (tempname (), [L;L], D); 728s ***** error ... 728s OUT = libsvmwrite (tempname (), L, D); 728s ***** error ... 728s libsvmwrite (tempname (), single (L), D); 728s ***** error libsvmwrite (13412, L, D); 728s ***** error ... 728s libsvmwrite (tempname (), L, full (D)); 728s ***** error ... 728s libsvmwrite (tempname (), L, D, D); 728s 7 tests, 7 passed, 0 known failure, 0 skipped 728s [src/libsvmread.cc] 728s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/src/libsvmread.cc 728s ***** error [L, D] = libsvmread (24); 728s ***** error ... 728s D = libsvmread ("filename"); 728s ***** test 728s [L, D] = libsvmread (file_in_loadpath ("heart_scale.dat")); 728s assert (size (L), [270, 1]); 728s assert (size (D), [270, 13]); 728s ***** test 728s [L, D] = libsvmread (file_in_loadpath ("heart_scale.dat")); 728s assert (issparse (L), false); 728s assert (issparse (D), true); 728s 4 tests, 4 passed, 0 known failure, 0 skipped 728s [src/editDistance.cc] 728s >>>>> /tmp/autopkgtest.eoBgOu/build.08j/src/src/editDistance.cc 728s ***** error d = editDistance (1, 2, 3, 4); 728s ***** error ... 728s [C, IA, IC, I] = editDistance ({"AS","SD","AD"}, 1); 728s ***** error ... 728s [C, IA] = editDistance ({"AS","SD","AD"}); 728s ***** error ... 728s d = editDistance ({"AS","SD","AD"}, [1, 2]); 728s ***** error ... 728s d = editDistance ({"AS","SD","AD"}, -2); 728s ***** error ... 728s d = editDistance ({"AS","SD","AD"}, 1.25); 728s ***** error ... 728s d = editDistance ({"AS","SD","AD"}, {"AS","SD","AD"}, [1, 2]); 728s ***** error ... 728s d = editDistance ({"AS","SD","AD"}, {"AS","SD","AD"}, -2); 728s ***** error ... 728s d = editDistance ({"AS","SD","AD"}, {"AS","SD","AD"}, 1.25); 728s ***** error ... 728s d = editDistance ("string1", "string2", [1, 2]); 728s ***** error ... 728s d = editDistance ("string1", "string2", -2); 728s ***** error ... 728s d = editDistance ("string1", "string2", 1.25); 728s ***** error ... 728s d = editDistance ({{"string1", "string2"}, 2}); 728s ***** error ... 728s d = editDistance ({{"string1", "string2"}, 2}, 2); 728s ***** error ... 728s d = editDistance ([1, 2, 3]); 728s ***** error ... 728s d = editDistance (["AS","SD","AD","AS"]); 728s ***** error ... 728s d = editDistance (["AS","SD","AD"], 2); 728s ***** error ... 728s d = editDistance (logical ([1,2,3]), {"AS","AS","AD"}); 728s ***** error ... 728s d = editDistance ({"AS","SD","AD"}, logical ([1,2,3])); 728s ***** error ... 728s d = editDistance ([1,2,3], {"AS","AS","AD"}); 728s ***** error ... 728s d = editDistance ({1,2,3}, {"AS","SD","AD"}); 728s ***** error ... 728s d = editDistance ({"AS","SD","AD"}, {1,2,3}); 728s ***** error ... 728s d = editDistance ({"AS","SD","AD"}, {"AS", "AS"}); 728s ***** test 728s d = editDistance ({"AS","SD","AD"}); 728s assert (d, [2; 1; 1]); 728s assert (class (d), "double"); 728s ***** test 728s C = editDistance ({"AS","SD","AD"}, 1); 728s assert (iscellstr (C), true); 728s assert (C, {"AS";"SD"}); 728s ***** test 728s [C, IA] = editDistance ({"AS","SD","AD"}, 1); 728s assert (class (IA), "double"); 728s assert (IA, [1;2]); 728s ***** test 728s A = {"ASS"; "SDS"; "FDE"; "EDS"; "OPA"}; 728s [C, IA] = editDistance (A, 2, "OutputAllIndices", false); 728s assert (class (IA), "double"); 728s assert (A(IA), C); 728s ***** test 728s A = {"ASS"; "SDS"; "FDE"; "EDS"; "OPA"}; 728s [C, IA] = editDistance (A, 2, "OutputAllIndices", true); 728s assert (class (IA), "cell"); 728s assert (C, {"ASS"; "FDE"; "OPA"}); 728s assert (A(IA{1}), {"ASS"; "SDS"; "EDS"}); 728s assert (A(IA{2}), {"FDE"; "EDS"}); 728s assert (A(IA{3}), {"OPA"}); 728s ***** test 728s A = {"ASS"; "SDS"; "FDE"; "EDS"; "OPA"}; 728s [C, IA, IC] = editDistance (A, 2); 728s assert (class (IA), "double"); 728s assert (A(IA), C); 728s assert (IC, [1; 1; 3; 1; 5]); 728s ***** test 728s d = editDistance ({"AS","SD","AD"}, {"AS", "AD", "SE"}); 728s assert (d, [0; 1; 2]); 728s assert (class (d), "double"); 728s ***** test 728s d = editDistance ({"AS","SD","AD"}, {"AS"}); 728s assert (d, [0; 2; 1]); 728s assert (class (d), "double"); 728s ***** test 728s d = editDistance ({"AS"}, {"AS","SD","AD"}); 728s assert (d, [0; 2; 1]); 728s assert (class (d), "double"); 728s ***** test 728s b = editDistance ("Octave", "octave"); 728s assert (b, 1); 728s assert (class (b), "double"); 728s 33 tests, 33 passed, 0 known failure, 0 skipped 728s Done running the unit tests. 728s Summary: 11028 tests, 11025 passed, 1 known failures, 2 skipped 729s autopkgtest [05:32:05]: test command1: -----------------------] 730s command1 PASS 730s autopkgtest [05:32:06]: test command1: - - - - - - - - - - results - - - - - - - - - - 730s autopkgtest [05:32:06]: @@@@@@@@@@@@@@@@@@@@ summary 730s command1 PASS 735s nova [W] Using flock in prodstack6-ppc64el 735s Creating nova instance adt-plucky-ppc64el-octave-statistics-20250216-051956-juju-7f2275-prod-proposed-migration-environment-20-1b0431f3-1496-4789-bd4b-32efe8382e14 from image adt/ubuntu-plucky-ppc64el-server-20250215.img (UUID 6b0563e5-c35c-4c0f-8fb5-aae43570455f)... 735s nova [W] Timed out waiting for 3a31a8aa-94c4-4b2a-80b0-9994b23e13eb to get deleted.