Programming Beginner

Blacktharne

Member
Nov 12, 2004
33
0
0
I need to find/write a program that will dump values generated by WINDAQ software into excel. It will save me an immense amount of time if I can automate this (at least in part) as I have somewhere on the order of 10,000 values that I will ultimately need to transfer from WINDAQ to excel.

I have no experience programming. I?ve downloaded ActivePython and the Dive into Python PDF. I?ve read through the tutorial that is included with the download and I understand the basic idea of Python (I think), but a lot of the jargon is confusing and maybe not pertinent to what I need to do. There seems to be a massive amount of information about Python out there ? Can anyone point me to a website, tutorial, beginner?s guide, etc. that is geared toward someone with no programming experience who has a concise idea of what he wants to do (i.e. automate data collection from one program and dump it into another)?

I could go into much greater detail but nobody wants to read that. Thanks in advance for the help.
 

notfred

Lifer
Feb 12, 2001
38,241
4
0
If you want to write macros or scripts for excel, then you want to be writing VB, not python.
 

Kyteland

Diamond Member
Dec 30, 2002
5,747
1
81
VB is fine if you want to do all of the work in excel, but if all you're doing is converting data to an excel file, any language that can print to a text file will do. I do this kind of thing in c++ all the time.

When I googled windaq the first link was to a program that dumped data in to excel. Is buying the software not possible?
 

Blacktharne

Member
Nov 12, 2004
33
0
0
The software is about $2000...I don't have that kind of funding...I'm a lowly graduate student working on my thesis.

I was told that Python was the most appropriate language to use for writing a simple program, especially given I have no experience. I'm willing to spend a good chunk of time learning the basics of programming, because in the end it will save me alot of time and will likely be something I can use in the future as well. Like I said, I've worked through the tutorial and have begun reading the Dive into Python guide (300+ pages though) and I'm learning things, but alot of the information seems more geared toward folks with programming experience in other languages.

I'm curious if anyone knows of a good begginers resource that is geared toward creating a simple program that can "grab data from one program and write it to text or excel and repeat" - I'm not up on programming jargon, but I think you get the idea of what I'm trying to do.

I haven't devoted a whole lot of time to this yet either, I was just wondering where other folks who took the self-taught approach to programming (with a specific goal in mind) got their start.
 

letdown427

Golden Member
Jan 3, 2006
1,594
1
0
I'd have to chime in and say VB6 is a good option. If I knew what WINDAQ was I'd offer to try to write the program for you, as it seems pretty simple. I'm new to programming aswell, and visual basic 6 has been really easy to learn for me.

Does WINDAQ produce one result at a time then I'm guessing? So it would be a case of taking the output from each windaq calculation (i assume) and adding that to excel? I'm sure you'll be able to find someone to do it for you lol, or it might even alreayd exist somewhere. I spent many hours on google until i eventually turned up some answers to a programming problem I had. Amazingly Microsoft had the answe! and it works. which was scary.

Although, if that company are charging $2000 for the software, it probably isn't THAT easy to make. Otherwise you could make it yourself in python, and sell it for saay, $1000.



http://www.dataq.com/products/software/windaqxl.htm


It says Downlad 60day trial? Any chance you could just wait until you've got all 10,000 values that are needed, then download the trial and do them all at once? I dno if that'll fit in with your position.
 

Zontor

Senior member
Sep 19, 2000
530
0
0
Don't rule out some of the "simpler" macro programs out there for a quick one-off job (such as AutoHotkey or AutoIt3) - IMHO they have a much shorter learning curve....
 

Blacktharne

Member
Nov 12, 2004
33
0
0
Thanks for the suggestions so far guys. I wasn't even aware VB existed, that will help quite a bit once the data is in excel.

As for the windaqXL program, it doesn't really do anything that I can't already do with the standard windaq software. I don't need data transferred to excel in realtime. I can save waveforms as .csv files and all the raw data is dropped into excel which works just as wel as the windaqXL (I d/l the trial version and tooled around with it).

I don't want to get into too great detail, because I'm sure no one will want to read it, but...

Each waveform file which I've saved contains three channels of waveform data (graphs basically). Within each channel there are 10 spikes which are of interest to me (they represent the stimulus I'm trying to measure the magnitude of). I ultimately need to get the maximum value associated with each spike (in all three channels, for a total of 30 maximums from one file) and a mean of one hundred or so points before the stimulus (which I will subtract from the spike maximum to get the voltage produced by the stimulus).

To make things more complicated, I need to apply a low-pass filter on each channel independently to remove noise from the signal. The software only allows me to do this to one channel at a time. So once I've performed the lowpass filter, I can save the transformed waveform (from only one channel though) as a csv file and open it in excel. Then I repeat this operation for the remaining two channels. - so to write some type of macro to be used within WINDAQ so that it would apply a filter, transform the waveform, save as a .csv file, and repeat for the other two channels would be helpful, but this may be too complicated to learn without devoting lots of time...I'll definitely check out autohotky and autoIt3 as they may help, at least in part to automate some of this.

Once the data is in excel, I will hopefully be able to use VB to automatically calculate the mean/max for each of the spikes from the raw data and drop it into one nice spreadsheet. I'll have three columns of raw voltage data (representing the three different channels) to work with. Problem is I don't know if its possible for VB/excel to identify a "spike" in the data...which is the reference point for recording mean/max associated with a given stimulus. I need to look into the more complicated functions of VB though.

In the end its probably not possible to automate many of the steps involved, but the more time saved the better. Thanks for the responses so far.


I should add, the software makes both the mean and max calculations via a statistics tool, but I have to manually select the range of data (via time bar on the graph) for the statistics to be applied to. I don't have much confidence that a program can be written to automate this (or at least one that I can write) as it requires the program to be able to recognize a spike. That's why I've switched gears toward focusing on bringing the raw data into excel and performing the calculations there...