// NewAdxrForStreamWithSrcLen creates an Average Directional Index Rating (Adxr) for offline usage with a source data stream
345753
func NewAdxrForStreamWithSrcLen(sourceLength uint, priceStream gotrade.DOHLCVStreamSubscriber, timePeriod int) (indicator *Adxr, err error) {
	ind, err := NewAdxrWithSrcLen(sourceLength, timePeriod)
	priceStream.AddTickSubscription(ind)
	return ind, err
}
597819
func NewMedPriceForStreamWithSrcLen(sourceLength uint, priceStream gotrade.DOHLCVStreamSubscriber) (indicator *MedPrice, err error) {
	ind, err := NewMedPriceWithSrcLen(sourceLength)
	priceStream.AddTickSubscription(ind)
	return ind, err
}
11726
func NewAdxrForStream(priceStream gotrade.DOHLCVStreamSubscriber, timePeriod int) (indicator *Adxr, err error) {
	ind, err := NewAdxr(timePeriod)
	priceStream.AddTickSubscription(ind)
	return ind, err
}
280611
func NewRocPForStreamWithSrcLen(sourceLength uint, priceStream gotrade.DOHLCVStreamSubscriber, timePeriod int, selectData gotrade.DOHLCVDataSelectionFunc) (indicator *RocP, err error) {
	ind, err := NewRocPWithSrcLen(sourceLength, timePeriod, selectData)
	priceStream.AddTickSubscription(ind)
	return ind, err
}
1245247
func NewDefaultEmaForStreamWithSrcLen(sourceLength uint, priceStream gotrade.DOHLCVStreamSubscriber) (indicator *Ema, err error) {
	ind, err := NewDefaultEmaWithSrcLen(sourceLength)
	priceStream.AddTickSubscription(ind)
	return ind, err
}
304001
func NewSarForStreamWithSrcLen(sourceLength uint, priceStream gotrade.DOHLCVStreamSubscriber, accelerationFactor float64, accelerationFactorMax float64) (indicator *Sar, err error) {
	ind, err := NewSarWithSrcLen(sourceLength, accelerationFactor, accelerationFactorMax)
	priceStream.AddTickSubscription(ind)
	return ind, err
}
1164446
func NewDefaultDxForStreamWithSrcLen(sourceLength uint, priceStream gotrade.DOHLCVStreamSubscriber) (indicator *Dx, err error) {
	ind, err := NewDefaultDxWithSrcLen(sourceLength)
	priceStream.AddTickSubscription(ind)
	return ind, err
}
147271
func NewDefaultMacdForStreamWithSrcLen(sourceLength uint, priceStream gotrade.DOHLCVStreamSubscriber) (indicator *Macd, err error) {
	ind, err := NewDefaultMacdWithSrcLen(sourceLength)
	priceStream.AddTickSubscription(ind)
	return ind, err
}
248613
func NewAdxWithSrcLen(sourceLength uint, timePeriod int) (indicator *Adx, err error) {
	ind, err := NewAdx(timePeriod)

	// only initialise the storage if there is enough source data to require it
	if sourceLength-uint(ind.GetLookbackPeriod()) > 1 {
		ind.Data = make([]float64, 0, sourceLength-uint(ind.GetLookbackPeriod()))
	}

	return ind, err
}
1244735
func NewDemaForStreamWithSrcLen(sourceLength uint, priceStream gotrade.DOHLCVStreamSubscriber, timePeriod int, selectData gotrade.DOHLCVDataSelectionFunc) (indicator *Dema, err error) {
	ind, err := NewDemaWithSrcLen(sourceLength, timePeriod, selectData)
	priceStream.AddTickSubscription(ind)
	return ind, err
}
247546
func NewAtrWithSrcLen(sourceLength uint, timePeriod int) (indicator *Atr, err error) {
	ind, err := NewAtr(timePeriod)

	// only initialise the storage if there is enough source data to require it
	if sourceLength-uint(ind.GetLookbackPeriod()) > 1 {
		ind.Data = make([]float64, 0, sourceLength-uint(ind.GetLookbackPeriod()))
	}

	return ind, err
}
711176
func NewAdxForStreamWithSrcLen(sourceLength uint, priceStream gotrade.DOHLCVStreamSubscriber, timePeriod int) (indicator *Adx, err error) {
	ind, err := NewAdxWithSrcLen(sourceLength, timePeriod)
	priceStream.AddTickSubscription(ind)
	return ind, err
}
1100061
func NewDefaultAdxrForStreamWithSrcLen(sourceLength uint, priceStream gotrade.DOHLCVStreamSubscriber) (indicator *Adxr, err error) {
	ind, err := NewDefaultAdxrWithSrcLen(sourceLength)
	priceStream.AddTickSubscription(ind)
	return ind, err
}
333378
func NewDefaultAtrWithSrcLen(sourceLength uint) (indicator *Atr, err error) {
	ind, err := NewDefaultAtr()

	// only initialise the storage if there is enough source data to require it
	if sourceLength-uint(ind.GetLookbackPeriod()) > 1 {
		ind.Data = make([]float64, 0, sourceLength-uint(ind.GetLookbackPeriod()))
	}

	return ind, err
}
1012365
func NewDefaultPlusDmForStreamWithSrcLen(sourceLength uint, priceStream gotrade.DOHLCVStreamSubscriber) (indicator *PlusDm, err error) {
	ind, err := NewDefaultPlusDmWithSrcLen(sourceLength)
	priceStream.AddTickSubscription(ind)
	return ind, err
}
1191759
func NewMinusDiForStreamWithSrcLen(sourceLength uint, priceStream gotrade.DOHLCVStreamSubscriber, timePeriod int) (indicator *MinusDi, err error) {
	ind, err := NewMinusDiWithSrcLen(sourceLength, timePeriod)
	priceStream.AddTickSubscription(ind)
	return ind, err
}
741864
func NewDefaultAdxWithSrcLen(sourceLength uint) (indicator *Adx, err error) {
	ind, err := NewDefaultAdx()

	// only initialise the storage if there is enough source data to require it
	if sourceLength-uint(ind.GetLookbackPeriod()) > 1 {
		ind.Data = make([]float64, 0, sourceLength-uint(ind.GetLookbackPeriod()))
	}

	return ind, err
}