Skip to content

Commit

Permalink
Final prerelease of 0.2.1
Browse files Browse the repository at this point in the history
  • Loading branch information
chrismainey committed Oct 9, 2019
1 parent c693137 commit db467b5
Show file tree
Hide file tree
Showing 3 changed files with 43 additions and 1 deletion.
1 change: 1 addition & 0 deletions .Rbuildignore
Original file line number Diff line number Diff line change
Expand Up @@ -14,3 +14,4 @@ cran-comments.md
^pkgdown$
^CRAN-RELEASE$
^README\.Rmd$
testers.R
2 changes: 1 addition & 1 deletion cran-comments.md
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ This is a second release of a package wrapper for ggplot2 to draw funnel plots f
There were no ERRORs or WARNINGs.

NOTES on win-builder and r-hub about possibly invalid links.
These refer to DOIs in references in the vignette. I've manually tested all links and they are valid.
These refer to DOIs for references in the vignette. I've manually tested all links and they are valid.

Further note on win-builder and some r-hub builds about a CRAN reference not being in canonical form. This has been changed to use https as suggested.

Expand Down
41 changes: 41 additions & 0 deletions testsers.R
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
a<-2
b<-2

if(a==1 | a==2 & b==1){
print("yes")
} else print("no")


number.seq<-seq(5,50,5)

t <- 0.5

t * ((qchisq(0.975, 2 * number.seq, lower.tail = FALSE) / 2) / number.seq)



funnel_plot(numerator = c(8, 15,18,8,12, 22), denominator= c(12, 21, 26,15,20, 30), OD_adjust=FALSE,
group = factor(c("a","b","c", "d","e","f")), type = "pr", return_elements = "plot")
)



mod_plot<-data.frame(numerator = c(8, 15,18,8,12, 22), denominator= c(12, 21, 26,15,20, 30),
group = factor(c("a","b","c", "d","e","f")))

mod_plot_agg<-aggregate_func(mod_plot)

aggregate_func<- function(mod_plot) {

mod_plot_agg <- mod_plot %>%
dplyr::group_by(.data$group) %>%
dplyr::summarise(
numerator = as.numeric(sum(.data$numerator)),
denominator = as.numeric(sum(.data$denominator)),
ratio = .data$numerator / .data$denominator
)

return(mod_plot_agg)

}

0 comments on commit db467b5

Please sign in to comment.