-
Notifications
You must be signed in to change notification settings - Fork 19
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
New constructor for ReplicateDesign
.
#251
New constructor for ReplicateDesign
.
#251
Conversation
`replicate_weights` for `ReplicateDesign`.
@ayushpatnaikgit @smishr one question: should we enforce the convention that the replicate weight columns should be called "replicate_i"? If so, some minor changes to the code will have to be made. |
i think this would be great, since downstream functions assume the "replicates_". Also we dont have to create extra functiona. |
Codecov Report
@@ Coverage Diff @@
## v0.1.1 #251 +/- ##
=========================================
Coverage 100.00% 100.00%
=========================================
Files 12 12
Lines 183 196 +13
=========================================
+ Hits 183 196 +13
Help us with your feedback. Take ten seconds to tell us how you rate us. Have a feature suggestion? Share it here. |
@smishr @ayushpatnaikgit small note: I think we should move the documentation of the constructors to the docstrings of the respective constructors (right now the documentation is in the docstring of the |
that sounds good |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
look at comments
constructor, and removing the redundant `replicates` argument.
`ReplicateDesign`.
@codetalker7 i changed base from main to v0.1.1. @ayushpatnaikgit have a look and merge if u think all good. Im fine with calling the base SurveyDesign constructor being common to both. |
Fixed minor error in documentation. It'll be helpful if we enable strict doctesting to detect these. |
|
Column names should be changed to “replicate_” if they aren't in this format. |
If this is too time consuming add as issue to be done later.
This should be relatively easy to add i think.
I think this is the most important out of all three suggestions to be implemented first |
Added all these suggestions, along with tests and documentation. |
In this PR, we add a new constructor for the
ReplicateDesign
struct which allows the user to directly construct aReplicateDesign
without having to first construct aSurveyDesign
.We've also added a default constructor for
ReplicateDesign
which just builds the object out of the given arguments.Finally, a new property called
replicate_weights
is added to theReplicateDesign
object; for now, this will be aVector{Symbol}
. Later we can add more iterators.For completeness, here is an example for how the constructor works now.
If this is okay, I will add tests, documentation and some other final touches to the PR.
Closes #194