Table Of Contents

semilog_y

Version:
    Last Modified: January 9, 2017

    Generates a plot with a logarithmic y-scale.

    spd-note-note
    Note  

    You can only use the semilog_y function in the MathScript Console.

    Syntax

    semilog_y(y)
    semilog_y(y, attributes)
    semilog_y(x, y)
    semilog_y(x, y, attributes)
    semilog_y(x1, y1, x2, y2, ..., xN, yN)
    semilog_y(x1, y1, x2, y2, ..., xN, yN, attributes)
    semilog_y(x1, y1, attributes1, x2, y2, attributes2, ..., xN, yN, attributesN)
    Legacy name: semilogy

    Inputs

    x

    Vector or matrix you want to plot.

    y

    Vector or matrix you want to plot.

    attributes

    Valid plot attributes. Order the plot attributes by color, point style, and line style. For example, 'bo-' specifies that the plot is blue, marks points with circles, and uses solid lines. attributes is a string that accepts a combination of the following values:

    Name Description
    'b'

    Colors the plot blue.

    'c'

    Colors the plot cyan.

    'g'

    Colors the plot green.

    'k'

    Colors the plot black.

    'm'

    Colors the plot magenta.

    'r'

    Colors the plot red.

    'w'

    Colors the plot white.

    'y'

    Colors the plot yellow.

    '.'

    Marks points with dots.

    'o'

    Marks points with circles.

    'x'

    Marks points with crosses.

    '+'

    Marks points with plus signs.

    '*'

    Marks points with asterisks.

    '-'

    Uses solid lines.

    ':'

    Uses dotted lines.

    '-.'

    Uses dashed and dotted lines.

    '--'

    Uses dashed lines.

    x1

    Further vector or matrix.

    y1

    Further vector or matrix.

    attributes1

    Further plot attributes.

    x2

    Further vector or matrix.

    y2

    Further vector or matrix.

    attributes2

    Further plot attributes.

    ...

    Further vector or matrix.

    xn

    Further vector or matrix.

    yn

    Further vector or matrix.

    attributesn

    Further plot attributes.

    Syntax Variants

    • semilog_y(y) plots the columns of y against the indexes of the columns. If y is complex, semilog_y(y) plots real(y) against imag(y).
    • If x and y are real vectors, semilog_y(x, y) plots y against x.
    • semilog_y(x, y, attributes) plots y against x using the specified attributes.
    • semilog_y(x1, y1, x2, y2, ..., xN, yN, attributes) plots y1, y2, ..., and yN against x1, x2, ..., and xN, respectively. In this syntax, MathScript uses the specified attributes for the last plot and the default attributes for previous plots.
    x = 1:10;
    semilog_y(x, x.^2, 'ro-')

    Where This Node Can Run:

    Desktop OS: Windows

    FPGA: Not supported


    Recently Viewed Topics