Skip to content

Conversation

@hossam26644
Copy link
Contributor

fixes #2440

  • simplified the fixed-pedigree example
  • fixed the stop_at_mrca_flag=True (should have been false)

@hossam26644 hossam26644 marked this pull request as ready for review December 15, 2025 14:10
@codecov
Copy link

codecov bot commented Dec 15, 2025

Codecov Report

✅ All modified and coverable lines are covered by tests.
✅ Project coverage is 91.22%. Comparing base (939a0e9) to head (3720520).
⚠️ Report is 2 commits behind head on main.

Additional details and impacted files
@@           Coverage Diff           @@
##             main    #2447   +/-   ##
=======================================
  Coverage   91.22%   91.22%           
=======================================
  Files          20       20           
  Lines       11847    11847           
  Branches     2300     2300           
=======================================
  Hits        10807    10807           
  Misses        569      569           
  Partials      471      471           
Flag Coverage Δ
C 91.22% <ø> (ø)
python 98.63% <ø> (ø)

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

🚀 New features to boost your workflow:
  • ❄️ Test Analytics: Detect flaky tests, report on failures, and find test suite problems.

@hossam26644
Copy link
Contributor Author

@jeromekelleher ready for review

@jeromekelleher
Copy link
Member

We don't want to change the existing example, it's doing it's job fine. We want a new example, just to illustrate this particular issue.

@hossam26644
Copy link
Contributor Author

Aw ok. Sorry, my bad

@hossam26644 hossam26644 force-pushed the fix/ancestry-pedigree-example-2440 branch from 18f0647 to c528755 Compare December 15, 2025 16:42
@hossam26644
Copy link
Contributor Author

@jeromekelleher check if this does the job

@hossam26644 hossam26644 force-pushed the fix/ancestry-pedigree-example-2440 branch from c528755 to f67ca5b Compare December 15, 2025 16:56
revert fixed pedigree example

update text
@jeromekelleher jeromekelleher force-pushed the fix/ancestry-pedigree-example-2440 branch from f67ca5b to 9f13711 Compare December 15, 2025 17:42
@jeromekelleher
Copy link
Member

I've pushed a commit changing to a simpler example - can you review to see if I've made any mistakes please?

pedigree = msprime.parse_pedigree(io.StringIO(ped_txt), sequence_length=100)
ped_ts = msprime.sim_ancestry(
initial_state=pedigree,
Copy link
Contributor Author

Choose a reason for hiding this comment

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

I suggest you move the simulations block to the next code block

Copy link
Member

Choose a reason for hiding this comment

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

good call - done.

share a common ancestor, which defines the **SMC′** model. Simulating under the Hudson
coalescent model is equivalent to setting the ```hull_offset``` to the sequence length. The
The {class}`SMC(k) <.SmcKApproxCoalescent>` model is a general simulations model that can simulate various **SMC** approximations
(e.g., **SMC** and **SMC′**). It accepts a ```hull_offset``` parameter, which defines the extent of
Copy link
Contributor Author

Choose a reason for hiding this comment

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

you are removing trailing white spaces from different lines. Is this intentional?

Copy link
Member

Choose a reason for hiding this comment

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

As I explained in another PR, this is because my editor is configured to automatically trim whitespace. The issue here is that your editor isn't set up to do this, and we're not enforcing lint checking on markdown files.

@hossam26644
Copy link
Contributor Author

Looks good. Sorry you had to do it yourself!

@jeromekelleher jeromekelleher force-pushed the fix/ancestry-pedigree-example-2440 branch from 9f13711 to 3720520 Compare December 16, 2025 09:49
@jeromekelleher jeromekelleher added this pull request to the merge queue Dec 16, 2025
Merged via the queue into tskit-dev:main with commit 12b3951 Dec 16, 2025
13 checks passed
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.

Error in "tracing ancestry through pedigree" docs example

2 participants