Last updated on 2019-03-27 00:48:06 CET.
Flavor | Version | Tinstall | Tcheck | Ttotal | Status | Flags |
---|---|---|---|---|---|---|
r-devel-linux-x86_64-debian-clang | 0.9.0 | 9.88 | 89.91 | 99.79 | ERROR | |
r-devel-linux-x86_64-debian-gcc | 0.9.0 | 9.25 | 69.16 | 78.41 | ERROR | |
r-devel-linux-x86_64-fedora-clang | 0.9.0 | 122.01 | ERROR | |||
r-devel-linux-x86_64-fedora-gcc | 0.9.0 | 115.93 | ERROR | |||
r-devel-windows-ix86+x86_64 | 0.9.0 | 31.00 | 174.00 | 205.00 | ERROR | |
r-patched-linux-x86_64 | 0.9.0 | 7.49 | 82.92 | 90.41 | ERROR | |
r-patched-solaris-x86 | 0.9.0 | 149.20 | ERROR | |||
r-release-linux-x86_64 | 0.9.0 | 9.84 | 83.45 | 93.29 | ERROR | |
r-release-windows-ix86+x86_64 | 0.9.0 | 26.00 | 145.00 | 171.00 | ERROR | |
r-release-osx-x86_64 | 0.9.0 | OK | ||||
r-oldrel-windows-ix86+x86_64 | 0.9.0 | 16.00 | 180.00 | 196.00 | ERROR | |
r-oldrel-osx-x86_64 | 0.9.0 | NOTE |
Version: 0.9.0
Check: S3 generic/method consistency
Result: WARN
network.dyadcount:
function(x, na.omit, ...)
network.dyadcount.active:
function(x, onset, terminus, length, at, rule, na.omit,
active.default)
network.edgecount:
function(x, na.omit, ...)
network.edgecount.active:
function(x, onset, terminus, length, at, rule, na.omit,
active.default)
network.naedgecount:
function(x, ...)
network.naedgecount.active:
function(x, onset, terminus, length, at, rule, active.default)
network.size:
function(x, ...)
network.size.active:
function(x, onset, terminus, length, at, rule, active.default)
See section 'Generic functions and methods' in the 'Writing R
Extensions' manual.
Found the following apparent S3 methods exported but not registered:
network.dyadcount.active network.edgecount.active
network.naedgecount.active network.size.active
See section 'Registering S3 methods' in the 'Writing R Extensions'
manual.
Flavors: r-devel-linux-x86_64-debian-clang, r-devel-linux-x86_64-debian-gcc, r-devel-linux-x86_64-fedora-clang, r-devel-linux-x86_64-fedora-gcc, r-devel-windows-ix86+x86_64, r-patched-linux-x86_64, r-patched-solaris-x86, r-release-linux-x86_64
Version: 0.9.0
Check: Rd \usage sections
Result: NOTE
S3 methods shown with full name in documentation object 'network.extensions':
'network.dyadcount.active' 'network.edgecount.active'
'network.naedgecount.active' 'network.size.active'
The \usage entries for S3 methods should use the \method markup and not
their full name.
See chapter 'Writing R documentation files' in the 'Writing R
Extensions' manual.
Flavors: r-devel-linux-x86_64-debian-clang, r-devel-linux-x86_64-debian-gcc, r-devel-linux-x86_64-fedora-clang, r-devel-linux-x86_64-fedora-gcc, r-devel-windows-ix86+x86_64, r-patched-linux-x86_64, r-patched-solaris-x86, r-release-linux-x86_64, r-release-windows-ix86+x86_64, r-oldrel-windows-ix86+x86_64
Version: 0.9.0
Check: tests
Result: ERROR
Running 'activate_tests.R' [1s/1s]
Running 'age.at_tests.R' [1s/1s]
Running 'classTests.R' [1s/1s]
Running 'converter_tests.R' [1s/1s]
Running 'get_tests.R' [3s/3s]
Running 'import_tests.R' [6s/6s]
Running 'network_tests.R' [1s/2s]
Running 'pid_tests.R' [1s/1s]
Running 'query_tests.R' [1s/1s]
Running 'reconcile.activityTests.R' [1s/1s]
Running 'tea_tests.R' [1s/1s]
Running 'utils_tests.R' [1s/1s]
Running 'when_tests.R' [1s/1s]
Running the tests in 'tests/converter_tests.R' failed.
Complete output:
> # Part of the statnet package, http://statnetproject.org
> #
> # This software is distributed under the GPL-3 license. It is free,
> # open source, and has the attribution requirements (GPL Section 7) in
> # http://statnetproject.org/attribution
> #
> # Copyright 2013 the statnet development team
> ######################################################################
>
> #test networkDynamic conversion functionality
>
> require(networkDynamic)
Loading required package: networkDynamic
Loading required package: network
network: Classes for Relational Data
Version 1.14-377 created on 2019-03-04.
copyright (c) 2005, Carter T. Butts, University of California-Irvine
Mark S. Handcock, University of California -- Los Angeles
David R. Hunter, Penn State University
Martina Morris, University of Washington
Skye Bender-deMoll, University of Washington
For citation information, type citation("network").
Type help("network-package") to get started.
networkDynamic: version 0.9.0, created on 2016-01-12
Copyright (c) 2016, Carter T. Butts, University of California -- Irvine
Ayn Leslie-Cook, University of Washington
Pavel N. Krivitsky, University of Wollongong
Skye Bender-deMoll, University of Washington
with contributions from
Zack Almquist, University of California -- Irvine
David R. Hunter, Penn State University
Li Wang
Kirk Li, University of Washington
Steven M. Goodreau, University of Washington
Jeffrey Horner
Martina Morris, University of Washington
Based on "statnet" project software (statnet.org).
For license and citation information see statnet.org/attribution
or type citation("networkDynamic").
> require(testthat)
Loading required package: testthat
>
>
> # ------ get.vertex.activity test ------
>
> net<-network.initialize(5)
> activate.vertices(net,onset=c(1,2,3,-Inf,100),terminus=c(10,20,Inf,30,Inf))
> activate.vertices(net,at=1000)
> expect_equal(unlist(get.vertex.activity(net)),c(1,1000,10,1000,2,1000,20,1000,3,Inf,-Inf,1000,30,1000,100,Inf),info='check if spell list has correct elements in get.vertex.activity')
>
> expect_equivalent(get.vertex.activity(net,as.spellList=TRUE),data.frame(onset=c(1,1000,2,1000,3,-Inf,1000,100),terminus=c(10,1000,20,1000,Inf,30,1000,Inf),vertex.id=c(1,1,2,2,3,4,4,5),onset.censored=c(FALSE,FALSE,FALSE,FALSE,FALSE,TRUE,FALSE,FALSE),terminus.censored=c(FALSE,FALSE,FALSE,FALSE,TRUE,FALSE,FALSE,TRUE),duration=c(9,0,18,0,Inf,Inf,0,Inf)),info="check if get.vertex.activity(spellList) returns correct data")
>
> # check sort order
> expect_equal(get.vertex.activity(net,as.spellList=TRUE)$vertex.id,c(1,1,2,2,3,4,4,5),info="check sort order of get.vertex.activity vertex.id")
>
> expect_equal(get.vertex.activity(net,as.spellList=TRUE)$onset,c(1,1000,2,1000,3,-Inf,1000,100),info="check sort order of get.vertex.activity onset")
> expect_equal(get.vertex.activity(net,as.spellList=TRUE)$terminus,c(10,1000,20,1000,Inf,30,1000,Inf),info="check sort order of get.vertex.activity terminus")
>
> expect_equal(get.vertex.activity(network.initialize(0)),list())
>
>
>
>
> # check that net.obs.period triggers censoring
> nop <- list(observations=list(c(-5,1001)), mode="discrete", time.increment=1,time.unit="step")
> set.network.attribute(net,'net.obs.period',nop)
> expect_equivalent(get.vertex.activity(net,as.spellList=TRUE),data.frame(onset=c(1,1000,2,1000,3,-5,1000,100),terminus=c(10,1000,20,1000,1001,30,1000,1001),vertex.id=c(1,1,2,2,3,4,4,5),onset.censored=c(FALSE,FALSE,FALSE,FALSE,FALSE,TRUE,FALSE,FALSE),terminus.censored=c(FALSE,FALSE,FALSE,FALSE,TRUE,FALSE,FALSE,TRUE),duration=c(9,0,18,0,998,35,0,901)),info="check that net.obs.period triggers censoring in get.vertex.activity(spellList)")
>
>
> # check for bug with no activity #192
> nd<-network.initialize(2)
> nd<-add.edges.active(nd,at=1,tail=1,head=2)
>
> expect_equivalent(get.vertex.activity(nd,as.spellList=TRUE),data.frame(onset=c(-Inf,-Inf),terminus=c(Inf,Inf),vertex.id=c(1,2),onset.censored=c(TRUE,TRUE),terminus.censored=c(TRUE,TRUE),duration=c(Inf,Inf)),info="checking with no vertex activity")
>
> # test if activity is missing for an element
> activate.vertices(nd,onset=1,terminus=2,v=2)
> expect_equivalent(get.vertex.activity(nd,as.spellList=TRUE),data.frame(onset=c(-Inf,1),terminus=c(Inf,2),vertex.id=c(1,2),onset.censored=c(TRUE,FALSE),terminus.censored=c(TRUE,FALSE),duration=c(Inf,1)),info="test when only some verticies have activity")
>
> # test when default activity set false
> expect_equivalent(
+ get.vertex.activity(nd,as.spellList=TRUE,active.default=FALSE),
+ data.frame(onset=1,terminus=2,vertex.id=2,onset.censored=FALSE,terminus.censored=FALSE,duration=1),info="test when only some verticies have activity and active.default=FALSE")
>
> # test if v specified for spellmatrix
> nd <- network.initialize(5)
> activate.vertices(nd,onset=0:4,terminus=1:5)
> expect_equivalent(
+ get.vertex.activity(nd,as.spellList=TRUE,v=2:4)[,1:3],
+ data.frame(onset=1:3,terminus=2:4,vertex.id=2:4),info="test when when v argument specified with spellmatrix")
>
> expect_equivalent(
+ unlist(get.vertex.activity(nd,,v=2:4)),c(1,2,2,3,3,4)
+ ,info="test when when v argument specified")
>
>
> # test if called with ordinary network
> expect_equal(unlist(get.vertex.activity(network.initialize(3))),c(-Inf,Inf,-Inf,Inf,-Inf,Inf),info="calling with ordinary network")
>
> # test when called with something else
> expect_error(get.vertex.activity(list()),'requires an argument of class network')
Error: `get.vertex.activity(list())` threw an error with unexpected message.
Expected match: "requires an argument of class network"
Actual message: "no applicable method for 'network.size' applied to an object of class \"list\""
Execution halted
Flavor: r-devel-linux-x86_64-debian-clang
Version: 0.9.0
Check: tests
Result: ERROR
Running ‘activate_tests.R’ [1s/1s]
Running ‘age.at_tests.R’ [1s/1s]
Running ‘classTests.R’ [1s/1s]
Running ‘converter_tests.R’ [1s/1s]
Running ‘get_tests.R’ [2s/3s]
Running ‘import_tests.R’ [4s/5s]
Running ‘network_tests.R’ [1s/2s]
Running ‘pid_tests.R’ [1s/1s]
Running ‘query_tests.R’ [1s/1s]
Running ‘reconcile.activityTests.R’ [1s/1s]
Running ‘tea_tests.R’ [1s/1s]
Running ‘utils_tests.R’ [1s/1s]
Running ‘when_tests.R’ [1s/1s]
Running the tests in ‘tests/converter_tests.R’ failed.
Complete output:
> # Part of the statnet package, http://statnetproject.org
> #
> # This software is distributed under the GPL-3 license. It is free,
> # open source, and has the attribution requirements (GPL Section 7) in
> # http://statnetproject.org/attribution
> #
> # Copyright 2013 the statnet development team
> ######################################################################
>
> #test networkDynamic conversion functionality
>
> require(networkDynamic)
Loading required package: networkDynamic
Loading required package: network
network: Classes for Relational Data
Version 1.14-377 created on 2019-03-04.
copyright (c) 2005, Carter T. Butts, University of California-Irvine
Mark S. Handcock, University of California -- Los Angeles
David R. Hunter, Penn State University
Martina Morris, University of Washington
Skye Bender-deMoll, University of Washington
For citation information, type citation("network").
Type help("network-package") to get started.
networkDynamic: version 0.9.0, created on 2016-01-12
Copyright (c) 2016, Carter T. Butts, University of California -- Irvine
Ayn Leslie-Cook, University of Washington
Pavel N. Krivitsky, University of Wollongong
Skye Bender-deMoll, University of Washington
with contributions from
Zack Almquist, University of California -- Irvine
David R. Hunter, Penn State University
Li Wang
Kirk Li, University of Washington
Steven M. Goodreau, University of Washington
Jeffrey Horner
Martina Morris, University of Washington
Based on "statnet" project software (statnet.org).
For license and citation information see statnet.org/attribution
or type citation("networkDynamic").
> require(testthat)
Loading required package: testthat
>
>
> # ------ get.vertex.activity test ------
>
> net<-network.initialize(5)
> activate.vertices(net,onset=c(1,2,3,-Inf,100),terminus=c(10,20,Inf,30,Inf))
> activate.vertices(net,at=1000)
> expect_equal(unlist(get.vertex.activity(net)),c(1,1000,10,1000,2,1000,20,1000,3,Inf,-Inf,1000,30,1000,100,Inf),info='check if spell list has correct elements in get.vertex.activity')
>
> expect_equivalent(get.vertex.activity(net,as.spellList=TRUE),data.frame(onset=c(1,1000,2,1000,3,-Inf,1000,100),terminus=c(10,1000,20,1000,Inf,30,1000,Inf),vertex.id=c(1,1,2,2,3,4,4,5),onset.censored=c(FALSE,FALSE,FALSE,FALSE,FALSE,TRUE,FALSE,FALSE),terminus.censored=c(FALSE,FALSE,FALSE,FALSE,TRUE,FALSE,FALSE,TRUE),duration=c(9,0,18,0,Inf,Inf,0,Inf)),info="check if get.vertex.activity(spellList) returns correct data")
>
> # check sort order
> expect_equal(get.vertex.activity(net,as.spellList=TRUE)$vertex.id,c(1,1,2,2,3,4,4,5),info="check sort order of get.vertex.activity vertex.id")
>
> expect_equal(get.vertex.activity(net,as.spellList=TRUE)$onset,c(1,1000,2,1000,3,-Inf,1000,100),info="check sort order of get.vertex.activity onset")
> expect_equal(get.vertex.activity(net,as.spellList=TRUE)$terminus,c(10,1000,20,1000,Inf,30,1000,Inf),info="check sort order of get.vertex.activity terminus")
>
> expect_equal(get.vertex.activity(network.initialize(0)),list())
>
>
>
>
> # check that net.obs.period triggers censoring
> nop <- list(observations=list(c(-5,1001)), mode="discrete", time.increment=1,time.unit="step")
> set.network.attribute(net,'net.obs.period',nop)
> expect_equivalent(get.vertex.activity(net,as.spellList=TRUE),data.frame(onset=c(1,1000,2,1000,3,-5,1000,100),terminus=c(10,1000,20,1000,1001,30,1000,1001),vertex.id=c(1,1,2,2,3,4,4,5),onset.censored=c(FALSE,FALSE,FALSE,FALSE,FALSE,TRUE,FALSE,FALSE),terminus.censored=c(FALSE,FALSE,FALSE,FALSE,TRUE,FALSE,FALSE,TRUE),duration=c(9,0,18,0,998,35,0,901)),info="check that net.obs.period triggers censoring in get.vertex.activity(spellList)")
>
>
> # check for bug with no activity #192
> nd<-network.initialize(2)
> nd<-add.edges.active(nd,at=1,tail=1,head=2)
>
> expect_equivalent(get.vertex.activity(nd,as.spellList=TRUE),data.frame(onset=c(-Inf,-Inf),terminus=c(Inf,Inf),vertex.id=c(1,2),onset.censored=c(TRUE,TRUE),terminus.censored=c(TRUE,TRUE),duration=c(Inf,Inf)),info="checking with no vertex activity")
>
> # test if activity is missing for an element
> activate.vertices(nd,onset=1,terminus=2,v=2)
> expect_equivalent(get.vertex.activity(nd,as.spellList=TRUE),data.frame(onset=c(-Inf,1),terminus=c(Inf,2),vertex.id=c(1,2),onset.censored=c(TRUE,FALSE),terminus.censored=c(TRUE,FALSE),duration=c(Inf,1)),info="test when only some verticies have activity")
>
> # test when default activity set false
> expect_equivalent(
+ get.vertex.activity(nd,as.spellList=TRUE,active.default=FALSE),
+ data.frame(onset=1,terminus=2,vertex.id=2,onset.censored=FALSE,terminus.censored=FALSE,duration=1),info="test when only some verticies have activity and active.default=FALSE")
>
> # test if v specified for spellmatrix
> nd <- network.initialize(5)
> activate.vertices(nd,onset=0:4,terminus=1:5)
> expect_equivalent(
+ get.vertex.activity(nd,as.spellList=TRUE,v=2:4)[,1:3],
+ data.frame(onset=1:3,terminus=2:4,vertex.id=2:4),info="test when when v argument specified with spellmatrix")
>
> expect_equivalent(
+ unlist(get.vertex.activity(nd,,v=2:4)),c(1,2,2,3,3,4)
+ ,info="test when when v argument specified")
>
>
> # test if called with ordinary network
> expect_equal(unlist(get.vertex.activity(network.initialize(3))),c(-Inf,Inf,-Inf,Inf,-Inf,Inf),info="calling with ordinary network")
>
> # test when called with something else
> expect_error(get.vertex.activity(list()),'requires an argument of class network')
Error: `get.vertex.activity(list())` threw an error with unexpected message.
Expected match: "requires an argument of class network"
Actual message: "no applicable method for 'network.size' applied to an object of class \"list\""
Execution halted
Flavor: r-devel-linux-x86_64-debian-gcc
Version: 0.9.0
Check: tests
Result: ERROR
Running ‘activate_tests.R’
Running ‘age.at_tests.R’
Running ‘classTests.R’
Running ‘converter_tests.R’
Running ‘get_tests.R’
Running ‘import_tests.R’
Running ‘network_tests.R’
Running ‘pid_tests.R’
Running ‘query_tests.R’
Running ‘reconcile.activityTests.R’
Running ‘tea_tests.R’
Running ‘utils_tests.R’
Running ‘when_tests.R’
Running the tests in ‘tests/converter_tests.R’ failed.
Complete output:
> # Part of the statnet package, http://statnetproject.org
> #
> # This software is distributed under the GPL-3 license. It is free,
> # open source, and has the attribution requirements (GPL Section 7) in
> # http://statnetproject.org/attribution
> #
> # Copyright 2013 the statnet development team
> ######################################################################
>
> #test networkDynamic conversion functionality
>
> require(networkDynamic)
Loading required package: networkDynamic
Loading required package: network
network: Classes for Relational Data
Version 1.14-377 created on 2019-03-04.
copyright (c) 2005, Carter T. Butts, University of California-Irvine
Mark S. Handcock, University of California -- Los Angeles
David R. Hunter, Penn State University
Martina Morris, University of Washington
Skye Bender-deMoll, University of Washington
For citation information, type citation("network").
Type help("network-package") to get started.
networkDynamic: version 0.9.0, created on 2016-01-12
Copyright (c) 2016, Carter T. Butts, University of California -- Irvine
Ayn Leslie-Cook, University of Washington
Pavel N. Krivitsky, University of Wollongong
Skye Bender-deMoll, University of Washington
with contributions from
Zack Almquist, University of California -- Irvine
David R. Hunter, Penn State University
Li Wang
Kirk Li, University of Washington
Steven M. Goodreau, University of Washington
Jeffrey Horner
Martina Morris, University of Washington
Based on "statnet" project software (statnet.org).
For license and citation information see statnet.org/attribution
or type citation("networkDynamic").
> require(testthat)
Loading required package: testthat
>
>
> # ------ get.vertex.activity test ------
>
> net<-network.initialize(5)
> activate.vertices(net,onset=c(1,2,3,-Inf,100),terminus=c(10,20,Inf,30,Inf))
> activate.vertices(net,at=1000)
> expect_equal(unlist(get.vertex.activity(net)),c(1,1000,10,1000,2,1000,20,1000,3,Inf,-Inf,1000,30,1000,100,Inf),info='check if spell list has correct elements in get.vertex.activity')
>
> expect_equivalent(get.vertex.activity(net,as.spellList=TRUE),data.frame(onset=c(1,1000,2,1000,3,-Inf,1000,100),terminus=c(10,1000,20,1000,Inf,30,1000,Inf),vertex.id=c(1,1,2,2,3,4,4,5),onset.censored=c(FALSE,FALSE,FALSE,FALSE,FALSE,TRUE,FALSE,FALSE),terminus.censored=c(FALSE,FALSE,FALSE,FALSE,TRUE,FALSE,FALSE,TRUE),duration=c(9,0,18,0,Inf,Inf,0,Inf)),info="check if get.vertex.activity(spellList) returns correct data")
>
> # check sort order
> expect_equal(get.vertex.activity(net,as.spellList=TRUE)$vertex.id,c(1,1,2,2,3,4,4,5),info="check sort order of get.vertex.activity vertex.id")
>
> expect_equal(get.vertex.activity(net,as.spellList=TRUE)$onset,c(1,1000,2,1000,3,-Inf,1000,100),info="check sort order of get.vertex.activity onset")
> expect_equal(get.vertex.activity(net,as.spellList=TRUE)$terminus,c(10,1000,20,1000,Inf,30,1000,Inf),info="check sort order of get.vertex.activity terminus")
>
> expect_equal(get.vertex.activity(network.initialize(0)),list())
>
>
>
>
> # check that net.obs.period triggers censoring
> nop <- list(observations=list(c(-5,1001)), mode="discrete", time.increment=1,time.unit="step")
> set.network.attribute(net,'net.obs.period',nop)
> expect_equivalent(get.vertex.activity(net,as.spellList=TRUE),data.frame(onset=c(1,1000,2,1000,3,-5,1000,100),terminus=c(10,1000,20,1000,1001,30,1000,1001),vertex.id=c(1,1,2,2,3,4,4,5),onset.censored=c(FALSE,FALSE,FALSE,FALSE,FALSE,TRUE,FALSE,FALSE),terminus.censored=c(FALSE,FALSE,FALSE,FALSE,TRUE,FALSE,FALSE,TRUE),duration=c(9,0,18,0,998,35,0,901)),info="check that net.obs.period triggers censoring in get.vertex.activity(spellList)")
>
>
> # check for bug with no activity #192
> nd<-network.initialize(2)
> nd<-add.edges.active(nd,at=1,tail=1,head=2)
>
> expect_equivalent(get.vertex.activity(nd,as.spellList=TRUE),data.frame(onset=c(-Inf,-Inf),terminus=c(Inf,Inf),vertex.id=c(1,2),onset.censored=c(TRUE,TRUE),terminus.censored=c(TRUE,TRUE),duration=c(Inf,Inf)),info="checking with no vertex activity")
>
> # test if activity is missing for an element
> activate.vertices(nd,onset=1,terminus=2,v=2)
> expect_equivalent(get.vertex.activity(nd,as.spellList=TRUE),data.frame(onset=c(-Inf,1),terminus=c(Inf,2),vertex.id=c(1,2),onset.censored=c(TRUE,FALSE),terminus.censored=c(TRUE,FALSE),duration=c(Inf,1)),info="test when only some verticies have activity")
>
> # test when default activity set false
> expect_equivalent(
+ get.vertex.activity(nd,as.spellList=TRUE,active.default=FALSE),
+ data.frame(onset=1,terminus=2,vertex.id=2,onset.censored=FALSE,terminus.censored=FALSE,duration=1),info="test when only some verticies have activity and active.default=FALSE")
>
> # test if v specified for spellmatrix
> nd <- network.initialize(5)
> activate.vertices(nd,onset=0:4,terminus=1:5)
> expect_equivalent(
+ get.vertex.activity(nd,as.spellList=TRUE,v=2:4)[,1:3],
+ data.frame(onset=1:3,terminus=2:4,vertex.id=2:4),info="test when when v argument specified with spellmatrix")
>
> expect_equivalent(
+ unlist(get.vertex.activity(nd,,v=2:4)),c(1,2,2,3,3,4)
+ ,info="test when when v argument specified")
>
>
> # test if called with ordinary network
> expect_equal(unlist(get.vertex.activity(network.initialize(3))),c(-Inf,Inf,-Inf,Inf,-Inf,Inf),info="calling with ordinary network")
>
> # test when called with something else
> expect_error(get.vertex.activity(list()),'requires an argument of class network')
Error: `get.vertex.activity(list())` threw an error with unexpected message.
Expected match: "requires an argument of class network"
Actual message: "no applicable method for 'network.size' applied to an object of class \"list\""
Execution halted
Flavors: r-devel-linux-x86_64-fedora-clang, r-devel-linux-x86_64-fedora-gcc
Version: 0.9.0
Check: running tests for arch ‘i386’
Result: ERROR
Running 'activate_tests.R' [2s]
Running 'age.at_tests.R' [1s]
Running 'classTests.R' [1s]
Running 'converter_tests.R' [1s]
Running 'get_tests.R' [3s]
Running 'import_tests.R' [6s]
Running 'network_tests.R' [2s]
Running 'pid_tests.R' [1s]
Running 'query_tests.R' [1s]
Running 'reconcile.activityTests.R' [1s]
Running 'tea_tests.R' [1s]
Running 'utils_tests.R' [1s]
Running 'when_tests.R' [1s]
Running the tests in 'tests/converter_tests.R' failed.
Complete output:
> # Part of the statnet package, http://statnetproject.org
> #
> # This software is distributed under the GPL-3 license. It is free,
> # open source, and has the attribution requirements (GPL Section 7) in
> # http://statnetproject.org/attribution
> #
> # Copyright 2013 the statnet development team
> ######################################################################
>
> #test networkDynamic conversion functionality
>
> require(networkDynamic)
Loading required package: networkDynamic
Loading required package: network
network: Classes for Relational Data
Version 1.14-377 created on 2019-03-04.
copyright (c) 2005, Carter T. Butts, University of California-Irvine
Mark S. Handcock, University of California -- Los Angeles
David R. Hunter, Penn State University
Martina Morris, University of Washington
Skye Bender-deMoll, University of Washington
For citation information, type citation("network").
Type help("network-package") to get started.
networkDynamic: version 0.9.0, created on 2016-01-12
Copyright (c) 2016, Carter T. Butts, University of California -- Irvine
Ayn Leslie-Cook, University of Washington
Pavel N. Krivitsky, University of Wollongong
Skye Bender-deMoll, University of Washington
with contributions from
Zack Almquist, University of California -- Irvine
David R. Hunter, Penn State University
Li Wang
Kirk Li, University of Washington
Steven M. Goodreau, University of Washington
Jeffrey Horner
Martina Morris, University of Washington
Based on "statnet" project software (statnet.org).
For license and citation information see statnet.org/attribution
or type citation("networkDynamic").
> require(testthat)
Loading required package: testthat
>
>
> # ------ get.vertex.activity test ------
>
> net<-network.initialize(5)
> activate.vertices(net,onset=c(1,2,3,-Inf,100),terminus=c(10,20,Inf,30,Inf))
> activate.vertices(net,at=1000)
> expect_equal(unlist(get.vertex.activity(net)),c(1,1000,10,1000,2,1000,20,1000,3,Inf,-Inf,1000,30,1000,100,Inf),info='check if spell list has correct elements in get.vertex.activity')
>
> expect_equivalent(get.vertex.activity(net,as.spellList=TRUE),data.frame(onset=c(1,1000,2,1000,3,-Inf,1000,100),terminus=c(10,1000,20,1000,Inf,30,1000,Inf),vertex.id=c(1,1,2,2,3,4,4,5),onset.censored=c(FALSE,FALSE,FALSE,FALSE,FALSE,TRUE,FALSE,FALSE),terminus.censored=c(FALSE,FALSE,FALSE,FALSE,TRUE,FALSE,FALSE,TRUE),duration=c(9,0,18,0,Inf,Inf,0,Inf)),info="check if get.vertex.activity(spellList) returns correct data")
>
> # check sort order
> expect_equal(get.vertex.activity(net,as.spellList=TRUE)$vertex.id,c(1,1,2,2,3,4,4,5),info="check sort order of get.vertex.activity vertex.id")
>
> expect_equal(get.vertex.activity(net,as.spellList=TRUE)$onset,c(1,1000,2,1000,3,-Inf,1000,100),info="check sort order of get.vertex.activity onset")
> expect_equal(get.vertex.activity(net,as.spellList=TRUE)$terminus,c(10,1000,20,1000,Inf,30,1000,Inf),info="check sort order of get.vertex.activity terminus")
>
> expect_equal(get.vertex.activity(network.initialize(0)),list())
>
>
>
>
> # check that net.obs.period triggers censoring
> nop <- list(observations=list(c(-5,1001)), mode="discrete", time.increment=1,time.unit="step")
> set.network.attribute(net,'net.obs.period',nop)
> expect_equivalent(get.vertex.activity(net,as.spellList=TRUE),data.frame(onset=c(1,1000,2,1000,3,-5,1000,100),terminus=c(10,1000,20,1000,1001,30,1000,1001),vertex.id=c(1,1,2,2,3,4,4,5),onset.censored=c(FALSE,FALSE,FALSE,FALSE,FALSE,TRUE,FALSE,FALSE),terminus.censored=c(FALSE,FALSE,FALSE,FALSE,TRUE,FALSE,FALSE,TRUE),duration=c(9,0,18,0,998,35,0,901)),info="check that net.obs.period triggers censoring in get.vertex.activity(spellList)")
>
>
> # check for bug with no activity #192
> nd<-network.initialize(2)
> nd<-add.edges.active(nd,at=1,tail=1,head=2)
>
> expect_equivalent(get.vertex.activity(nd,as.spellList=TRUE),data.frame(onset=c(-Inf,-Inf),terminus=c(Inf,Inf),vertex.id=c(1,2),onset.censored=c(TRUE,TRUE),terminus.censored=c(TRUE,TRUE),duration=c(Inf,Inf)),info="checking with no vertex activity")
>
> # test if activity is missing for an element
> activate.vertices(nd,onset=1,terminus=2,v=2)
> expect_equivalent(get.vertex.activity(nd,as.spellList=TRUE),data.frame(onset=c(-Inf,1),terminus=c(Inf,2),vertex.id=c(1,2),onset.censored=c(TRUE,FALSE),terminus.censored=c(TRUE,FALSE),duration=c(Inf,1)),info="test when only some verticies have activity")
>
> # test when default activity set false
> expect_equivalent(
+ get.vertex.activity(nd,as.spellList=TRUE,active.default=FALSE),
+ data.frame(onset=1,terminus=2,vertex.id=2,onset.censored=FALSE,terminus.censored=FALSE,duration=1),info="test when only some verticies have activity and active.default=FALSE")
>
> # test if v specified for spellmatrix
> nd <- network.initialize(5)
> activate.vertices(nd,onset=0:4,terminus=1:5)
> expect_equivalent(
+ get.vertex.activity(nd,as.spellList=TRUE,v=2:4)[,1:3],
+ data.frame(onset=1:3,terminus=2:4,vertex.id=2:4),info="test when when v argument specified with spellmatrix")
>
> expect_equivalent(
+ unlist(get.vertex.activity(nd,,v=2:4)),c(1,2,2,3,3,4)
+ ,info="test when when v argument specified")
>
>
> # test if called with ordinary network
> expect_equal(unlist(get.vertex.activity(network.initialize(3))),c(-Inf,Inf,-Inf,Inf,-Inf,Inf),info="calling with ordinary network")
>
> # test when called with something else
> expect_error(get.vertex.activity(list()),'requires an argument of class network')
Error: `get.vertex.activity(list())` threw an error with unexpected message.
Expected match: "requires an argument of class network"
Actual message: "no applicable method for 'network.size' applied to an object of class \"list\""
Execution halted
Flavor: r-devel-windows-ix86+x86_64
Version: 0.9.0
Check: running tests for arch ‘x64’
Result: ERROR
Running 'activate_tests.R' [2s]
Running 'age.at_tests.R' [1s]
Running 'classTests.R' [1s]
Running 'converter_tests.R' [1s]
Running 'get_tests.R' [4s]
Running 'import_tests.R' [7s]
Running 'network_tests.R' [2s]
Running 'pid_tests.R' [1s]
Running 'query_tests.R' [1s]
Running 'reconcile.activityTests.R' [1s]
Running 'tea_tests.R' [1s]
Running 'utils_tests.R' [1s]
Running 'when_tests.R' [1s]
Running the tests in 'tests/converter_tests.R' failed.
Complete output:
> # Part of the statnet package, http://statnetproject.org
> #
> # This software is distributed under the GPL-3 license. It is free,
> # open source, and has the attribution requirements (GPL Section 7) in
> # http://statnetproject.org/attribution
> #
> # Copyright 2013 the statnet development team
> ######################################################################
>
> #test networkDynamic conversion functionality
>
> require(networkDynamic)
Loading required package: networkDynamic
Loading required package: network
network: Classes for Relational Data
Version 1.14-377 created on 2019-03-04.
copyright (c) 2005, Carter T. Butts, University of California-Irvine
Mark S. Handcock, University of California -- Los Angeles
David R. Hunter, Penn State University
Martina Morris, University of Washington
Skye Bender-deMoll, University of Washington
For citation information, type citation("network").
Type help("network-package") to get started.
networkDynamic: version 0.9.0, created on 2016-01-12
Copyright (c) 2016, Carter T. Butts, University of California -- Irvine
Ayn Leslie-Cook, University of Washington
Pavel N. Krivitsky, University of Wollongong
Skye Bender-deMoll, University of Washington
with contributions from
Zack Almquist, University of California -- Irvine
David R. Hunter, Penn State University
Li Wang
Kirk Li, University of Washington
Steven M. Goodreau, University of Washington
Jeffrey Horner
Martina Morris, University of Washington
Based on "statnet" project software (statnet.org).
For license and citation information see statnet.org/attribution
or type citation("networkDynamic").
> require(testthat)
Loading required package: testthat
>
>
> # ------ get.vertex.activity test ------
>
> net<-network.initialize(5)
> activate.vertices(net,onset=c(1,2,3,-Inf,100),terminus=c(10,20,Inf,30,Inf))
> activate.vertices(net,at=1000)
> expect_equal(unlist(get.vertex.activity(net)),c(1,1000,10,1000,2,1000,20,1000,3,Inf,-Inf,1000,30,1000,100,Inf),info='check if spell list has correct elements in get.vertex.activity')
>
> expect_equivalent(get.vertex.activity(net,as.spellList=TRUE),data.frame(onset=c(1,1000,2,1000,3,-Inf,1000,100),terminus=c(10,1000,20,1000,Inf,30,1000,Inf),vertex.id=c(1,1,2,2,3,4,4,5),onset.censored=c(FALSE,FALSE,FALSE,FALSE,FALSE,TRUE,FALSE,FALSE),terminus.censored=c(FALSE,FALSE,FALSE,FALSE,TRUE,FALSE,FALSE,TRUE),duration=c(9,0,18,0,Inf,Inf,0,Inf)),info="check if get.vertex.activity(spellList) returns correct data")
>
> # check sort order
> expect_equal(get.vertex.activity(net,as.spellList=TRUE)$vertex.id,c(1,1,2,2,3,4,4,5),info="check sort order of get.vertex.activity vertex.id")
>
> expect_equal(get.vertex.activity(net,as.spellList=TRUE)$onset,c(1,1000,2,1000,3,-Inf,1000,100),info="check sort order of get.vertex.activity onset")
> expect_equal(get.vertex.activity(net,as.spellList=TRUE)$terminus,c(10,1000,20,1000,Inf,30,1000,Inf),info="check sort order of get.vertex.activity terminus")
>
> expect_equal(get.vertex.activity(network.initialize(0)),list())
>
>
>
>
> # check that net.obs.period triggers censoring
> nop <- list(observations=list(c(-5,1001)), mode="discrete", time.increment=1,time.unit="step")
> set.network.attribute(net,'net.obs.period',nop)
> expect_equivalent(get.vertex.activity(net,as.spellList=TRUE),data.frame(onset=c(1,1000,2,1000,3,-5,1000,100),terminus=c(10,1000,20,1000,1001,30,1000,1001),vertex.id=c(1,1,2,2,3,4,4,5),onset.censored=c(FALSE,FALSE,FALSE,FALSE,FALSE,TRUE,FALSE,FALSE),terminus.censored=c(FALSE,FALSE,FALSE,FALSE,TRUE,FALSE,FALSE,TRUE),duration=c(9,0,18,0,998,35,0,901)),info="check that net.obs.period triggers censoring in get.vertex.activity(spellList)")
>
>
> # check for bug with no activity #192
> nd<-network.initialize(2)
> nd<-add.edges.active(nd,at=1,tail=1,head=2)
>
> expect_equivalent(get.vertex.activity(nd,as.spellList=TRUE),data.frame(onset=c(-Inf,-Inf),terminus=c(Inf,Inf),vertex.id=c(1,2),onset.censored=c(TRUE,TRUE),terminus.censored=c(TRUE,TRUE),duration=c(Inf,Inf)),info="checking with no vertex activity")
>
> # test if activity is missing for an element
> activate.vertices(nd,onset=1,terminus=2,v=2)
> expect_equivalent(get.vertex.activity(nd,as.spellList=TRUE),data.frame(onset=c(-Inf,1),terminus=c(Inf,2),vertex.id=c(1,2),onset.censored=c(TRUE,FALSE),terminus.censored=c(TRUE,FALSE),duration=c(Inf,1)),info="test when only some verticies have activity")
>
> # test when default activity set false
> expect_equivalent(
+ get.vertex.activity(nd,as.spellList=TRUE,active.default=FALSE),
+ data.frame(onset=1,terminus=2,vertex.id=2,onset.censored=FALSE,terminus.censored=FALSE,duration=1),info="test when only some verticies have activity and active.default=FALSE")
>
> # test if v specified for spellmatrix
> nd <- network.initialize(5)
> activate.vertices(nd,onset=0:4,terminus=1:5)
> expect_equivalent(
+ get.vertex.activity(nd,as.spellList=TRUE,v=2:4)[,1:3],
+ data.frame(onset=1:3,terminus=2:4,vertex.id=2:4),info="test when when v argument specified with spellmatrix")
>
> expect_equivalent(
+ unlist(get.vertex.activity(nd,,v=2:4)),c(1,2,2,3,3,4)
+ ,info="test when when v argument specified")
>
>
> # test if called with ordinary network
> expect_equal(unlist(get.vertex.activity(network.initialize(3))),c(-Inf,Inf,-Inf,Inf,-Inf,Inf),info="calling with ordinary network")
>
> # test when called with something else
> expect_error(get.vertex.activity(list()),'requires an argument of class network')
Error: `get.vertex.activity(list())` threw an error with unexpected message.
Expected match: "requires an argument of class network"
Actual message: "no applicable method for 'network.size' applied to an object of class \"list\""
Execution halted
Flavor: r-devel-windows-ix86+x86_64
Version: 0.9.0
Check: tests
Result: ERROR
Running ‘activate_tests.R’ [1s/1s]
Running ‘age.at_tests.R’ [1s/1s]
Running ‘classTests.R’ [1s/1s]
Running ‘converter_tests.R’ [1s/1s]
Running ‘get_tests.R’ [3s/3s]
Running ‘import_tests.R’ [5s/6s]
Running ‘network_tests.R’ [1s/2s]
Running ‘pid_tests.R’ [1s/1s]
Running ‘query_tests.R’ [1s/1s]
Running ‘reconcile.activityTests.R’ [1s/1s]
Running ‘tea_tests.R’ [1s/1s]
Running ‘utils_tests.R’ [1s/1s]
Running ‘when_tests.R’ [1s/1s]
Running the tests in ‘tests/converter_tests.R’ failed.
Complete output:
> # Part of the statnet package, http://statnetproject.org
> #
> # This software is distributed under the GPL-3 license. It is free,
> # open source, and has the attribution requirements (GPL Section 7) in
> # http://statnetproject.org/attribution
> #
> # Copyright 2013 the statnet development team
> ######################################################################
>
> #test networkDynamic conversion functionality
>
> require(networkDynamic)
Loading required package: networkDynamic
Loading required package: network
network: Classes for Relational Data
Version 1.14-377 created on 2019-03-04.
copyright (c) 2005, Carter T. Butts, University of California-Irvine
Mark S. Handcock, University of California -- Los Angeles
David R. Hunter, Penn State University
Martina Morris, University of Washington
Skye Bender-deMoll, University of Washington
For citation information, type citation("network").
Type help("network-package") to get started.
networkDynamic: version 0.9.0, created on 2016-01-12
Copyright (c) 2016, Carter T. Butts, University of California -- Irvine
Ayn Leslie-Cook, University of Washington
Pavel N. Krivitsky, University of Wollongong
Skye Bender-deMoll, University of Washington
with contributions from
Zack Almquist, University of California -- Irvine
David R. Hunter, Penn State University
Li Wang
Kirk Li, University of Washington
Steven M. Goodreau, University of Washington
Jeffrey Horner
Martina Morris, University of Washington
Based on "statnet" project software (statnet.org).
For license and citation information see statnet.org/attribution
or type citation("networkDynamic").
> require(testthat)
Loading required package: testthat
>
>
> # ------ get.vertex.activity test ------
>
> net<-network.initialize(5)
> activate.vertices(net,onset=c(1,2,3,-Inf,100),terminus=c(10,20,Inf,30,Inf))
> activate.vertices(net,at=1000)
> expect_equal(unlist(get.vertex.activity(net)),c(1,1000,10,1000,2,1000,20,1000,3,Inf,-Inf,1000,30,1000,100,Inf),info='check if spell list has correct elements in get.vertex.activity')
>
> expect_equivalent(get.vertex.activity(net,as.spellList=TRUE),data.frame(onset=c(1,1000,2,1000,3,-Inf,1000,100),terminus=c(10,1000,20,1000,Inf,30,1000,Inf),vertex.id=c(1,1,2,2,3,4,4,5),onset.censored=c(FALSE,FALSE,FALSE,FALSE,FALSE,TRUE,FALSE,FALSE),terminus.censored=c(FALSE,FALSE,FALSE,FALSE,TRUE,FALSE,FALSE,TRUE),duration=c(9,0,18,0,Inf,Inf,0,Inf)),info="check if get.vertex.activity(spellList) returns correct data")
>
> # check sort order
> expect_equal(get.vertex.activity(net,as.spellList=TRUE)$vertex.id,c(1,1,2,2,3,4,4,5),info="check sort order of get.vertex.activity vertex.id")
>
> expect_equal(get.vertex.activity(net,as.spellList=TRUE)$onset,c(1,1000,2,1000,3,-Inf,1000,100),info="check sort order of get.vertex.activity onset")
> expect_equal(get.vertex.activity(net,as.spellList=TRUE)$terminus,c(10,1000,20,1000,Inf,30,1000,Inf),info="check sort order of get.vertex.activity terminus")
>
> expect_equal(get.vertex.activity(network.initialize(0)),list())
>
>
>
>
> # check that net.obs.period triggers censoring
> nop <- list(observations=list(c(-5,1001)), mode="discrete", time.increment=1,time.unit="step")
> set.network.attribute(net,'net.obs.period',nop)
> expect_equivalent(get.vertex.activity(net,as.spellList=TRUE),data.frame(onset=c(1,1000,2,1000,3,-5,1000,100),terminus=c(10,1000,20,1000,1001,30,1000,1001),vertex.id=c(1,1,2,2,3,4,4,5),onset.censored=c(FALSE,FALSE,FALSE,FALSE,FALSE,TRUE,FALSE,FALSE),terminus.censored=c(FALSE,FALSE,FALSE,FALSE,TRUE,FALSE,FALSE,TRUE),duration=c(9,0,18,0,998,35,0,901)),info="check that net.obs.period triggers censoring in get.vertex.activity(spellList)")
>
>
> # check for bug with no activity #192
> nd<-network.initialize(2)
> nd<-add.edges.active(nd,at=1,tail=1,head=2)
>
> expect_equivalent(get.vertex.activity(nd,as.spellList=TRUE),data.frame(onset=c(-Inf,-Inf),terminus=c(Inf,Inf),vertex.id=c(1,2),onset.censored=c(TRUE,TRUE),terminus.censored=c(TRUE,TRUE),duration=c(Inf,Inf)),info="checking with no vertex activity")
>
> # test if activity is missing for an element
> activate.vertices(nd,onset=1,terminus=2,v=2)
> expect_equivalent(get.vertex.activity(nd,as.spellList=TRUE),data.frame(onset=c(-Inf,1),terminus=c(Inf,2),vertex.id=c(1,2),onset.censored=c(TRUE,FALSE),terminus.censored=c(TRUE,FALSE),duration=c(Inf,1)),info="test when only some verticies have activity")
>
> # test when default activity set false
> expect_equivalent(
+ get.vertex.activity(nd,as.spellList=TRUE,active.default=FALSE),
+ data.frame(onset=1,terminus=2,vertex.id=2,onset.censored=FALSE,terminus.censored=FALSE,duration=1),info="test when only some verticies have activity and active.default=FALSE")
>
> # test if v specified for spellmatrix
> nd <- network.initialize(5)
> activate.vertices(nd,onset=0:4,terminus=1:5)
> expect_equivalent(
+ get.vertex.activity(nd,as.spellList=TRUE,v=2:4)[,1:3],
+ data.frame(onset=1:3,terminus=2:4,vertex.id=2:4),info="test when when v argument specified with spellmatrix")
>
> expect_equivalent(
+ unlist(get.vertex.activity(nd,,v=2:4)),c(1,2,2,3,3,4)
+ ,info="test when when v argument specified")
>
>
> # test if called with ordinary network
> expect_equal(unlist(get.vertex.activity(network.initialize(3))),c(-Inf,Inf,-Inf,Inf,-Inf,Inf),info="calling with ordinary network")
>
> # test when called with something else
> expect_error(get.vertex.activity(list()),'requires an argument of class network')
Error: `get.vertex.activity(list())` threw an error with unexpected message.
Expected match: "requires an argument of class network"
Actual message: "no applicable method for 'network.size' applied to an object of class \"list\""
Execution halted
Flavors: r-patched-linux-x86_64, r-release-linux-x86_64
Version: 0.9.0
Check: tests
Result: ERROR
Running ‘activate_tests.R’
Running ‘age.at_tests.R’
Running ‘classTests.R’
Running ‘converter_tests.R’
Running ‘get_tests.R’
Running ‘import_tests.R’ [9s/11s]
Running ‘network_tests.R’
Running ‘pid_tests.R’
Running ‘query_tests.R’
Running ‘reconcile.activityTests.R’
Running ‘tea_tests.R’
Running ‘utils_tests.R’
Running ‘when_tests.R’
Running the tests in ‘tests/converter_tests.R’ failed.
Complete output:
> # Part of the statnet package, http://statnetproject.org
> #
> # This software is distributed under the GPL-3 license. It is free,
> # open source, and has the attribution requirements (GPL Section 7) in
> # http://statnetproject.org/attribution
> #
> # Copyright 2013 the statnet development team
> ######################################################################
>
> #test networkDynamic conversion functionality
>
> require(networkDynamic)
Loading required package: networkDynamic
Loading required package: network
network: Classes for Relational Data
Version 1.14-377 created on 2019-03-04.
copyright (c) 2005, Carter T. Butts, University of California-Irvine
Mark S. Handcock, University of California -- Los Angeles
David R. Hunter, Penn State University
Martina Morris, University of Washington
Skye Bender-deMoll, University of Washington
For citation information, type citation("network").
Type help("network-package") to get started.
networkDynamic: version 0.9.0, created on 2016-01-12
Copyright (c) 2016, Carter T. Butts, University of California -- Irvine
Ayn Leslie-Cook, University of Washington
Pavel N. Krivitsky, University of Wollongong
Skye Bender-deMoll, University of Washington
with contributions from
Zack Almquist, University of California -- Irvine
David R. Hunter, Penn State University
Li Wang
Kirk Li, University of Washington
Steven M. Goodreau, University of Washington
Jeffrey Horner
Martina Morris, University of Washington
Based on "statnet" project software (statnet.org).
For license and citation information see statnet.org/attribution
or type citation("networkDynamic").
> require(testthat)
Loading required package: testthat
>
>
> # ------ get.vertex.activity test ------
>
> net<-network.initialize(5)
> activate.vertices(net,onset=c(1,2,3,-Inf,100),terminus=c(10,20,Inf,30,Inf))
> activate.vertices(net,at=1000)
> expect_equal(unlist(get.vertex.activity(net)),c(1,1000,10,1000,2,1000,20,1000,3,Inf,-Inf,1000,30,1000,100,Inf),info='check if spell list has correct elements in get.vertex.activity')
>
> expect_equivalent(get.vertex.activity(net,as.spellList=TRUE),data.frame(onset=c(1,1000,2,1000,3,-Inf,1000,100),terminus=c(10,1000,20,1000,Inf,30,1000,Inf),vertex.id=c(1,1,2,2,3,4,4,5),onset.censored=c(FALSE,FALSE,FALSE,FALSE,FALSE,TRUE,FALSE,FALSE),terminus.censored=c(FALSE,FALSE,FALSE,FALSE,TRUE,FALSE,FALSE,TRUE),duration=c(9,0,18,0,Inf,Inf,0,Inf)),info="check if get.vertex.activity(spellList) returns correct data")
>
> # check sort order
> expect_equal(get.vertex.activity(net,as.spellList=TRUE)$vertex.id,c(1,1,2,2,3,4,4,5),info="check sort order of get.vertex.activity vertex.id")
>
> expect_equal(get.vertex.activity(net,as.spellList=TRUE)$onset,c(1,1000,2,1000,3,-Inf,1000,100),info="check sort order of get.vertex.activity onset")
> expect_equal(get.vertex.activity(net,as.spellList=TRUE)$terminus,c(10,1000,20,1000,Inf,30,1000,Inf),info="check sort order of get.vertex.activity terminus")
>
> expect_equal(get.vertex.activity(network.initialize(0)),list())
>
>
>
>
> # check that net.obs.period triggers censoring
> nop <- list(observations=list(c(-5,1001)), mode="discrete", time.increment=1,time.unit="step")
> set.network.attribute(net,'net.obs.period',nop)
> expect_equivalent(get.vertex.activity(net,as.spellList=TRUE),data.frame(onset=c(1,1000,2,1000,3,-5,1000,100),terminus=c(10,1000,20,1000,1001,30,1000,1001),vertex.id=c(1,1,2,2,3,4,4,5),onset.censored=c(FALSE,FALSE,FALSE,FALSE,FALSE,TRUE,FALSE,FALSE),terminus.censored=c(FALSE,FALSE,FALSE,FALSE,TRUE,FALSE,FALSE,TRUE),duration=c(9,0,18,0,998,35,0,901)),info="check that net.obs.period triggers censoring in get.vertex.activity(spellList)")
>
>
> # check for bug with no activity #192
> nd<-network.initialize(2)
> nd<-add.edges.active(nd,at=1,tail=1,head=2)
>
> expect_equivalent(get.vertex.activity(nd,as.spellList=TRUE),data.frame(onset=c(-Inf,-Inf),terminus=c(Inf,Inf),vertex.id=c(1,2),onset.censored=c(TRUE,TRUE),terminus.censored=c(TRUE,TRUE),duration=c(Inf,Inf)),info="checking with no vertex activity")
>
> # test if activity is missing for an element
> activate.vertices(nd,onset=1,terminus=2,v=2)
> expect_equivalent(get.vertex.activity(nd,as.spellList=TRUE),data.frame(onset=c(-Inf,1),terminus=c(Inf,2),vertex.id=c(1,2),onset.censored=c(TRUE,FALSE),terminus.censored=c(TRUE,FALSE),duration=c(Inf,1)),info="test when only some verticies have activity")
>
> # test when default activity set false
> expect_equivalent(
+ get.vertex.activity(nd,as.spellList=TRUE,active.default=FALSE),
+ data.frame(onset=1,terminus=2,vertex.id=2,onset.censored=FALSE,terminus.censored=FALSE,duration=1),info="test when only some verticies have activity and active.default=FALSE")
>
> # test if v specified for spellmatrix
> nd <- network.initialize(5)
> activate.vertices(nd,onset=0:4,terminus=1:5)
> expect_equivalent(
+ get.vertex.activity(nd,as.spellList=TRUE,v=2:4)[,1:3],
+ data.frame(onset=1:3,terminus=2:4,vertex.id=2:4),info="test when when v argument specified with spellmatrix")
>
> expect_equivalent(
+ unlist(get.vertex.activity(nd,,v=2:4)),c(1,2,2,3,3,4)
+ ,info="test when when v argument specified")
>
>
> # test if called with ordinary network
> expect_equal(unlist(get.vertex.activity(network.initialize(3))),c(-Inf,Inf,-Inf,Inf,-Inf,Inf),info="calling with ordinary network")
>
> # test when called with something else
> expect_error(get.vertex.activity(list()),'requires an argument of class network')
Error: `get.vertex.activity(list())` threw an error with unexpected message.
Expected match: "requires an argument of class network"
Actual message: "no applicable method for 'network.size' applied to an object of class \"list\""
Execution halted
Flavor: r-patched-solaris-x86
Version: 0.9.0
Check: S3 generic/method consistency
Result: WARN
network.dyadcount:
function(x, na.omit, ...)
network.dyadcount.active:
function(x, onset, terminus, length, at, rule, na.omit,
active.default)
network.edgecount:
function(x, na.omit, ...)
network.edgecount.active:
function(x, onset, terminus, length, at, rule, na.omit,
active.default)
network.naedgecount:
function(x, ...)
network.naedgecount.active:
function(x, onset, terminus, length, at, rule, active.default)
network.size:
function(x, ...)
network.size.active:
function(x, onset, terminus, length, at, rule, active.default)
See section 'Generic functions and methods' in the 'Writing R
Extensions' manual.
Flavors: r-release-windows-ix86+x86_64, r-oldrel-windows-ix86+x86_64
Version: 0.9.0
Check: running tests for arch ‘i386’
Result: ERROR
Running 'activate_tests.R' [1s]
Running 'age.at_tests.R' [1s]
Running 'classTests.R' [1s]
Running 'converter_tests.R' [1s]
Running 'get_tests.R' [2s]
Running 'import_tests.R' [5s]
Running 'network_tests.R' [1s]
Running 'pid_tests.R' [1s]
Running 'query_tests.R' [1s]
Running 'reconcile.activityTests.R' [1s]
Running 'tea_tests.R' [1s]
Running 'utils_tests.R' [1s]
Running 'when_tests.R' [1s]
Running the tests in 'tests/converter_tests.R' failed.
Complete output:
> # Part of the statnet package, http://statnetproject.org
> #
> # This software is distributed under the GPL-3 license. It is free,
> # open source, and has the attribution requirements (GPL Section 7) in
> # http://statnetproject.org/attribution
> #
> # Copyright 2013 the statnet development team
> ######################################################################
>
> #test networkDynamic conversion functionality
>
> require(networkDynamic)
Loading required package: networkDynamic
Loading required package: network
network: Classes for Relational Data
Version 1.14-377 created on 2019-03-04.
copyright (c) 2005, Carter T. Butts, University of California-Irvine
Mark S. Handcock, University of California -- Los Angeles
David R. Hunter, Penn State University
Martina Morris, University of Washington
Skye Bender-deMoll, University of Washington
For citation information, type citation("network").
Type help("network-package") to get started.
networkDynamic: version 0.9.0, created on 2016-01-12
Copyright (c) 2016, Carter T. Butts, University of California -- Irvine
Ayn Leslie-Cook, University of Washington
Pavel N. Krivitsky, University of Wollongong
Skye Bender-deMoll, University of Washington
with contributions from
Zack Almquist, University of California -- Irvine
David R. Hunter, Penn State University
Li Wang
Kirk Li, University of Washington
Steven M. Goodreau, University of Washington
Jeffrey Horner
Martina Morris, University of Washington
Based on "statnet" project software (statnet.org).
For license and citation information see statnet.org/attribution
or type citation("networkDynamic").
> require(testthat)
Loading required package: testthat
>
>
> # ------ get.vertex.activity test ------
>
> net<-network.initialize(5)
> activate.vertices(net,onset=c(1,2,3,-Inf,100),terminus=c(10,20,Inf,30,Inf))
> activate.vertices(net,at=1000)
> expect_equal(unlist(get.vertex.activity(net)),c(1,1000,10,1000,2,1000,20,1000,3,Inf,-Inf,1000,30,1000,100,Inf),info='check if spell list has correct elements in get.vertex.activity')
>
> expect_equivalent(get.vertex.activity(net,as.spellList=TRUE),data.frame(onset=c(1,1000,2,1000,3,-Inf,1000,100),terminus=c(10,1000,20,1000,Inf,30,1000,Inf),vertex.id=c(1,1,2,2,3,4,4,5),onset.censored=c(FALSE,FALSE,FALSE,FALSE,FALSE,TRUE,FALSE,FALSE),terminus.censored=c(FALSE,FALSE,FALSE,FALSE,TRUE,FALSE,FALSE,TRUE),duration=c(9,0,18,0,Inf,Inf,0,Inf)),info="check if get.vertex.activity(spellList) returns correct data")
>
> # check sort order
> expect_equal(get.vertex.activity(net,as.spellList=TRUE)$vertex.id,c(1,1,2,2,3,4,4,5),info="check sort order of get.vertex.activity vertex.id")
>
> expect_equal(get.vertex.activity(net,as.spellList=TRUE)$onset,c(1,1000,2,1000,3,-Inf,1000,100),info="check sort order of get.vertex.activity onset")
> expect_equal(get.vertex.activity(net,as.spellList=TRUE)$terminus,c(10,1000,20,1000,Inf,30,1000,Inf),info="check sort order of get.vertex.activity terminus")
>
> expect_equal(get.vertex.activity(network.initialize(0)),list())
>
>
>
>
> # check that net.obs.period triggers censoring
> nop <- list(observations=list(c(-5,1001)), mode="discrete", time.increment=1,time.unit="step")
> set.network.attribute(net,'net.obs.period',nop)
> expect_equivalent(get.vertex.activity(net,as.spellList=TRUE),data.frame(onset=c(1,1000,2,1000,3,-5,1000,100),terminus=c(10,1000,20,1000,1001,30,1000,1001),vertex.id=c(1,1,2,2,3,4,4,5),onset.censored=c(FALSE,FALSE,FALSE,FALSE,FALSE,TRUE,FALSE,FALSE),terminus.censored=c(FALSE,FALSE,FALSE,FALSE,TRUE,FALSE,FALSE,TRUE),duration=c(9,0,18,0,998,35,0,901)),info="check that net.obs.period triggers censoring in get.vertex.activity(spellList)")
>
>
> # check for bug with no activity #192
> nd<-network.initialize(2)
> nd<-add.edges.active(nd,at=1,tail=1,head=2)
>
> expect_equivalent(get.vertex.activity(nd,as.spellList=TRUE),data.frame(onset=c(-Inf,-Inf),terminus=c(Inf,Inf),vertex.id=c(1,2),onset.censored=c(TRUE,TRUE),terminus.censored=c(TRUE,TRUE),duration=c(Inf,Inf)),info="checking with no vertex activity")
>
> # test if activity is missing for an element
> activate.vertices(nd,onset=1,terminus=2,v=2)
> expect_equivalent(get.vertex.activity(nd,as.spellList=TRUE),data.frame(onset=c(-Inf,1),terminus=c(Inf,2),vertex.id=c(1,2),onset.censored=c(TRUE,FALSE),terminus.censored=c(TRUE,FALSE),duration=c(Inf,1)),info="test when only some verticies have activity")
>
> # test when default activity set false
> expect_equivalent(
+ get.vertex.activity(nd,as.spellList=TRUE,active.default=FALSE),
+ data.frame(onset=1,terminus=2,vertex.id=2,onset.censored=FALSE,terminus.censored=FALSE,duration=1),info="test when only some verticies have activity and active.default=FALSE")
>
> # test if v specified for spellmatrix
> nd <- network.initialize(5)
> activate.vertices(nd,onset=0:4,terminus=1:5)
> expect_equivalent(
+ get.vertex.activity(nd,as.spellList=TRUE,v=2:4)[,1:3],
+ data.frame(onset=1:3,terminus=2:4,vertex.id=2:4),info="test when when v argument specified with spellmatrix")
>
> expect_equivalent(
+ unlist(get.vertex.activity(nd,,v=2:4)),c(1,2,2,3,3,4)
+ ,info="test when when v argument specified")
>
>
> # test if called with ordinary network
> expect_equal(unlist(get.vertex.activity(network.initialize(3))),c(-Inf,Inf,-Inf,Inf,-Inf,Inf),info="calling with ordinary network")
>
> # test when called with something else
> expect_error(get.vertex.activity(list()),'requires an argument of class network')
Error: `get.vertex.activity(list())` threw an error with unexpected message.
Expected match: "requires an argument of class network"
Actual message: "no applicable method for 'network.size' applied to an object of class \"list\""
Execution halted
Flavor: r-release-windows-ix86+x86_64
Version: 0.9.0
Check: running tests for arch ‘x64’
Result: ERROR
Running 'activate_tests.R' [2s]
Running 'age.at_tests.R' [1s]
Running 'classTests.R' [1s]
Running 'converter_tests.R' [1s]
Running 'get_tests.R' [3s]
Running 'import_tests.R' [6s]
Running 'network_tests.R' [2s]
Running 'pid_tests.R' [1s]
Running 'query_tests.R' [1s]
Running 'reconcile.activityTests.R' [1s]
Running 'tea_tests.R' [1s]
Running 'utils_tests.R' [1s]
Running 'when_tests.R' [1s]
Running the tests in 'tests/converter_tests.R' failed.
Complete output:
> # Part of the statnet package, http://statnetproject.org
> #
> # This software is distributed under the GPL-3 license. It is free,
> # open source, and has the attribution requirements (GPL Section 7) in
> # http://statnetproject.org/attribution
> #
> # Copyright 2013 the statnet development team
> ######################################################################
>
> #test networkDynamic conversion functionality
>
> require(networkDynamic)
Loading required package: networkDynamic
Loading required package: network
network: Classes for Relational Data
Version 1.14-377 created on 2019-03-04.
copyright (c) 2005, Carter T. Butts, University of California-Irvine
Mark S. Handcock, University of California -- Los Angeles
David R. Hunter, Penn State University
Martina Morris, University of Washington
Skye Bender-deMoll, University of Washington
For citation information, type citation("network").
Type help("network-package") to get started.
networkDynamic: version 0.9.0, created on 2016-01-12
Copyright (c) 2016, Carter T. Butts, University of California -- Irvine
Ayn Leslie-Cook, University of Washington
Pavel N. Krivitsky, University of Wollongong
Skye Bender-deMoll, University of Washington
with contributions from
Zack Almquist, University of California -- Irvine
David R. Hunter, Penn State University
Li Wang
Kirk Li, University of Washington
Steven M. Goodreau, University of Washington
Jeffrey Horner
Martina Morris, University of Washington
Based on "statnet" project software (statnet.org).
For license and citation information see statnet.org/attribution
or type citation("networkDynamic").
> require(testthat)
Loading required package: testthat
>
>
> # ------ get.vertex.activity test ------
>
> net<-network.initialize(5)
> activate.vertices(net,onset=c(1,2,3,-Inf,100),terminus=c(10,20,Inf,30,Inf))
> activate.vertices(net,at=1000)
> expect_equal(unlist(get.vertex.activity(net)),c(1,1000,10,1000,2,1000,20,1000,3,Inf,-Inf,1000,30,1000,100,Inf),info='check if spell list has correct elements in get.vertex.activity')
>
> expect_equivalent(get.vertex.activity(net,as.spellList=TRUE),data.frame(onset=c(1,1000,2,1000,3,-Inf,1000,100),terminus=c(10,1000,20,1000,Inf,30,1000,Inf),vertex.id=c(1,1,2,2,3,4,4,5),onset.censored=c(FALSE,FALSE,FALSE,FALSE,FALSE,TRUE,FALSE,FALSE),terminus.censored=c(FALSE,FALSE,FALSE,FALSE,TRUE,FALSE,FALSE,TRUE),duration=c(9,0,18,0,Inf,Inf,0,Inf)),info="check if get.vertex.activity(spellList) returns correct data")
>
> # check sort order
> expect_equal(get.vertex.activity(net,as.spellList=TRUE)$vertex.id,c(1,1,2,2,3,4,4,5),info="check sort order of get.vertex.activity vertex.id")
>
> expect_equal(get.vertex.activity(net,as.spellList=TRUE)$onset,c(1,1000,2,1000,3,-Inf,1000,100),info="check sort order of get.vertex.activity onset")
> expect_equal(get.vertex.activity(net,as.spellList=TRUE)$terminus,c(10,1000,20,1000,Inf,30,1000,Inf),info="check sort order of get.vertex.activity terminus")
>
> expect_equal(get.vertex.activity(network.initialize(0)),list())
>
>
>
>
> # check that net.obs.period triggers censoring
> nop <- list(observations=list(c(-5,1001)), mode="discrete", time.increment=1,time.unit="step")
> set.network.attribute(net,'net.obs.period',nop)
> expect_equivalent(get.vertex.activity(net,as.spellList=TRUE),data.frame(onset=c(1,1000,2,1000,3,-5,1000,100),terminus=c(10,1000,20,1000,1001,30,1000,1001),vertex.id=c(1,1,2,2,3,4,4,5),onset.censored=c(FALSE,FALSE,FALSE,FALSE,FALSE,TRUE,FALSE,FALSE),terminus.censored=c(FALSE,FALSE,FALSE,FALSE,TRUE,FALSE,FALSE,TRUE),duration=c(9,0,18,0,998,35,0,901)),info="check that net.obs.period triggers censoring in get.vertex.activity(spellList)")
>
>
> # check for bug with no activity #192
> nd<-network.initialize(2)
> nd<-add.edges.active(nd,at=1,tail=1,head=2)
>
> expect_equivalent(get.vertex.activity(nd,as.spellList=TRUE),data.frame(onset=c(-Inf,-Inf),terminus=c(Inf,Inf),vertex.id=c(1,2),onset.censored=c(TRUE,TRUE),terminus.censored=c(TRUE,TRUE),duration=c(Inf,Inf)),info="checking with no vertex activity")
>
> # test if activity is missing for an element
> activate.vertices(nd,onset=1,terminus=2,v=2)
> expect_equivalent(get.vertex.activity(nd,as.spellList=TRUE),data.frame(onset=c(-Inf,1),terminus=c(Inf,2),vertex.id=c(1,2),onset.censored=c(TRUE,FALSE),terminus.censored=c(TRUE,FALSE),duration=c(Inf,1)),info="test when only some verticies have activity")
>
> # test when default activity set false
> expect_equivalent(
+ get.vertex.activity(nd,as.spellList=TRUE,active.default=FALSE),
+ data.frame(onset=1,terminus=2,vertex.id=2,onset.censored=FALSE,terminus.censored=FALSE,duration=1),info="test when only some verticies have activity and active.default=FALSE")
>
> # test if v specified for spellmatrix
> nd <- network.initialize(5)
> activate.vertices(nd,onset=0:4,terminus=1:5)
> expect_equivalent(
+ get.vertex.activity(nd,as.spellList=TRUE,v=2:4)[,1:3],
+ data.frame(onset=1:3,terminus=2:4,vertex.id=2:4),info="test when when v argument specified with spellmatrix")
>
> expect_equivalent(
+ unlist(get.vertex.activity(nd,,v=2:4)),c(1,2,2,3,3,4)
+ ,info="test when when v argument specified")
>
>
> # test if called with ordinary network
> expect_equal(unlist(get.vertex.activity(network.initialize(3))),c(-Inf,Inf,-Inf,Inf,-Inf,Inf),info="calling with ordinary network")
>
> # test when called with something else
> expect_error(get.vertex.activity(list()),'requires an argument of class network')
Error: `get.vertex.activity(list())` threw an error with unexpected message.
Expected match: "requires an argument of class network"
Actual message: "no applicable method for 'network.size' applied to an object of class \"list\""
Execution halted
Flavor: r-release-windows-ix86+x86_64
Version: 0.9.0
Check: running tests for arch ‘i386’
Result: ERROR
Running 'activate_tests.R' [3s]
Running 'age.at_tests.R' [2s]
Running 'classTests.R' [2s]
Running 'converter_tests.R' [1s]
Running the tests in 'tests/converter_tests.R' failed.
Complete output:
> # Part of the statnet package, http://statnetproject.org
> #
> # This software is distributed under the GPL-3 license. It is free,
> # open source, and has the attribution requirements (GPL Section 7) in
> # http://statnetproject.org/attribution
> #
> # Copyright 2013 the statnet development team
> ######################################################################
>
> #test networkDynamic conversion functionality
>
> require(networkDynamic)
Loading required package: networkDynamic
Loading required package: network
network: Classes for Relational Data
Version 1.14-377 created on 2019-03-04.
copyright (c) 2005, Carter T. Butts, University of California-Irvine
Mark S. Handcock, University of California -- Los Angeles
David R. Hunter, Penn State University
Martina Morris, University of Washington
Skye Bender-deMoll, University of Washington
For citation information, type citation("network").
Type help("network-package") to get started.
networkDynamic: version 0.9.0, created on 2016-01-12
Copyright (c) 2016, Carter T. Butts, University of California -- Irvine
Ayn Leslie-Cook, University of Washington
Pavel N. Krivitsky, University of Wollongong
Skye Bender-deMoll, University of Washington
with contributions from
Zack Almquist, University of California -- Irvine
David R. Hunter, Penn State University
Li Wang
Kirk Li, University of Washington
Steven M. Goodreau, University of Washington
Jeffrey Horner
Martina Morris, University of Washington
Based on "statnet" project software (statnet.org).
For license and citation information see statnet.org/attribution
or type citation("networkDynamic").
> require(testthat)
Loading required package: testthat
>
>
> # ------ get.vertex.activity test ------
>
> net<-network.initialize(5)
> activate.vertices(net,onset=c(1,2,3,-Inf,100),terminus=c(10,20,Inf,30,Inf))
> activate.vertices(net,at=1000)
> expect_equal(unlist(get.vertex.activity(net)),c(1,1000,10,1000,2,1000,20,1000,3,Inf,-Inf,1000,30,1000,100,Inf),info='check if spell list has correct elements in get.vertex.activity')
>
> expect_equivalent(get.vertex.activity(net,as.spellList=TRUE),data.frame(onset=c(1,1000,2,1000,3,-Inf,1000,100),terminus=c(10,1000,20,1000,Inf,30,1000,Inf),vertex.id=c(1,1,2,2,3,4,4,5),onset.censored=c(FALSE,FALSE,FALSE,FALSE,FALSE,TRUE,FALSE,FALSE),terminus.censored=c(FALSE,FALSE,FALSE,FALSE,TRUE,FALSE,FALSE,TRUE),duration=c(9,0,18,0,Inf,Inf,0,Inf)),info="check if get.vertex.activity(spellList) returns correct data")
>
> # check sort order
> expect_equal(get.vertex.activity(net,as.spellList=TRUE)$vertex.id,c(1,1,2,2,3,4,4,5),info="check sort order of get.vertex.activity vertex.id")
>
> expect_equal(get.vertex.activity(net,as.spellList=TRUE)$onset,c(1,1000,2,1000,3,-Inf,1000,100),info="check sort order of get.vertex.activity onset")
> expect_equal(get.vertex.activity(net,as.spellList=TRUE)$terminus,c(10,1000,20,1000,Inf,30,1000,Inf),info="check sort order of get.vertex.activity terminus")
>
> expect_equal(get.vertex.activity(network.initialize(0)),list())
>
>
>
>
> # check that net.obs.period triggers censoring
> nop <- list(observations=list(c(-5,1001)), mode="discrete", time.increment=1,time.unit="step")
> set.network.attribute(net,'net.obs.period',nop)
> expect_equivalent(get.vertex.activity(net,as.spellList=TRUE),data.frame(onset=c(1,1000,2,1000,3,-5,1000,100),terminus=c(10,1000,20,1000,1001,30,1000,1001),vertex.id=c(1,1,2,2,3,4,4,5),onset.censored=c(FALSE,FALSE,FALSE,FALSE,FALSE,TRUE,FALSE,FALSE),terminus.censored=c(FALSE,FALSE,FALSE,FALSE,TRUE,FALSE,FALSE,TRUE),duration=c(9,0,18,0,998,35,0,901)),info="check that net.obs.period triggers censoring in get.vertex.activity(spellList)")
>
>
> # check for bug with no activity #192
> nd<-network.initialize(2)
> nd<-add.edges.active(nd,at=1,tail=1,head=2)
>
> expect_equivalent(get.vertex.activity(nd,as.spellList=TRUE),data.frame(onset=c(-Inf,-Inf),terminus=c(Inf,Inf),vertex.id=c(1,2),onset.censored=c(TRUE,TRUE),terminus.censored=c(TRUE,TRUE),duration=c(Inf,Inf)),info="checking with no vertex activity")
>
> # test if activity is missing for an element
> activate.vertices(nd,onset=1,terminus=2,v=2)
> expect_equivalent(get.vertex.activity(nd,as.spellList=TRUE),data.frame(onset=c(-Inf,1),terminus=c(Inf,2),vertex.id=c(1,2),onset.censored=c(TRUE,FALSE),terminus.censored=c(TRUE,FALSE),duration=c(Inf,1)),info="test when only some verticies have activity")
>
> # test when default activity set false
> expect_equivalent(
+ get.vertex.activity(nd,as.spellList=TRUE,active.default=FALSE),
+ data.frame(onset=1,terminus=2,vertex.id=2,onset.censored=FALSE,terminus.censored=FALSE,duration=1),info="test when only some verticies have activity and active.default=FALSE")
>
> # test if v specified for spellmatrix
> nd <- network.initialize(5)
> activate.vertices(nd,onset=0:4,terminus=1:5)
> expect_equivalent(
+ get.vertex.activity(nd,as.spellList=TRUE,v=2:4)[,1:3],
+ data.frame(onset=1:3,terminus=2:4,vertex.id=2:4),info="test when when v argument specified with spellmatrix")
>
> expect_equivalent(
+ unlist(get.vertex.activity(nd,,v=2:4)),c(1,2,2,3,3,4)
+ ,info="test when when v argument specified")
>
>
> # test if called with ordinary network
> expect_equal(unlist(get.vertex.activity(network.initialize(3))),c(-Inf,Inf,-Inf,Inf,-Inf,Inf),info="calling with ordinary network")
>
> # test when called with something else
> expect_error(get.vertex.activity(list()),'requires an argument of class network')
Error: `get.vertex.activity(list())` threw an error with unexpected message.
Expected match: "requires an argument of class network"
Actual message: "no applicable method for 'network.size' applied to an object of class \"list\""
Execution halted
Flavor: r-oldrel-windows-ix86+x86_64
Version: 0.9.0
Check: running tests for arch ‘x64’
Result: ERROR
Running 'activate_tests.R' [4s]
Running 'age.at_tests.R' [2s]
Running 'classTests.R' [2s]
Running 'converter_tests.R' [2s]
Running the tests in 'tests/converter_tests.R' failed.
Complete output:
> # Part of the statnet package, http://statnetproject.org
> #
> # This software is distributed under the GPL-3 license. It is free,
> # open source, and has the attribution requirements (GPL Section 7) in
> # http://statnetproject.org/attribution
> #
> # Copyright 2013 the statnet development team
> ######################################################################
>
> #test networkDynamic conversion functionality
>
> require(networkDynamic)
Loading required package: networkDynamic
Loading required package: network
network: Classes for Relational Data
Version 1.14-377 created on 2019-03-04.
copyright (c) 2005, Carter T. Butts, University of California-Irvine
Mark S. Handcock, University of California -- Los Angeles
David R. Hunter, Penn State University
Martina Morris, University of Washington
Skye Bender-deMoll, University of Washington
For citation information, type citation("network").
Type help("network-package") to get started.
networkDynamic: version 0.9.0, created on 2016-01-12
Copyright (c) 2016, Carter T. Butts, University of California -- Irvine
Ayn Leslie-Cook, University of Washington
Pavel N. Krivitsky, University of Wollongong
Skye Bender-deMoll, University of Washington
with contributions from
Zack Almquist, University of California -- Irvine
David R. Hunter, Penn State University
Li Wang
Kirk Li, University of Washington
Steven M. Goodreau, University of Washington
Jeffrey Horner
Martina Morris, University of Washington
Based on "statnet" project software (statnet.org).
For license and citation information see statnet.org/attribution
or type citation("networkDynamic").
> require(testthat)
Loading required package: testthat
>
>
> # ------ get.vertex.activity test ------
>
> net<-network.initialize(5)
> activate.vertices(net,onset=c(1,2,3,-Inf,100),terminus=c(10,20,Inf,30,Inf))
> activate.vertices(net,at=1000)
> expect_equal(unlist(get.vertex.activity(net)),c(1,1000,10,1000,2,1000,20,1000,3,Inf,-Inf,1000,30,1000,100,Inf),info='check if spell list has correct elements in get.vertex.activity')
>
> expect_equivalent(get.vertex.activity(net,as.spellList=TRUE),data.frame(onset=c(1,1000,2,1000,3,-Inf,1000,100),terminus=c(10,1000,20,1000,Inf,30,1000,Inf),vertex.id=c(1,1,2,2,3,4,4,5),onset.censored=c(FALSE,FALSE,FALSE,FALSE,FALSE,TRUE,FALSE,FALSE),terminus.censored=c(FALSE,FALSE,FALSE,FALSE,TRUE,FALSE,FALSE,TRUE),duration=c(9,0,18,0,Inf,Inf,0,Inf)),info="check if get.vertex.activity(spellList) returns correct data")
>
> # check sort order
> expect_equal(get.vertex.activity(net,as.spellList=TRUE)$vertex.id,c(1,1,2,2,3,4,4,5),info="check sort order of get.vertex.activity vertex.id")
>
> expect_equal(get.vertex.activity(net,as.spellList=TRUE)$onset,c(1,1000,2,1000,3,-Inf,1000,100),info="check sort order of get.vertex.activity onset")
> expect_equal(get.vertex.activity(net,as.spellList=TRUE)$terminus,c(10,1000,20,1000,Inf,30,1000,Inf),info="check sort order of get.vertex.activity terminus")
>
> expect_equal(get.vertex.activity(network.initialize(0)),list())
>
>
>
>
> # check that net.obs.period triggers censoring
> nop <- list(observations=list(c(-5,1001)), mode="discrete", time.increment=1,time.unit="step")
> set.network.attribute(net,'net.obs.period',nop)
> expect_equivalent(get.vertex.activity(net,as.spellList=TRUE),data.frame(onset=c(1,1000,2,1000,3,-5,1000,100),terminus=c(10,1000,20,1000,1001,30,1000,1001),vertex.id=c(1,1,2,2,3,4,4,5),onset.censored=c(FALSE,FALSE,FALSE,FALSE,FALSE,TRUE,FALSE,FALSE),terminus.censored=c(FALSE,FALSE,FALSE,FALSE,TRUE,FALSE,FALSE,TRUE),duration=c(9,0,18,0,998,35,0,901)),info="check that net.obs.period triggers censoring in get.vertex.activity(spellList)")
>
>
> # check for bug with no activity #192
> nd<-network.initialize(2)
> nd<-add.edges.active(nd,at=1,tail=1,head=2)
>
> expect_equivalent(get.vertex.activity(nd,as.spellList=TRUE),data.frame(onset=c(-Inf,-Inf),terminus=c(Inf,Inf),vertex.id=c(1,2),onset.censored=c(TRUE,TRUE),terminus.censored=c(TRUE,TRUE),duration=c(Inf,Inf)),info="checking with no vertex activity")
>
> # test if activity is missing for an element
> activate.vertices(nd,onset=1,terminus=2,v=2)
> expect_equivalent(get.vertex.activity(nd,as.spellList=TRUE),data.frame(onset=c(-Inf,1),terminus=c(Inf,2),vertex.id=c(1,2),onset.censored=c(TRUE,FALSE),terminus.censored=c(TRUE,FALSE),duration=c(Inf,1)),info="test when only some verticies have activity")
>
> # test when default activity set false
> expect_equivalent(
+ get.vertex.activity(nd,as.spellList=TRUE,active.default=FALSE),
+ data.frame(onset=1,terminus=2,vertex.id=2,onset.censored=FALSE,terminus.censored=FALSE,duration=1),info="test when only some verticies have activity and active.default=FALSE")
>
> # test if v specified for spellmatrix
> nd <- network.initialize(5)
> activate.vertices(nd,onset=0:4,terminus=1:5)
> expect_equivalent(
+ get.vertex.activity(nd,as.spellList=TRUE,v=2:4)[,1:3],
+ data.frame(onset=1:3,terminus=2:4,vertex.id=2:4),info="test when when v argument specified with spellmatrix")
>
> expect_equivalent(
+ unlist(get.vertex.activity(nd,,v=2:4)),c(1,2,2,3,3,4)
+ ,info="test when when v argument specified")
>
>
> # test if called with ordinary network
> expect_equal(unlist(get.vertex.activity(network.initialize(3))),c(-Inf,Inf,-Inf,Inf,-Inf,Inf),info="calling with ordinary network")
>
> # test when called with something else
> expect_error(get.vertex.activity(list()),'requires an argument of class network')
Error: `get.vertex.activity(list())` threw an error with unexpected message.
Expected match: "requires an argument of class network"
Actual message: "no applicable method for 'network.size' applied to an object of class \"list\""
Execution halted
Flavor: r-oldrel-windows-ix86+x86_64
Version: 0.9.0
Check: re-building of vignette outputs
Result: NOTE
Error in re-building vignettes:
...
trying URL 'http://vlado.fmf.uni-lj.si/pub/networks/data/esna/Sampson.zip'
Content type 'application/zip' length 2182 bytes
==================================================
downloaded 2182 bytes
Warning in get.vertex.attribute.active(net, "happiness", onset = 2.5, terminus = 4.5) :
Multiple attribute values matched query spell for attribute happiness.active on some vertices. Only earliest value used
Error in texi2dvi(file = file, pdf = TRUE, clean = clean, quiet = quiet, :
Running 'texi2dvi' on 'networkDynamic.tex' failed.
LaTeX errors:
! LaTeX Error: File `comment.sty' not found.
Type X to quit or <RETURN> to proceed,
or enter new name. (Default extension: sty)
! Emergency stop.
<read *>
l.6 \usepackage
{color}^^M
! ==> Fatal error occurred, no output PDF file produced!
Calls: buildVignettes -> texi2pdf -> texi2dvi
Execution halted
Flavor: r-oldrel-osx-x86_64