# Latest

**URL:** https://discourse.julialang.org/latest.md?page=1030

[Latest](https://discourse.julialang.org/latest.md) · [Categories](https://discourse.julialang.org/categories.md) · [Tags](https://discourse.julialang.org/tags.md)

**Page:** 1031

---

## [VSCode in notebook doesn't print if has error](https://discourse.julialang.org/t/vscode-in-notebook-doesnt-print-if-has-error/81640)

<div class="topic-metadata">

**Author:** [@Elyco](https://discourse.julialang.org/u/Elyco)\
**Replies:** 3\
**Last updated:** [May 25, 2022, 5:17pm UTC](https://discourse.julialang.org/t/vscode-in-notebook-doesnt-print-if-has-error/81640 "2022-05-25T17:17:47Z")

</div>

Hi, When using VS Code notebook I notice the following behavior: println("You won't see this print.") error() The cell doesn’t output the println command. This is very common practice for me while debugging. Even mo…

---

## [Heatmap from Matrix with custom indices](https://discourse.julialang.org/t/heatmap-from-matrix-with-custom-indices/81596)

<div class="topic-metadata">

**Author:** [@ctrebbau](https://discourse.julialang.org/u/ctrebbau)\
**Replies:** 20\
**Last updated:** [May 25, 2022, 5:13pm UTC](https://discourse.julialang.org/t/heatmap-from-matrix-with-custom-indices/81596 "2022-05-25T17:13:20Z")

</div>

Hello Community! I have data like so where I would like to visualise a heatmap of the TimeDiff\_mean column and the other two columns (representing a reticulation over geographical datapoints). I have sought for one …

---

## [Plot can't take Observables](https://discourse.julialang.org/t/plot-cant-take-observables/81607)

<div class="topic-metadata">

**Author:** [@Willi\_Wespe](https://discourse.julialang.org/u/Willi_Wespe)\
**Replies:** 8\
**Last updated:** [May 25, 2022, 4:09pm UTC](https://discourse.julialang.org/t/plot-cant-take-observables/81607 "2022-05-25T16:09:10Z")

</div>

I want to plot lines!() with Observables as x and y parameters. The value of the Obervables changes obviously, because I print them to the console. However, the lines!() plot won’t update: using GLMakie x = \[\[\[4, 3\]…

---

## [Specifying JuMP solvers for function-wrapped optimization models](https://discourse.julialang.org/t/specifying-jump-solvers-for-function-wrapped-optimization-models/81030)

<div class="topic-metadata">

**Author:** [@Tominapa](https://discourse.julialang.org/u/Tominapa)\
**Replies:** 2\
**Last updated:** [May 25, 2022, 4:06pm UTC](https://discourse.julialang.org/t/specifying-jump-solvers-for-function-wrapped-optimization-models/81030 "2022-05-25T16:06:54Z")

</div>

I am building a package based around a specific optimization problem, implemented in JuMP. My code builds an optimization model based on input data, with most everything automated behind the scenes for user-friendliness…

---

## [Bookmark button not working on firefox](https://discourse.julialang.org/t/bookmark-button-not-working-on-firefox/81659)

<div class="topic-metadata">

**Author:** [@albheim](https://discourse.julialang.org/u/albheim)\
**Replies:** 2\
**Last updated:** [May 25, 2022, 3:27pm UTC](https://discourse.julialang.org/t/bookmark-button-not-working-on-firefox/81659 "2022-05-25T15:27:43Z")

</div>

I just noticed that the bookmark button didn’t work for me on firefox, seems to work fine on chrome. When pressed there is no popup for the “Create Bookmark” settings, and after moving to a new post there is an error pop…

---

## [Change variable outside of local scope](https://discourse.julialang.org/t/change-variable-outside-of-local-scope/81645)

<div class="topic-metadata">

**Author:** [@IljaK91](https://discourse.julialang.org/u/IljaK91)\
**Replies:** 4\
**Last updated:** [May 25, 2022, 3:15pm UTC](https://discourse.julialang.org/t/change-variable-outside-of-local-scope/81645 "2022-05-25T15:15:07Z")

</div>

Hi everyone, I try to solve a model and would like to update the parameters of the model with each iteration. For instance, I have a function like this: function solve\_GE(par::Pars) res = zeros(2) f!(x) = resi…

---

## [?swap: Swap values of two arrays. As fast as you can, dear](https://discourse.julialang.org/t/swap-swap-values-of-two-arrays-as-fast-as-you-can-dear/81661)

<div class="topic-metadata">

**Author:** [@PetrKryslUCSD](https://discourse.julialang.org/u/PetrKryslUCSD)\
**Replies:** 1\
**Last updated:** [May 25, 2022, 2:53pm UTC](https://discourse.julialang.org/t/swap-swap-values-of-two-arrays-as-fast-as-you-can-dear/81661 "2022-05-25T14:53:00Z")

</div>

LAPACK has a function called ?swap to swap the values stored in two arrays subroutine dswap (n,dx,incx,dy,incy) # # interchanges two vectors. # uses unrolled loops for increments equal one. # jack don…

---

## [Help with sciml\_train](https://discourse.julialang.org/t/help-with-sciml-train/81657)

<div class="topic-metadata">

**Author:** [@Marius\_123](https://discourse.julialang.org/u/Marius_123)\
**Replies:** 0\
**Last updated:** [May 25, 2022, 2:03pm UTC](https://discourse.julialang.org/t/help-with-sciml-train/81657 "2022-05-25T14:03:17Z")

</div>

Hello, i am trying to fit parameters of an ODE system to data. In this case, not all of the componenets have the same time points where measurements are taken. If i set up the loss function and plug it into sciml\_train, …

---

## [AlgebraOfGraphics: How to add text to a plot?](https://discourse.julialang.org/t/algebraofgraphics-how-to-add-text-to-a-plot/81646)

<div class="topic-metadata">

**Author:** [@e3c6](https://discourse.julialang.org/u/e3c6)\
**Replies:** 1\
**Last updated:** [May 25, 2022, 1:31pm UTC](https://discourse.julialang.org/t/algebraofgraphics-how-to-add-text-to-a-plot/81646 "2022-05-25T13:31:16Z")

</div>

How can I add text at some position in AlgebraOfGraphics?

---

## [What are the benefits of using IOBuffer()?](https://discourse.julialang.org/t/what-are-the-benefits-of-using-iobuffer/28693)

<div class="topic-metadata">

**Author:** [@chbian](https://discourse.julialang.org/u/chbian)\
**Replies:** 20\
**Last updated:** [May 25, 2022, 1:21pm UTC](https://discourse.julialang.org/t/what-are-the-benefits-of-using-iobuffer/28693 "2022-05-25T13:21:13Z")

</div>

Are there potential benefits of writing to an IOBuffer() rather than printing to a file IO directly? For example, I see the following implementation, function append(io::IO, data::SomeCompositeType) # append a mutable s…

---

## [CairoMakie broken rendering of axis and ticklabels](https://discourse.julialang.org/t/cairomakie-broken-rendering-of-axis-and-ticklabels/81635)

<div class="topic-metadata">

**Author:** [@mihrits](https://discourse.julialang.org/u/mihrits)\
**Replies:** 0\
**Last updated:** [May 25, 2022, 9:20am UTC](https://discourse.julialang.org/t/cairomakie-broken-rendering-of-axis-and-ticklabels/81635 "2022-05-25T09:20:58Z")

</div>

I am using CairoMakie to plot some results but found that in some circumstances some characters in axis labels and/or tick labels are rendered as boxes. For example, this code using CairoMakie fig = Figure(size=(200,200…

---

## [Precompiling ImageView generates an infinite cascade of windows](https://discourse.julialang.org/t/precompiling-imageview-generates-an-infinite-cascade-of-windows/81575)

<div class="topic-metadata">

**Author:** [@gdalle](https://discourse.julialang.org/u/gdalle)\
**Replies:** 3\
**Last updated:** [May 25, 2022, 7:04am UTC](https://discourse.julialang.org/t/precompiling-imageview-generates-an-infinite-cascade-of-windows/81575 "2022-05-25T07:04:00Z")

</div>

Hi there! I’m trying to install ImageView but precompilation doesn’t work. Instead, it spawns an infinite sequence of other (terminal?) windows and I have no choice but to interrupt the process. Has anyone encountered a…

---

## [What does RR and xx mean?](https://discourse.julialang.org/t/what-does-rr-and-xx-mean/81624)

<div class="topic-metadata">

**Author:** [@Raymond](https://discourse.julialang.org/u/Raymond)\
**Replies:** 2\
**Last updated:** [May 25, 2022, 3:31am UTC](https://discourse.julialang.org/t/what-does-rr-and-xx-mean/81624 "2022-05-25T03:31:01Z")

</div>

Dear all, I have an simple question about Finance. What does RR and xx mean in USD10YT = RR and USD10YT =xx?

---

## [Type instability with tuples of functions and parameters](https://discourse.julialang.org/t/type-instability-with-tuples-of-functions-and-parameters/81588)

<div class="topic-metadata">

**Author:** [@DanielVandH](https://discourse.julialang.org/u/DanielVandH)\
**Replies:** 13\
**Last updated:** [May 25, 2022, 6:30am UTC](https://discourse.julialang.org/t/type-instability-with-tuples-of-functions-and-parameters/81588 "2022-05-25T06:30:19Z")

</div>

My general application of interest requires a vector of functions of the form f(x, y, p), for some known parameters p. I put the functions in a Tuple so that their types are known, and define for example the following st…

---

## [InexactError on write\_to\_file](https://discourse.julialang.org/t/inexacterror-on-write-to-file/81577)

<div class="topic-metadata">

**Author:** [@berkorbay](https://discourse.julialang.org/u/berkorbay)\
**Replies:** 4\
**Last updated:** [May 25, 2022, 6:10am UTC](https://discourse.julialang.org/t/inexacterror-on-write-to-file/81577 "2022-05-25T06:10:08Z")

</div>

Hi, I encountered a problem with writing model specs to an LP file. I was replicating the Diet Problem example on JuMP’s page. https://jump.dev/JuMP.jl/stable/tutorials/linear/diet/ Everything went fine until the end. …

---

## [Yet another TCO thread](https://discourse.julialang.org/t/yet-another-tco-thread/81146)

<div class="topic-metadata">

**Author:** [@Seif\_Shebl](https://discourse.julialang.org/u/Seif_Shebl)\
**Replies:** 5\
**Last updated:** [May 25, 2022, 6:06am UTC](https://discourse.julialang.org/t/yet-another-tco-thread/81146 "2022-05-25T06:06:53Z")

</div>

Also, AFAIK, Julia doesn’t implement the tail-call optimization yet, which is crucial for the performance of recursive functions.

---

## [I have: Vector{UInt8}. I need: BitVector](https://discourse.julialang.org/t/i-have-vector-uint8-i-need-bitvector/2286)

<div class="topic-metadata">

**Author:** [@anon94023334](https://discourse.julialang.org/u/anon94023334)\
**Replies:** 6\
**Last updated:** [May 25, 2022, 4:59am UTC](https://discourse.julialang.org/t/i-have-vector-uint8-i-need-bitvector/2286 "2022-05-25T04:59:28Z")

</div>

I have julia\> z 3-element Array{UInt8,1}: 0x66 0x6f 0x6f What I’d like is the (24-element) BitVector representation of this sequence. However, my attempt to use reinterpret yielded a very confusing error: julia\> re…

---

## [How can I control what variables are in scope](https://discourse.julialang.org/t/how-can-i-control-what-variables-are-in-scope/81622)

<div class="topic-metadata">

**Author:** [@davidstreader](https://discourse.julialang.org/u/davidstreader)\
**Replies:** 3\
**Last updated:** [May 25, 2022, 3:34am UTC](https://discourse.julialang.org/t/how-can-i-control-what-variables-are-in-scope/81622 "2022-05-25T03:34:18Z")

</div>

Hi I am writing a Domain Specific Language and want to check that an Expr is formatted correctly. I have been trying to use eval(ex). But this evaluates the expression with access to variables in global scope. Is the…

---

## [Call for Julia Community Prize 2022 Nominations](https://discourse.julialang.org/t/call-for-julia-community-prize-2022-nominations/77756)

<div class="topic-metadata">

**Author:** [@logankilpatrick](https://discourse.julialang.org/u/logankilpatrick)\
**Replies:** 1\
**Last updated:** [May 24, 2022, 9:25pm UTC](https://discourse.julialang.org/t/call-for-julia-community-prize-2022-nominations/77756 "2022-05-24T21:25:38Z")

</div>

Hey folks! I wanted to make sure to do a separate post to remind everyone that the Julia Community Prize nominations are open for 2022. Prizes will be announced at JuliaCon in July. You can find the nomination details he…

---

## [Question about defining parameters in Julia?](https://discourse.julialang.org/t/question-about-defining-parameters-in-julia/81617)

<div class="topic-metadata">

**Author:** [@Raymond](https://discourse.julialang.org/u/Raymond)\
**Replies:** 1\
**Last updated:** [May 24, 2022, 10:05pm UTC](https://discourse.julialang.org/t/question-about-defining-parameters-in-julia/81617 "2022-05-24T22:05:44Z")

</div>

Dear all, Is this a good way to define parameters in Julia? using Parameters para\_def = @with\_kw ( β=0.87, δ=0.06, γ=2, α=0.35, wage=1, za=1, ϵ=3, μ=ϵ / (ϵ - 1), D=1, phil=0.00,…

---

## [Supporting offset arrays without explicit dependency](https://discourse.julialang.org/t/supporting-offset-arrays-without-explicit-dependency/81565)

<div class="topic-metadata">

**Author:** [@Alexander-Barth](https://discourse.julialang.org/u/Alexander-Barth)\
**Replies:** 13\
**Last updated:** [May 24, 2022, 9:46pm UTC](https://discourse.julialang.org/t/supporting-offset-arrays-without-explicit-dependency/81565 "2022-05-24T21:46:11Z")

</div>

In my package (NCDatasets) I am calling a C function which expect an array as input. I use two functions so that ranges, bit arrays, transposed arrays,… get converted to plain arrays. However this does not work for off…

---

## [How to rewrite a function for Julia codes?](https://discourse.julialang.org/t/how-to-rewrite-a-function-for-julia-codes/81616)

<div class="topic-metadata">

**Author:** [@Raymond](https://discourse.julialang.org/u/Raymond)\
**Replies:** 2\
**Last updated:** [May 24, 2022, 9:05pm UTC](https://discourse.julialang.org/t/how-to-rewrite-a-function-for-julia-codes/81616 "2022-05-24T21:05:29Z")

</div>

Dear all, I want to write a function for the codes. while VFIcontinue == 1 error\_vfi\_old = error\_vfi for i\_state in 1:n\_state prob\_mat = repeat(transpose(prob\[i\_state, :\]), n\_choice, 1) EXP\[:, i\_…

---

## [Question about Float64 and Int?](https://discourse.julialang.org/t/question-about-float64-and-int/81605)

<div class="topic-metadata">

**Author:** [@Raymond](https://discourse.julialang.org/u/Raymond)\
**Replies:** 12\
**Last updated:** [May 24, 2022, 8:35pm UTC](https://discourse.julialang.org/t/question-about-float64-and-int/81605 "2022-05-24T20:35:14Z")

</div>

Dear all, I have an Int array and Float64 array. And I want to merge them. julia\> a =\[1, 2, 3\]; julia\> b =\[1.0, 2.0, 3.0\]; julia\> A =hcat(a, b) 3×2 Matrix{Float64}: 1.0 1.0 2.0 2.0 3.0 3.0 Here I get a Float6…

---

## [How to get vector from set of ranges?](https://discourse.julialang.org/t/how-to-get-vector-from-set-of-ranges/81571)

<div class="topic-metadata">

**Author:** [@Minimum-Pollution-96](https://discourse.julialang.org/u/Minimum-Pollution-96)\
**Replies:** 7\
**Last updated:** [May 24, 2022, 6:55pm UTC](https://discourse.julialang.org/t/how-to-get-vector-from-set-of-ranges/81571 "2022-05-24T18:55:45Z")

</div>

I am trying to create a vector using in-line for loop. indices = \[2,5,6,8\] \[i:i+6; for i in indices\] which returns 4-element Vector{UnitRange{Int64}}: 2:8 5:11 6:12 8:14 How to create vector of values instead o…

---

## [Driftless Stochastic differential equation](https://discourse.julialang.org/t/driftless-stochastic-differential-equation/81525)

<div class="topic-metadata">

**Author:** [@stochasticguy](https://discourse.julialang.org/u/stochasticguy)\
**Replies:** 5\
**Last updated:** [May 24, 2022, 5:46pm UTC](https://discourse.julialang.org/t/driftless-stochastic-differential-equation/81525 "2022-05-24T17:46:21Z")

</div>

Hi everybody, I’m using the GREAT StochasticDiffEq.jl package to define a multidimensional driftless SDE as follows: using StochasticDiffEq function f!(du, u, p, t) du .= p\[1\] return nothing end function g!(d…

---

## [Downloading package source code without using its git repo](https://discourse.julialang.org/t/downloading-package-source-code-without-using-its-git-repo/81516)

<div class="topic-metadata">

**Author:** [@julbinb](https://discourse.julialang.org/u/julbinb)\
**Replies:** 6\
**Last updated:** [May 24, 2022, 5:42pm UTC](https://discourse.julialang.org/t/downloading-package-source-code-without-using-its-git-repo/81516 "2022-05-24T17:42:09Z")

</div>

Is there a way to download the source code of a package (given a version or its SHA) directly, without using the package repo? (I could do a git clone and checkout, but if there is a way to get just the source code dire…

---

## [Does eachline loads whole stream/file in memory?](https://discourse.julialang.org/t/does-eachline-loads-whole-stream-file-in-memory/81602)

<div class="topic-metadata">

**Author:** [@Maxim\_Lubov](https://discourse.julialang.org/u/Maxim_Lubov)\
**Replies:** 1\
**Last updated:** [May 24, 2022, 5:27pm UTC](https://discourse.julialang.org/t/does-eachline-loads-whole-stream-file-in-memory/81602 "2022-05-24T17:27:12Z")

</div>

My problem is following. I have a huge .csv file stored in S3 bucket. I don’t want to load it on disk, just read it line by line with the consecutive processing of each line. For the locally stored files I usually use CS…

---

## [\`eachindex(x)\` replacement for \`1:length(x)-1\` and similar](https://discourse.julialang.org/t/eachindex-x-replacement-for-1-length-x-1-and-similar/81481)

<div class="topic-metadata">

**Author:** [@maxkapur](https://discourse.julialang.org/u/maxkapur)\
**Replies:** 27\
**Last updated:** [May 24, 2022, 4:54pm UTC](https://discourse.julialang.org/t/eachindex-x-replacement-for-1-length-x-1-and-similar/81481 "2022-05-24T16:54:45Z")

</div>

I have been following the discussion lately about how functions that take an AbstractArray argument should avoid using the pattern 1:length(x) as an iterator because it is incompatible with interfaces like OffsetArrays.j…

---

## [Appreciation for Pluto](https://discourse.julialang.org/t/appreciation-for-pluto/81267)

<div class="topic-metadata">

**Author:** [@rikh](https://discourse.julialang.org/u/rikh)\
**Replies:** 4\
**Last updated:** [May 24, 2022, 4:32pm UTC](https://discourse.julialang.org/t/appreciation-for-pluto/81267 "2022-05-24T16:32:36Z")

</div>

In response to \[Shout-out\]: A shout-out for more shout-outs. I’ve said it before and gonna say it again. Working in Pluto.jl notebooks on a data analyses is insane. Productivity over 1000.

---

## [Parallel sparse solve and inverse](https://discourse.julialang.org/t/parallel-sparse-solve-and-inverse/81538)

<div class="topic-metadata">

**Author:** [@sobhan](https://discourse.julialang.org/u/sobhan)\
**Replies:** 0\
**Last updated:** [May 23, 2022, 8:32pm UTC](https://discourse.julialang.org/t/parallel-sparse-solve-and-inverse/81538 "2022-05-23T20:32:42Z")

</div>

So i need to solve a really big (and sparse) system of equation and to my knowledge there are no parallel sparse solvers for julia. I tried the pardiso for MKL but that wasn’t parallel and had performance similar to the …

[Previous page](https://discourse.julialang.org/latest.md?page=1029)

[Next page](https://discourse.julialang.org/latest.md?page=1031)
