You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: docs/src/backends.md
+16Lines changed: 16 additions & 0 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -50,6 +50,22 @@ For those who haven't had the pleasure of hacking on 15 different plotting APIs:
50
50
However, you will probably have a hard time choosing the right backend for your task at hand.
51
51
This document is meant to be a guide and introduction to make that choice.
52
52
53
+
# Persistent backend selection
54
+
55
+
Plots uses the [Preferences](https://github.com/JuliaPackaging/Preferences.jl) mechanism to make the default backend choice persistent across julia restart.
56
+
57
+
```julia
58
+
$ JULIA_PKG_PRECOMPILE_AUTO=0 julia -e 'import Plots; Plots.set_default_backend!(:pythonplot)'
julia>plot(1:2) |> display # uses `PythonPlot` by default
64
+
```
65
+
66
+
You can clear preferences with `Plots.set_default_backend!()`.
67
+
Alternatively, one can use the environment variable `PLOTS_DEFAULT_BACKEND` to select the default backend (but this will need to trigger manual precompilation using `Base.compilecache(Plots)`).
68
+
53
69
# At a glance
54
70
55
71
My favorites: `GR` for speed, `Plotly(JS)` for interactivity, `UnicodePlots` for REPL/SSH and `PythonPlot` otherwise.
0 commit comments