lmcai / Coalescent_simulation_and_gene_flow_detection

R and Python scripts used to simulate gene trees under coalescent model and detect gene flow using triple frequency
GNU General Public License v3.0
10 stars 3 forks source link

More guidance for creating correctly formatted input files, and better error codes when files are incorrectly formatted #4

Open toddmclay opened 1 year ago

toddmclay commented 1 year ago

Hello,

I have been trying to use your workflow but keep running into a paste error, which I have assumed is due to an incorrectly formatted input file (likely the bootstrap file).

Error in 2:(colon[1] - 1) : NA/NaN argument Calls: geneTr_sim -> sim.coal.mpest -> read.tree.nodes -> paste Execution halted

However, I cannot work out which of my files are incorrectly formatted, but I am also not confident I have tried to input the correct file for any of the three inputs required. Commands used to either produce the input files in ASTRAL/IQTREE etc., or how to manipulate the outputs so they are in phybase readable format would be extremely helpful.

Cheers Todd

LuoChen2 commented 1 week ago

Hi Todd,

I have come across the same issue. Did you manage to solve it in the end? Thanks.

Best, Luo

haoxianger commented 6 days ago

Hello, luo The reason for ‘-> sim.coal.mpest -> read.tree.nodes -> paste ’ may be due to formatting problems with the results of the mpest run. For examble:

Nexus

[This analysis was conducted at local time 09:54AM on 04-09-2024 with seed = 31646. The branch length 1.0 of the external branches is arbitrary because mp-est does not estimate the lengths of the external branches. If the internal branch length is 7.0, it indicates that all gene trees support the species tree triple. In the output.tre file, the tree block contains the output trees (and their likelihood scores) generated from the algorithm, while the besttree.tre file contains the final mpest tree. If multiple runs are specified, the besttree.tre file contains multiple mpest trees generated from multiple runs. Choose the tree with the maximum likelihood score as the estimate of the species tree.]

Begin trees; translate 1 ...... tree mpest [-430643.305396] = ((18:1.00,19:1.00)[&concordance=1.00]:5.91,((((9:1.00,((12:1.00,13:1.00)[&concordance=0.88]:1.61,(11:1.00,10:1.00)[&concordance=0.89]:1.55)[&concordance=0.69]:0.72)[&concordance=0.80]:1.59,(((3:1.00,4:1.00)[&concordance=0.89]:2.11,((7:1.00,6:1.00)[&concordance=0.26]:0.07,8:1.00)[&concordance=0.50]:0.64)[&concordance=0.39]:0.32,(5:1.00,2:1.00)[&concordance=0.79]:1.42)[&concordance=0.59]:0.92)[&concordance=0.43]:0.33,((17:1.00,16:1.00)[&concordance=0.72]:0.96,(14:1.00,15:1.00)[&concordance=0.79]:1.09)[&concordance=0.89]:2.47)[&concordance=0.70]:1.01,1:1.00)[&concordance=1.00]:5.36)[&concordance=1.00]; end;

Of the above, "((18:1.00,19:1.00):5.91,((((9:1.00,((12:1.00,13:1.00):1.61,(11:1.00,10:1.00):1.55):0.72):1.59,(((3:1.00,4:1.00):2.11,((7:1.00,6:1.00):0.07,8:1.00):0.64):0.32,(5:1.00,2:1.00):1.42):0.92):0.33,((17:1.00,16:1.00):0.96,(14:1.00,15:1.00):1.09):2.47):1.01,1:1.00):5.36);" is only thing that's needed. All the files needed should be in this format in "Coalescent_simulation_and_gene_flow_detection".

Best, HaoXiang


发件人: LuoChen2 @.> 发送时间: 2024年9月1日 2:53 收件人: lmcai/Coalescent_simulation_and_gene_flow_detection @.> 抄送: haoxianger @.>; Comment @.> 主题: Re: [lmcai/Coalescent_simulation_and_gene_flow_detection] More guidance for creating correctly formatted input files, and better error codes when files are incorrectly formatted (Issue #4)

Hi Todd,

I have come across the same issue. Did you manage to solve it in the end? Thanks.

Best, Luo

― Reply to this email directly, view it on GitHubhttps://github.com/lmcai/Coalescent_simulation_and_gene_flow_detection/issues/4#issuecomment-2323013949, or unsubscribehttps://github.com/notifications/unsubscribe-auth/BDSDUDCY6TVT27IOWST5OWLZUIGJZAVCNFSM6AAAAAAZEGWBBSVHI2DSMVQWIX3LMV43OSLTON2WKQ3PNVWWK3TUHMZDGMRTGAYTGOJUHE. You are receiving this because you commented.

toddmclay commented 2 days ago

Hi Luo,

I did not I'm afraid.

Cheers Todd