# Help me in using Plots Pkg, scatter

**URL:** <https://discourse.julialang.org/t/help-me-in-using-plots-pkg-scatter/54115>\
**Category:** General Usage\
**Tags:** package, data, plots\
**Created:** [January 28, 2021, 12:14pm UTC](https://discourse.julialang.org/t/help-me-in-using-plots-pkg-scatter/54115 "2021-01-28T12:14:27Z")\
**Posts on this page:** 2\
**Page:** 1

<div class="post-metadata">

**Author:** ![Mahnazi](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/mahnazi/32/21426_2.png) [@Mahnazi](https://discourse.julialang.org/u/Mahnazi)\
**Post date:** [January 28, 2021, 12:14pm UTC](https://discourse.julialang.org/t/help-me-in-using-plots-pkg-scatter/54115/1 "2021-01-28T12:14:27Z")

</div>

using XLSX  
using Plots  
Data = XLSX.readxlsx(“VRPTW.xlsx”)  
Xd=Data[“C101!E3:E28”]  
Yd=Data[“C101!F3:F28”]

#Display the data  
scatter(Xd,Yd)

but  
Cannot convert Array{Any,2} to series data for plotting  
error(::String) at error.jl:33  
\_prepare\_series\_data(::Array{Any,2}) at series.jl:8  
\_series\_data\_vector(::Array{Any,2}, ::Dict{Symbol,Any}) at series.jl:27  
macro expansion at series.jl:144 [inlined]  
apply\_recipe(::AbstractDict{Symbol,Any}, ::Type{RecipesPipeline.SliceIt}, ::Any, ::Any, ::Any) at RecipesBase.jl:282  
\_process\_userrecipes!(::Any, ::Any, ::Any) at user\_recipe.jl:36  
recipe\_pipeline!(::Any, ::Any, ::Any) at RecipesPipeline.jl:70  
\_plot!(::Plots.Plot, ::Any, ::Any) at plot.jl:172  
plot(::Any, ::Vararg{Any,N} where N; kw::Any) at plot.jl:58  
(::RecipesBase.var"#plot##kw")(::NamedTuple{(:seriestype,),Tuple{Symbol}}, ::typeof(plot), ::Array{Any,2}, ::Array{Any,2}) at plot.jl:52  
scatter(::Any, ::Vararg{Any,N} where N; kw::Any) at RecipesBase.jl:403  
scatter(::Any, ::Vararg{Any,N} where N) at RecipesBase.jl:403  
top-level scope at VRPTW:19

---

<div class="post-metadata">

**Author:** ![hendri54](https://sea2.discourse-cdn.com/julialang/user_avatar/discourse.julialang.org/hendri54/32/9621_2.png) [@hendri54](https://discourse.julialang.org/u/hendri54)\
**Post date:** [January 28, 2021, 1:18pm UTC](https://discourse.julialang.org/t/help-me-in-using-plots-pkg-scatter/54115/2 "2021-01-28T13:18:08Z")

</div>

Well, the error message pretty much says it all:  
The data you are trying to plot is a `1 x N` range from the excel file, which is read into a `Matrix` (not a `Vector`).  
When you pass a `Matrix` to `scatter`, the [columns are interpreted as series](https://docs.juliaplots.org/latest/input_data/)).  
I think you want

```julia
scatter(vec(Xd), vec(Yd))

```
