Page 1 of 1

How to make Dynamic Plots?

Posted: Sat Jan 24, 2026 12:29 pm
by asmpro
Hi,
I work on analysis that expanded according to variables provided and each variable need a separated plot
so how to make a dynamic plots according to variables?

and another question
Is there a way to make the plot not appear in jamovi until a condition met?
something like if statement but control the appear of plots

Re: How to make Dynamic Plots?

Posted: Sun Jan 25, 2026 4:45 am
by jonathon
to make one plot per variable, you can do something like what's doing in the independent samples t-test. it creates an array of groups, but you can change this to an array of plots.

https://github.com/jamovi/jmv/blob/main ... #L458-L485

the key part is that the plots object is of type Array, and has items bound to the number of variables provided (i.e. items: (vars) ... where vars is the name of the option).

wrt visibility, easiest way is to bind the visibility like this:

visible: (optionName)

where optionName is the name of an option which is used to toggle the visibility.

cheers

jonathon

Re: How to make Dynamic Plots?

Posted: Sun Jan 25, 2026 8:10 am
by asmpro
I Will try
Thanks