VectorConstructors

trait VectorConstructors[Vec <: ([T] =>> Vector[T])]

Trait that can mixed to companion objects to enable utility methods for creating vectors.

class Object
trait Matchable
class Any
object Vector

Value members

Abstract methods

def apply[@specialized(Double, Int, Float, Long) V](values: Array[V]): Vec[V]

Creates a vector with the specified elements

Creates a vector with the specified elements

def zeros[V](size: Int)(implicit evidence$1: ClassTag[V], evidence$2: Zero[V]): Vec[V]

Creates a Vector of size size.

Creates a Vector of size size.

Concrete methods

def apply[V](values: V*)(implicit evidence$3: ClassTag[V]): Vec[V]

Creates a vector with the specified elements

Creates a vector with the specified elements

def rand[T](size: Int, rand: Rand[T])(implicit evidence$6: ClassTag[T]): Vec[T]

Creates a Vector of uniform random numbers in (0,1)

Creates a Vector of uniform random numbers in (0,1)

def range(start: Int, end: Int): Vec[Int]
def range(start: Int, end: Int, step: Int): Vec[Int]
def rangeD(start: Double, end: Double, step: Double): Vec[Double]
def rangeF(start: Float, end: Float, step: Float): Vec[Float]

Implicits

Implicits

implicit def canCreateZeros[V](implicit evidence$4: ClassTag[V], evidence$5: Zero[V]): CanCreateZeros[Vec[V], Int]