02-08-2009 04:27 PM
Hello Group
I have found cmax(chnno) only update the chn property of minimum, and cmin does the same thing of update the minimum. I'm not sure if this only applies to me or anyone else out here. Could anyone please conform this?
I've also tried to use ChnPropSet(2,"minimum",5) , it came with an errror of "error from diadem kernel, .......Unable to write attribute value ....error number:-212"
Thanks in advance
Steven
02-09-2009 03:38 PM
Hello Steven,
CMax( ) and CMin( ) are functions that return the maximum and minimum values respectively of data already in the designated channel. They do not update anything about the channel. Are you looking for a function to impose contraints on data within a channel?
02-09-2009 03:49 PM
Here is the description of cmax from diadem help file
Valid names: ChnValMax, CMax
Specifies the maximum value in a channel.
These functions can be used as return type as you said in privious reply
or
they could be also used as to update chn's property of 'maximum' eg
cmax(chnno) = double
What i was looking for is , cmax only updates the channel properties of minimum not the maximum.
02-09-2009 03:59 PM
Hey Steven,
I am aware of this help documentation, and I think the confusion centers around the use of the word specifies. I believe that the documentation means that the function specifies to you what the maximum value is rather than you specifying to it what that value should be. That is, the function returns the maximum value in the channel. However, if you are saying that it returns the minimum value in version 9.1, that is something I can look into. In version 11, both CMax( ) and CMin( ) function correctly. Would you like me to see if this is still the case on my end for version 9.1?
02-09-2009 03:59 PM
Hi
I have attached 2 gif files.
gif1 shows channel property with correct chn max & min,
gif2 shows after running the command of cmax(2)=200 , it only updates the channel property of minimum so does cmin.
I would like to know could I fix this problem?
Thanks
Steven
02-09-2009 04:03 PM
Matt
That would be greatttt if you could please have look in DIAdem 9.10.2936
Thanks
Steven
02-09-2009 09:46 PM
Hi Steve,
The CMax() and CMin() functions return the channel's currently stored maximum and minum value, respectively. The do NOT set these values. DIAdem will not let you set the minimum and maximum value, because it uses these to automatically scale the Y axis when the channel is plotted in VIEW or REPORT.
You can force DIAdem to recalculate the minimum, maximum, novaluekey, and monotony properties with the following commands
ChnCharacter()
ChnCharacterAll()
Brad Turpin
DIAdem Product Suppot Engineer
National Instruments
02-11-2009 03:48 PM
Hi Brad,
My question was, Assign any integers to cmax it updates the value of 'minimum' rather than 'maximum' under channels properties. How could I fix this problem?
Maybe cmax is only used as a return chn maximum from your point of view, but we've been using cmax to set channels maximum manually since in DIAdem8 and IT ALWAYS worked.
It's very clear this is a bug in diadem9 and we'd like to know how can we fix it?
Regards
Steven
02-17-2009 05:02 PM
Hello
are there any solutions to this yet? its a bug
Thanks
Steven
02-18-2009 12:22 PM
Steven,
In DIAdem 8 the CMax() and CMin() functions could be used to set the maximum and minimum values. To do this was a (sort of) hack since these values were suppose to be read-only values. We determined that the implementation to be incorrect behavior. This behavior was corrected in DIAdem 9.1 and is why your old code worked fine in version 8 but now it doesn't in 9.1. To clarify, the bug was in the older version and not in the current version.
Regards,
Steven Zittrower
Applications Engineer
National Instruments