Questions tagged [julia-plots]
95 questions
13
votes
1 answer
How to save plot in julia?
I am using StatsPlots package to perform basic plotting.
df = DataFrame(A = 1:10, B =rand(10))
@df df plot(:A, :B)
it returns a plot file like below as I expected.
Is there anyway I can save this plot image into my machine(Ubuntu) as a file?

Mohamed Thasin ah
- 10,754
- 11
- 52
- 111
7
votes
2 answers
How can I make scientific y-ticks in Julia plots?
I use Plots in Julia 1.5.
How can I make the y-ticks as shown below?
We sometime see figure with the right type of axis in scientific paper.

Sakurai.JJ
- 553
- 3
- 10
6
votes
1 answer
Plot simple moving average over dataframe in Julia
I have an excel file with dates and stock prices. I read this data into a dataframe with DataFrames.jl
using DataFrames, StatsPlots, Indicators
df = DataFrame(XLSX.readtable("Demo-sv.xlsx", "Blad3")...)
This works great and here I print the first…

hbrovell
- 547
- 6
- 17
5
votes
1 answer
Error in loadNamespace(x) : there is no package called ‘JuliaCall’
I just started to learn Julia in Quarto but when I run the following code in a Julia chunk in Quarto:
---
title: "Julia in Quarto"
editor: visual
format: html
---
```{julia}
# generating vectors
# x-axis
x = 1:10
# y-axis
y = rand(10)
# simple…

Quinten
- 35,235
- 5
- 20
- 53
5
votes
2 answers
How to make the jitter by using vegalite package
I got the following graph for each job title with salary in box plot:
so there are some outliers here, presented as dot, I want to make some jitters like this for each job title have outliers:
Is there any way I can do it with Vegalite…

hahaha
- 183
- 5
5
votes
2 answers
Function that sets an exponent in string in Julia
I am looking for a function that does the following rending:
f("2") = 2²
f("15") = 2¹⁵
I tried f(s) = "2\^($s)" but this doesn't seem to be a valid exponent as I can't TAB.

Tanj
- 442
- 2
- 9
5
votes
2 answers
How do I make x and y axes thicker with Plots (Julia)?
How can I make the lines for the x- and y-axes thicker in Julia Plots?
Is there a simple way to achieve this?
MWE:
using Plots
Nx, Ny = 101,101
x = LinRange(0, 100, Nx)
y = LinRange(0, 100, Ny)
foo(x,y; x0=50, y0=50, sigma =1) = exp(- ((x-x0)^2 +…

Mirko Czentovic
- 53
- 4
5
votes
1 answer
Julia SimpleHypergraphs - Hypernetx Error
I tried to compute a small example with the library SimpleHypergraphs. I followed the install instructions however, I have this error :
ERROR: "HyperNetX is not installed in Python used by this Julia. Install HyperNetX and reload…

Samako
- 53
- 3
4
votes
2 answers
plotting a series of coordinates stored in a 2D array
So let's say I define the following array in Julia:
M=[[1,1],[2,4],[3,9],[4,16],[5,25],[6,36],[7,49],[8,64],[9,81],[10,100],[11,121],[12,144]]
Clearly each element [x,y] follows the quadratic rule $y=x^2$ and so I expect to get a parabolic shape…

jboy
- 209
- 1
- 5
4
votes
0 answers
Does Julia's Plotly backend support basic animation or buttons?
I'm new-ish to Julia, and the docs & discourse make a big deal about integration with Plot.ly, but without mentioning the standard Plotly feature of animated figures with control widgets.
Is is possible to create, for example, the classic Our World…

Elliott Collins
- 184
- 1
- 7
4
votes
1 answer
I got a message "using Plots" in Julia and I do no how to resolve it
I am a new in Julia and after adding the Plots package I tried to use Plots and I got this Error message:
julia> using Plots
[ Info: Precompiling Plots [91a5bcdd-55d7-5caf-9e0b-520d859cae80]
ERROR: LoadError: InitError: could not load library…

Ehsan
- 41
- 1
3
votes
1 answer
How to do interval algorithms based integration using "IntervalArithmetic" package in Julia?
How to integrate an interval-algorithm-based nonlinear function (for example, d(F(X))/dX= a/(1+cX), where a=[1, 2], c=[2, 3] are interval constants) using the "IntervalArithmetic" package in Julia? Could you please give an example? Or could you…

Kanishk Sharma
- 173
- 7
3
votes
1 answer
Remove only axis values in plot Julia
In R you can use this to remove the axis values:
x <- 1:20
y <- runif(20)
plot(x, y, axes=FALSE, frame.plot=TRUE)
Axis(side=1, labels=FALSE)
Axis(side=2, labels=FALSE)
Output:
As mentioned in this answer, you can remove the axis values and tick…

Quinten
- 35,235
- 5
- 20
- 53
3
votes
0 answers
How to draw 3D plot of interval valued function using "IntervalArithmetic" package in Julia?
I have a function P = f(a, b, c) = squareroot( a^2 + b^2 + ac + bc), where a, b, and c are in intervals. I want to draw a 3D or cubical type plot where a, b, and c will be on the x, y, and z axes. My aim is to visualize how the interval value of P…

Kanishk Sharma
- 173
- 7
3
votes
1 answer
Problem with making plot using Plots in Jupyternotebook
When I am trying to make plot in Julia REPL it is possible, but when I use Jupyternotebook for even make the basic plot from Julia documentation
using Plots
x = 1:10; y = rand(10); # These are the plotting data
plot(x, y)
I see error:
SystemError:…

Kat
- 29
- 5