On Sat, May 3, 2014 at 2:17 AM, Kenta Takagaki <notifications@github.com>wrote:

> In math/src/main/scala/breeze/linalg/constructors/random.scala:
>
> > @@ -0,0 +1,149 @@
> > +package breeze.linalg
> > +
> > +import breeze.generic.UFunc
> > +import breeze.stats.distributions.Rand
> > +
> > +/**Gives a random Double.
> > +  * +  randomDouble()... returns a random double, in [0, 1]
>
> I wonder once again, though, whether it might be good to have either a
> breeze.Predef or breeze.Numpy type of place, where we would put
> simplified syntax like
>
> def  randInt( n,  rand: Rand[Int] = Rand.randInt ) = DenseVector.rand( n, rand)
> def  randn( n ) = DenseVector.rand(n, Rand.gaussian)
>
> I could also put in the half-dead "TuplePimper" (1,2,3).v stuff here
> too...
>
> I'm thinking here in terms of ease of adaption for Numpy/Matlab types...
> Having to type DenseVector is really kind of a pain (and makes it much
> more intimidating until you get into the nitty-gritty implementation
> structure of breeze). Importing with an alias is of course OK, but since
> these things are used so commonly in Matlab-type computing uses, having to
> import each object with an alias feels really stilted from that POV. It is
> also less readable if you use these commands a lot.
>

Sure. Let's just go ahead and keep your rand functions.


> —
> Reply to this email directly or view it on GitHub<https://github.com/scalanlp/breeze/pull/237/files#r12255658>
> .
>