Skip to content
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

Add interesting sample-subsetting in Fig 3 #66

Open
jeromekelleher opened this issue Dec 15, 2023 · 1 comment
Open

Add interesting sample-subsetting in Fig 3 #66

jeromekelleher opened this issue Dec 15, 2023 · 1 comment

Comments

@jeromekelleher
Copy link
Collaborator

Figure 3 is about demonstrating how we access subsets of the genotype matrix, and compute performance. It currently looks like this:

Screenshot from 2023-12-15 12-28-25

The left-hand column shows the performance of the various approaches to subsetting (total CPU time), and the right-hand column shows how they are implemented. It's currently a sketch.

I think it would be helpful to show how one would do this for more realistic criteria. We have quite a bit of information in the original simulations about pedigree data, so we could include this in the header of the VCF, and do some sort of filtering on that, and show how this can be used to specify the dataset we're interested in.

Essentially I want to show us doing something useful in clean simple to understand and decompose code using sgkit, and highlight the cryptic horror of complex Unix pipelines (great and all as they are).

@jeromekelleher
Copy link
Collaborator Author

The simulated FC pedigree has per-individual metadata fields like this:

{'decade': '1940.0',
 'geo_coord': [49.248, -65.3551],
 'individual_name': '35252060',
 'loc': '13310.0',
 'sex': '2.0'}

So, the plan is to export this information from the simulations to a per-sample metadata file which we load via pandas in the example code, and then get all individuals with (say) decade >= 1940, or with location north of some lat-long value. We then do the same thing using Awk or something to create a temporary sample file, and then use this in bcftools.

That's probably a nice illustration of the awkwardness of doing this soft of stuff in the shell.

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

No branches or pull requests

1 participant