-
Notifications
You must be signed in to change notification settings - Fork 80
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
v0.4.0 #203
v0.4.0 #203
Conversation
Used {styler} (1.0.2): `styler::style_pkg(scope = "none", strict = FALSE)`.
Details: - Remove trailing spaces in comments (both raw and roxygen). - Update spacing in function calls and definitions. - Remove spaces after `!!` and `!!!` (also a tidyverse style guide). Used {styler} (1.0.2.9000 from commit 1dd6b04, as it has some bugs fixed): `styler::style_pkg(scope = "spaces", strict = FALSE, include_roxygen_examples = FALSE)`. After that manually remove spaces around `/` in simple fractions in test files.
Master -> develop
Update code style (#169)
Fix `calculate()` to not depend on order of `p` (fixes #122).
This also implements fixed shade transparency for all types of plots. Earlier it was fixed for "theoretical" and varied for "simulation" and "both".
Also this renames "Chi-square" into "Chi-Square" in warnings about right-tailed tests.
Add visualise as alias
Merge branch 'develop' into dry-code # Conflicts: # R/visualize.R
@echasnovski Do you want to look into #203 (comment)? This might also be helpful. |
Do you suggest to change logic of computing two-sided p-value in two_sided_p_value <- function(x, obs_stat){
right_pval <- mean(x[["stat"]] >= obs_stat)
# No need to round down to 1 due to nature of computation
tibble::tibble(p_value = 2 * min(right_pval, 1 - right_pval))
} Or to this: two_sided_p_value <- function(x, obs_stat) {
left_pval <- mean(x[["stat"]] <= obs_stat)
right_pval <- mean(x[["stat"]] >= obs_stat)
raw_res <- 2 * min(left_pval, right_pval)
tibble::tibble(p_value = min(raw_res, 1))
} |
This might introduce inconsistency in treating two-sided p-value in |
Ultimately, we just want to have |
I think I like the first implementation better, but it's worth checking some examples to see which works better in practice. |
I wonder, if the following reasoning makes sense:
So there are two options of implementing two-sided p-value in
two_sided_p_value <- function(x, obs_stat) {
stat <- x[["stat"]]
second_border <- mirror_obs_stat(stat, obs_stat)
left_border <- min(obs_stat, second_border)
right_border <- max(obs_stat, second_border)
is_in_tail <- (stat <= left_border) | (stat >= right_border)
tibble::tibble(p_value = mean(is_in_tail))
} |
This seems tricky enough without any theoretical underpinning as to which method would be preferred that an extra logical argument might be helpful if a user would prefer one of the two options over the other. The default could be the "Chihara and Hesterberg" approach. What do you think? |
Update `get_p_value()`
This looks ready to go. It probably makes sense to first submit to CRAN, which I'm happy to do, then pull into master only after it has been accepted. One thing: @ismayc which version is this? NEWS says 0.3.1.9000 but this PR is called 0.4.0. |
I usually use *.9000 for the developmental version. Feel free to change to 0.4.0 when we have settled on what goes in the release, which appears to be this. |
I plan to submit |
Exclude possible vector conditions in `bootstrap()` (related to #210)
… in environments without long doubles.
This pull request has been automatically locked. If you believe you have found a related problem, please file a new issue (with a reprex: https://reprex.tidyverse.org) and link to this issue. |
A refactoring of
visualize()
and lots of other "Don't Repeat Yourself" cleaning up here. It would be great to get this sent tomaster
by October 1 so we can send an update out to CRAN at the beginning of Q4.Let's get list-columns implemented in v0.5.0 by the end of October.