# Latest

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

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

**Page:** 1230

---

## [Animation using frames in Dash for Julia](https://discourse.julialang.org/t/animation-using-frames-in-dash-for-julia/70254)

<div class="topic-metadata">

**Author:** [@valeroc](https://discourse.julialang.org/u/valeroc)\
**Replies:** 2\
**Last updated:** [October 23, 2021, 12:32pm UTC](https://discourse.julialang.org/t/animation-using-frames-in-dash-for-julia/70254 "2021-10-23T12:32:23Z")

</div>

Hi, I have been trying to do animation in Dash for Julia using frames (see the Simple Play Button Demo at Intro to animations in Python) . I managed to make that demo work for Dash in Python but after translating it to …

---

## [Broadcasting for a new type & passing a value by ref](https://discourse.julialang.org/t/broadcasting-for-a-new-type-passing-a-value-by-ref/70255)

<div class="topic-metadata">

**Author:** [@dodoplus](https://discourse.julialang.org/u/dodoplus)\
**Replies:** 3\
**Last updated:** [October 23, 2021, 11:39am UTC](https://discourse.julialang.org/t/broadcasting-for-a-new-type-passing-a-value-by-ref/70255 "2021-10-23T11:39:52Z")

</div>

Hi, I have a struct as follows: struct P df::DataFrame end where the DataFrame contains labels (qs) & prior probabilities (probs). I’ve implemented multiplication & normalization: Base.:(\*)(p::P, v) = P(DataFrame…

---

## [Insert Array into another](https://discourse.julialang.org/t/insert-array-into-another/65836)

<div class="topic-metadata">

**Author:** [@victormororo](https://discourse.julialang.org/u/victormororo)\
**Replies:** 3\
**Last updated:** [October 23, 2021, 11:30am UTC](https://discourse.julialang.org/t/insert-array-into-another/65836 "2021-10-23T11:30:30Z")

</div>

is there already something like this? function insert!(a::Array{T,1}, i::Integer, item::Array{T,1}) \_growat!(a, i, length(item)) bd = i + length(item) - 1 @inbounds for \_i in i:bd a\[\_i\] = item\[\_i-i+1\] end …

---

## [Variable interpolation in string within expression](https://discourse.julialang.org/t/variable-interpolation-in-string-within-expression/70258)

<div class="topic-metadata">

**Author:** [@disberd](https://discourse.julialang.org/u/disberd)\
**Replies:** 2\
**Last updated:** [October 23, 2021, 9:58am UTC](https://discourse.julialang.org/t/variable-interpolation-in-string-within-expression/70258 "2021-10-23T09:58:38Z")

</div>

Hi there, I am experimenting a bit with macros and wanted to know wheter there is a way to interpolate a variable (that is local to the macro) value inside a string within an expression returned by the macro. a MWE is …

---

## [Taking rolling functions seriously](https://discourse.julialang.org/t/taking-rolling-functions-seriously/70257)

<div class="topic-metadata">

**Author:** [@JeffreySarnoff](https://discourse.julialang.org/u/JeffreySarnoff)\
**Replies:** 0\
**Last updated:** [October 23, 2021, 8:40am UTC](https://discourse.julialang.org/t/taking-rolling-functions-seriously/70257 "2021-10-23T08:40:23Z")

</div>

Generally speaking, a to roll a function over windowed data is to apply that function to consecutive data subspans, where the length (for vector data) of each subspan is given by the window size. The language has advanc…

---

## [When will a vector of structs be contiguous in memory?](https://discourse.julialang.org/t/when-will-a-vector-of-structs-be-contiguous-in-memory/70181)

<div class="topic-metadata">

**Author:** [@Lilith](https://discourse.julialang.org/u/Lilith)\
**Replies:** 8\
**Last updated:** [October 23, 2021, 4:29am UTC](https://discourse.julialang.org/t/when-will-a-vector-of-structs-be-contiguous-in-memory/70181 "2021-10-23T04:29:38Z")

</div>

Checking if a vector of structs is contiguous in memory gives some tips for how to check, but would like to know the general pattern. My specific use case is a sort of nested dictionary. I have an iterator of key-value …

---

## [Reading a vector string file](https://discourse.julialang.org/t/reading-a-vector-string-file/70247)

<div class="topic-metadata">

**Author:** [@Peter-Jolly](https://discourse.julialang.org/u/Peter-Jolly)\
**Replies:** 4\
**Last updated:** [October 23, 2021, 4:26am UTC](https://discourse.julialang.org/t/reading-a-vector-string-file/70247 "2021-10-23T04:26:27Z")

</div>

Hi I am trying to do a very simple operation dealing with strings (normally I work with numerical data so not too familiar with strings). I want to read in a list of names from a file called Name\_List.txt (each name on o…

---

## [The usage of callback](https://discourse.julialang.org/t/the-usage-of-callback/70219)

<div class="topic-metadata">

**Author:** [@BYS](https://discourse.julialang.org/u/BYS)\
**Replies:** 6\
**Last updated:** [October 23, 2021, 4:07am UTC](https://discourse.julialang.org/t/the-usage-of-callback/70219 "2021-10-23T04:07:26Z")

</div>

Hi all, I have seen an example of callback usage \>https://jump.dev/JuMP.jl/stable/tutorials/Optimization%20concepts/benders\_lazy\_constraints/ there is a line x\_current = callback\_value.(Ref(cb\_data), x), I wonder if it …

---

## [Precompilation, \_\_init\_\_, and eval](https://discourse.julialang.org/t/precompilation-init-and-eval/70188)

<div class="topic-metadata">

**Author:** [@Kurt\_Franke](https://discourse.julialang.org/u/Kurt_Franke)\
**Replies:** 3\
**Last updated:** [October 23, 2021, 3:38am UTC](https://discourse.julialang.org/t/precompilation-init-and-eval/70188 "2021-10-23T03:38:19Z")

</div>

I have some formulas that are loaded from text configuration files. These are used in other places besides my Julia program so I don’t have any control over the format. They are in the form of an expression using the sin…

---

## [How to test functions that operate on abstract types](https://discourse.julialang.org/t/how-to-test-functions-that-operate-on-abstract-types/70246)

<div class="topic-metadata">

**Author:** [@Lilith](https://discourse.julialang.org/u/Lilith)\
**Replies:** 16\
**Last updated:** [October 23, 2021, 1:51am UTC](https://discourse.julialang.org/t/how-to-test-functions-that-operate-on-abstract-types/70246 "2021-10-23T01:51:11Z")

</div>

I have a function f(x::Vector). It’s tested on Vectors and seems to do okay. I looked at the code and think it should also work for all AbstractVectors, but I don’t know how to test this. In general, are there any princi…

---

## [\[Makie\] Rotate bar plot labels](https://discourse.julialang.org/t/makie-rotate-bar-plot-labels/68679)

<div class="topic-metadata">

**Author:** [@TheLateKronos](https://discourse.julialang.org/u/TheLateKronos)\
**Replies:** 3\
**Last updated:** [October 22, 2021, 8:42am UTC](https://discourse.julialang.org/t/makie-rotate-bar-plot-labels/68679 "2021-10-22T08:42:20Z")

</div>

I have a bar-plot: But the labels are hard to read in this orientation. A workaround is to make the plot with direction = :x: But is there a way to simply rotate the labels in the first plot? Code used to create…

---

## [Basic datastructures benchmark](https://discourse.julialang.org/t/basic-datastructures-benchmark/69753)

<div class="topic-metadata">

**Author:** [@goerch](https://discourse.julialang.org/u/goerch)\
**Replies:** 1\
**Last updated:** [October 22, 2021, 9:22pm UTC](https://discourse.julialang.org/t/basic-datastructures-benchmark/69753 "2021-10-22T21:22:41Z")

</div>

With the help of all you here I finished my evaluation of allocators for basic data structures with some at least for me surprising results. Thank you very much again! Please see https://github.com/goerch/Allocators.jl.…

---

## [How to read string arrays out of a MAT file?](https://discourse.julialang.org/t/how-to-read-string-arrays-out-of-a-mat-file/70234)

<div class="topic-metadata">

**Author:** [@leon](https://discourse.julialang.org/u/leon)\
**Replies:** 0\
**Last updated:** [October 22, 2021, 6:41pm UTC](https://discourse.julialang.org/t/how-to-read-string-arrays-out-of-a-mat-file/70234 "2021-10-22T18:41:55Z")

</div>

I have two string arrays stored in a MAT file named test3.mat. They can be read out easily within Matlab, but I’m having big trouble reading them out in Julia. Below is my code: using MAT F1 = matopen("test3.mat"); a =…

---

## [Construct \`Union{T, U} where T\<:Integer where U\<:Float64\` from \`Union{TypeVar(:T, Integer), TypeVar(:U, Float64)}\`](https://discourse.julialang.org/t/construct-union-t-u-where-t-integer-where-u-float64-from-union-typevar-t-integer-typevar-u-float64/70230)

<div class="topic-metadata">

**Author:** [@kdheepak](https://discourse.julialang.org/u/kdheepak)\
**Replies:** 3\
**Last updated:** [October 22, 2021, 5:40pm UTC](https://discourse.julialang.org/t/construct-union-t-u-where-t-integer-where-u-float64-from-union-typevar-t-integer-typevar-u-float64/70230 "2021-10-22T17:40:20Z")

</div>

I’m trying to construct a type programmatically but failing to do so. The crux of my problem is that UnionAll(TypeVar(:T, Integer), Union{TypeVar(:T, Integer), TypeVar(:U, Float64)}) doesn’t return a UnionAll type, and …

---

## [Automatic Differentiation (AD) in Python compared to Julia and AD Basics](https://discourse.julialang.org/t/automatic-differentiation-ad-in-python-compared-to-julia-and-ad-basics/56031)

<div class="topic-metadata">

**Author:** [@kimlaberinto](https://discourse.julialang.org/u/kimlaberinto)\
**Replies:** 6\
**Last updated:** [October 22, 2021, 5:36pm UTC](https://discourse.julialang.org/t/automatic-differentiation-ad-in-python-compared-to-julia-and-ad-basics/56031 "2021-10-22T17:36:26Z")

</div>

Hello everyone! The quotes below is a reconstruction of a wonderful conversation I had with Lyndon White (@oxinabox) on the Julia Slack on February 24, 2021 (Thank you to Lyndon as well to let me quote and repost this on…

---

## [DifferentialEquations: Callback which is only triggered the first time condition is satisfied](https://discourse.julialang.org/t/differentialequations-callback-which-is-only-triggered-the-first-time-condition-is-satisfied/70216)

<div class="topic-metadata">

**Author:** [@pbryde](https://discourse.julialang.org/u/pbryde)\
**Replies:** 5\
**Last updated:** [October 22, 2021, 5:31pm UTC](https://discourse.julialang.org/t/differentialequations-callback-which-is-only-triggered-the-first-time-condition-is-satisfied/70216 "2021-10-22T17:31:04Z")

</div>

Is there an elegant way to define a ContinuousCallback which calls affect! only the first time that condition is satisfied (after which it does nothing)? For example, how could one modify the Bouncing Ball example (Event…

---

## [Questions about modeling Fokker-Planck equation](https://discourse.julialang.org/t/questions-about-modeling-fokker-planck-equation/70118)

<div class="topic-metadata">

**Author:** [@jlmaccal](https://discourse.julialang.org/u/jlmaccal)\
**Replies:** 2\
**Last updated:** [October 22, 2021, 5:30pm UTC](https://discourse.julialang.org/t/questions-about-modeling-fokker-planck-equation/70118 "2021-10-22T17:30:16Z")

</div>

I’m interested in solving a certain Fokker-Planck equation. The goal is to learn an underlying potential energy function given a time series of the evolution of a distribution. I’m planning to use the approach of this p…

---

## [Julia v1.7.0-rc2 is now available](https://discourse.julialang.org/t/julia-v1-7-0-rc2-is-now-available/70228)

<div class="topic-metadata">

**Author:** [@ararslan](https://discourse.julialang.org/u/ararslan)\
**Replies:** 0\
**Last updated:** [October 22, 2021, 4:50pm UTC](https://discourse.julialang.org/t/julia-v1-7-0-rc2-is-now-available/70228 "2021-10-22T16:50:25Z")

</div>

The Julia developers are pleased to announce that the second release candidate for Julia v1.7.0 is now available. You can download binaries at https://julialang.org/downloads in the “upcoming release” section for macOS …

---

## [Inset axis in Makie](https://discourse.julialang.org/t/inset-axis-in-makie/70209)

<div class="topic-metadata">

**Author:** [@ohmsweetohm1](https://discourse.julialang.org/u/ohmsweetohm1)\
**Replies:** 4\
**Last updated:** [October 22, 2021, 4:45pm UTC](https://discourse.julialang.org/t/inset-axis-in-makie/70209 "2021-10-22T16:45:06Z")

</div>

How to make the inset axis non-transparent? using CairoMakie f = Figure() ax1 = Axis(f\[1,1\]) scatter!(ax1, randn(1000), randn(1000)) ax2 = Axis(f\[1,1\], width=Relative(0.2), height=Relative(0.3), halign=0.1, valign=0.1, …

---

## [Question about Ref and about unique](https://discourse.julialang.org/t/question-about-ref-and-about-unique/70202)

<div class="topic-metadata">

**Author:** [@gitboy16](https://discourse.julialang.org/u/gitboy16)\
**Replies:** 8\
**Last updated:** [October 22, 2021, 4:40pm UTC](https://discourse.julialang.org/t/question-about-ref-and-about-unique/70202 "2021-10-22T16:40:31Z")

</div>

Please see the below code: x = rand(10\_000\_000); @time unique(x); # 1.6 seconds @time unique(Ref(x))\[1\]; # 0.006373 seconds unique(x) == unique(Ref(x))\[1\] # true Why would anyone use unique on it owns instead of unique…

---

## [Is it possible to pass a struct in MPI.jl?](https://discourse.julialang.org/t/is-it-possible-to-pass-a-struct-in-mpi-jl/70137)

<div class="topic-metadata">

**Author:** [@giancarloantonucci](https://discourse.julialang.org/u/giancarloantonucci)\
**Replies:** 9\
**Last updated:** [October 22, 2021, 4:23pm UTC](https://discourse.julialang.org/t/is-it-possible-to-pass-a-struct-in-mpi-jl/70137 "2021-10-22T16:23:47Z")

</div>

I have something like struct Struct a::Vector b::Vector i::Integer end mystruct = Struct(rand(10), rand(5), 1) How can I pass mystruct around with MPI.jl? If it’s not possible as it is, what’s the easiest wor…

---

## [A French prize for the development (and documentation) of open source software in the research field](https://discourse.julialang.org/t/a-french-prize-for-the-development-and-documentation-of-open-source-software-in-the-research-field/70225)

<div class="topic-metadata">

**Author:** [@sylvaticus](https://discourse.julialang.org/u/sylvaticus)\
**Replies:** 0\
**Last updated:** [October 22, 2021, 4:04pm UTC](https://discourse.julialang.org/t/a-french-prize-for-the-development-and-documentation-of-open-source-software-in-the-research-field/70225 "2021-10-22T16:04:28Z")

</div>

Deadline: 6 December 2021 A French prize for the development (and documentation) of open source software in the research field. The description and the field is in French, but nowhere (that I found) it is stated that t…

---

## [Writing data from curl request using LibCURL](https://discourse.julialang.org/t/writing-data-from-curl-request-using-libcurl/15276)

<div class="topic-metadata">

**Author:** [@Julien\_Gooris](https://discourse.julialang.org/u/Julien_Gooris)\
**Replies:** 1\
**Last updated:** [October 22, 2021, 3:55pm UTC](https://discourse.julialang.org/t/writing-data-from-curl-request-using-libcurl/15276 "2021-10-22T15:55:46Z")

</div>

Hi all, I (as Julia Newbie) am trying to execute some Curl requests using LibCURL and to fetch the response content (not only the http code) into a string variable. I’m following the instructions from GitHub - JuliaWeb/…

---

## [How can I define functions inside of functions in a performant way?](https://discourse.julialang.org/t/how-can-i-define-functions-inside-of-functions-in-a-performant-way/70213)

<div class="topic-metadata">

**Author:** [@giancarloantonucci](https://discourse.julialang.org/u/giancarloantonucci)\
**Replies:** 9\
**Last updated:** [October 22, 2021, 3:52pm UTC](https://discourse.julialang.org/t/how-can-i-define-functions-inside-of-functions-in-a-performant-way/70213 "2021-10-22T15:52:04Z")

</div>

I want to define functions f1 and f2 (to be inputted inside a struct S) from another function f, defined at global scope, using another auxiliary function fun: mutable struct S f1::Function f2::Function end fun…

---

## [Segmentation Fault Error using Julia LibCurl Wrapper](https://discourse.julialang.org/t/segmentation-fault-error-using-julia-libcurl-wrapper/31201)

<div class="topic-metadata">

**Author:** [@rkapurbh](https://discourse.julialang.org/u/rkapurbh)\
**Replies:** 1\
**Last updated:** [October 22, 2021, 3:41pm UTC](https://discourse.julialang.org/t/segmentation-fault-error-using-julia-libcurl-wrapper/31201 "2021-10-22T15:41:07Z")

</div>

Running the Following Code with Julia LibCurl.jl curl\_header\_list = Cstring\[\] for header in keys(headers) value = headers\[header\] item =Cstring(pointer("$header: $value")) push!(curl\_header…

---

## [Visualization, analytics, and database integration internship (remote)](https://discourse.julialang.org/t/visualization-analytics-and-database-integration-internship-remote/70220)

<div class="topic-metadata">

**Author:** [@tim.holy](https://discourse.julialang.org/u/tim.holy)\
**Replies:** 1\
**Last updated:** [October 22, 2021, 3:35pm UTC](https://discourse.julialang.org/t/visualization-analytics-and-database-integration-internship-remote/70220 "2021-10-22T15:35:55Z")

</div>

Project goals Washington University in St. Louis is looking for an intern to help develop new approaches to Ph.D. student recruitment. Its Division of Biology and Biomedical Sciences (DBBS) is the umbrella organization s…

---

## [Debugging a script to replace NaN or -999 values with missing values](https://discourse.julialang.org/t/debugging-a-script-to-replace-nan-or-999-values-with-missing-values/70214)

<div class="topic-metadata">

**Author:** [@leon](https://discourse.julialang.org/u/leon)\
**Replies:** 6\
**Last updated:** [October 22, 2021, 2:15pm UTC](https://discourse.julialang.org/t/debugging-a-script-to-replace-nan-or-999-values-with-missing-values/70214 "2021-10-22T14:15:17Z")

</div>

I’m trying to write a program to replace all NaN values or -999 values in my matrix B with missing values (write down nothing) before I use Dataframe to put them into CSV files). Below is my code: B = \[-0 0 1; NaN 0.2 …

---

## [Human Rights Data Analysis Group Data Scientist](https://discourse.julialang.org/t/human-rights-data-analysis-group-data-scientist/70212)

<div class="topic-metadata">

**Author:** [@Nosferican](https://discourse.julialang.org/u/Nosferican)\
**Replies:** 0\
**Last updated:** [October 22, 2021, 1:30pm UTC](https://discourse.julialang.org/t/human-rights-data-analysis-group-data-scientist/70212 "2021-10-22T13:30:46Z")

</div>

HRDAG – Human Rights Data Analysis Group | Opportunities Data Scientist position (uses Julia)

---

## [Float32 performance fluctuating over time](https://discourse.julialang.org/t/float32-performance-fluctuating-over-time/70206)

<div class="topic-metadata">

**Author:** [@Chiil](https://discourse.julialang.org/u/Chiil)\
**Replies:** 1\
**Last updated:** [October 22, 2021, 1:20pm UTC](https://discourse.julialang.org/t/float32-performance-fluctuating-over-time/70206 "2021-10-22T13:20:10Z")

</div>

I have coded a CFD code in Julia that has Float32 performance that increases as the simulation progresses, while the Float64 performance is constant in time. My suspicion is that is has to do with underflow in case of th…

---

## [Minibatches of graphs in GeometricFlux.jl](https://discourse.julialang.org/t/minibatches-of-graphs-in-geometricflux-jl/70170)

<div class="topic-metadata">

**Author:** [@bad\_at\_math](https://discourse.julialang.org/u/bad_at_math)\
**Replies:** 2\
**Last updated:** [October 22, 2021, 1:04pm UTC](https://discourse.julialang.org/t/minibatches-of-graphs-in-geometricflux-jl/70170 "2021-10-22T13:04:55Z")

</div>

In the supervised graph problem, you train a neural network that maps entire graph instances to target values. The GeometricFlux.jl package has great functionality for training graph neural networks; however, all of the …

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

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