Thanks to visit codestin.com
Credit goes to github.com

Skip to content

Commit ef4d4bd

Browse files
committed
Whitespace normalized.
1 parent b66e1a3 commit ef4d4bd

1 file changed

Lines changed: 11 additions & 11 deletions

File tree

Lib/random.py

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -117,7 +117,7 @@ class Random:
117117
Class Random can also be subclassed if you want to use a different basic
118118
generator of your own devising: in that case, override the following
119119
methods: random(), seed(), getstate(), setstate() and jumpahead().
120-
120+
121121
"""
122122

123123
VERSION = 1 # used by getstate/setstate
@@ -374,7 +374,7 @@ def normalvariate(self, mu, sigma):
374374
"""Normal distribution.
375375
376376
mu is the mean, and sigma is the standard deviation.
377-
377+
378378
"""
379379
# mu = mean, sigma = standard deviation
380380

@@ -401,7 +401,7 @@ def lognormvariate(self, mu, sigma):
401401
If you take the natural logarithm of this distribution, you'll get a
402402
normal distribution with mean mu and standard deviation sigma.
403403
mu can have any value, and sigma must be greater than zero.
404-
404+
405405
"""
406406
return _exp(self.normalvariate(mu, sigma))
407407

@@ -417,7 +417,7 @@ def cunifvariate(self, mean, arc):
417417
418418
Deprecated in version 2.3. Use:
419419
(mean + arc * (Random.random() - 0.5)) % Math.pi
420-
420+
421421
"""
422422
# mean: mean angle (in radians between 0 and pi)
423423
# arc: range of distribution (in radians between 0 and pi)
@@ -436,7 +436,7 @@ def expovariate(self, lambd):
436436
lambd is 1.0 divided by the desired mean. (The parameter would be
437437
called "lambda", but that is a reserved word in Python.) Returned
438438
values range from 0 to positive infinity.
439-
439+
440440
"""
441441
# lambd: rate lambd = 1/mean
442442
# ('lambda' is a Python reserved word)
@@ -451,12 +451,12 @@ def expovariate(self, lambd):
451451

452452
def vonmisesvariate(self, mu, kappa):
453453
"""Circular data distribution.
454-
454+
455455
mu is the mean angle, expressed in radians between 0 and 2*pi, and
456456
kappa is the concentration parameter, which must be greater than or
457457
equal to zero. If kappa is equal to zero, this distribution reduces
458458
to a uniform random angle over the range 0 to 2*pi.
459-
459+
460460
"""
461461
# mu: mean angle (in radians between 0 and 2*pi)
462462
# kappa: concentration parameter kappa (>= 0)
@@ -590,7 +590,7 @@ def gauss(self, mu, sigma):
590590
slightly faster than the normalvariate() function.
591591
592592
Not thread-safe without a lock around calls.
593-
593+
594594
"""
595595

596596
# When x and y are two variables from [0, 1), uniformly
@@ -641,9 +641,9 @@ def betavariate(self, alpha, beta):
641641
642642
Conditions on the parameters are alpha > -1 and beta} > -1.
643643
Returned values range between 0 and 1.
644-
644+
645645
"""
646-
646+
647647
# This version due to Janne Sinkkonen, and matches all the std
648648
# texts (e.g., Knuth Vol 2 Ed 3 pg 134 "the beta distribution").
649649
y = self.gammavariate(alpha, 1.)
@@ -667,7 +667,7 @@ def weibullvariate(self, alpha, beta):
667667
"""Weibull distribution.
668668
669669
alpha is the scale parameter and beta is the shape parameter.
670-
670+
671671
"""
672672
# Jain, pg. 499; bug fix courtesy Bill Arms
673673

0 commit comments

Comments
 (0)