Conversation
git add 02_activities/assignments/a1_sampling_and_reproducibility.ipynb
anjali-deshpande-hub
left a comment
There was a problem hiding this comment.
Great start! Can you split your Q1 answer into these 4 specific sampling stages?
Step 1: Setting Up the DataFrame
Function Used: pd.DataFrame
Sample Size: 1000 individuals
Sampling Frame: The entire population of event attendees, consisting of two event types: weddings and brunches.
Procedure:
The script creates a DataFrame representing 1000 individuals attending events.
200 individuals are assigned to weddings, and 800 to brunches.
Underlying Distribution: Deterministic allocation (200 weddings, 800 brunches).
Step 2: Infecting Random Subset
Function: np.random.choice(...)
Frame? Sample size? (hint: ATTACK_RATE × 1000)
Step 3: Primary Contact Tracing
Function: np.random.rand(...)
Frame? Expected sample size?
Step 4: Secondary Contact Tracing
Functions: value_counts() + threshold
Random or deterministic?
Q3: Can you describe the changes you see when you add seed to the code?
|
A friendly reminder to complete the requested review changes. Thanks! |
…use of that. Thank you.
git add 02_activities/assignments/a1_sampling_and_reproducibility.ipynb
What changes are you trying to make? (e.g. Adding or removing code, refactoring existing code, adding reports)
added explanations and one line to the code
What did you learn from the changes you have made?
to increase reproducibility.
Was there another approach you were thinking about making? If so, what approach(es) were you thinking of?
no other approach
Were there any challenges? If so, what issue(s) did you face? How did you overcome it?
yes. the graph kept changing and was difficult to interpret
How were these changes tested?
on VS
A reference to a related issue in your repository (if applicable)
Checklist