Back to Multiple platform build/check report for BioC 3.20:   simplified   long
ABCDEFGHIJKLMNOPQRS[T]UVWXYZ

This page was generated on 2024-12-23 12:04 -0500 (Mon, 23 Dec 2024).

HostnameOSArch (*)R versionInstalled pkgs
nebbiolo2Linux (Ubuntu 24.04.1 LTS)x86_644.4.2 (2024-10-31) -- "Pile of Leaves" 4744
palomino8Windows Server 2022 Datacenterx644.4.2 (2024-10-31 ucrt) -- "Pile of Leaves" 4487
merida1macOS 12.7.5 Montereyx86_644.4.2 (2024-10-31) -- "Pile of Leaves" 4515
kjohnson1macOS 13.6.6 Venturaarm644.4.2 (2024-10-31) -- "Pile of Leaves" 4467
Click on any hostname to see more info about the system (e.g. compilers)      (*) as reported by 'uname -p', except on Windows and Mac OS X

Package 2132/2289HostnameOS / ArchINSTALLBUILDCHECKBUILD BIN
ternarynet 1.50.0  (landing page)
McCall N. Matthew
Snapshot Date: 2024-12-19 13:00 -0500 (Thu, 19 Dec 2024)
git_url: https://git.bioconductor.org/packages/ternarynet
git_branch: RELEASE_3_20
git_last_commit: 7c8c037
git_last_commit_date: 2024-10-29 09:40:14 -0500 (Tue, 29 Oct 2024)
nebbiolo2Linux (Ubuntu 24.04.1 LTS) / x86_64  OK    OK    OK  UNNEEDED, same version is already published
palomino8Windows Server 2022 Datacenter / x64  OK    OK    OK    OK  UNNEEDED, same version is already published
merida1macOS 12.7.5 Monterey / x86_64  OK    OK    OK    OK  UNNEEDED, same version is already published
kjohnson1macOS 13.6.6 Ventura / arm64  OK    OK    OK    OK  UNNEEDED, same version is already published


CHECK results for ternarynet on nebbiolo2

To the developers/maintainers of the ternarynet package:
- Allow up to 24 hours (and sometimes 48 hours) for your latest push to git@git.bioconductor.org:packages/ternarynet.git to reflect on this report. See Troubleshooting Build Report for more information.
- Use the following Renviron settings to reproduce errors and warnings.
- If 'R CMD check' started to fail recently on the Linux builder(s) over a missing dependency, add the missing dependency to 'Suggests:' in your DESCRIPTION file. See Renviron.bioc for more information.

raw results


Summary

Package: ternarynet
Version: 1.50.0
Command: /home/biocbuild/bbs-3.20-bioc/R/bin/R CMD check --install=check:ternarynet.install-out.txt --library=/home/biocbuild/bbs-3.20-bioc/R/site-library --timings ternarynet_1.50.0.tar.gz
StartedAt: 2024-12-20 06:06:51 -0500 (Fri, 20 Dec 2024)
EndedAt: 2024-12-20 06:07:36 -0500 (Fri, 20 Dec 2024)
EllapsedTime: 45.0 seconds
RetCode: 0
Status:   OK  
CheckDir: ternarynet.Rcheck
Warnings: 0

Command output

##############################################################################
##############################################################################
###
### Running command:
###
###   /home/biocbuild/bbs-3.20-bioc/R/bin/R CMD check --install=check:ternarynet.install-out.txt --library=/home/biocbuild/bbs-3.20-bioc/R/site-library --timings ternarynet_1.50.0.tar.gz
###
##############################################################################
##############################################################################


* using log directory ‘/home/biocbuild/bbs-3.20-bioc/meat/ternarynet.Rcheck’
* using R version 4.4.2 (2024-10-31)
* using platform: x86_64-pc-linux-gnu
* R was compiled by
    gcc (Ubuntu 13.2.0-23ubuntu4) 13.2.0
    GNU Fortran (Ubuntu 13.2.0-23ubuntu4) 13.2.0
* running under: Ubuntu 24.04.1 LTS
* using session charset: UTF-8
* checking for file ‘ternarynet/DESCRIPTION’ ... OK
* this is package ‘ternarynet’ version ‘1.50.0’
* checking package namespace information ... OK
* checking package dependencies ... OK
* checking if this is a source package ... OK
* checking if there is a namespace ... OK
* checking for hidden files and directories ... OK
* checking for portable file names ... OK
* checking for sufficient/correct file permissions ... OK
* checking whether package ‘ternarynet’ can be installed ... OK
* used C compiler: ‘gcc (Ubuntu 13.3.0-6ubuntu2~24.04) 13.3.0’
* used C++ compiler: ‘g++ (Ubuntu 13.3.0-6ubuntu2~24.04) 13.3.0’
* checking installed package size ... OK
* checking package directory ... OK
* checking ‘build’ directory ... OK
* checking DESCRIPTION meta-information ... OK
* checking top-level files ... OK
* checking for left-over files ... OK
* checking index information ... OK
* checking package subdirectories ... OK
* checking code files for non-ASCII characters ... OK
* checking R files for syntax errors ... OK
* checking whether the package can be loaded ... OK
* checking whether the package can be loaded with stated dependencies ... OK
* checking whether the package can be unloaded cleanly ... OK
* checking whether the namespace can be loaded with stated dependencies ... OK
* checking whether the namespace can be unloaded cleanly ... OK
* checking loading without being on the library search path ... OK
* checking dependencies in R code ... OK
* checking S3 generic/method consistency ... OK
* checking replacement functions ... OK
* checking foreign function calls ... OK
* checking R code for possible problems ... OK
* checking Rd files ... OK
* checking Rd metadata ... OK
* checking Rd cross-references ... OK
* checking for missing documentation entries ... OK
* checking for code/documentation mismatches ... OK
* checking Rd \usage sections ... OK
* checking Rd contents ... OK
* checking for unstated dependencies in examples ... OK
* checking line endings in shell scripts ... OK
* checking line endings in C/C++/Fortran sources/headers ... OK
* checking line endings in Makefiles ... OK
* checking compilation flags in Makevars ... OK
* checking for GNU extensions in Makefiles ... OK
* checking for portable use of $(BLAS_LIBS) and $(LAPACK_LIBS) ... OK
* checking use of PKG_*FLAGS in Makefiles ... OK
* checking compiled code ... NOTE
Note: information on .o files is not available
* checking files in ‘vignettes’ ... OK
* checking examples ... OK
* checking for unstated dependencies in ‘tests’ ... OK
* checking tests ...
  Running ‘test_smallmodel.R’
  Running ‘test_smallmodel_2.R’
 OK
* checking for unstated dependencies in vignettes ... OK
* checking package vignettes ... OK
* checking re-building of vignette outputs ... OK
* checking PDF version of manual ... OK
* DONE

Status: 1 NOTE
See
  ‘/home/biocbuild/bbs-3.20-bioc/meat/ternarynet.Rcheck/00check.log’
for details.


Installation output

ternarynet.Rcheck/00install.out

##############################################################################
##############################################################################
###
### Running command:
###
###   /home/biocbuild/bbs-3.20-bioc/R/bin/R CMD INSTALL ternarynet
###
##############################################################################
##############################################################################


* installing to library ‘/home/biocbuild/bbs-3.20-bioc/R/site-library’
* installing *source* package ‘ternarynet’ ...
** using staged installation
** libs
using C compiler: ‘gcc (Ubuntu 13.3.0-6ubuntu2~24.04) 13.3.0’
using C++ compiler: ‘g++ (Ubuntu 13.3.0-6ubuntu2~24.04) 13.3.0’
gcc -I"/home/biocbuild/bbs-3.20-bioc/R/include" -DNDEBUG   -I/usr/local/include    -fpic  -g -O2  -Wall -c array.c -o array.o
gcc -I"/home/biocbuild/bbs-3.20-bioc/R/include" -DNDEBUG   -I/usr/local/include    -fpic  -g -O2  -Wall -c gn.c -o gn.o
gn.c: In function ‘score’:
gn.c:486: warning: ignoring ‘#pragma omp parallel’ [-Wunknown-pragmas]
  486 | #pragma omp parallel for
      | 
gn.c:493: warning: ignoring ‘#pragma omp atomic’ [-Wunknown-pragmas]
  493 | #pragma omp atomic
      | 
gcc -I"/home/biocbuild/bbs-3.20-bioc/R/include" -DNDEBUG   -I/usr/local/include    -fpic  -g -O2  -Wall -c gn_Rwrap.c -o gn_Rwrap.o
gcc -I"/home/biocbuild/bbs-3.20-bioc/R/include" -DNDEBUG   -I/usr/local/include    -fpic  -g -O2  -Wall -c init.c -o init.o
g++ -std=gnu++17 -I"/home/biocbuild/bbs-3.20-bioc/R/include" -DNDEBUG   -I/usr/local/include    -fpic  -g -O2  -Wall  -c tnetfit.cc -o tnetfit.o
tnetfit.cc: In function ‘SEXPREC* tnetfit(SEXP, SEXP, SEXP, SEXP, SEXP, SEXP, SEXP, SEXP, SEXP, SEXP, SEXP, SEXP, SEXP, SEXP, SEXP, SEXP, SEXP, SEXP, SEXP, SEXP, SEXP, SEXP)’:
tnetfit.cc:24:9: warning: variable ‘perturbationType’ set but not used [-Wunused-but-set-variable]
   24 |     int perturbationType, scoreType, backupStage, maxStage, maxTransition;
      |         ^~~~~~~~~~~~~~~~
tnetfit.cc:24:27: warning: variable ‘scoreType’ set but not used [-Wunused-but-set-variable]
   24 |     int perturbationType, scoreType, backupStage, maxStage, maxTransition;
      |                           ^~~~~~~~~
tnetfit.cc:24:38: warning: variable ‘backupStage’ set but not used [-Wunused-but-set-variable]
   24 |     int perturbationType, scoreType, backupStage, maxStage, maxTransition;
      |                                      ^~~~~~~~~~~
tnetfit.cc:73:39: warning: unused variable ‘tempi’ [-Wunused-variable]
   73 |     int nOutcomes=3, l0, stage_count, tempi, jtrans, nTransition;
      |                                       ^~~~~
tnetfit.cc:207:25: warning: ‘sigma0’ may be used uninitialized [-Wmaybe-uninitialized]
  207 |             convergence = (muci-muci_old)/sigma0;
      |             ~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~
tnetfit.cc:98:12: note: ‘sigma0’ was declared here
   98 |     double sigma0, sigmaci, sigmaRaw, muci, muci_old, convergence;
      |            ^~~~~~
tnetfit.cc:202:43: warning: ‘sigmaci’ may be used uninitialized [-Wmaybe-uninitialized]
  202 |           sigmaci = rho*sigmaRaw + (1-rho)*sigmaci;
      |                                    ~~~~~~~^~~~~~~~
tnetfit.cc:98:20: note: ‘sigmaci’ was declared here
   98 |     double sigma0, sigmaci, sigmaRaw, muci, muci_old, convergence;
      |                    ^~~~~~~
tnetfit.cc:207:32: warning: ‘muci_old’ may be used uninitialized [-Wmaybe-uninitialized]
  207 |             convergence = (muci-muci_old)/sigma0;
      |                           ~~~~~^~~~~~~~~~
tnetfit.cc:98:45: note: ‘muci_old’ was declared here
   98 |     double sigma0, sigmaci, sigmaRaw, muci, muci_old, convergence;
      |                                             ^~~~~~~~
tnetfit.cc:311:19: warning: ‘newScore’ may be used uninitialized [-Wmaybe-uninitialized]
  311 |     SET_VECTOR_ELT(Routput, 10, ScalarReal(newScore));
      |     ~~~~~~~~~~~~~~^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
tnetfit.cc:77:12: note: ‘newScore’ was declared here
   77 |     double newScore, oldScore, difference, minScore = 999999999;
      |            ^~~~~~~~
g++ -std=gnu++17 -I"/home/biocbuild/bbs-3.20-bioc/R/include" -DNDEBUG   -I/usr/local/include    -fpic  -g -O2  -Wall  -c tnetfuncs.cc -o tnetfuncs.o
tnetfuncs.cc: In function ‘double AttractorDistanceForced(int, int, int, int, double, int*, int*, int*, const double*, const int*)’:
tnetfuncs.cc:427:5: warning: unused variable ‘tableWidth’ [-Wunused-variable]
  427 | int tableWidth = powi(nOutcomes,maxDegree);
      |     ^~~~~~~~~~
tnetfuncs.cc:435:5: warning: unused variable ‘ipause’ [-Wunused-variable]
  435 | int ipause;
      |     ^~~~~~
tnetfuncs.cc: In function ‘double initialTemp(double, int, int, int, int, int, double, double, double, int, const double*, int*, int*, int*, const double*, const int*)’:
tnetfuncs.cc:517:13: warning: unused variable ‘ipause’ [-Wunused-variable]
  517 |         int ipause;
      |             ^~~~~~
tnetfuncs.cc:521:21: warning: unused variable ‘i’ [-Wunused-variable]
  521 |         int m1, m2, i;
      |                     ^
g++ -std=gnu++17 -I"/home/biocbuild/bbs-3.20-bioc/R/include" -DNDEBUG   -I/usr/local/include    -fpic  -g -O2  -Wall  -c tnetpost.cc -o tnetpost.o
tnetpost.cc: In function ‘SEXPREC* tnetpost(SEXP, SEXP, SEXP, SEXP, SEXP, SEXP, SEXP, SEXP, SEXP, SEXP, SEXP, SEXP, SEXP, SEXP, SEXP, SEXP, SEXP, SEXP, SEXP, SEXP, SEXP, SEXP, SEXP, SEXP, SEXP, SEXP, SEXP, SEXP, SEXP, SEXP, SEXP, SEXP)’:
tnetpost.cc:25:9: warning: unused variable ‘ipause’ [-Wunused-variable]
   25 |     int ipause;
      |         ^~~~~~
tnetpost.cc:27:9: warning: unused variable ‘m0fit’ [-Wunused-variable]
   27 |     int m0fit;
      |         ^~~~~
tnetpost.cc:28:32: warning: variable ‘minScore’ set but not used [-Wunused-but-set-variable]
   28 |     double newScore, oldScore, minScore, finalScore;
      |                                ^~~~~~~~
tnetpost.cc:28:42: warning: unused variable ‘finalScore’ [-Wunused-variable]
   28 |     double newScore, oldScore, minScore, finalScore;
      |                                          ^~~~~~~~~~
tnetpost.cc:30:9: warning: unused variable ‘l0’ [-Wunused-variable]
   30 |     int l0, stage_count, tempi, jtrans, nTransition;
      |         ^~
tnetpost.cc:30:13: warning: unused variable ‘stage_count’ [-Wunused-variable]
   30 |     int l0, stage_count, tempi, jtrans, nTransition;
      |             ^~~~~~~~~~~
tnetpost.cc:30:26: warning: unused variable ‘tempi’ [-Wunused-variable]
   30 |     int l0, stage_count, tempi, jtrans, nTransition;
      |                          ^~~~~
tnetpost.cc:30:33: warning: unused variable ‘jtrans’ [-Wunused-variable]
   30 |     int l0, stage_count, tempi, jtrans, nTransition;
      |                                 ^~~~~~
tnetpost.cc:30:41: warning: unused variable ‘nTransition’ [-Wunused-variable]
   30 |     int l0, stage_count, tempi, jtrans, nTransition;
      |                                         ^~~~~~~~~~~
tnetpost.cc:36:21: warning: variable ‘xSeedFit’ set but not used [-Wunused-but-set-variable]
   36 |     int m0, mdelta, xSeedFit;
      |                     ^~~~~~~~
tnetpost.cc:38:9: warning: variable ‘perturbationType’ set but not used [-Wunused-but-set-variable]
   38 |     int perturbationType, scoreType, backupStage;
      |         ^~~~~~~~~~~~~~~~
tnetpost.cc:38:27: warning: variable ‘scoreType’ set but not used [-Wunused-but-set-variable]
   38 |     int perturbationType, scoreType, backupStage;
      |                           ^~~~~~~~~
tnetpost.cc:38:38: warning: variable ‘backupStage’ set but not used [-Wunused-but-set-variable]
   38 |     int perturbationType, scoreType, backupStage;
      |                                      ^~~~~~~~~~~
tnetpost.cc:39:9: warning: variable ‘maxStage’ set but not used [-Wunused-but-set-variable]
   39 |     int maxStage, maxTransition;
      |         ^~~~~~~~
tnetpost.cc:39:19: warning: variable ‘maxTransition’ set but not used [-Wunused-but-set-variable]
   39 |     int maxStage, maxTransition;
      |                   ^~~~~~~~~~~~~
tnetpost.cc:40:12: warning: variable ‘epsilon’ set but not used [-Wunused-but-set-variable]
   40 |     double epsilon, chi0, delta, rho;
      |            ^~~~~~~
tnetpost.cc:40:21: warning: variable ‘chi0’ set but not used [-Wunused-but-set-variable]
   40 |     double epsilon, chi0, delta, rho;
      |                     ^~~~
tnetpost.cc:40:27: warning: variable ‘delta’ set but not used [-Wunused-but-set-variable]
   40 |     double epsilon, chi0, delta, rho;
      |                           ^~~~~
tnetpost.cc:40:34: warning: variable ‘rho’ set but not used [-Wunused-but-set-variable]
   40 |     double epsilon, chi0, delta, rho;
      |                                  ^~~
In file included from tnetpost.cc:14:
/home/biocbuild/bbs-3.20-bioc/R/include/Rmath.h:210:25: warning: variable ‘Rf_beta’ set but not used [-Wunused-but-set-variable]
  210 | #define beta            Rf_beta
      |                         ^~~~~~~
tnetpost.cc:41:9: note: in expansion of macro ‘beta’
   41 |     int beta;
      |         ^~~~
tnetpost.cc:44:9: warning: variable ‘ne’ set but not used [-Wunused-but-set-variable]
   44 |     int ne, maxDegree;
      |         ^~
tnetpost.cc:150:10: warning: variable ‘minDump’ set but not used [-Wunused-but-set-variable]
  150 |     bool minDump = true;
      |          ^~~~~~~
gcc -I"/home/biocbuild/bbs-3.20-bioc/R/include" -DNDEBUG   -I/usr/local/include    -fpic  -g -O2  -Wall -c util.c -o util.o
g++ -std=gnu++17 -shared -L/home/biocbuild/bbs-3.20-bioc/R/lib -L/usr/local/lib -o ternarynet.so array.o gn.o gn_Rwrap.o init.o tnetfit.o tnetfuncs.o tnetpost.o util.o -L/home/biocbuild/bbs-3.20-bioc/R/lib -lR
installing to /home/biocbuild/bbs-3.20-bioc/R/site-library/00LOCK-ternarynet/00new/ternarynet/libs
** R
** inst
** byte-compile and prepare package for lazy loading
** help
*** installing help indices
** building package indices
** installing vignettes
** testing if installed package can be loaded from temporary location
** checking absolute paths in shared objects and dynamic libraries
** testing if installed package can be loaded from final location
** testing if installed package keeps a record of temporary installation path
* DONE (ternarynet)

Tests output

ternarynet.Rcheck/tests/test_smallmodel.Rout


R version 4.4.2 (2024-10-31) -- "Pile of Leaves"
Copyright (C) 2024 The R Foundation for Statistical Computing
Platform: x86_64-pc-linux-gnu

R is free software and comes with ABSOLUTELY NO WARRANTY.
You are welcome to redistribute it under certain conditions.
Type 'license()' or 'licence()' for distribution details.

R is a collaborative project with many contributors.
Type 'contributors()' for more information and
'citation()' on how to cite R or R packages in publications.

Type 'demo()' for some demos, 'help()' for on-line help, or
'help.start()' for an HTML browser interface to help.
Type 'q()' to quit R.

> library(testthat)
> library(ternarynet) 
> 
> smallmodel_score <- function() {
+ 
+     library(ternarynet)
+ 
+     i_exp <- as.integer(c(0,0,0, 0,0,0, 0,0,0, 0,0,0,
+                           1,1,1, 1,1,1, 1,1,1, 1,1,1,
+                           2,2,2, 2,2,2, 2,2,2, 2,2,2,
+                           3,3,3, 3,3,3, 3,3,3, 3,3,3,
+                           4,4,4, 4,4,4, 4,4,4, 4,4,4,
+                           5,5,5, 5,5,5, 5,5,5, 5,5,5,
+                           6,6,6, 6,6,6, 6,6,6, 6,6,6,
+                           7,7,7, 7,7,7, 7,7,7, 7,7,7))
+ 
+     i_node <- as.integer(c(0,0,0, 1,1,1, 2,2,2, 3,3,3,
+                            0,0,0, 1,1,1, 2,2,2, 3,3,3,
+                            0,0,0, 1,1,1, 2,2,2, 3,3,3,
+                            0,0,0, 1,1,1, 2,2,2, 3,3,3,
+                            0,0,0, 1,1,1, 2,2,2, 3,3,3,
+                            0,0,0, 1,1,1, 2,2,2, 3,3,3,
+                            0,0,0, 1,1,1, 2,2,2, 3,3,3,
+                            0,0,0, 1,1,1, 2,2,2, 3,3,3))
+ 
+     outcome <- as.integer(c(-1,0,1, -1,0,1, -1,0,1, -1,0,1,
+                             -1,0,1, -1,0,1, -1,0,1, -1,0,1,
+                             -1,0,1, -1,0,1, -1,0,1, -1,0,1,
+                             -1,0,1, -1,0,1, -1,0,1, -1,0,1,
+                             -1,0,1, -1,0,1, -1,0,1, -1,0,1,
+                             -1,0,1, -1,0,1, -1,0,1, -1,0,1,
+                             -1,0,1, -1,0,1, -1,0,1, -1,0,1,
+                             -1,0,1, -1,0,1, -1,0,1, -1,0,1))
+ 
+     value <- c(0,1,2, 0,1,2, 0,1,2, 0,1,2,
+                2,1,0, 0,1,2, 0,1,2, 0,1,2,
+                2,1,0, 2,1,0, 0,1,2, 0,1,2,
+                2,1,0, 2,1,0, 2,1,0, 0,1,2,
+                2,1,0, 2,1,0, 2,1,0, 2,1,0,
+                0,1,2, 2,1,0, 2,1,0, 2,1,0,
+                0,1,2, 0,1,2, 2,1,0, 2,1,0,
+                0,1,2, 0,1,2, 0,1,2, 2,1,0)
+ 
+     is_perturbation <- c(TRUE,TRUE,TRUE,  FALSE,FALSE,FALSE, FALSE,FALSE,FALSE, FALSE,FALSE,FALSE,
+                          FALSE,FALSE,FALSE,  TRUE,TRUE,TRUE, FALSE,FALSE,FALSE, FALSE,FALSE,FALSE,
+                          FALSE,FALSE,FALSE,  FALSE,FALSE,FALSE, TRUE,TRUE,TRUE, FALSE,FALSE,FALSE,
+                          FALSE,FALSE,FALSE,  FALSE,FALSE,FALSE, FALSE,FALSE,FALSE, TRUE,TRUE,TRUE,
+                          TRUE,TRUE,TRUE,  FALSE,FALSE,FALSE, FALSE,FALSE,FALSE, FALSE,FALSE,FALSE,
+                          FALSE,FALSE,FALSE,  TRUE,TRUE,TRUE, FALSE,FALSE,FALSE, FALSE,FALSE,FALSE,
+                          FALSE,FALSE,FALSE,  FALSE,FALSE,FALSE, TRUE,TRUE,TRUE, FALSE,FALSE,FALSE,
+                          FALSE,FALSE,FALSE,  FALSE,FALSE,FALSE, FALSE,FALSE,FALSE, TRUE,TRUE,TRUE)
+ 
+     indata <- data.frame(i_exp,i_node,outcome,value,is_perturbation)
+ 
+     results <- parallelFit(indata,
+                             max_parents=1,
+                             n_cycles=1000000,
+                             n_write=10,
+                             T_lo=0.001,
+                             T_hi=1.0,
+                             target_score=0,
+                             n_proc=1,
+                             logfile='try.log')
+     
+     lowest_temp_results <- results[[1]]
+ 
+     lowest_temp_results$unnormalized_score
+ 
+ }
>    
> test_that("smallmodel", {
+     expect_true(smallmodel_score() == 0)
+ })
Test passed 🌈
> 
> proc.time()
   user  system elapsed 
  1.135   0.078   1.200 

ternarynet.Rcheck/tests/test_smallmodel_2.Rout


R version 4.4.2 (2024-10-31) -- "Pile of Leaves"
Copyright (C) 2024 The R Foundation for Statistical Computing
Platform: x86_64-pc-linux-gnu

R is free software and comes with ABSOLUTELY NO WARRANTY.
You are welcome to redistribute it under certain conditions.
Type 'license()' or 'licence()' for distribution details.

R is a collaborative project with many contributors.
Type 'contributors()' for more information and
'citation()' on how to cite R or R packages in publications.

Type 'demo()' for some demos, 'help()' for on-line help, or
'help.start()' for an HTML browser interface to help.
Type 'q()' to quit R.

> library(testthat)
> library(ternarynet) 
> 
> smallmodel_2_score <- function() {
+ 
+     library(ternarynet)
+ 
+     i_exp <- as.integer(c(0,0,0, 0,0,0, 0,0,0,
+                         1,1,1, 1,1,1, 1,1,1,
+                         2,2,2, 2,2,2, 2,2,2,
+                         3,3,3, 3,3,3, 3,3,3,
+                         4,4,4, 4,4,4, 4,4,4,
+                         5,5,5, 5,5,5, 5,5,5,
+                         6,6,6, 6,6,6, 6,6,6,
+                         7,7,7, 7,7,7, 7,7,7,
+                         8,8,8, 8,8,8, 8,8,8,
+                         9,9,9, 9,9,9, 9,9,9,
+                         10,10,10, 10,10,10, 10,10,10,
+                         11,11,11, 11,11,11, 11,11,11,
+                         12,12,12, 12,12,12, 12,12,12,
+                         13,13,13, 13,13,13, 13,13,13,
+                         14,14,14, 14,14,14, 14,14,14,
+                         15,15,15, 15,15,15, 15,15,15,
+                         16,16,16, 16,16,16, 16,16,16,
+                         17,17,17, 17,17,17, 17,17,17))
+ 
+     i_node <- as.integer(c(0,0,0, 1,1,1, 2,2,2,
+                         0,0,0, 1,1,1, 2,2,2,
+                         0,0,0, 1,1,1, 2,2,2,
+                         0,0,0, 1,1,1, 2,2,2,
+                         0,0,0, 1,1,1, 2,2,2,
+                         0,0,0, 1,1,1, 2,2,2,
+                         0,0,0, 1,1,1, 2,2,2,
+                         0,0,0, 1,1,1, 2,2,2,
+                         0,0,0, 1,1,1, 2,2,2,
+                         0,0,0, 1,1,1, 2,2,2,
+                         0,0,0, 1,1,1, 2,2,2,
+                         0,0,0, 1,1,1, 2,2,2,
+                         0,0,0, 1,1,1, 2,2,2,
+                         0,0,0, 1,1,1, 2,2,2,
+                         0,0,0, 1,1,1, 2,2,2,
+                         0,0,0, 1,1,1, 2,2,2,
+                         0,0,0, 1,1,1, 2,2,2,
+                         0,0,0, 1,1,1, 2,2,2))
+ 
+     outcome <- as.integer(c(-1,0,1, -1,0,1, -1,0,1,
+                             -1,0,1, -1,0,1, -1,0,1,
+                             -1,0,1, -1,0,1, -1,0,1,
+                             -1,0,1, -1,0,1, -1,0,1,
+                             -1,0,1, -1,0,1, -1,0,1,
+                             -1,0,1, -1,0,1, -1,0,1,
+                             -1,0,1, -1,0,1, -1,0,1,
+                             -1,0,1, -1,0,1, -1,0,1,
+                             -1,0,1, -1,0,1, -1,0,1,
+                             -1,0,1, -1,0,1, -1,0,1,
+                             -1,0,1, -1,0,1, -1,0,1,
+                             -1,0,1, -1,0,1, -1,0,1,
+                             -1,0,1, -1,0,1, -1,0,1,
+                             -1,0,1, -1,0,1, -1,0,1,
+                             -1,0,1, -1,0,1, -1,0,1,
+                             -1,0,1, -1,0,1, -1,0,1,
+                             -1,0,1, -1,0,1, -1,0,1,
+                             -1,0,1, -1,0,1, -1,0,1))
+ 
+     value <- c(2,1,0, 1,0,1, 2,1,0,
+             1,0,1, 2,1,0, 0,1,2,
+             1,0,1, 1,0,1, 2,1,0,
+             0,1,2, 1,0,1, 0,1,2,
+             1,0,1, 0,1,2, 2,1,0,
+             1,0,1, 1,0,1, 0,1,2,
+             2,1,0, 1,0,1, 2,1,0,
+             0,1,2, 1,0,1, 0,1,2,
+             1,0,1, 2,1,0, 0,1,2,
+             1,0,1, 0,1,2, 2,1,0,
+             2,1,0, 2,1,0, 1,0,1,
+             0,1,2, 0,1,2, 1,0,1,
+             2,1,0, 0,1,2, 2,1,0,
+             0,1,2, 2,1,0, 0,1,2,
+             2,1,0, 1,0,1, 0,1,2,
+             0,1,2, 1,0,1, 2,1,0,
+             1,0,1, 2,1,0, 2,1,0,
+             1,0,1, 0,1,2, 0,1,2)
+ 
+     is_perturbation <- c(TRUE,TRUE,TRUE,  FALSE,FALSE,FALSE, FALSE,FALSE,FALSE,
+                         FALSE,FALSE,FALSE,  TRUE,TRUE,TRUE, FALSE,FALSE,FALSE,
+                         FALSE,FALSE,FALSE,  FALSE,FALSE,FALSE, TRUE,TRUE,TRUE,
+                         TRUE,TRUE,TRUE,  FALSE,FALSE,FALSE, FALSE,FALSE,FALSE,
+                         FALSE,FALSE,FALSE,  TRUE,TRUE,TRUE, FALSE,FALSE,FALSE,
+                         FALSE,FALSE,FALSE,  FALSE,FALSE,FALSE, TRUE,TRUE,TRUE,
+                         TRUE,TRUE,TRUE,  FALSE,FALSE,FALSE, TRUE,TRUE,TRUE,
+                         TRUE,TRUE,TRUE,  FALSE,FALSE,FALSE, TRUE,TRUE,TRUE,
+                         FALSE,FALSE,FALSE,  TRUE,TRUE,TRUE, TRUE,TRUE,TRUE,
+                         FALSE,FALSE,FALSE,  TRUE,TRUE,TRUE, TRUE,TRUE,TRUE,
+                         TRUE,TRUE,TRUE,  TRUE,TRUE,TRUE, FALSE,FALSE,FALSE,
+                         TRUE,TRUE,TRUE,  TRUE,TRUE,TRUE, FALSE,FALSE,FALSE,
+                         TRUE,TRUE,TRUE,  TRUE,TRUE,TRUE, FALSE,FALSE,FALSE,
+                         TRUE,TRUE,TRUE,  TRUE,TRUE,TRUE, FALSE,FALSE,FALSE,
+                         TRUE,TRUE,TRUE,  FALSE,FALSE,FALSE, TRUE,TRUE,TRUE,
+                         TRUE,TRUE,TRUE,  FALSE,FALSE,FALSE, TRUE,TRUE,TRUE,
+                         FALSE,FALSE,FALSE,  TRUE,TRUE,TRUE, TRUE,TRUE,TRUE,
+                         FALSE,FALSE,FALSE,  TRUE,TRUE,TRUE, TRUE,TRUE,TRUE)
+ 
+     indata <- data.frame(i_exp,i_node,outcome,value,is_perturbation)
+ 
+     results <- parallelFit(indata,
+                             max_parents=2,
+                             n_cycles=1000000,
+                             n_write=10,
+                             T_lo=0.001,
+                             T_hi=2.0,
+                             target_score=0,
+                             n_proc=1,
+                             logfile='try2.log')
+     
+     lowest_temp_results <- results[[1]]
+ 
+     lowest_temp_results$unnormalized_score
+ 
+ }
>    
> test_that("smallmodel_2", {
+     expect_true(smallmodel_2_score() == 0)
+ })
Test passed 🎊
> 
> proc.time()
   user  system elapsed 
  1.405   0.073   1.467 

Example timings

ternarynet.Rcheck/ternarynet-Ex.timings

nameusersystemelapsed
attractorSummary1.6950.0061.702
graphPosterior1.6920.0001.693
parallelFit0.2240.0130.237
plotFit1.7810.0141.796
plotPost1.7140.0601.773
plotTraces1.6850.0011.686
predictAttractor1.6870.0071.695
simulateSteadyState0.0000.0010.001
ternaryFit-class1.6830.0011.685
ternaryFitParameters-class0.0010.0000.002
ternaryPost-class1.6940.0021.697
tnetfit1.7020.0001.702
tnetpost1.6810.0011.683