ComplexListPlot

ComplexListPlot[{z1,z2,}]

plots complex numbers z1, z2, as points in the complex plane.

ComplexListPlot[{data1,data2,}]

plots data from all datai.

ComplexListPlot[{,w[datai,],}]

plots data_(i) with features defined by the symbolic wrapper w.

Details and Options

  • The datai have the following forms and interpretations:
  • <|"k1"z1,"k2"z2,|>values {z1,z2,}
    {z1"lbl1",z2"lbl2",}, {z1,z2,}{"lbl1","lbl2",}values {z1,z2,} with labels {lbl1,lbl2,}
    SparseArrayvalues as a normal array
  • The following wrappers w can be used for the datai:
  • Annotation[datai,label]provide an annotation for the data
    Button[datai,action]define an action to execute when the data is clicked
    Callout[datai,label]label the data with a callout
    Callout[datai,label,pos]place the callout at relative position pos
    EventHandler[datai,]define a general event handler for the data
    Hyperlink[datai,uri]make the data a hyperlink
    Labeled[datai,label]label the data
    Labeled[datai,label,pos]place the label at relative position pos
    Legended[datai,label]identify the data in a legend
    PopupWindow[datai,cont]attach a popup window to the data
    StatusArea[datai,label]display in the status area on mouseover
    Style[datai,styles]show the data using the specified styles
    Tooltip[datai,label]attach a tooltip to the data
    Tooltip[datai]use data values as tooltips
  • Wrappers w can be applied at multiple levels:
  • {,w[zi],}wrap the value zi in data
    w[datai]wrap the data
    w[{data1,}]wrap a collection of datai
    w1[w2[]]use nested wrappers
  • Callout, Labeled and Placed can use the following positions pos:
  • Automaticautomatically placed labels
    Above, Below, Before, Afterpositions around the data
    xnear the data at a position x
    Scaled[s]scaled position s along the data
    {s,Above},{s,Below},relative position at position s along the data
    {pos,epos}epos in label placed at relative position pos of the data
  • ComplexListPlot has the same options as Graphics, with the following additions and changes:
  • AxesTruewhether to draw axes
    JoinedFalsewhether to join points
    LabelingFunctionAutomatichow to label points
    LabelingSizeAutomaticmaximum size of callouts and labels
    PerformanceGoal$PerformanceGoalaspects of performance to try to optimize
    PlotLabelNoneoverall label for the plot
    PlotLabelsNonelabels for data
    PlotLegendsNonelegends for data
    PlotMarkersNonemarkers to use to indicate each point
    PlotRangeAutomaticrange of values to include
    PlotRangeClippingTruewhether to clip at the plot range
    PlotStyleAutomaticgraphics directives to determine styles of points
    PlotTheme$PlotThemeoverall theme for the plot
    PolarAxesFalsewhether to draw polar axes
    PolarAxesOriginAutomaticwhere to draw polar axes
    PolarGridLinesNonepolar gridlines to draw
    PolarTicksAutomaticpolar axes ticks
    ScalingFunctionsNonehow to scale individual coordinates
  • LabelingFunction->f specifies that each point should have a label given by f[value,index,lbls], where value is the value associated with the point, index is its position in the data and lbls is the list of relevant labels.
  • Typical settings for PlotLegends include:
  • Noneno legend
    Automaticautomatically determine legend
    {lbl1,lbl2,}use lbl1, lbl2, as legend labels
    Placed[lspec,]specify placement for legend
  • The arguments supplied to functions in MeshFunctionsare x, y, θ, r where θ and r are the argument and radius of the zi. Functions in ColorFunction are by default supplied with scaled versions of these arguments.
  • ScalingFunctions->"scale" scales the modulus of the zi. ScalingFunctions{"scalex","scaley"} scales the and imaginary components, respectively.

Examples

open allclose all

Basic Examples  (4)

Plot a set of complex numbers:

Plot multiple sets of complex numbers:

Plot several data_i with a legend:

Label each point with a callout:

Scope  (37)

Data  (7)

A list of complex values is plotted as a list of {Re[z_(i)],Im[z_(i)]} pairs:

Plot multiple sets of regular data:

Non-numeric and missing data is excluded:

Use MaxPlotPoints to limit the number of points used:

PlotRange is selected automatically:

Use PlotRange to focus on areas of interest:

Use ScalingFunctions to scale the axes:

Special Data  (4)

Specify strings to use as labels:

Specify a location for labels:

Numeric values in an Association are used as the (x,y) coordinates:

Plot data in a SparseArray:

Wrappers  (6)

Use wrappers on individual data, datasets or collections of datasets:

Wrappers can be nested:

Use a specific label for all of the points:

Label points with automatically positioned text:

Use PopupWindow to click an eigenvalue to see a corresponding eigenvector:

Button can be used to trigger any action:

Labeling and Legending  (14)

Label points with automatically positioned text:

Place the labels relative to the points:

Label data with Labeled:

Label data with PlotLabels:

Place the label near the points at a particular x value:

Use a scaled position:

Specify the text position relative to the point:

Label data automatically with Callout:

Place a label with a specific location:

Specify label names with LabelingFunction:

For dense sets of points, some labels may be turned into tooltips by default:

Increasing the size of the plot will show more labels:

Include legends for each datai:

Use Legended to provide a legend for a specific dataset:

Use Placed to change the legend location:

Use association keys as labels:

Presentation  (6)

Multiple datasets are automatically colored to be distinct:

Provide explicit styling to different sets:

Include legends for each curve:

Use a plot theme:

Include legends for each dataset:

Use Legended to provide a legend for a specific dataset:

Provide an interactive Tooltip for the data:

Use shapes to distinguish different datasets:

Use labels to distinguish different datasets:

Use Joined to connect datasets with lines:

Use InterpolationOrder to smooth joined data:

Options  (96)

AspectRatio  (1)

Use numerical values for AspectRatio:

AxesLabel  (1)

Specify different labels for the real and imaginary axes:

AxesOrigin  (2)

The locations of the axes are determined automatically:

Specify where the axes cross:

ClippingStyle  (4)

ClippingStyle requires at least one dataset to be Joined:

Omit clipped regions of the plot:

Show clipped regions as red at the bottom and thick at the top:

Show clipped regions as red and thick:

ColorFunction  (3)

Color by scaled x, y, theta and r coordinates:

ColorFunction has higher priority than PlotStyle for coloring the curve:

Use Automatic in MeshShading to use ColorFunction:

ColorFunctionScaling  (4)

ColorFunctionScaling requires at least one dataset to be Joined:

Color the curve based on the scaled y value:

Color the curve based on the unscaled y value:

Color by unscaled x, y, theta and r coordinates:

ImageSize  (1)

The number of points that are labeled directly may depend on the image size:

Smaller graphics will have fewer labeled points:

Larger graphics will have more labeled points:

InterpolationOrder  (4)

InterpolationOrder requires at least one dataset to be Joined:

By default, linear interpolation is used:

Use zero-order or piecewise-constant interpolation:

Interpolation order 0 to 3:

Joined  (3)

Join the points in a dataset:

Join the first dataset with a line, but use points for the second dataset:

Join the dataset with a line and show the original points:

LabelingFunction  (7)

A Rule can be used to label points if the lists of values and labels are the same length:

A list of rules and values can be used to label selected points:

Use LabelingFunctionNone to suppress the labels:

Put the labels above the points:

Put them in a Tooltip:

Label the points as ordered pairs:

Label the points with their indices:

LabelingSize  (3)

Textual labels are shown at their actual sizes:

Specify a maximum size for textual labels:

Image labels are automatically resized:

Specify a maximum size for image labels:

Show image labels at their natural sizes:

MaxPlotPoints  (1)

Use MaxPlotPoints to limit the number of points used:

Mesh  (6)

Mesh requires at least one dataset to be Joined:

The initial and final sampling meshes are typically the same:

Interpolated data may introduce points:

Use 20 mesh levels evenly spaced in the direction:

Use an explicit list of values for the mesh in the direction:

Use explicit styles at specific points:

MeshFunctions  (3)

MeshFunctions requires at least one dataset to be Joined:

Show 5 mesh levels in the direction (red) and 10 in the direction (blue):

Use a mesh evenly spaced in the , , and directions:

MeshShading  (7)

MeshShading requires at least one dataset to be Joined:

Alternate red and blue segments of equal width in the direction:

Use None to remove segments:

MeshShading can be used with PlotStyle:

MeshShading has higher priority than PlotStyle:

Use PlotStyle for some segments by setting MeshShading to Automatic:

MeshShading can be used with ColorFunction:

PlotLabel  (1)

Add an overall label to the plot:

PlotLabels  (5)

Specify text to label sets of points:

Place the labels above the points:

Use callouts to identify the points:

Use the keys from an Association as labels:

Use None to not add a label:

PlotLegends  (6)

Generate a legend using labels:

Generate a legend using placeholders:

Legends use the same styles as the plot:

Use Placed to specify the legend placement:

Place the legend inside the plot:

Use PlotLegends to change the appearance:

PlotMarkers  (8)

ComplexListPlot normally uses distinct colors to distinguish different sets of data:

Automatically use colors and shapes to distinguish sets of data:

Use shapes only:

Change the size of the default plot markers:

Use arbitrary text for plot markers:

Use explicit graphics for plot markers:

Use the same symbol for all the sets of data:

Explicitly use a symbol and size:

PlotRange  (4)

PlotRange is automatically calculated:

Show the whole dataset:

Explicitly choose the x and y ranges:

Implicitly choose the x and y ranges by giving complex coordinates of the bottom-left and top-right corners:

PlotStyle  (7)

Use different style directives:

By default, different styles are chosen for multiple datasets:

Explicitly specify the style for different datasets:

PlotStyle applies to both curves and points:

PlotStyle can be combined with ColorFunction:

PlotStyle can be combined with MeshShading:

MeshStyle by default uses the same style as PlotStyle:

PlotTheme  (2)

Use a theme with simple ticks and grid lines in a bright color scheme:

Change the color scheme:

PolarAxes  (2)

Add polar axes and polar grid lines:

Control the radial and polar axes independently:

PolarAxesOrigin  (2)

Specify the angular axes and radial axes to intersect at :

Place radial axes at the right of the graph:

PolarGridLines  (2)

Use automatically chosen polar grid lines:

Draw grid lines at the specified positions:

PolarTicks  (4)

Place polar tick marks and labels automatically:

Modify the angular ticks:

Indicate angles with degrees:

Place polar tick marks at the specified positions:

ScalingFunctions  (3)

A single scaling function scales the data radially:

Specifying two scaling functions scales the data in the x and y directions separately:

None indicates no scaling in the specified direction:

Applications  (9)

Plot roots of unity:

Plot a discrete time signal and its spectrum:

Graph zeros of the zeta function:

Graph eigenvalues of a Cauchy matrix:

Graphs solutions of :

Show Gershgorin discs and eigenvalues for a matrix:

Show the eigenvalues for a PDE problem. Seek solutions of the structurally damped wave equation u_(tt)-epsilon u_(xxt)=u_(xx), u(0,t)=u(pi,t)=0 of the form u(x,t)=ⅇ^(lambda t)sin(n x):

Visualize iterations of Newton's method:

The eigenvalues of bipartite graphs are symmetric about the imaginary axis:

Properties & Relations  (8)

Use ListPlot, ListLinePlot or ListPolarPlot for real data:

ComplexListPlot is closely related to ListPlot:

Use ComplexPlot to use color to show the argument and magnitude of a function:

Use ComplexPlot3D to use the axis for the magnitude:

Use ReImPlot and AbsArgPlot to plot complex values over the real numbers:

ComplexContourPlot plots curves over the complexes:

ComplexRegionPlot plots regions over the complexes:

ComplexStreamPlot and ComplexVectorPlot treat complex numbers as directions:

Possible Issues  (2)

Real-valued data is plotted along the axis.:

Radial scaling is different when using the same scaling functions in the real and imaginary directions:

Neat Examples  (3)

Eigenvalue analysis of the weighted adjacency matrix of the wins by teams in the National Hockey League in the 20102011 regular season:

Symmetry in the real parts of the eigenvalues of an adjacency matrix for a graph suggests that the graph may be bipartite, but in this case the graph is not bipartite:

Compute an integer two times the numbers in {0,1,,n-1} modulo :

Graphically represent the integer as the point in the complex plane and connect the dots between the points representing and TemplateBox[{{m,  , x}, n}, Mod]:

If you use a larger value of , then an envelope appears:

Use multiples of three and five instead:

Introduced in 2019
 (12.0)