-
Notifications
You must be signed in to change notification settings - Fork 5
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
Missing code for RecombinationNodeMrcas figures #120
Missing code for RecombinationNodeMrcas figures #120
Comments
I started dumping the CSV creation code into |
I think the plots file might need to read in the trees file, if only to be able to plot the cophylogenies, right? So either we have a file which produces a smaller set of tree sequences for plotting the trees (so that the computation of simplifying the trees down is done there), or we do that simplification in the plots file. The same goes for the subgraphs, which make up most of the code in |
We don't need to read the trees for this particular plot, and there's a lot of analysis in this that I (for one) don't fully follow. A notebook would be helpful. |
Happy to make a notebook for the MRCAs plot(s). In fact, I think I have one anyway, that I used to get it all working. I thought you meant that you didn't want the any of the code in plots.py to read the trees, which would be tricky, IMO. |
We want a notebook that has analysis to produce (a) the CSV used and (b) all the numbers quoted in the text. |
I'll sort that. FWIW producing the CSV (in df = treeinfo.export_recombinant_breakpoints()
df.to_csv(f"data/breakpoints_{prefix}.csv") and the numbers are output as extra info when running the plot-producing script with |
I don't think that produces |
It was a PR to the sc2ts utils file that was merged a while ago, I think? I'll check. |
Not all of them - there's some more numbers in the text with no source |
Not merged yet, That's why. Sorry! jeromekelleher/sc2ts#141
Ah, good spotting then. I'll check. |
Just looking at this again. I think it's helpful to have the trees in the plotting code, because we need to find the number of descendants of different types (e.g. BA.1) to label the top 4 MRCA nodes. This isn't something you can easily store in the CSV (since you don't want it for all nodes). But I agree that we should be using a CSV for the point locations etc. |
I think this is sorted now @hyanwong? Can we use We may as well delete the |
Yep, fine. |
I can't find the code for where the fields (e.g. fwd_bck_parents_max_mut_dist) in the data frame used in the RecombinationNodeMrcas figure is defined @hyanwong.
Do you think you could pull this out into a notebook that would do the calculations and export to a CSV? We don't really want to be doing computation in the plots file (which shouldn't need to read in the actual trees files at all).
The text was updated successfully, but these errors were encountered: