Hi Leonardo

Sorry, it looks like it doesn't support a debug mode - my mistake. Maybe
try manually running BayesTraits. Export the data and tree files:

write.table(final_data_bt, "data.txt", row.names = FALSE, col.names = TRUE,
quote = FALSE) ape::write.tree(frog_newtree_50, file = "tree.txt")

The run it through a terminal or command prompt:

BayesTraits tree.txt data.txt

then you should be able to input your commands manually when prompted. If
it runs successfully, the issue is with how btw is interfacing with
BayesTraits. If this doesn't work then maybe try checking the BayesTraits
Path in btw

results_1 <- bayestraits(
  data = final_data_bt,
  tree = frog_newtree_50,
  commands = command_vec1,
  bt_path = "/full/path/to/BayesTraits"
)

Replace "/full/path/to/BayesTraits" with the actual path to the BayesTraits
executable.

Hope this helps!


Best wishes

Michael Zyphur
Director
Institute for Statistical and Data Science
*instats.org* <http://instats.org>


On Fri, 29 Nov 2024 at 22:00, Leonardo Matheus Servino <
[email protected]> wrote:

> Dear Michael,
>
> Thanks for your answer. I tried to run in debug mode, but the console
> simply gave me another error message:
>
> Error in bayestraits(data = final_data_bt, tree = frog_newtree_50, commands = 
> command_vec1,  :
>   unused argument (debug = TRUE)
>
>
> Em qui., 28 de nov. de 2024 às 21:43, Michael Zyphur <[email protected]>
> escreveu:
>
>> Hi Leonardo
>>
>> The "btw can't find a log file" error is common with the btw package when
>> the underlying BayesTraits executable fails to run properly or save its
>> output. Assuming that 1) the BayesTraits installation is fine, 2) the file
>> and path permissions are all ok, and 3) your input data format is
>> appropriate given the requirements, then you can try running it in debug
>> mode to troubleshoot the problem with something like:
>>
>> results_1 <- bayestraits(
>>   data = final_data_bt,
>>   tree = frog_newtree_50,
>>   commands = command_vec1,
>>   debug = TRUE
>> )
>>
>> This may provide clues about where the process is failing.
>>
>>
>> Best wishes
>>
>> Michael Zyphur
>> Director
>> Institute for Statistical and Data Science
>> *instats.org* <http://instats.org>
>>
>>
>> On Fri, 29 Nov 2024 at 04:50, Leonardo Matheus Servino <
>> [email protected]> wrote:
>>
>>> Dear group,
>>>
>>> Anyone here is familiar with package btw?I'm trying to perform some
>>> analysis with my dataset, but I got the following error message:
>>>
>>> command_vec1 <- c("3", "2")
>>>
>>>
>>> results_1 <- bayestraits(data = final_data_bt, tree = frog_newtree_50,
>>> commands = command_vec1)
>>>
>>> Error in bayestraits(data = final_data_bt, tree = frog_newtree_50,
>>> commands = command_vec1) :
>>>   Something went wrong: btw can't find a log file
>>>
>>>
>>> Has anyone here ever faced this error?
>>>
>>> Cheers
>>> --
>>> Leonardo Matheus Servino
>>> Pós-graduação em Ecologia
>>>
>>> Departamento de Ecologia
>>> Universidade de São Paulo
>>> Rua do Matão, Trav. 14, n˚ 101
>>> Cid. Universitária - São Paulo, SP
>>> 05508-090
>>> Brasil
>>>
>>> *Lattes <http://lattes.cnpq.br/3993528079964952> - **ResearchGate
>>> <https://www.researchgate.net/profile/Leonardo_Servino> - ORCID
>>> <https://orcid.org/0000-0002-6772-376X> - LinkedIn
>>> <https://www.linkedin.com/in/leonardo-matheus-servino-8379ba1b2>*
>>>
>>>         [[alternative HTML version deleted]]
>>>
>>> _______________________________________________
>>> R-sig-phylo mailing list - [email protected]
>>> https://stat.ethz.ch/mailman/listinfo/r-sig-phylo
>>> Searchable archive at
>>> http://www.mail-archive.com/[email protected]/
>>>
>>
>
> --
> Leonardo Matheus Servino
> Pós-graduação em Ecologia
>
> Departamento de Ecologia
> Universidade de São Paulo
> Rua do Matão, Trav. 14, n˚ 101
> Cid. Universitária - São Paulo, SP
> 05508-090
> Brasil
>
> *Lattes <http://lattes.cnpq.br/3993528079964952> - **ResearchGate
> <https://www.researchgate.net/profile/Leonardo_Servino> - ORCID
> <https://orcid.org/0000-0002-6772-376X> - LinkedIn
> <https://www.linkedin.com/in/leonardo-matheus-servino-8379ba1b2>*
>

        [[alternative HTML version deleted]]

_______________________________________________
R-sig-phylo mailing list - [email protected]
https://stat.ethz.ch/mailman/listinfo/r-sig-phylo
Searchable archive at http://www.mail-archive.com/[email protected]/

Reply via email to