Skip to content

Commit

Permalink
Removing some unused functions
Browse files Browse the repository at this point in the history
  • Loading branch information
gvegayon committed Jan 19, 2024
1 parent 32db30f commit 217ba45
Show file tree
Hide file tree
Showing 5 changed files with 2 additions and 36 deletions.
1 change: 0 additions & 1 deletion NAMESPACE
Original file line number Diff line number Diff line change
Expand Up @@ -58,7 +58,6 @@ S3method(plot,epiworld_surv)
S3method(print,epiworld_agent)
S3method(print,epiworld_agents)
S3method(print,epiworld_agents_tools)
S3method(print,epiworld_agents_viruses)
S3method(print,epiworld_globalaction)
S3method(print,epiworld_model)
S3method(print,epiworld_saver)
Expand Down
24 changes: 0 additions & 24 deletions R/virus.R
Original file line number Diff line number Diff line change
Expand Up @@ -536,29 +536,5 @@ set_incubation_fun <- function(virus, model, vfun) {

}

#' @export
#' @rdname virus
#' @param max_print Numeric scalar. Maximum number of viruses to print.
#' @param ... Currently ignored.
#' @param x An object of class `epiworld_agents_viruses`.
print.epiworld_agents_viruses <- function(x, max_print = 10, ...) {

for (i in 1:min(max_print, length(x))) {
print_agent_viruses_cpp(x[[i]])
}

if (length(x) > max_print) {
cat(sprintf("Showing first %s of %s viruses.\n", max_print, length(x)))
}

invisible(x)

}

#' @export
print.epiworld_viruses <- function(x, ...) {
print_agent_viruses_cpp(x)
invisible(x)
}


2 changes: 1 addition & 1 deletion README.Rmd
Original file line number Diff line number Diff line change
Expand Up @@ -205,7 +205,7 @@ net <- get_transmissions(sir)
# Plotting
library(epiworldR)
library(netplot)
library(epiworldR)
x <- igraph::graph_from_edgelist(
as.matrix(net[,2:3]) + 1
)
Expand Down
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -346,7 +346,7 @@ net <- get_transmissions(sir)

# Plotting
library(epiworldR)
library(netplot)
library(epiworldR)
#> Loading required package: grid
x <- igraph::graph_from_edgelist(
as.matrix(net[,2:3]) + 1
Expand Down
9 changes: 0 additions & 9 deletions man/virus.Rd

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

0 comments on commit 217ba45

Please sign in to comment.