Batch Table Operations – A QtiPlot plug-in/script

I’ve been taking lots of data at work. Each data file collected has to be imported to QtiPlot as a table and then several columns are added to the table and calculated from the imported data. Some days I have over 100 data sets, which means > 100 tables to manipulate. It was becoming impractical to perform all of the necessary table operations by hand. This script was written to automate the table operations I needed.

Batch Table Operations

To use one simply selects the tables to be affected from the list of existing tables. Then one selects and configures the operation to perform. Finally, clicking the “apply” button will perform the operation on the chosen tables.

As of today (1/30/14) the script allows adding and removing columns based on name, changing column types (x, y, z, etc.), and applying formulas to columns. Obviously, alot more could be done, but at the moment, this fits my needs. As I require more features I will add them. If you would like to request a feature add a comment or send me an email and I’ll see what I can do.

Download:

batchTable.zip

Edit 8/5/14:

I just tried to install this in version 0.9.8.9 of QtiPlot running on Windows 7 but was unable to get the script interface to load. The particular version of QtiPlot installed on the target machine came from an unofficial Windows binary (https://www.cells.es/old/Members/cpascual/docs/unofficial-qtiplot-packages-for-windows) that I’ve used before. That QtiPlot package comes with parts of PyQt4 but not the entire library. As such it is necessary to install both python 2.7 and PyQt4 as well. Then, the …/PyQt4/uic module folder has to be copied into the PyQt4 directory of the the QtiPlot installation.

At least, that was the solution in the past. Now this no longer works. The uic module is found but fails to load. I expect it’s because the version of Qt against which QtiPlot was complied and the version for which the uic module were written are now too different. Or it may be that the version of Python is too new (2.7.8). I got this to work in the past with Python 2.7.5. Anyway, under Windows at least, I no longer expect for the batchTable plugin to be usable because it draws its interface using the uic module I can’t get working. Things should still work on Linux installations. The long term solution would be to rewrite the plugin to use a Tkinter interface instead of Qt thereby removing the dependency problem.

2 thoughts on “Batch Table Operations – A QtiPlot plug-in/script”

  1. Hi,

    I tried to use your script with a windows version of QTI Plot. Every time I try to start the script from the menu QTIPlot crashes.

    Any suggests? Or is this script only working under linux?

    1. Hi Erik, sorry I didn’t see your comment earlier. It’s hard to find the real comments among all of the spam. I can verify that the script works under Linux (Debian) and Windows XP. I’ve used it with QtiPlot version 0.9.8.9 svn 2288 so far. I’m not sure what the trouble is. I suspect it’s either your python configuration or your QtiPlot version (really, the Qt version on which it’s built). I can try to help. First some questions: Are you able to execute any other python scripts from within QtiPlot? What is the version of QtiPlot you’re running, and on what distribution? What version of python do you have installed?

      I’ll try to work with you on the comments so others can see the process and hoepfully solution, but if it gets too cumbersome, we can arrange a more direct communication.

Leave a Reply

Your email address will not be published. Required fields are marked *