xiaoming-liu / stairway-plot-v2

The stairway plot is a method for inferring detailed population demographic history using the site frequency spectrum (SFS) from DNA sequence data.
Other
31 stars 4 forks source link

invarying recent estimates #6

Open cistarsa opened 3 years ago

cistarsa commented 3 years ago

Hello and thank you for this useful update to stairway plot! I've been tweaking parameters on a folded spectrum, in order to reconstruct recent history in my system, but the traces are constant until deeper time.

here is my blueprint file and the trace it generated:

#example blueprint file
#input setting
popid: WI # id of the population (no white space)
nseq: 44 # number of sequences
L: 3123151 # total number of observed nucleic sites, including polymorphic and monomorphic
whether_folded: true # whethr the SFS is folded (true or false)
SFS: 90178.851552 44800.504778 24586.544105 16952.260443 8275.385253 12074.645967 735.847425 7850.372219 1777.298971 5309.394851 1424.851973 2026.402121 2691.210433 1296.710106 2886.049022 569.463347 1480.689523 2361.568106 1408.533305 806.231535 967.109463 1633.826291  # snp frequency spectrum: number of singleton, number of doubleton, etc. (separated by white space)
#smallest_size_of_SFS_bin_used_for_estimation: 2 # default is 1; to ignore singletons, uncomment this line and change this number to 2
#largest_size_of_SFS_bin_used_for_estimation: 48 # default is n-1; to ignore singletons, uncomment this line and change this number to nseq-2
pct_training: 0.67 # percentage of sites for training
nrand: 10   21  32  42 # number of random break points for each try (separated by white space)
project_dir: wi_fold_29 # project directory
stairway_plot_dir: stairway_plot_es # directory to the stairway plot files
ninput: 200 # number of input files to be created for each estimation
#random_seed: 6
#output setting
mu: 2.1e-9 # assumed mutation rate per site per generation
year_per_generation: 0.1 # assumed generation time (in years)
#plot setting
plot_title: WI_folded_29 # title of the plot
xrange: 0,0 # Time (1k year) range; format: xmin,xmax; "0,0" for default
yrange: 0,0 # Ne (1k individual) range; format: xmin,xmax; "0,0" for default
xspacing: 2 # X axis spacing
yspacing: 2 # Y axis spacing
fontsize: 12 # Font size

WI_fold final summary

cistarsa commented 3 years ago

here's the correct reconstruction WI_fold final summary

JuiTse commented 2 years ago

Hi, @cistarsa I come across the similar issue, and could you tell me how to fix it? Thank you. And also, it seems like this issue will cause different estimate of "current" time in different populations, like the figure I provide below (current time of population demography are different among CL/Tai/Ngroup and Sgroup). Do you have any idea to fix this? Or it can be biological meaningful? If so, how to interpret it? Thank for the discussion and look forward for your response. Best regards, Jui-Tse test

JuiTse commented 2 years ago

Here is the original result from Tai population. (i.e., constant trance until the deeper time) two-epoch_fold.final.summary.pdf