logspace: Logarithmically spaced sequence generation

Description Usage Arguments Value Author(s) See Also Examples

Description

Function generates a logarithmically spaced sequence of n values between decades 10^l and 10^u.

Usage

1
logspace(l, u, n)

Arguments

l

10^l will be the lower value to start from

u

10^u will be the upper value to end with

n

number of values to generate

Value

Logarithmically spaced sequence of length n between 10^l and 10^u.

Author(s)

Jan Saputra Mueller

See Also

seq, selectmodel

Examples

1
2
## generate 100 logarithmically spaced values between 10^(-3) and 10^3
logspace(-3, 3, 100)

Example output

  [1] 1.000000e-03 1.149757e-03 1.321941e-03 1.519911e-03 1.747528e-03
  [6] 2.009233e-03 2.310130e-03 2.656088e-03 3.053856e-03 3.511192e-03
 [11] 4.037017e-03 4.641589e-03 5.336699e-03 6.135907e-03 7.054802e-03
 [16] 8.111308e-03 9.326033e-03 1.072267e-02 1.232847e-02 1.417474e-02
 [21] 1.629751e-02 1.873817e-02 2.154435e-02 2.477076e-02 2.848036e-02
 [26] 3.274549e-02 3.764936e-02 4.328761e-02 4.977024e-02 5.722368e-02
 [31] 6.579332e-02 7.564633e-02 8.697490e-02 1.000000e-01 1.149757e-01
 [36] 1.321941e-01 1.519911e-01 1.747528e-01 2.009233e-01 2.310130e-01
 [41] 2.656088e-01 3.053856e-01 3.511192e-01 4.037017e-01 4.641589e-01
 [46] 5.336699e-01 6.135907e-01 7.054802e-01 8.111308e-01 9.326033e-01
 [51] 1.072267e+00 1.232847e+00 1.417474e+00 1.629751e+00 1.873817e+00
 [56] 2.154435e+00 2.477076e+00 2.848036e+00 3.274549e+00 3.764936e+00
 [61] 4.328761e+00 4.977024e+00 5.722368e+00 6.579332e+00 7.564633e+00
 [66] 8.697490e+00 1.000000e+01 1.149757e+01 1.321941e+01 1.519911e+01
 [71] 1.747528e+01 2.009233e+01 2.310130e+01 2.656088e+01 3.053856e+01
 [76] 3.511192e+01 4.037017e+01 4.641589e+01 5.336699e+01 6.135907e+01
 [81] 7.054802e+01 8.111308e+01 9.326033e+01 1.072267e+02 1.232847e+02
 [86] 1.417474e+02 1.629751e+02 1.873817e+02 2.154435e+02 2.477076e+02
 [91] 2.848036e+02 3.274549e+02 3.764936e+02 4.328761e+02 4.977024e+02
 [96] 5.722368e+02 6.579332e+02 7.564633e+02 8.697490e+02 1.000000e+03

rdetools documentation built on May 29, 2017, 8:50 p.m.