-
Notifications
You must be signed in to change notification settings - Fork 6
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
create_beast2_input_file() ignores tipdates_filename argument #108
Comments
Thanks for this bug report! I will take a look now ... |
Note to self: Indeed, creating the BEAST2 input file works perfect: test_that("use", {
expect_true(file.exists(get_beautier_path("babette_issue_108_tipdates.txt")))
expect_true(file.exists(get_beautier_path("babette_issue_108.fasta")))
fasta_filename <- get_beautier_path("babette_issue_108.fasta")
output_filename <- get_beautier_tempfilename()
tipdates_filename <- get_beautier_tempfilename(pattern = "absent_")
create_beast2_input_file(
fasta_filename,
output_filename,
tipdates_filename = tipdates_filename,
clock_model = create_rln_clock_model(),
site_model = create_gtr_site_model(),
mcmc = create_mcmc(),
tree_prior = create_cbs_tree_prior(),
beauti_options = create_beauti_options_v2_6()
)
expect_true(file.exists(output_filename))
expect_false(file.exists(tipdates_filename))
remove_beautier_folder()
}) This test is in |
Note to self:
Attaching the created XML... |
Note to self: On the other hand, it seems that the absent tipdates file did not make it into the XML at all ...? |
Note to self: the tipdates file is not stored in the BEAST2 input XML file. Instead, its content is added to the sequences, e.g.
So indeed beautier should give an error! |
Hi @WJH58, Thanks again for this bug report! I think I fixed it. To use the new code, install it with: remotes::install_github("ropensci/beautier", ref = "develop") Could you confirm that now you get a proper error message? I've added you as a contributor of the beautier package as I know how tedious it is to make a proper bug report like that 👍 |
P.S. the code will reach CRAN when testing has finished and after CRAN has had their (well-deserved) holidays 👍 |
@richelbilderbeek
|
It is because of the function tipdate_taxa_to_xml_trait():
Only when the version of beast is not 2.6, inference_model$tipdates_filename would be read. However beastierinstall::install_beast2() automatically installs v2.6. I would like to try v2.7 later. |
update:
I changed the beast2 version to 2.7. In this way, create_beast2_input_file() finally reads tipdates file, but run_beast2() reports error due to the conflicts between Java17 and beast2.7 ...
Hope you might give me suggestions about which beast2 version to use. Or fix that tipdate_taxa_to_xml_trait() function. I'd be happy to use beast v2.6. |
Hi @WJH58, Thanks for confirming that the first part of your bug report works (i.e. give an error message if the tipdates file is not found). I will take a look at the second part before Sunday 23:59 and inform you about my progress 👍 |
Hi @WJH58, this Sunday did not work out. I will take a look at the second part before next Sunday (January 19th) 23:59 and inform you about my progress 👍 |
Describe the bug
Whatever tipdates filename I specify or even when the tipdates file does not exist, create_beast2_input_file() keeps running smoothly and generate a xml file that does not contain any tip dates information.
To Reproduce
Expected behavior
Screenshots
My files if you would like to test
The text was updated successfully, but these errors were encountered: