# Latest

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

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

**Page:** 974

---

## [Creating multiple functions (in a different or global scope) using a one macro](https://discourse.julialang.org/t/creating-multiple-functions-in-a-different-or-global-scope-using-a-one-macro/84614)

<div class="topic-metadata">

**Author:** [@mongi](https://discourse.julialang.org/u/mongi)\
**Replies:** 6\
**Last updated:** [July 22, 2022, 11:21am UTC](https://discourse.julialang.org/t/creating-multiple-functions-in-a-different-or-global-scope-using-a-one-macro/84614 "2022-07-22T11:21:20Z")

</div>

Hi, I am having a problem creating multiple functions/methods using a one macro since this latter outputs either one function (via combinedef for example) or an array of expressions that could be used later to create th…

---

## [Can you avoid using Base.invokelatest in this example?](https://discourse.julialang.org/t/can-you-avoid-using-base-invokelatest-in-this-example/33269)

<div class="topic-metadata">

**Author:** [@rvignolo](https://discourse.julialang.org/u/rvignolo)\
**Replies:** 20\
**Last updated:** [January 13, 2020, 3:49pm UTC](https://discourse.julialang.org/t/can-you-avoid-using-base-invokelatest-in-this-example/33269 "2020-01-13T15:49:44Z")

</div>

Hi all! Is there any way to avoid using Base.invokelatest or GeneralizedGenerated.mk\_function in an example of the following type. This is a minimal working example: function main(vars, val) f\_ex = build\_function\_ex…

---

## [Error using Peaks function to get maximum of ODE solution](https://discourse.julialang.org/t/error-using-peaks-function-to-get-maximum-of-ode-solution/84631)

<div class="topic-metadata">

**Author:** [@ak47](https://discourse.julialang.org/u/ak47)\
**Replies:** 2\
**Last updated:** [July 23, 2022, 7:31am UTC](https://discourse.julialang.org/t/error-using-peaks-function-to-get-maximum-of-ode-solution/84631 "2022-07-23T07:31:42Z")

</div>

I am trying to get the maximum of a plot from ODE solve using Peaks function. I need help cause i get error. Here is my code. Thanks. using DifferentialEquations using Plots ; gr() function f(du,u,p,t) du\[1\] = dx = …

---

## [Nested groupby](https://discourse.julialang.org/t/nested-groupby/78958)

<div class="topic-metadata">

**Author:** [@rocco\_sprmnt21](https://discourse.julialang.org/u/rocco_sprmnt21)\
**Replies:** 9\
**Last updated:** [July 23, 2022, 5:17am UTC](https://discourse.julialang.org/t/nested-groupby/78958 "2022-07-23T05:17:36Z")

</div>

trying to understand the role of kwarg isgathered, I practiced this exercise. julia\> ds = Dataset(id = \[1,1,1,1,1,2,2,2,3,3,3\], date = Date.(\["2019-03-05", "2019-03-12", "2019-04-10", …

---

## [Leftjoin with replacement](https://discourse.julialang.org/t/leftjoin-with-replacement/83457)

<div class="topic-metadata">

**Author:** [@alfaromartino](https://discourse.julialang.org/u/alfaromartino)\
**Replies:** 3\
**Last updated:** [July 23, 2022, 5:15am UTC](https://discourse.julialang.org/t/leftjoin-with-replacement/83457 "2022-07-23T05:15:46Z")

</div>

I thought of an option that seems a natural extension of leftjoin. Suppose that you have two dataframes, where one is a strict subset of the other. df1 = DataFrame(ID=\[1, 2, 3\], Name=\["John Doe", "Jane Doe", "Joe Blogs"…

---

## [How to filter InMemoryDatasets](https://discourse.julialang.org/t/how-to-filter-inmemorydatasets/83478)

<div class="topic-metadata">

**Author:** [@ufechner7](https://discourse.julialang.org/u/ufechner7)\
**Replies:** 7\
**Last updated:** [July 23, 2022, 5:14am UTC](https://discourse.julialang.org/t/how-to-filter-inmemorydatasets/83478 "2022-07-23T05:14:31Z")

</div>

Example: using InMemoryDatasets ds = Dataset(x1 = 1, x2 = 1:10, x3 = repeat(1:2, 5)) res = modify!(ds, :x2 =\> byrow(isodd) =\> :ODD) The output is; julia\> include("test/filter.jl") 10×4 Dataset Row │ x1 x2 …

---

## [NLopt return flag: is there a simple way to check for success?](https://discourse.julialang.org/t/nlopt-return-flag-is-there-a-simple-way-to-check-for-success/84637)

<div class="topic-metadata">

**Author:** [@mcreel](https://discourse.julialang.org/u/mcreel)\
**Replies:** 2\
**Last updated:** [July 23, 2022, 4:35am UTC](https://discourse.julialang.org/t/nlopt-return-flag-is-there-a-simple-way-to-check-for-success/84637 "2022-07-23T04:35:50Z")

</div>

NLopt.optimize returns a tuple (objvalue, xopt, flag), and flag is a symbol that can hold strings such as FTOL\_REACHED or SUCCESS. The C API mentions that positive return values indicate success. Is there a similar way t…

---

## [LinearAlgebra./ breaks CuArray](https://discourse.julialang.org/t/linearalgebra-breaks-cuarray/84570)

<div class="topic-metadata">

**Author:** [@Lian\_Yunlong](https://discourse.julialang.org/u/Lian_Yunlong)\
**Replies:** 4\
**Last updated:** [July 23, 2022, 4:15am UTC](https://discourse.julialang.org/t/linearalgebra-breaks-cuarray/84570 "2022-07-23T04:15:29Z")

</div>

Hi, I have made a minimal reproducible example on the errors reported in my previous posts. It seems to me that the A / b operation breaks sonething in the CuArray, which is obscure to the user. Mysterious as it is, t…

---

## [What is the best way to update matrix in callable function?](https://discourse.julialang.org/t/what-is-the-best-way-to-update-matrix-in-callable-function/84641)

<div class="topic-metadata">

**Author:** [@Amro](https://discourse.julialang.org/u/Amro)\
**Replies:** 9\
**Last updated:** [July 23, 2022, 2:29am UTC](https://discourse.julialang.org/t/what-is-the-best-way-to-update-matrix-in-callable-function/84641 "2022-07-23T02:29:16Z")

</div>

I have a file called “run.jl” which has a function “update”. I have a main function which create matrix “Record”, which needs to be updated in a for loop. However, the matrix is not updated. What is the best way to updat…

---

## [Zygote Type error when using Rodas5() solver but only when manually setting sensealg](https://discourse.julialang.org/t/zygote-type-error-when-using-rodas5-solver-but-only-when-manually-setting-sensealg/84434)

<div class="topic-metadata">

**Author:** [@infiniteFun](https://discourse.julialang.org/u/infiniteFun)\
**Replies:** 3\
**Last updated:** [July 23, 2022, 1:48am UTC](https://discourse.julialang.org/t/zygote-type-error-when-using-rodas5-solver-but-only-when-manually-setting-sensealg/84434 "2022-07-23T01:48:15Z")

</div>

I’m dealing with an error here that I’m unable to understand. It would be great if someone more experienced could help me understand what’s going on here. It happens when I try to do pullback on a loss function with: …

---

## [OpenBLAS much slower on Windows than Linux](https://discourse.julialang.org/t/openblas-much-slower-on-windows-than-linux/84562)

<div class="topic-metadata">

**Author:** [@PeterSimon](https://discourse.julialang.org/u/PeterSimon)\
**Replies:** 4\
**Last updated:** [July 23, 2022, 1:09am UTC](https://discourse.julialang.org/t/openblas-much-slower-on-windows-than-linux/84562 "2022-07-23T01:09:21Z")

</div>

This is a continuation of a discussion in issues 159 and 166 of LinearSolve.jl. I have two computers with similar, 8-core i7-9700 CPUs, one of which runs Windows and the other Manjaro Linux. I ran the benchmark script …

---

## [Fitting parameters of the model against data](https://discourse.julialang.org/t/fitting-parameters-of-the-model-against-data/84530)

<div class="topic-metadata">

**Author:** [@Curio\_math](https://discourse.julialang.org/u/Curio_math)\
**Replies:** 3\
**Last updated:** [July 22, 2022, 2:30pm UTC](https://discourse.julialang.org/t/fitting-parameters-of-the-model-against-data/84530 "2022-07-22T14:30:04Z")

</div>

Hi, I have to fit parameters of my model against the data I have. My model equation is of the form, z = ax / (by - c) where a, b, c are the parameters and x, y, z forms variables. Is that possible to fit the optimal …

---

## [Can I save the code I typed in the REPL?](https://discourse.julialang.org/t/can-i-save-the-code-i-typed-in-the-repl/84654)

<div class="topic-metadata">

**Author:** [@eduardo-zambrano](https://discourse.julialang.org/u/eduardo-zambrano)\
**Replies:** 2\
**Last updated:** [July 22, 2022, 10:36pm UTC](https://discourse.julialang.org/t/can-i-save-the-code-i-typed-in-the-repl/84654 "2022-07-22T22:36:13Z")

</div>

Hi everyone, I’m very new to Julia. This is my first question here in Discourse. Before asking I looked it up using the search function and could not see an answer for it. Say I have written a few lines of code in the…

---

## [How to write a recursive macro?](https://discourse.julialang.org/t/how-to-write-a-recursive-macro/84652)

<div class="topic-metadata">

**Author:** [@greatpet](https://discourse.julialang.org/u/greatpet)\
**Replies:** 5\
**Last updated:** [July 22, 2022, 9:42pm UTC](https://discourse.julialang.org/t/how-to-write-a-recursive-macro/84652 "2022-07-22T21:42:39Z")

</div>

I came across some online posts about implementing short-circuiting logical operators as macros in Lisp, and I’m wondering how to do the same in Julia. I’m trying to write a vararg macro @or such that @or expr1 expr2 ex…

---

## [Yticks on Makie plots get on top of the legend box](https://discourse.julialang.org/t/yticks-on-makie-plots-get-on-top-of-the-legend-box/84633)

<div class="topic-metadata">

**Author:** [@RayleighLord](https://discourse.julialang.org/u/RayleighLord)\
**Replies:** 5\
**Last updated:** [July 22, 2022, 7:42pm UTC](https://discourse.julialang.org/t/yticks-on-makie-plots-get-on-top-of-the-legend-box/84633 "2022-07-22T19:42:54Z")

</div>

Hello, Using a customized set of attributes for my plots, I found that the yticks can appear on top of a legend box. For me, this behaviour is highly undesirable but I have not found a way to make the legend box appear …

---

## [Multivariate Maximum Likelihood](https://discourse.julialang.org/t/multivariate-maximum-likelihood/84618)

<div class="topic-metadata">

**Author:** [@Cristian\_Montes](https://discourse.julialang.org/u/Cristian_Montes)\
**Replies:** 4\
**Last updated:** [July 22, 2022, 4:34pm UTC](https://discourse.julialang.org/t/multivariate-maximum-likelihood/84618 "2022-07-22T16:34:57Z")

</div>

I am writing a simple program to determine maximum likelihood parameters for a non-linear function. For that I am using a multivariate normal, as the function needs to calibrate two functions with correlated errors. I …

---

## [How can I reduce memory consumption when using Zygote and Integrals together](https://discourse.julialang.org/t/how-can-i-reduce-memory-consumption-when-using-zygote-and-integrals-together/84638)

<div class="topic-metadata">

**Author:** [@F-YF](https://discourse.julialang.org/u/F-YF)\
**Replies:** 0\
**Last updated:** [July 22, 2022, 3:43pm UTC](https://discourse.julialang.org/t/how-can-i-reduce-memory-consumption-when-using-zygote-and-integrals-together/84638 "2022-07-22T15:43:25Z")

</div>

Let’s start with a simple example: julia\> using Integrals julia\> using SciMLSensitivity julia\> using BenchmarkTools julia\> using Zygote julia\> f(x,h)=sin(x)\*exp(h\*cos(x)) f (generic function with 1 method) julia\> …

---

## [\[ANN\] JuliaCon 2022 NYC Meetup](https://discourse.julialang.org/t/ann-juliacon-2022-nyc-meetup/84246)

<div class="topic-metadata">

**Author:** [@JeffreySarnoff](https://discourse.julialang.org/u/JeffreySarnoff)\
**Replies:** 1\
**Last updated:** [July 22, 2022, 3:35pm UTC](https://discourse.julialang.org/t/ann-juliacon-2022-nyc-meetup/84246 "2022-07-22T15:35:07Z")

</div>

There is a meetup in NYC (Manhattan) on Thursday evening, 28 July 2022. If you want to attend, register for the event on the group meetup, here. You need to join the meetup group first. ~15 places remain as of this po…

---

## [Graph computing benchmarks: comparing the scalability of Dask, Dagger.jl, Tensorflow and Julius](https://discourse.julialang.org/t/graph-computing-benchmarks-comparing-the-scalability-of-dask-dagger-jl-tensorflow-and-julius/80745)

<div class="topic-metadata">

**Author:** [@Yadong\_Li](https://discourse.julialang.org/u/Yadong_Li)\
**Replies:** 6\
**Last updated:** [July 22, 2022, 3:29pm UTC](https://discourse.julialang.org/t/graph-computing-benchmarks-comparing-the-scalability-of-dask-dagger-jl-tensorflow-and-julius/80745 "2022-07-22T15:29:55Z")

</div>

Graph computing solutions like Dask/Dagger.jl are gaining popularity among developers, mainly because of their easy built-in distribution capabilities. If you are considering one of these graph computing solutions for yo…

---

## [Custom keybindings doesn't work in VS Code REPL](https://discourse.julialang.org/t/custom-keybindings-doesnt-work-in-vs-code-repl/84636)

<div class="topic-metadata">

**Author:** [@wsshin](https://discourse.julialang.org/u/wsshin)\
**Replies:** 1\
**Last updated:** [July 22, 2022, 3:18pm UTC](https://discourse.julialang.org/t/custom-keybindings-doesnt-work-in-vs-code-repl/84636 "2022-07-22T15:18:53Z")

</div>

I use Greek characters very frequently in my code. So, for example, instead of entering λ by \\lambda followed by the tab key, I press Control-Option-L. (I’m a Mac user, and Mac’s Option key would correspond to Window’s…

---

## [Distance matrix](https://discourse.julialang.org/t/distance-matrix/84619)

<div class="topic-metadata">

**Author:** [@JosieG](https://discourse.julialang.org/u/JosieG)\
**Replies:** 5\
**Last updated:** [July 22, 2022, 2:44pm UTC](https://discourse.julialang.org/t/distance-matrix/84619 "2022-07-22T14:44:42Z")

</div>

I’m given a 20\*122 matrix p. Each row of matrix is a 20-element vector. I want to calculate the distance between each vector and form a distance matrix. Here’s my code mul = \[\] for i in 1:size(p,1) push!(mul,norm…

---

## [Complex filtering of DataFrame](https://discourse.julialang.org/t/complex-filtering-of-dataframe/78650)

<div class="topic-metadata">

**Author:** [@amrods](https://discourse.julialang.org/u/amrods)\
**Replies:** 9\
**Last updated:** [July 22, 2022, 1:48pm UTC](https://discourse.julialang.org/t/complex-filtering-of-dataframe/78650 "2022-07-22T13:48:37Z")

</div>

I have this data frame that I want to filter: using DataFrames using StatsBase df = DataFrame(id = repeat(sample(1:1000, 100; replace=false), inner=2), s = repeat(1:2, inner=1, outer=100)) insertcols!(df, :t =\> rand(2:…

---

## [Juliacon live, youtube restricted mode](https://discourse.julialang.org/t/juliacon-live-youtube-restricted-mode/84542)

<div class="topic-metadata">

**Author:** [@raminammour](https://discourse.julialang.org/u/raminammour)\
**Replies:** 1\
**Last updated:** [July 22, 2022, 1:15pm UTC](https://discourse.julialang.org/t/juliacon-live-youtube-restricted-mode/84542 "2022-07-22T13:15:49Z")

</div>

Hello all, The juliacon live videos won’t play for me (the offline ones do), the banner claims that they won’t play in restricted mode on youtube. I cannot turn off restricted mode on youtube (I tried, but I am at work,…

---

## [Reduce compilation time in Testing](https://discourse.julialang.org/t/reduce-compilation-time-in-testing/84387)

<div class="topic-metadata">

**Author:** [@kellertuer](https://discourse.julialang.org/u/kellertuer)\
**Replies:** 6\
**Last updated:** [July 22, 2022, 11:45am UTC](https://discourse.julialang.org/t/reduce-compilation-time-in-testing/84387 "2022-07-22T11:45:05Z")

</div>

In the package I am (co-)developing, we write a lot of tests. Now we are running into the problem, that the tests run quite long (currently for example a little more than an hour). In our output like So most of these…

---

## [What is the cleanest way to broadcast a multi-variate function over all input vectors](https://discourse.julialang.org/t/what-is-the-cleanest-way-to-broadcast-a-multi-variate-function-over-all-input-vectors/84599)

<div class="topic-metadata">

**Author:** [@jinml](https://discourse.julialang.org/u/jinml)\
**Replies:** 7\
**Last updated:** [July 22, 2022, 10:26am UTC](https://discourse.julialang.org/t/what-is-the-cleanest-way-to-broadcast-a-multi-variate-function-over-all-input-vectors/84599 "2022-07-22T10:26:25Z")

</div>

For example, I have a function f(x,y,z) and three vectors x, y, z. I’d like to compute all combinations and return a 3D array of values. What I can do is this: f.(x,y',reshape(z,1,1,:)). Is there a less cumbersome way, e…

---

## [SDEProblem with mutliple independent Wiener Processes](https://discourse.julialang.org/t/sdeproblem-with-mutliple-independent-wiener-processes/84610)

<div class="topic-metadata">

**Author:** [@olliethurston](https://discourse.julialang.org/u/olliethurston)\
**Replies:** 4\
**Last updated:** [July 22, 2022, 9:48am UTC](https://discourse.julialang.org/t/sdeproblem-with-mutliple-independent-wiener-processes/84610 "2022-07-22T09:48:02Z")

</div>

I am trying to solve a 4D chemical Langevin SDE problem with multiplicative noise in the form of independent wiener processes (WPs). Since my system is built upon 4 states and 8 reactions, my drift function F returns a (…

---

## [Making Sure the Graphs I Plot is Correct](https://discourse.julialang.org/t/making-sure-the-graphs-i-plot-is-correct/84626)

<div class="topic-metadata">

**Author:** [@Freya\_the\_Goddess](https://discourse.julialang.org/u/Freya_the_Goddess)\
**Replies:** 2\
**Last updated:** [July 22, 2022, 9:37am UTC](https://discourse.julialang.org/t/making-sure-the-graphs-i-plot-is-correct/84626 "2022-07-22T09:37:56Z")

</div>

Hi all, I just want to make sure that the graphs plot I made are correct. It is a limit problems in Calculus. I am just doubting if the graphs of mine are correct. I want t know whether we can automatically plot the: …

---

## [DataFrames invert index](https://discourse.julialang.org/t/dataframes-invert-index/84603)

<div class="topic-metadata">

**Author:** [@laut](https://discourse.julialang.org/u/laut)\
**Replies:** 6\
**Last updated:** [July 22, 2022, 9:37am UTC](https://discourse.julialang.org/t/dataframes-invert-index/84603 "2022-07-22T09:37:00Z")

</div>

@bkamins How do I get the inverted row index in DataFrames? # make data frame df = DataFrame(x=1:10, y=11:20) # subset df (train set) df2 = df\[\[1,3,9\],:\] # invert subset (test set) df3 = df\[Not(df2,:\]),:\] # error df3…

---

## [Hiding "Live Docs" bar in Pluto](https://discourse.julialang.org/t/hiding-live-docs-bar-in-pluto/84621)

<div class="topic-metadata">

**Author:** [@patrick](https://discourse.julialang.org/u/patrick)\
**Replies:** 3\
**Last updated:** [July 22, 2022, 7:14am UTC](https://discourse.julialang.org/t/hiding-live-docs-bar-in-pluto/84621 "2022-07-22T07:14:14Z")

</div>

Is there a simple way to permanently hide the “live docs” bar that appears at the bottom of Pluto notebooks?

---

## [Sorting in vscode workspace view](https://discourse.julialang.org/t/sorting-in-vscode-workspace-view/84624)

<div class="topic-metadata">

**Author:** [@Oto\_Brzobohaty](https://discourse.julialang.org/u/Oto_Brzobohaty)\
**Replies:** 0\
**Last updated:** [July 22, 2022, 6:30am UTC](https://discourse.julialang.org/t/sorting-in-vscode-workspace-view/84624 "2022-07-22T06:30:09Z")

</div>

Dear All, is there any way how to sort the workspace in julia view (in vscode julia extension)? Normally there is mix of variables, modules, etc. I would like to have variables and modules in separated subsections.

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

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