You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Had a thought about the expect_prop() API - it would be nice to make a slight change to make the cmp argument take an arbitrary function that takes the proportion meeting the check condition and indicates whether this proportion passes some test or not. This makes it more flexible and I think reads pretty nicely.
For e.g., with a little helper function, you can do nice things like this:
expect_prop(a1, chk_blank, is_gte(0.8))
Where is_gte() is a function generator:
is_gte<-function(prop) {
function(x) x>=prop
}
The text was updated successfully, but these errors were encountered:
Had a thought about the
expect_prop()
API - it would be nice to make a slight change to make thecmp
argument take an arbitrary function that takes the proportion meeting the check condition and indicates whether this proportion passes some test or not. This makes it more flexible and I think reads pretty nicely.For e.g., with a little helper function, you can do nice things like this:
Where
is_gte()
is a function generator:The text was updated successfully, but these errors were encountered: