11-09-2006 04:16 AM
11-09-2006 08:36 AM
Hi kaan,
This depends strongly on your DIAdem version. Over the last 3 or 4 years this sort of action has gotten steadily easier with each new version. What DIAdem version are you using? Is the channel into which you want to insert values a channel that was loaded directly from a data file or one that was created by DIAdem (say, through an ANALYSIS routine)? How are you trying to insert the NoValues-- are you using the DataBlInsertVal() function? Did you try to reset the length of the channel first? If so, how-- with ChnLength() or ChnReAlloc()?
Brad Turpin
DIAdem Product Support Engineer
National Instruments
11-09-2006 08:58 AM
Hi Brad,
I am using DIAdem 10.0 , i am also using DIAdem 10.1 beta3 but my script should function with DIAdem 10.0
The channel i want to insert values is a copy of a channel from original data loaded: First i load the data to dataportal and create a new channel group then copy some of the channels into new channel group to work on them / modify them. Then i insert the values to these channels (new channel group)
yes, I am using DATABLINSERTVAL() function
normally i didnt need to set a new channel length , because when u insert values, the length of the channel automatically increases and is actualised.
For some channels i dont have any problems inserting values, because i dont insert more than 100 values at once but there are some channels that i have to insert more than 10 000 values at once which results in above mentioned error message
i tried to set the channel length to the desired value (which is known already) but because of the fact that when values are inserted , the channel length increases automatically, it results in a longer channel with "0" values at the last rows which is not desirable for my application
i am sending you the script so that you can have a quick look on it. the script aims to re-create the points in X and Y channels which were lost during lossy compression (deleting the values which are on a line) i have to recreate those points in order to acquire a equi-distant X axis (hence a vaweform channel) in order to be able to apply some evaluations on those channels
thanks in advance
Kaan
11-10-2006 07:19 AM
11-10-2006 09:41 AM
Hi kaan,
Based on your stated objective-- to take a channel with lossy compression and reinstate all the X values that were suppressed, I'm going to recommend that you change course entirely and use the DIAdem ANALYSIS function "Linear Mapping", available programmatically as: ChnMapLinCalc(). You can use this function on the existing imported data channel, and it will automatically create a new channel (of correct length) with constant deltaX in the default Group.
If I understand your goal correctly, this will be MUCH easier and faster than trying to insert values and do the linear interpolation yourself.
Brad Turpin
DIAdem Product Support Engineer
National Instruments
11-14-2006 02:24 AM
hi stefan and brad
thanks for the answers
has been very helpful
Kaan
11-16-2006 03:56 AM