Tinderbox & R (RStudio)

Sounds promising…this was my thinking too. :slight_smile: Maybe you could join one of our next meets and we could explore how to do this.

Not related, but I would like to take this opportunity to encourage those who are not English-fluent to also participate! With today’s realtime translators we could potentially make a go of it. I’m regularly communicating with others in languages I know little to nothing of.

Just a thought:)

5 Likes

That’s a good idea! I also do a lot of work in RStudio and with Quarto. Joining forces and discussing that in a meetup would be great!

1 Like

Tangential to this thread, but your script should work if (changing “/FigTest” to the actual path of your note) you do something like this:

tell application "Tinderbox 10" to set value of attribute "MediaFileName" of (find note in front document with path "/FigTest") to "tinderboxplot.png"

See forum discussion here and explanation of find note in [specifier] with path [text] in aTbRef here or the AppleScript Dictionary for Tinderbox.

1 Like

A nice R learning YouTube channel:

R Programming 101.

1 Like

I have fixed a bug related to the section label list. Additionally, I have added support for the Quarto manuscript format. Please wait a little longer for the usage tutorial video.

Demo_TBX_for_Quarto.tbx.zip (770.2 KB)


2025/01/12 update
I have uploaded a YouTube video explaining the basic usage of the file:


2025/01/19 update
I’ve added explanations for Appendix and Manuscript to the YouTube video and re-uploaded it.
Tinderbox with Quarto part1 (English & Japanese sub)

7 Likes

Adding a link to an earlier related thread for completeness:

3 Likes

I have fixed and updated “Demo_TBX_for_Quarto.tbx” with some features.

  • Graphviz ( β version. Support for limited attributes and tested only “dot” engine )
  • Add stamps that run the command quarto preview or render in Terminal.app or WezTerm.app.
    (inspired by an early related thread )

github repogitory

4 Likes

Dear Takeshi Otsuka,
Thank you for providing the sample file Demo_TBX_for_Quarto.tbx.
I am trying to compile after reading your explanation.
The following comment was issued from the terminal, and the rendering stopped midway.
I would appreciate it if you could tell me how to avoid this situation.
My Mac environment is Mac Studio M1Max, running macOS 13.7.8 Ventura.
I understand that pacman cannot be installed on a Mac.
[ 1/15] index.qmd

processing file: index.qmd
1/4 [unnamed-chunk-1]
Error in loadNamespace():
! there is no package called ‘pacman’
Backtrace:
x

  1. -base::loadNamespace(x)
  2. -base::withRestarts(stop(cond), retry_loadNamespace = function() NULL)
  3. \-base (local) withOneRestart(expr, restarts[[1L]])
    
  4.   \-base (local) doWithOneRestart(return(expr), restart)
    

Quitting from index.qmd:1-5 [unnamed-chunk-1]
Execution halted
WARN: Error encountered when rendering files

I think it’s because I don’t fully understand the explanation on your github?
(I am about to turn 80 years old.)
Yours, WAKAMATSU

Dear Kunimitsu Wakamatsu.
Thank you for your interest in my file.

I apologize, the explanation on GitHub may be insufficient.

You have to install pacman package in your R environment.

Steps

  1. Run R command.

    $ R
    
  2. Install pacman or Run renv::restore()

    >  install.packages("pacman")
    

    Alternatively, if you cloned from my repository, you have renv directory and renv.lock file. you can install the necessary packages using the following command:

    > renv::restore()
    

The reticulate package didn’t get installed with renv::restore() in my environment. If you re-compile and get an error saying the reticulate package is missing, please run install.packages("reticulate").

2 Likes