The object that buffers consecutive values in order to compute statistics and produce a tolerance result. It is meant to be used stand-alone and not in conjunction with the CogDataAnalysisTool.
Inheritance Hierarchy
System MarshalByRefObject
Cognex.VisionPro.Implementation CogObjectBase
Cognex.VisionPro CogStatistics
Namespace: Cognex.VisionPro
Assembly: Cognex.VisionPro.Core (in Cognex.VisionPro.Core.dll) Version: 75.1.0.0
Syntax
The CogStatistics type exposes the following members.
Constructors
| Name | Description | |
|---|---|---|
| CogStatistics | Constructs a new instance of this class. | |
| CogStatistics(IntPtr) | Constructs a new instance of this class using com pointer. | |
| CogStatistics(CogStatistics) | Constructs a new instance of this class as a deep copy of the given instance. |
Methods
| Name | Description | |
|---|---|---|
| AddEmptyValue | Adds an empty entry to the buffer. The entry will be marked in the buffer as an invalid data value. When GetBufferedValues is called these entries can be substituted by any appropriate value for display. | |
| AddValue | Adds a value to the buffer and generates a tolerance status according to the specified limits. | |
| Clone | Returns a deep copy of this class instance. Derived classes that implement Clone should override this method; other clients who wish to clone this instance should call ICloneable.Clone. See also CogSerializer.DeepCopyObject | |
| CreateObjRef | Creates an object that contains all the relevant information required to generate a proxy used to communicate with a remote object. (Inherited from MarshalByRefObject.) | |
| Dispose | ||
| Dispose(Boolean) | ||
| Equals | (Inherited from Object.) | |
| Finalize | (Overrides Object Finalize .) | |
| GetAttributes |
Implements the corresponding member of the ICustomTypeDescriptor interface.
May be overridden in derived classes to provide custom type information.
(Inherited from CogObjectBase.) | |
| GetBufferedMaxValue | The maximum value sampled over the specified range of buffered values. Index 0 represents the oldest value. Index NumBufferedValues-1 represents the most recent value. | |
| GetBufferedMean | The mean (average) value generated over the specified range of buffered values. Index 0 represents the oldest value. Index NumBufferedValues-1 represents the most recent value. | |
| GetBufferedMinValue | The minimum value sampled over the specified range of buffered values. Index 0 represents the oldest value. Index NumBufferedValues-1 represents the most recent value. | |
| GetBufferedNumSamples | The number of samples over the specified range of buffered values. Invalid values will not be included in the value returned. Index 0 represents the oldest value. Index NumBufferedValues-1 represents the most recent value. | |
| GetBufferedStandardDeviation | The standard deviation value generated over the specified range of buffered values. Index 0 represents the oldest value. Index NumBufferedValues-1 represents the most recent value. | |
| GetBufferedValues | Get the values buffered. BufferedValues may include entries that were invalid. These entries will be substituted with InvalidDataValue. Returned value Index 0 represents the oldest value. Index NumBufferedValues-1 represents the most recent value. | |
| GetClassName |
Implements the corresponding member of the ICustomTypeDescriptor interface.
May be overridden in derived classes to provide custom type information.
(Inherited from CogObjectBase.) | |
| GetComponentName |
Implements the corresponding member of the ICustomTypeDescriptor interface.
May be overridden in derived classes to provide custom type information.
(Inherited from CogObjectBase.) | |
| GetConverter |
Implements the corresponding member of the ICustomTypeDescriptor interface.
May be overridden in derived classes to provide custom type information.
(Inherited from CogObjectBase.) | |
| GetDefaultEvent |
Implements the corresponding member of the ICustomTypeDescriptor interface.
May be overridden in derived classes to provide custom type information.
(Inherited from CogObjectBase.) | |
| GetDefaultProperty |
Implements the corresponding member of the ICustomTypeDescriptor interface.
May be overridden in derived classes to provide custom type information.
(Inherited from CogObjectBase.) | |
| GetEditor |
Implements the corresponding member of the ICustomTypeDescriptor interface.
May be overridden in derived classes to provide custom type information.
(Inherited from CogObjectBase.) | |
| GetEvents |
Implements the corresponding member of the ICustomTypeDescriptor interface.
May be overridden in derived classes to provide custom type information.
(Inherited from CogObjectBase.) | |
| GetEvents( Attribute ) |
Implements the corresponding member of the ICustomTypeDescriptor interface.
May be overridden in derived classes to provide custom type information.
(Inherited from CogObjectBase.) | |
| GetHashCode | Serves as a hash function for a particular type. (Inherited from Object.) | |
| GetLifetimeService | Retrieves the current lifetime service object that controls the lifetime policy for this instance. (Inherited from MarshalByRefObject.) | |
| GetLimitEnables | Get one or more of the tolerance limit enable flags. | |
| GetLimits | Get one or more of the tolerance limit values. | |
| GetObjectData | ||
| GetProperties |
Implements the corresponding member of the ICustomTypeDescriptor interface.
May be overridden in derived classes to provide custom type information.
(Inherited from CogObjectBase.) | |
| GetProperties( Attribute ) |
Implements the corresponding member of the ICustomTypeDescriptor interface.
May be overridden in derived classes to provide custom type information.
(Inherited from CogObjectBase.) | |
| GetPropertyOwner |
Implements the corresponding member of the ICustomTypeDescriptor interface.
May be overridden in derived classes to provide custom type information.
(Inherited from CogObjectBase.) | |
| GetType | Gets the Type of the current instance. (Inherited from Object.) | |
| InitializeLifetimeService | Obtains a lifetime service object to control the lifetime policy for this instance. (Inherited from MarshalByRefObject.) | |
| MemberwiseClone | Creates a shallow copy of the current Object. (Inherited from Object.) | |
| MemberwiseClone(Boolean) | Creates a shallow copy of the current MarshalByRefObject object. (Inherited from MarshalByRefObject.) | |
| ResetBufferedValues | Clears the buffered values. Sets NumBufferedValues to zero. | |
| ResetRunningStatistics | Resets the running statistics. Sets RunningNumSamples to zero. | |
| ResumeAndRaiseChangedEvent | Re-enables raising of the Changed event after SuspendChangedEvent has been called. Also raises the Changed event if the ChangedEventSuspended count is reduced to zero and any changes were made while events were suspended. Must be called once for each call to SuspendChangedEvent. | |
| SetLimitEnables | Set all of the tolerance limit enable flags. | |
| SetLimits | Set all of the tolerance limit values. | |
| SuspendChangedEvent | Temporarily suspends the raising of the Changed event. May be called more than once, and a corresponding call to ResumeAndRaiseChangedEvent must be made for each call to SuspendChangedEvent. | |
| ToString | (Inherited from Object.) |
Fields
| Name | Description | |
|---|---|---|
| SfBufferLength | This bit will be set in the EventArgs of a Changed event every time the value returned by BufferLength may have changed. | |
| SfCurrentValue | This bit will be set in the EventArgs of a Changed event every time the value returned by CurrentValue may have changed. | |
| SfCurrentValueIsInvalid | This bit will be set in the EventArgs of a Changed event every time the value returned by CurrentValueIsInvalid may have changed. | |
| SfDescription | This bit will be set in the EventArgs of a Changed event every time the value returned by Description may have changed. | |
| SfName | This bit will be set in the EventArgs of a Changed event every time the value returned by Name may have changed. | |
| SfNominalValue | This bit will be set in the EventArgs of a Changed event every time the value returned by NominalValue may have changed. | |
| SfNumBufferedValues | This bit will be set in the EventArgs of a Changed event every time the value returned by NumBufferedValues may have changed. | |
| SfRejectHighLimit | This bit will be set in the EventArgs of a Changed event every time the value returned by RejectHighLimit may have changed. | |
| SfRejectHighLimitEnabled | This bit will be set in the EventArgs of a Changed event every time the value returned by RejectHighLimitEnabled may have changed. | |
| SfRejectLowLimit | This bit will be set in the EventArgs of a Changed event every time the value returned by RejectLowLimit may have changed. | |
| SfRejectLowLimitEnabled | This bit will be set in the EventArgs of a Changed event every time the value returned by RejectLowLimitEnabled may have changed. | |
| SfRunningMaxValue | This bit will be set in the EventArgs of a Changed event every time the value returned by RunningMaxValue may have changed. | |
| SfRunningMean | This bit will be set in the EventArgs of a Changed event every time the value returned by RunningMean may have changed. | |
| SfRunningMinValue | This bit will be set in the EventArgs of a Changed event every time the value returned by RunningMinValue may have changed. | |
| SfRunningNumSamples | This bit will be set in the EventArgs of a Changed event every time the value returned by RunningNumSamples may have changed. | |
| SfRunningStandardDeviation | This bit will be set in the EventArgs of a Changed event every time the value returned by RunningStandardDeviation may have changed. | |
| SfWarnHighLimit | This bit will be set in the EventArgs of a Changed event every time the value returned by WarnHighLimit may have changed. | |
| SfWarnHighLimitEnabled | This bit will be set in the EventArgs of a Changed event every time the value returned by WarnHighLimitEnabled may have changed. | |
| SfWarnLowLimit | This bit will be set in the EventArgs of a Changed event every time the value returned by WarnLowLimit may have changed. | |
| SfWarnLowLimitEnabled | This bit will be set in the EventArgs of a Changed event every time the value returned by WarnLowLimitEnabled may have changed. |
Properties
| Name | Description | |
|---|---|---|
| BufferLength | Returns/sets the number of values to buffer. | |
| ChangedEventSuspended | If nonzero, indicates that the raising of the Changed event has been suspended. This value is incremented when SuspendChangedEvent is called and decremented when ResumeAndRaiseChangedEvent is called. | |
| CurrentValue | Returns/sets the value that will be used by Execute to compute the tolerance status for this channel. If the value is invalid (it hasn't been updated since the last call to Execute), the status will be set to cogDataAnalysisToleranceStatusInvalidValue. | |
| CurrentValueIsInvalid | Returns the flag that specifies whether or not the CurrentValue has been used by Execute. If true, the status for the channel will be set to cogDataAnalysisToleranceStatusInvalidValue. | |
| Description | Returns/sets a description string for the object. The Description may be optionally set to store a readable description of the use of the channel. | |
| HasChanged | If true, the serializable state of this object has changed since the last time it was serialized. | |
| Name | Returns the name of the channel. This is the same as the Key that was used when the channel was created via AddNew. | |
| NominalValue | Returns/sets the nominal or expected value of the current value. This value is not used to produce the tolerance result, but is merely provided as a reference for the expected value. | |
| NumBufferedValues | Returns the number of values that are currently held in the buffer. Entries that are marked with No Value (by calling AddEmptyValue) will be included in this count. This count will not exceed BufferLength. | |
| RejectHighLimit | Returns/sets the tolerance limit that triggers a reject-high status, if enabled and the value exceeds it. Setting may cause the other limit values to be adjusted so that the RejectHighLimit remains the highest limit. | |
| RejectHighLimitEnabled | Returns/sets the use of the RejectHighLimit to generate a tolerance status. | |
| RejectLowLimit | Returns/sets the tolerance limit that triggers a reject-low status, if enabled and the value falls below it. Setting may cause the other limit values to be adjusted so that the RejectLowLimit remains the lowest limit. | |
| RejectLowLimitEnabled | Returns/sets the use of the RejectLowLimit to generate a tolerance status. | |
| RunningMaxValue | Returns the maximum value sampled since last reset. Calling ResetRunningStatistics() will restart this calculation. | |
| RunningMean | Returns the mean (average) value generated from sampled data since last reset. Calling ResetRunningStatistics() will restart this calculation. | |
| RunningMinValue | Returns the minimum value sampled since last reset. Calling ResetRunningStatistics() will restart this calculation. | |
| RunningNumSamples | Returns the number of samples (valid values) used to compute the running statistics. Running statistics are not affected by the buffer size; they are calculated from all samples since last reset. Calling ResetRunningStatistics() will set this to zero. | |
| RunningStandardDeviation | Returns the standard deviation value generated from sampled data since last reset. Calling ResetRunningStatistics() will restart this calculation. | |
| WarnHighLimit | Returns/sets the tolerance limit that triggers a warn-high status, if enabled and the value exceeds it but does not exceed the RejectHighLimit. Setting may cause the other limit values to be adjusted so that the limit values remain consistent. | |
| WarnHighLimitEnabled | Returns/sets the use of the WarnHighLimit to generate a tolerance status. | |
| WarnLowLimit | Returns/sets the tolerance limit that triggers a warn-low status, if enabled and the value falls below it but does not fall below the RejectLowLimit. Setting may cause the other limit values to be adjusted so that the limit values remain consistent. | |
| WarnLowLimitEnabled | Returns/sets the use of the WarnLowLimit to generate a tolerance status. |
Events
| Name | Description | |
|---|---|---|
| Changed | Occurs when one or more parts of the object's state may have changed. |
Remarks
This interface provides functions and properties that let you compute statistical measures of a set of data, where the individual data values are supplied in sequence.
This interface is very similar to CogStatistics. Unlike that interface, which can only be used as part of a CogDataAnalysis tool, CogStatistics is intended for stand-alone use.
See Also