[rkward-devel] GUI element for nxn matrix

Thomas Friedrichsmeier thomas.friedrichsmeier at ruhr-uni-bochum.de
Wed Aug 29 15:14:24 UTC 2012


Hi!

On Wednesday 29 August 2012, Birk Diedenhofen wrote:
> I thought it would be great to have a GUI element in RKWard that allows to
> enter a nxn matrix: First, n has to be specified. Then the user can type
> his or her data in a simple table with n rows and n columns. Finally, a
> matrix is created from that.
> 
> The matrix GUI element could be used in RKWard dialogs to facilitate the
> input, especially for inexperienced users who don't know how to create a
> matrix. At least, I have two dialogs under development that would benefit
> from such an element ;).

A few questions for clarification:
- I guess you are talking about rather small values of n, here, probably <= 5 
in typical usage?
- The idea is to use the data once, not store it as an R object?
- You want the table directly in the dialog, not separately like the 
data.frame editor?
- n should probably be adjustable, dynamically?
 
> What do you think? How much effort would it take to implement such an
> element? I am sure Qt provides simple tables for this purpose. The
> dimensions of the table must then somehow be manipulated via JavaScript.

It's always somewhat hard to tell how much effort something will be. And of 
course it depends on how elaborate it will end up. E.g. if you want to allow 
factor data, column names, etc. in the table, that will increase complexity, 
considerably. In contrast, a small table allowing only numerical input could 
probably be done in a few hours work. Either way, I won't give you any 
promises. There's always that large list of things that I've been wanting to 
implement for a long time, and never got around to...

Design-wise, I'm asking myself whether it would be possible / reasonable to 
base this on the existing data.frame editor. Suppose the current data editor 
would be extended such that:
- It will handle 2-dimensional matrices. This would make a lot of sense on 
it's own.
- It can be confined to a fixed nubmer of rows / columns.
- It can be tied to a dialog, somehow, i.e., when you click a button in the 
dialog, an editor-window comes up, and when the dialog is closed, the editor 
closes, automatically.

Would that cover your use-case?

Regards
Thomas
-------------- next part --------------
A non-text attachment was scrubbed...
Name: signature.asc
Type: application/pgp-signature
Size: 198 bytes
Desc: This is a digitally signed message part.
URL: <http://mail.kde.org/pipermail/rkward-devel/attachments/20120829/d2f12f63/attachment.sig>


More information about the Rkward-devel mailing list