Visual editing via charts and sliders

2.43K viewsScripting
0

Currently Quantrix doesn’t support direct manipulation of data from a chart i.e. pulling on a chart value as an input mechanism (unless that is another feature that has escaped me…). However with a little scripting one can achieve something very close using sliders to select an edit point in a chart – see the attached for a demonstration. (Screenshot: [ATTACH]409[/ATTACH])

This shows editing parameter values in a times series – assuming these are input to some further modeling. In this case I’m working with annual data and constructing a quarterly series via a 4 period moving average – but that’s really beside the point. (And, in case you’re wondering, the table to which the sliders are bound is hidden behind the Fix Values button.)

My reason for posting (other than pure altruism :)) is to seek some specific enhancements, the value of which is hopefully clear from the example…

1. The ability to bind a script to a cell (like a slider etc), so that the script would trigger when the value of the cell changed. That would remove the need for a clumsy extra button to synchronize with the filter selections (and of course would enable all sorts of other cool uses).

2. A default script to run on start-up. Would be incredibly useful in general to be able to set up state for subsequent scripts.

3. And to really take this to next level, create a new sort of bindable object, which would appear as a draggable point on a chart, with values corresponding to the [font=”Courier New”]getSelection [/font]address (and btw – while you’re doing that, could you also provide the function to convert the coordinates returned by [font=”Courier New”]model.selection[/font] to the string needed for [font=”Courier New”]<matrix>.getSelection[/font]. Yes, it can be coded by iterating over the row and column categories in the matrix and mapping to the table coordinates – but it would be much nicer, and more efficient, to put it in the scripting interface ;))

Regards

Simon

Attachments

VisualEdit.PNG