KristofferC / PGFPlotsX.jl

Plots in Julia using the PGFPlots LaTeX package
Other
301 stars 40 forks source link

How to create a cycle list #276

Closed zsoerenm closed 2 years ago

zsoerenm commented 3 years ago

I try to create something like this:

\begin{axis}[
    cycle list={
        {blue!70!black,fill=blue},
        {blue!60!white,fill=blue!30!white},
        {draw=none,fill={rgb:red,138;green,82;blue,232}},
        {red,thick}
    },
]

With this:

using PGFPlotsX, Colors
colors = distinguishable_colors(10, [RGB(1,1,1), RGB(0,0,0)], dropseed=true)
markers = ["*", "x", "+", "o", "asterisk", "oplus", "square", "triangle", "diamond", "pentagon"]
cycle_list = map((color, mark) -> @pgf({color = color, mark = mark}), colors, markers)
@pgf Axis({
        cycle_list = {cycle_list...}
    })

However, I get the following error:

ERROR: LoadError: MethodError: Cannot `convert` an object of type Vector{PGFPlotsX.Options} to an object of type PGFPlotsX.Options

How would I create a cycle list?

KristofferC commented 3 years ago

Please provide an MWE. For example, ests.cn0_ests is not defined here.

zsoerenm commented 3 years ago

I'm sorry, I updated the MWE above.