Skip to content

Commit

Permalink
Preparing for CRAN
Browse files Browse the repository at this point in the history
  • Loading branch information
gvegayon committed Sep 16, 2022
1 parent d095657 commit e093adb
Show file tree
Hide file tree
Showing 7 changed files with 94 additions and 24 deletions.
4 changes: 2 additions & 2 deletions DESCRIPTION
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 22,7 @@ Depends:
R (>= 3.1.1)
License: MIT file LICENSE
LazyData: true
Date: 2021-05-21
Date: 2022-09-16
Imports:
Rcpp (>= 0.12.1),
sna,
Expand Down Expand Up @@ -50,7 50,7 @@ Suggests:
survival
VignetteBuilder: knitr
LinkingTo: Rcpp, RcppArmadillo
RoxygenNote: 7.1.1
RoxygenNote: 7.2.1
Encoding: UTF-8
URL: https://github.com/USCCANA/netdiffuseR,
https://USCCANA.github.io/netdiffuseR/
Expand Down
8 changes: 7 additions & 1 deletion NEWS.md
Original file line number Diff line number Diff line change
@@ -1,3 1,9 @@
# Changes in netdiffuseR version 1.22.4 (2022-09-16)

* Replaced `getMethod("t"...)` by `t` responding to changes in the
`Matrix` package.


# Changes in netdiffuseR version 1.22.1 (2021-05-27)

* netdiffuseR has now a logo!
Expand All @@ -11,7 17,7 @@
new version, the function has been fully ported to R, which should avoid
problems related to the C code.

* As documented, struct_equiv now returns he euclidean distance matrix (it was
* As documented, `struct_equiv` now returns he euclidean distance matrix (it was
not doing that).


Expand Down
92 changes: 77 additions & 15 deletions inst/NEWS
Original file line number Diff line number Diff line change
@@ -1,10 1,24 @@
Changes in netdiffuseR version 1.22.1 (2021-05-27)


CHANGES IN NETDIFFUSER VERSION 1.22.4 (2022-09-16)


- Replaced getMethod("t"...) by t responding to changes in the Matrix
package.



CHANGES IN NETDIFFUSER VERSION 1.22.1 (2021-05-27)


- netdiffuseR has now a logo!

- Making updates after changes in knitr and Matrix.

Changes in netdiffuseR version 1.22.0 (2020-05-17)


CHANGES IN NETDIFFUSER VERSION 1.22.0 (2020-05-17)


- Fixing a new issue regarding structural equivalence calculation. In
the new version, the function has been fully ported to R, which
Expand All @@ -13,28 27,41 @@ Changes in netdiffuseR version 1.22.0 (2020-05-17)
- As documented, struct_equiv now returns he euclidean distance matrix
(it was not doing that).

Changes in netdiffuseR version 1.21.0 (2020-02-10)


CHANGES IN NETDIFFUSER VERSION 1.21.0 (2020-02-10)


- Getting netdiffuseR back to CRAN. We have fixed issues that arise
from the next big CRAN release, in particular, matrices are now
arrays. That was creating issues throughout the package (now fixed).

Changes in netdiffuseR version 1.20.2 (2019-03-25)


CHANGES IN NETDIFFUSER VERSION 1.20.2 (2019-03-25)


- Repaired broken link in bootnet.

Changes in netdiffuseR version 1.20.1 (2019-03-22)


CHANGES IN NETDIFFUSER VERSION 1.20.1 (2019-03-22)


- This version has no user level visible changes.


Other changes

- Changing PI macros in C code as requested by RcppCore.

- Setting 3.5 seed version for tests so that test won’t break
following message from CRAN.

Changes in netdiffuseR version 1.20.0 (2018-06-06)


CHANGES IN NETDIFFUSER VERSION 1.20.0 (2018-06-06)


New functions and features

Expand All @@ -44,12 71,14 @@ New functions and features
now selected from the viridis R package, which provides perceptually
uniform and colorblind proof colors.


Bug fixes

- plot_diffnet2 now has the correct scaling in nodes positions.

- rdiffnet_multiple calls library(netdiffuseR) when using multicore.


Other changes

- arrow.width in plot_threshold.default now set to be equal to
Expand All @@ -60,7 89,10 @@ Other changes
- The c function edges_arrow now returns two different elements (the
edge, and the arrow).

Changes in netdiffuseR version 1.19.0 (2017-10-16)


CHANGES IN NETDIFFUSER VERSION 1.19.0 (2017-10-16)


New functions and features

Expand All @@ -84,6 116,7 @@ New functions and features
- exposure has a new parameter: lags. By default lags = 0, returns a
lagged exposure matrix.


Bug fixes

- igraph_to_diffnet was failing with the graph had no weights.
Expand All @@ -101,6 134,7 @@ Bug fixes
corrected in diffnet_to_igraph, and other plot methods using igraph
for plotting.


Other changes

- Replacing some C functions by R functions in cases in which there
Expand All @@ -113,7 147,10 @@ Other changes
Innovations”, and “Simulating diffusion networks: Using the rdiffnet
function”.

Changes in netdiffuseR version 1.18.1 (2017-07-22)


CHANGES IN NETDIFFUSER VERSION 1.18.1 (2017-07-22)


New functions

Expand All @@ -123,10 160,12 @@ New functions
- networkDynamic_to_diffnet, diffnet_to_networkDynamc coercion between
diffnet and networkDynamic objects.


New features

- new_diffnet and as_diffnet now receive static networks as well.


Bug fixes

- diffnet_to_igraph was copying over a single adjacency matrix, which
Expand All @@ -136,7 175,10 @@ Bug fixes

- In unexpected situations egonet_attrs was crashing.

Changes in netdiffuseR version 1.18.0 (2017-07-16)


CHANGES IN NETDIFFUSER VERSION 1.18.0 (2017-07-16)


New functions

Expand All @@ -162,6 204,7 @@ New functions
- netmatch and netmatch_prepare (on development) implement matching
estimators with network data.


Bugs Fixes

- dgr returned with error when self == TRUE
Expand All @@ -175,6 218,7 @@ Bugs Fixes
- transformGraphBy was returning with error when the time periods
ranged other than 1, 2, …


New Features

- rgraph_er is now significantly faster (orders of magnitude compare
Expand All @@ -187,12 231,15 @@ New Features
- rewire_graph now also uses QAP. This affects directly to
structu_test.

Changes in netdiffuseR version 1.17.0 (2016-11-10)


CHANGES IN NETDIFFUSER VERSION 1.17.0 (2016-11-10)


New features and changes

- The title of the package is now Analysis of Diffusion and Contagion
Processes on Networks.
- The title of the package is now _Analysis of Diffusion and Contagion
Processes on Networks_.

- The function struct_test now allows other types of graphs. Before it
only supported diffnet objects.
Expand Down Expand Up @@ -222,6 269,7 @@ New features and changes

- classify_adopters now always includes Non-Adopters.


New functions

- vertex_covariate_dist computes distances between vertices using both
Expand Down Expand Up @@ -256,6 304,7 @@ New functions

- rewire_qap generates isomorphic graphs by “changing the labels”.


Bug fixes

- ^.diffnet method was rasing to 1 power, e.g. diffnet^2 was actually
Expand All @@ -281,7 330,10 @@ Bug fixes
- The method [[<-.diffnet failed when replacing a dynamic attribute
with a NULL value (e.g. dn[["my_dyn_att"]] <- NULL).

Changes in netdiffuseR version 1.16.7 (2016-07-07)


CHANGES IN NETDIFFUSER VERSION 1.16.7 (2016-07-07)


Bug fixes

Expand All @@ -299,6 351,7 @@ Bug fixes
- Fixed bug on egonet_attrs: The matrix method was returning with
error.


New features and changes

- plot_infectsuscept includes 2D kernel smoother via MASS::kde2d.
Expand All @@ -316,6 369,7 @@ New features and changes
as exposure lags time periods prior to the time of adoption. By
default is 0 so its exposure at the time of adoption.


New functions

- New method c.diffnet_struct_test: A wrapper of boot:::c.boot.
Expand Down Expand Up @@ -343,7 397,10 @@ New functions
when calling plot.igraph so that the size is proportional to the
x-axis.

Changes in netdiffuseR version 1.16.5 (2016-05-02)


CHANGES IN NETDIFFUSER VERSION 1.16.5 (2016-05-02)


Bug fixes

Expand All @@ -366,6 423,7 @@ Bug fixes
slices names different from the time periods, the slices names were
kept. Now these are replaced by meta$pers.


New features and changes

- Support for int64_t in RcppArmadillo now allows for creating/reading
Expand Down Expand Up @@ -442,6 500,7 @@ New features and changes
rewire_ws which has been implemented as it was presented in Watts
and Strogatz (1998).


New functions

- New function: survey_to_diffnet. This function allows importing
Expand Down Expand Up @@ -480,6 539,9 @@ New functions
- New rewiring algorithm, rewire_swap implements the edge-switch
algorithm in an efficient way. This preserves degree sequences.

Changes in netdiffuseR version 1.16.2 (2016-02-18)


CHANGES IN NETDIFFUSER VERSION 1.16.2 (2016-02-18)


- First CRAN version.
2 changes: 1 addition & 1 deletion man/bass.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 4 additions & 2 deletions man/diffusionMap.Rd

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

2 changes: 1 addition & 1 deletion tests/testthat/test-diffnet-methods.R
Original file line number Diff line number Diff line change
Expand Up @@ -243,7 243,7 @@ test_that("Arithmetic and others", {
# Multiply and transpose
ans0 <- g*t(g)
ans1 <- g
ans1$graph <- Map(function(x) x*methods::getMethod("t","dgCMatrix")(x), x=ans1$graph)
ans1$graph <- Map(function(x) x * t(x), x=ans1$graph)

expect_equal(ans0, ans1)

Expand Down
4 changes: 2 additions & 2 deletions tests/testthat/test-netdiffuser_extra.R
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 4,7 @@ context("C extra functions")
test_that("sp_trimatl", {
x <- ring_lattice(10,4, undirected = TRUE)
ans <- netdiffuseR:::sp_trimatl(x)
expect_equal(ans methods::getMethod("t", "dgCMatrix")(ans), x)
expect_equal(ans t(ans), x)
})

# ------------------------------------------------------------------------------
Expand All @@ -21,7 21,7 @@ test_that("sp_as_undirected", {
set.seed(123131312)
ans0 <- rgraph_ba(t=9,m=3)
ans1 <- netdiffuseR:::sp_as_undirected(ans0)
ans0 <- ans0 methods::getMethod("t", "dgCMatrix")(ans0)
ans0 <- ans0 t(ans0)
Matrix::diag(ans0) <- Matrix::diag(ans0)/2

expect_equivalent(ans1, ans0)
Expand Down

0 comments on commit e093adb

Please sign in to comment.