Hi all,
I want to do multiple plots with layout for parametric equations. This is my code:
using Plots, LaTeXStrings
pyplot()
θ1 = 0:0.1:2π
x1 = 3 .*cos.(θ1)
y1 = 3 .*sin.(θ1)
x2 = 3 .*cos.(θ1)
y2 = sin.(θ1)
θ2 = 0:0.1:6π
x3 = θ2.*cos.(θ2)
y3 = θ2.*sin.(θ2)
x4 = cos.(θ1)
y4 = sin.(2θ1)
p1 = (x1, y1, -10,10)
p2 = (x2, y2, -10,10)
p3 = (x3, y3, -10,10)
p4 = (x4, y4, -10,10)
s1 = L"(x,y) = (3 \ \cos \ t, 3 \ \sin \ t)";
s2 = L"(x,y) = (3 \ \cos \ t, \sin \ t)";
s3 = L"(x,y) = (t \ \cos \ t, t \ \sin \ t)";
s4 = L"(x,y) = (\cos \ t, \sin \ 2t)";
plot(p1, p2, p3, p4, layout = (2, 2), xaxis = "x", yaxis = "y", label=[s1 s2 s3 s4],
title=["a" "b" "c" "d"],
titleloc = :bottom, titlefont = font(8))
but there is an error:
LoadError: Couldn't process recipe args: (Vector{Float64}, Vector{Float64}, Vector{Float64}, Vector{Float64})
Stacktrace:
[1] error(s::String)
@ Base ./error.jl:33
[2] macro expansion
@ ~/.julia/packages/RecipesPipeline/XxUHt/src/user_recipe.jl:158 [inlined]
[3] apply_recipe(::AbstractDict{Symbol, Any}, ::Any, ::Any, ::Any, ::Any)
@ RecipesPipeline ~/.julia/packages/RecipesBase/eU0hg/src/RecipesBase.jl:300
[4] _process_userrecipes!(plt::Any, plotattributes::Any, args::Any)
@ RecipesPipeline ~/.julia/packages/RecipesPipeline/XxUHt/src/user_recipe.jl:38
[5] recipe_pipeline!(plt::Any, plotattributes::Any, args::Any)
@ RecipesPipeline ~/.julia/packages/RecipesPipeline/XxUHt/src/RecipesPipeline.jl:72
[6] _plot!(plt::Plots.Plot, plotattributes::Any, args::Any)
@ Plots ~/.julia/packages/Plots/M4dfL/src/plot.jl:223
[7] plot(::Any, ::Vararg{Any}; kw::Base.Pairs{Symbol, V, Tuple{Vararg{Symbol, N}}, NamedTuple{names, T}} where {V, N, names, T<:Tuple{Vararg{Any, N}}})
@ Plots ~/.julia/packages/Plots/M4dfL/src/plot.jl:102
[8] top-level scope
@ ~/LasthrimProjection/Test/plotjulia.jl:28
[9] include(fname::String)
@ Base.MainInclude ./client.jl:451
[10] top-level scope
@ REPL[1]:1
in expression starting at /home/browni/LasthrimProjection/Test/plotjulia.jl:28