Skip to content

Add the h1_spending argument to gs_power_wlr #561

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

Open
wants to merge 4 commits into
base: main
Choose a base branch
from

Conversation

LittleBeannie
Copy link
Collaborator

@LittleBeannie LittleBeannie commented Jun 30, 2025

To solve issue #560.

@LittleBeannie LittleBeannie added this to the 2025 Q3 milestone Jun 30, 2025
@LittleBeannie LittleBeannie self-assigned this Jun 30, 2025
@LittleBeannie LittleBeannie linked an issue Jun 30, 2025 that may be closed by this pull request
@LittleBeannie LittleBeannie marked this pull request as draft June 30, 2025 21:52
@LittleBeannie LittleBeannie marked this pull request as ready for review July 1, 2025 13:19
@LittleBeannie LittleBeannie requested a review from keaven July 1, 2025 13:20
# Given the above statistical information calculate the power ----
y_h1 <- gs_power_npe(
theta = x$theta,
theta = x$theta, theta0 = 0, theta1 = theta1,
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Since all the other arguments are on their own line, I recommend keeping this consistent with the surrounding code and moving theta0 and theta1 to new lines

theta = 0,
theta0 = 0,
theta1 = x$theta,
theta = 0, theta0 = 0, theta1 = theta1,
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ditto above comment

upar = list(sf = gsDesign::sfLDOF, total_spend = 0.025),
lower = gs_spending_bound,
lpar = list(sf = gsDesign::sfLDOF, total_spend = 0.025),
binding = TRUE, h1_spending = FALSE)
Copy link
Collaborator

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Love the test! For completeness, would it also make sense to have a test with h1_spending = TRUE to demonstrate that in that case the upper and lower bounds are not equal?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

Add h1_spending =... to gs_power_wlr
2 participants