Simplified data browser
Thomas.Dane
As a bit of background I am creating a package for loading (& processing) and graphing X-ray reflectivity data. I have decided to use two windows for the package; one is the XRR_loader panel which handles various input parameters for loading data and the other is the XRR_data_browser panel which is where I would like to have the data browser. The user switches between windows through a user-defined menu which just hides/shows the desired window. I have the loading panel sorted but it is with the data browser I am having trouble. The goal is to have the data browser with allowed non-contiguous multiple selections appending/removing curves to the embedded plot as the user selects.
My data structure is as follows (please see for example the attached picture); root:XRR_package - within this folder there is Experimental_Info (which contains global variables and strings) and a variety of experiment folders (SI7218-1, SI6928 etc. in the attached file). Within each experiment folder is a folder for each of the samples with all the waves which are made during processing (I could kill all these when finished but for the moment I would like to keep this) and a folder called All_data which contains the final processed data from each of the samples.
I would like to have the data browser show only the experiment folders i.e. SI7218-1, SI6298 etc. and the contents of the All_data folder within each of these experiment folders (if necessary I am happy for the flow to be exptFolder>All_data>ListOfWaves , I just want to hide all the other folders containing the bulk of processing).
I have had a play with the WaveSelectorWidget demo and it is great but there are a couple of issues which mean that I am inclined to write my own wave selector:
1) The creation of the root:Packages data folder - this is not much of a problem but I would like to keep everything as simple as possible without the generation of this extra folder.
2) again related to the first point - in having to use the packages DF, you have to use the selWave among other things rather than having user-defined waves in other locations.
3) The main point is the selected data folders - as mentioned above I would like to only have certain folders displayed which I guess would be possible with nameFilterProc.
Any advice on how best to go about this would be much appreciated - whether I should write my own package or just try and use the widget.
I would also like to have check boxes as the means of selection, there is talk of checkboxes in the documentation but am I right in thinking that this is a feature of the latest public beta release?
Many thanks,
Tom
I think your comments about the WaveSelectorWidget are correct- it is aimed at being a general-purpose DataBrowser for control panels, but you have a nice but specialized layout of data that suits your project. It might be a nice enhancement to the WaveSelectorWidget to permit hiding folders.
You might look at the HierarchicalListWidget package. It's harder to find- look in Windows->Help Windows->WMProcedures Index.ihf for a pointer to it. It is like the WaveSelectorWidget in that it coerces a ListBox control into being a way to select data that has a hierarchical structure, but is not specifically aimed at waves and data folders. You can see it in action by selecting Misc->Packages->Window Browser.
Using HierarchicalListWidget would permit you to show just the data folder you want as top-level containers. You would be responsible for populating the data folders in the list, but that's the price of flexibility.
Hm. You might be able to modify HierarchicalListWidget to do that, but it's not presently an option. ListBox controls can be made to show a checkbox in a list cell; the disclosure controls in a WaveSelectorWidget are a variant of the checkbox. Detecting a selected cell requires testing for different values in the SelWave than detecting a checked checkbox, so the HierarchicalListWidget doesn't do that for you as written.
Sounds like a big project- good luck with it!
John Weeks
WaveMetrics, Inc.
support@wavemetrics.com
January 25, 2012 at 09:08 am - Permalink
January 26, 2012 at 08:12 am - Permalink