Rogue Wave banner
Previous fileTop of DocumentContentsIndex pageNext file
Business Analysis Module Reference Guide
Rogue Wave web site:  Home Page  |  Main Documentation Page

RWInterval<T>


Does not inherit

Local Index

Members

Non-Members

Synopsis

#include <rw/analytics/interval.h>

RWInterval<double> ci( -1.031, 2.045, RWInterval<double>::closed);

Description

RWInterval<T> is a general-purpose class for describing an interval of values. The values in the interval are of type T. An interval may be considered a set of contiguous values where the interval endpoints are either included or excluded from the set. If an interval's endpoints are excluded, it is said to be open; if the endpoints are included, the interval is said to be closed.

In Linear Algebra Module, the class RWInterval<T> is used to describe confidence intervals for regression predictions and parameter estimates.

Example

The following example prints the linear regression prediction interval for the first pattern in the predictor matrix at a confidence level of 99 percent.

Public Enumeration

enum Type {open, closed, openClosed, closedOpen}

Public Constructors

RWInterval(); 
RWInterval(T lb, T up,  RWInterval<T>::Type t); 
RWInterval(const RWInterval<T>& i); 

Public Member Functions

bool 
contains(T x) const; 
T 
lowerBound() const; 
void 
setBound(T x);
void 
setBounds(T x, T y) const; 
void  
setType(RWInterval<T>::Type t);
RWInterval<T>::Type  
type() const; 
T 
upperBound() const; 

Public Member Operator

RWInterval<T>&  
operator=(const RWInterval<T>& i);

Global Operator

bool  operator==(const RWInterval<T>& lhs, 
                      const RWInterval<T>& rhs);


Previous fileTop of DocumentContentsIndex pageNext file

© Copyright Rogue Wave Software, Inc. All Rights Reserved.
Rogue Wave and SourcePro are registered trademarks of Rogue Wave Software, Inc. in the United States and other countries. All other trademarks are the property of their respective owners.
Contact Rogue Wave about documentation or support issues.