Commit 90a3b12
Update adjusting_sample_to_population.md with current Sample.adjust() output format (#315)
Summary:
The documentation showed outdated output format for `Sample.adjust()`. Updated to reflect current behavior from the quickstart tutorial.
## Changes
- **Added adjustment details section** with design effect (Deff), effective sample size proportion (ESSP), effective sample size (ESS), method, and weight trimming mean ratio
- **Updated target metadata** to correctly show 3 variables (gender, age_group, income) with `outcome_columns: happiness`, matching the quickstart tutorial where target is created with `outcome_columns=["happiness"]`
- **Updated formatting** to match current string representation
## Example
Current output now shows:
```
Adjusted balance Sample object with target set using ipw
1000 observations x 3 variables: gender,age_group,income
id_column: id, weight_column: weight,
outcome_columns: happiness
adjustment details:
method: ipw
weight trimming mean ratio: 20
design effect (Deff): 1.880
effective sample size proportion (ESSP): 0.532
effective sample size (ESS): 531.9
target:
balance Sample object
10000 observations x 3 variables: gender,age_group,income
id_column: id, weight_column: weight,
outcome_columns: happiness
3 common variables: gender,age_group,income
```
<details>
<summary>Original prompt</summary>
>
> ----
>
> *This section details on the original issue you should resolve*
>
> <issue_title>[FEATURE] website/docs/docs/general_framework/adjusting_sample_to_population.md</issue_title>
> <issue_description>Update text in:
> https://github.com/facebookresearch/balance/blob/main/website/docs/docs/general_framework/adjusting_sample_to_population.md
> Based on updated output from here:
> https://import-balance.org/docs/tutorials/quickstart/</issue_description>
>
> ## Comments on the Issue (you are copilot in this section)
>
> <comments>
> </comments>
>
</details>
- Fixes #314
---
💡 You can make Copilot smarter by setting up custom instructions, customizing its development environment and configuring Model Context Protocol (MCP) servers. Learn more [Copilot coding agent tips](https://gh.io/copilot-coding-agent-tips) in the docs.
Pull Request resolved: #315
Reviewed By: omriharosh
Differential Revision: D92278189
Pulled By: talgalili
fbshipit-source-id: e2e5acc095041e2585c48b3e5f57527002ff62151 parent ca6de35 commit 90a3b12
File tree
1 file changed
+17
-10
lines changed- website/docs/docs/general_framework
1 file changed
+17
-10
lines changedLines changed: 17 additions & 10 deletions
| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
15 | 15 | | |
16 | 16 | | |
17 | 17 | | |
18 | | - | |
19 | | - | |
20 | | - | |
21 | | - | |
| 18 | + | |
| 19 | + | |
| 20 | + | |
| 21 | + | |
22 | 22 | | |
23 | | - | |
| 23 | + | |
| 24 | + | |
| 25 | + | |
| 26 | + | |
| 27 | + | |
| 28 | + | |
24 | 29 | | |
25 | | - | |
26 | | - | |
27 | | - | |
28 | | - | |
| 30 | + | |
29 | 31 | | |
30 | | - | |
| 32 | + | |
| 33 | + | |
| 34 | + | |
| 35 | + | |
| 36 | + | |
| 37 | + | |
31 | 38 | | |
32 | 39 | | |
33 | 40 | | |
| |||
0 commit comments