2

I have two groups, each one with 2 vectors that represent "attributes".

Group1
2-element Vector{Any}:
[0.557, -0.13, 0.34, 0.62]
[0.62, -1.20, -0.79, 0.48]

Group2 
2-element Vector{Any}
[-1.20, -0.58, 1.07, -0.89]
[1.31, -1.58, -1.27, -0.16]

I want to make a scatter plot that shows Group 1 Attribute 1, Group 1 Attribute 2, Group 2 Attribute 1, and so on. Each category with a different color.

How can i do that?

jvm.97
  • 247
  • 1
  • 7

1 Answers1

2

You can do e.g.:

julia> using Plots

julia> scatter(vec1..., legend=nothing, color="red")

julia> scatter!(vec2..., color="blue")

if vec1 and vec2 are variables storing vectors of vectors of per group information (as in the output you have shown)

Bogumił Kamiński
  • 66,844
  • 3
  • 80
  • 107