Questions relating to the dynamic family of functions in Mathematica, such as Dynamic, DynamicModule and Manipulate.

learn more… | top users | synonyms

4
votes
2answers
102 views

Layers of Locators of Different Colors?

I am a Mathematica novice trying to do some interactive segmentation of microscopy images. I've been trying to understand and build upon some code from a previous StackExchange discussion (Can ...
4
votes
1answer
201 views

Manipulate Plot and control variables using multiple controls

Here's a simple Manipulate example: ...
4
votes
2answers
123 views

Refresh dynamic variable when used with Get

I came across this issue with a more complicated program I was working on. Suppose we have a volatile variable data: ...
4
votes
1answer
128 views

Using the mouse coordinates to index a matrix

I would like to "write" on to a matrix using the mouse. That is, I would like to use the integer value of Locator coordinates (p) to index a matrix. Then, if the mouse button is down, write a 1 in ...
4
votes
1answer
404 views

Emulating a button push or a mouse click with Mathematica code

I need to perform a long action with a button. I tried setting the DynamicEvaluationTimeout, but it seems it doesn't work for me. So I want to try using several ...
4
votes
1answer
95 views

Why does a heavy background slow LocatorPane from updating, even if only the locators are Dynamic?

I'm having some trouble getting a dynamic plot to operate efficiently, and I think I've tracked down at least part of the problem to some pretty weird behaviour on the part of ...
4
votes
1answer
211 views

Dynamic legends involving show

My question is how do I get dynamic legends (legends that turn data on/off) to work with Show? This is an extension of an old question here; How to dynamically toggle curves on/off in a crowded ...
4
votes
1answer
213 views

Cannot calculate with Dynamic variables in a grid

This is a prototype of a grading scheme. In reality it is bigger. The 10 pts in initPtsPartA comes from the school. The output cell should be deployed as a CDF ...
4
votes
1answer
152 views

Transform sequential cell operations to programmatic workflow

Let's say I have a workflow that involves importing images and turning them into an animated gif. Here's how I currently have it setup: Import Images: ...
4
votes
1answer
337 views

help with dynamic input

I'm trying to build a pop up window with i lines. Each line would read: Number of neurons in layer 1: Number of neurons in layer 2: etc until layer i The user would enter a numeric value on each ...
4
votes
2answers
180 views

How to add the pause button to that dynamic stopwatch?

Referring to How to make a dynamic stopwatch? Timers can now be created with timer = makeTimer[] and utilised with actions such as ...
4
votes
1answer
145 views

Change CurrentValue of a key press

I was wondering if there is a way that I could change the value of a key press such as Shift, Ctrl, etc. Normally, when nothing is pressed, the CurrentValue will ...
4
votes
2answers
141 views

Cusom PopupMenu file selector

Lately I come across what I think not uninteresting problem which is a good exercise for the usage of Dynamic. Assume you have files in a directory structure (a ...
4
votes
1answer
182 views

Dynamically link cell content in Mathematica?

Is it possible to dynamically link the content of two cells? For example, can I set up a Notebook with two text cells that display the same value, and if the user types in one the other updates, etc.? ...
4
votes
1answer
126 views

How to speed up mouse events?

Grids of dynamic objects responding to mouseovers seem to be quite slow in general, for instance: ...
4
votes
1answer
202 views

How to control variables of outer and inner Manipulates?

Consider the following ( working ) snippet: ...
4
votes
1answer
254 views

How to force Pane to always scroll to end of content? [duplicate]

Mathematica seems to know about the actual end of content position in a Pane if given large enough (but not too large$^1$) initial position value. Here, the ...
4
votes
0answers
107 views

Multi-Camera streaming using Mathematica

I am attempting to capture dynamic streams from multiple usb webcams using only mathematica. Using ImageCapture["Device" -> $ImagingDevices[[x]], I've tried to ...
4
votes
0answers
115 views

Resources for Sound Synthesis & Design

Are there any resources for sound synthesis using Mathematica? This page, Mathematica: Audio Synthesis Software, refers to other software packages, e.g. Max/MSP and Csound, for real-time synthesis. ...
4
votes
0answers
55 views

FlipView can't handle CurrentValue[“MouseOver”]. Kernel crash

Is this code crashing your Mathematica session? (it can so look out :P) ...
4
votes
0answers
128 views

DynamicModule, SaveDefinitions and global functions

Unfortunately, I had not checked stackoverflow, because there, the exact same behavior was already reported. Please see the Q&A "SaveDefinitions considered dangerous". Up-front, I'm on Ubuntu ...
4
votes
0answers
235 views

Front-end glitch when interacting with dynamic content

This is now bugging me too much to ignore it anymore. When I interact with a notebook that has dynamic content, for example moving a slider, Mathematica regularly brings other open notebook windows to ...
3
votes
1answer
256 views

Can I create a dynamic number of rows in TabView through an iteration?

I have written code, with the help of stackoverflow of course, and I want to make it user friendly so that other people in my lab can use it. I'm playing with DialogCreate and similar functions. I ...
3
votes
4answers
265 views

Change all Options of Plot Dynamically

I am trying to make a series of changes in the appearance of the Plot of some function. I am trying to use Manipulate for my experiments. I tried to change the following code ...
3
votes
2answers
137 views

A timed switch with Dynamic

I'm trying to make a binary switch that switches after a fixed given interval. Why doesn't the following work: ...
3
votes
3answers
187 views

Extracting the coordinates of a point of interest from a ListDensityPlot

How can I extract coordinates from a list density plot. Example plot of interest: I need to place two points on either side of the center white circle and calculate the distance between them. My ...
3
votes
2answers
169 views

How can I align the labels of the buttons on a setter bar to the button centers?

I tried to align the labels on the buttons of a SetterBarto the button centers. This is my code: ...
3
votes
2answers
282 views

Dynamic lists as function arguments

Suppose I have a function that requires a list is as input. I.e. f[list_]:=DoSomethingWithList Now, if I pass a variable as Dynamic like this ...
3
votes
2answers
143 views

Interactively Manipulate Code

Bear with me, I'm a noob; I simply want to create a radio button bar that selects whether I want to add or subtract two numbers: ...
3
votes
2answers
314 views

Dynamic matrix multiplication

I have the following problem: I want to multiply two matrices and sum them to another matrix C. A.B+ 2B Easy! The matrix A varies as a function of three inputs a,b and c. The second matrix, B, is a ...
3
votes
1answer
146 views

How can I allow a user to input a list using parentheses and convert this to Mathematica notation dynamically?

I have the following dynamic module. It works. The problem is that whenever I try to make the variable list or the variable s dynamic the code doesn't work. My goal is to allow students to enter a ...
3
votes
1answer
108 views

Safely generating multiple controls from a list of variables

Suppose I need to create sliders associated with variables from a given list: ...
3
votes
2answers
246 views

How to show the coordinates of a point and the equation of a line dynamically? [duplicate]

I am constructing a diagram that consists of a sine curve and its tangent line at a given argument. However, I want to show the coordinates of the point of tangency and the equation of the tangent ...
3
votes
2answers
217 views

Why does the syntax highlighter color a local symbol red inside DynamicModule?

I am adding a Module inside DynamicModule here is an example (thanks to @rm-rf for this simple example) ...
3
votes
2answers
220 views

In a Manipulate[], control timing of Autorun

I've made a gauge like instrument that will get used to prompt someone to maintain rhythmic breathing patterns during heart/brain coherence training. ...
3
votes
1answer
200 views

Using DynamicWrapper with multiple Dynamics with different TrackedSymbols

I have two variables A and B that are linked such that changes to one causes the other to be updated to the same value. However at each change I'd also like to know which variable cause the update to ...
3
votes
2answers
221 views

Can't get DynamicModule[{..},..EventHandler[] ] working

This makes a slider to control the number of points. Click in the Graphics and the points slide over to where you click. ...
3
votes
2answers
128 views

Dynamically show usage

As the title states I would like to dynamically show ::usage on several functions. Let's consider two functions here: ...
3
votes
2answers
148 views

Using list elements in TrackedSymbols for Dynamic

During the execution of the following code a column of three lists and two sliders are displaying in output. The first list updates if either a or b changes. The second list updates only if the value ...
3
votes
1answer
274 views

How to improve this dynamic progress bar code

I created this progress bar to use in my codes: ...
3
votes
1answer
595 views

Mathematica - Dynamic - ListPlot - baseline

I am performing baseline fitting to a raw dataset on a two-state equilibrium process. The process involves fitting the sigmoidal curve to an upper and lower linear baseline, and subtracting so that ...
3
votes
1answer
252 views

How to efficiently drag points on a curve within a Manipulate

My intention is to demonstrate on any conic various metrics properties on points belonging to the conic and connected by lines. I want the points to be dynamically moved not the usual way, ...
3
votes
1answer
128 views

Dynamic inside Button

This bit of code runs a little animation of a stochastic process: ...
3
votes
1answer
107 views

In a DynamicModule, is it possible to use multiple EventHandler declarations? [duplicate]

Possible Duplicate: Wrapping EventHandler by Table I am running Mathematica 7. However, I am new to using Dynamic, ...
3
votes
1answer
209 views

Forcing a graph not to resize

This code: ...
3
votes
3answers
85 views

EventHandler Not Detecting KeyDown

I am trying to use EventHandler to detect KeyDown within a LocatorPane. Anytime I press a key inside the LocatorPane the proper action is not executed (doesn't matter which key I choose) but rather ...
3
votes
1answer
75 views

Export LocatorPane as image by button

How to Export LocatorPane as image by button or at least by something else? Kuba, thank you! Your method works in a simple case: ...
3
votes
1answer
107 views

How to simulate the 1-D motion of a particle under constant acceleration? [duplicate]

I am trying to represent the position of an object under freefall, but am completely lost. Here is my attempt so far: ...
3
votes
1answer
92 views

How can I get precise frame rates in dynamic?

I've been the Spritz sdk in my ios apps, and I love it. For funsies I wanted to see how much less code a mathematica version would take! Using dynamic I get a nice result, shown below in code. ...
3
votes
1answer
117 views

Dynamic generation of Buttons

The Project I am trying to dynamically turn on/off the display of data for a circos-esque plot that I generated. The Code I have data stored in mfData and a ...