legacy.go 1.0 KB

123456789101112131415161718192021222324252627282930313233343536
  1. package stats
  2. // VarP is a shortcut to PopulationVariance
  3. func VarP(input Float64Data) (sdev float64, err error) {
  4. return PopulationVariance(input)
  5. }
  6. // VarS is a shortcut to SampleVariance
  7. func VarS(input Float64Data) (sdev float64, err error) {
  8. return SampleVariance(input)
  9. }
  10. // StdDevP is a shortcut to StandardDeviationPopulation
  11. func StdDevP(input Float64Data) (sdev float64, err error) {
  12. return StandardDeviationPopulation(input)
  13. }
  14. // StdDevS is a shortcut to StandardDeviationSample
  15. func StdDevS(input Float64Data) (sdev float64, err error) {
  16. return StandardDeviationSample(input)
  17. }
  18. // LinReg is a shortcut to LinearRegression
  19. func LinReg(s []Coordinate) (regressions []Coordinate, err error) {
  20. return LinearRegression(s)
  21. }
  22. // ExpReg is a shortcut to ExponentialRegression
  23. func ExpReg(s []Coordinate) (regressions []Coordinate, err error) {
  24. return ExponentialRegression(s)
  25. }
  26. // LogReg is a shortcut to LogarithmicRegression
  27. func LogReg(s []Coordinate) (regressions []Coordinate, err error) {
  28. return LogarithmicRegression(s)
  29. }