# General Usage

**URL:** https://discourse.julialang.org/c/usage/6.md?page=380

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

**Page:** 381

---

## [Autocomplete for keys of keyword arguments; is it possible?](https://discourse.julialang.org/t/autocomplete-for-keys-of-keyword-arguments-is-it-possible/70780)

<div class="topic-metadata">

**Author:** [@xinchin](https://discourse.julialang.org/u/xinchin)\
**Replies:** 5\
**Last updated:** [October 21, 2022, 1:22pm UTC](https://discourse.julialang.org/t/autocomplete-for-keys-of-keyword-arguments-is-it-possible/70780 "2022-10-21T13:22:01Z")

</div>

is there anyway to have autocomplete for keyword arguments?

---

## [Is there an equivalent of eachindex() for DataFrames?](https://discourse.julialang.org/t/is-there-an-equivalent-of-eachindex-for-dataframes/88945)

<div class="topic-metadata">

**Author:** [@phantom](https://discourse.julialang.org/u/phantom)\
**Replies:** 13\
**Last updated:** [October 21, 2022, 10:18am UTC](https://discourse.julialang.org/t/is-there-an-equivalent-of-eachindex-for-dataframes/88945 "2022-10-21T10:18:13Z")

</div>

Hi suppose I have an array and want append some string to entry I can iterate across it with eachindex() singers = \[\["Marley", "Kiiara", "Sinead"\] \["Rynn","Illenium","Nelly"\]\] for k = eachindex(singers) singers\[k\] = "$…

---

## [Stack Overflow confusion](https://discourse.julialang.org/t/stack-overflow-confusion/89054)

<div class="topic-metadata">

**Author:** [@prittjam](https://discourse.julialang.org/u/prittjam)\
**Replies:** 3\
**Last updated:** [October 21, 2022, 12:01pm UTC](https://discourse.julialang.org/t/stack-overflow-confusion/89054 "2022-10-21T12:01:28Z")

</div>

const Tmp{T \<: AbstractFloat} = SMatrix{3,4,T,12} Why does this overflow? Tmp(rand(Float32,3,4)) of course, this works, Tmp{Float32}(rand(Float32,3,4)) but I don’t understand why the first case overflows.

---

## [First call latency in distributed code](https://discourse.julialang.org/t/first-call-latency-in-distributed-code/88917)

<div class="topic-metadata">

**Author:** [@shce](https://discourse.julialang.org/u/shce)\
**Replies:** 42\
**Last updated:** [October 21, 2022, 11:52am UTC](https://discourse.julialang.org/t/first-call-latency-in-distributed-code/88917 "2022-10-21T11:52:38Z")

</div>

Hello! I am facing with an issue I haven’t encountered so far with distributed code. I have a code to optimize some function f for several initial conditions. Function f might be very complicated. To avoid high times i…

---

## [\`Plots.jl\` spline](https://discourse.julialang.org/t/plots-jl-spline/88720)

<div class="topic-metadata">

**Author:** [@this\_josh](https://discourse.julialang.org/u/this_josh)\
**Replies:** 8\
**Last updated:** [October 21, 2022, 11:30am UTC](https://discourse.julialang.org/t/plots-jl-spline/88720 "2022-10-21T11:30:26Z")

</div>

How can I plot a line with line\_style=spline in Plots.jl? For an example of what I’m after see the ‘spline’ trace in these plotly docs The closest I can find in the docs is about how to step Any suggestions should be a…

---

## [Can't get rid of legend in Plotlyjs.jl](https://discourse.julialang.org/t/cant-get-rid-of-legend-in-plotlyjs-jl/88910)

<div class="topic-metadata">

**Author:** [@1153dent](https://discourse.julialang.org/u/1153dent)\
**Replies:** 12\
**Last updated:** [October 21, 2022, 10:39am UTC](https://discourse.julialang.org/t/cant-get-rid-of-legend-in-plotlyjs-jl/88910 "2022-10-21T10:39:28Z")

</div>

Hi all I am using julia 1.8.2 PlotlyJS v0.18.10 I want to remove the legend from this plot I tried using using PlotlyJS make\_plot() = plot(scatter(x=1:10, y=rand(10)), Layout(yaxis\_visible=fa…

---

## [Function conflict with different signatures](https://discourse.julialang.org/t/function-conflict-with-different-signatures/88921)

<div class="topic-metadata">

**Author:** [@RockerM4NHUN](https://discourse.julialang.org/u/RockerM4NHUN)\
**Replies:** 5\
**Last updated:** [October 21, 2022, 8:10am UTC](https://discourse.julialang.org/t/function-conflict-with-different-signatures/88921 "2022-10-21T08:10:34Z")

</div>

Hi! I’m trying to organize a bigger project into multiple modules and I want to create function overloads specific to types found in those modules. Before all my code was in a single module and worked fine, but now my f…

---

## [Installing "uber-juno@0.3.0" failed in atom](https://discourse.julialang.org/t/installing-uber-juno-0-3-0-failed-in-atom/89047)

<div class="topic-metadata">

**Author:** [@Rocco\_Suanno](https://discourse.julialang.org/u/Rocco_Suanno)\
**Replies:** 2\
**Last updated:** [October 21, 2022, 7:28am UTC](https://discourse.julialang.org/t/installing-uber-juno-0-3-0-failed-in-atom/89047 "2022-10-21T07:28:42Z")

</div>

I can’t install the uber-juno package in atom. A discussion in this forum suggested to disable windows firewall and defender. But even after disabling them, I get this error when i try to install uber-juno in atom: npm…

---

## [Move light source and material in MakieGL](https://discourse.julialang.org/t/move-light-source-and-material-in-makiegl/89044)

<div class="topic-metadata">

**Author:** [@Veenty](https://discourse.julialang.org/u/Veenty)\
**Replies:** 1\
**Last updated:** [October 21, 2022, 6:42am UTC](https://discourse.julialang.org/t/move-light-source-and-material-in-makiegl/89044 "2022-10-21T06:42:13Z")

</div>

Hey I’m trying to move the light source in MakieGL for a 3D plot. I can’t find it for the current version. Note that here LScene they do it, but that code doesn’t work anymore in the current version. I have not being a…

---

## [Custom transport for Distributed.jl to utilize Infiniband and avoid MPI?](https://discourse.julialang.org/t/custom-transport-for-distributed-jl-to-utilize-infiniband-and-avoid-mpi/74097)

<div class="topic-metadata">

**Author:** [@fgerick](https://discourse.julialang.org/u/fgerick)\
**Replies:** 4\
**Last updated:** [October 20, 2022, 3:29pm UTC](https://discourse.julialang.org/t/custom-transport-for-distributed-jl-to-utilize-infiniband-and-avoid-mpi/74097 "2022-10-20T15:29:49Z")

</div>

Hi, I was wondering if there’s any prospect of Distributed.jl and/or Dagger.jl to support interconnects such as Infiniband on HPC clusters? There’s a nice summary of the downsides of MPI.jl and Distributed.jl in this p…

---

## [Grid of all elements of an arbitrarily sized matrix](https://discourse.julialang.org/t/grid-of-all-elements-of-an-arbitrarily-sized-matrix/89024)

<div class="topic-metadata">

**Author:** [@CeterisPartybus](https://discourse.julialang.org/u/CeterisPartybus)\
**Replies:** 7\
**Last updated:** [October 20, 2022, 5:35pm UTC](https://discourse.julialang.org/t/grid-of-all-elements-of-an-arbitrarily-sized-matrix/89024 "2022-10-20T17:35:17Z")

</div>

I have an n\*m sized array A, and I would like to create a grid of its elements. The output should look something like: B = (A\[1,1\], A\[2,1\] A\[1,1\], A\[2,2\] ... A\[1,1\], A\[2,m\] A\[1,2\], A\[2,1\] A\[1,2\]…

---

## [ReverseDiff friendly code and domain errors](https://discourse.julialang.org/t/reversediff-friendly-code-and-domain-errors/89007)

<div class="topic-metadata">

**Author:** [@Luis\_Calderon](https://discourse.julialang.org/u/Luis_Calderon)\
**Replies:** 1\
**Last updated:** [October 20, 2022, 4:10pm UTC](https://discourse.julialang.org/t/reversediff-friendly-code-and-domain-errors/89007 "2022-10-20T16:10:16Z")

</div>

Dear all, At the moment, I have the following set-up: Opts = Optim.Options( x\_tol = 0.0, f\_tol = 0.0, g\_…

---

## [Want to contiguously access underlying data of a struct array where the struct is a pair of static arrays](https://discourse.julialang.org/t/want-to-contiguously-access-underlying-data-of-a-struct-array-where-the-struct-is-a-pair-of-static-arrays/89012)

<div class="topic-metadata">

**Author:** [@prittjam](https://discourse.julialang.org/u/prittjam)\
**Replies:** 0\
**Last updated:** [October 20, 2022, 2:25pm UTC](https://discourse.julialang.org/t/want-to-contiguously-access-underlying-data-of-a-struct-array-where-the-struct-is-a-pair-of-static-arrays/89012 "2022-10-20T14:25:03Z")

</div>

using StaticArrays, TensorCast const Point2d{T \<: AbstractFloat} = SVector{2,T} struct PointCspond{T \<: AbstractFloat} first::Point2d{T} second::Point2d{T} end function point\_csponds(u₁,u₂) @cast u₁\[j\]{i:2…

---

## [Freezing when getting out of loop](https://discourse.julialang.org/t/freezing-when-getting-out-of-loop/89006)

<div class="topic-metadata">

**Author:** [@alirza\_azampour](https://discourse.julialang.org/u/alirza_azampour)\
**Replies:** 0\
**Last updated:** [October 20, 2022, 12:21pm UTC](https://discourse.julialang.org/t/freezing-when-getting-out-of-loop/89006 "2022-10-20T12:21:54Z")

</div>

Hey everyone I have this code that runs well for most of the inputs but in some cases, in the loop marked with j counter, it freezes at the time when it has to break out of the loop. I follow the memory and CPU usage du…

---

## [Is it possible to redefine a base operator like .\* in customer package?](https://discourse.julialang.org/t/is-it-possible-to-redefine-a-base-operator-like-in-customer-package/88997)

<div class="topic-metadata">

**Author:** [@lionisxn](https://discourse.julialang.org/u/lionisxn)\
**Replies:** 2\
**Last updated:** [October 20, 2022, 12:05pm UTC](https://discourse.julialang.org/t/is-it-possible-to-redefine-a-base-operator-like-in-customer-package/88997 "2022-10-20T12:05:31Z")

</div>

I try to redefine the basic operator like .\* for my special variable type, through the code: import Base: .\* function .\*(a, b) execute some behavior. end I get a warning message of “could not import Base…\* into Main…

---

## [Trouble exporting functions from different packages with different methods but same name](https://discourse.julialang.org/t/trouble-exporting-functions-from-different-packages-with-different-methods-but-same-name/88972)

<div class="topic-metadata">

**Author:** [@natgeo-wong](https://discourse.julialang.org/u/natgeo-wong)\
**Replies:** 2\
**Last updated:** [October 20, 2022, 6:00am UTC](https://discourse.julialang.org/t/trouble-exporting-functions-from-different-packages-with-different-methods-but-same-name/88972 "2022-10-20T06:00:24Z")

</div>

Hi! I have two different packages. Both export the same function getLandSea, but the methods are different. These two packages sometimes intersect, because they are climate-related datasets, but are for different datase…

---

## [Index into N-dimensional array with N indices](https://discourse.julialang.org/t/index-into-n-dimensional-array-with-n-indices/88989)

<div class="topic-metadata">

**Author:** [@torrance](https://discourse.julialang.org/u/torrance)\
**Replies:** 5\
**Last updated:** [October 20, 2022, 2:50am UTC](https://discourse.julialang.org/t/index-into-n-dimensional-array-with-n-indices/88989 "2022-10-20T02:50:23Z")

</div>

Given an N-dimensional (custom) array A \<: AbstractArray{T, N}, I want to index into this with N indices: eg. if A \<: AbstractArray{T, 2} I want A\[:, :\] or if A \<: AbstractArray{T, 3} I want A\[:, :, :\] This is a custom…

---

## [Custom structure constructor](https://discourse.julialang.org/t/custom-structure-constructor/88958)

<div class="topic-metadata">

**Author:** [@Maucejo](https://discourse.julialang.org/u/Maucejo)\
**Replies:** 3\
**Last updated:** [October 20, 2022, 12:34am UTC](https://discourse.julialang.org/t/custom-structure-constructor/88958 "2022-10-20T00:34:55Z")

</div>

Dear all, I have a question about the use of custom constructor to initialize a Julia struct. I would like to initialize a parameter z (operational parameter) of a structure from some physical parameters, e.g. x and y. …

---

## [How to efficiently create a table/array through known function?](https://discourse.julialang.org/t/how-to-efficiently-create-a-table-array-through-known-function/88965)

<div class="topic-metadata">

**Author:** [@swish47](https://discourse.julialang.org/u/swish47)\
**Replies:** 6\
**Last updated:** [October 19, 2022, 6:43pm UTC](https://discourse.julialang.org/t/how-to-efficiently-create-a-table-array-through-known-function/88965 "2022-10-19T18:43:33Z")

</div>

As the question, if I want to create a table by a function, I may use collect: @elapsed collect(Vector{Float64}(m\*\[2\*pi,(2pi)/sqrt(3)\]+n\*\[0,(4\*pi)/sqrt(3)\]) for m in range(0.,1.,1001), n in range(0.,1.,1001)) with outp…

---

## [Memory allocation and usage of dot notation](https://discourse.julialang.org/t/memory-allocation-and-usage-of-dot-notation/88951)

<div class="topic-metadata">

**Author:** [@dgegen](https://discourse.julialang.org/u/dgegen)\
**Replies:** 6\
**Last updated:** [October 19, 2022, 6:35pm UTC](https://discourse.julialang.org/t/memory-allocation-and-usage-of-dot-notation/88951 "2022-10-19T18:35:59Z")

</div>

The article Performance Tips advises to pay attention to memory allocation when trying to evaluate or improve the efficiency of a program. This made me wonder whether the estimated number of allocations or the estimated …

---

## [Broadcasting with functions of structs](https://discourse.julialang.org/t/broadcasting-with-functions-of-structs/88975)

<div class="topic-metadata">

**Author:** [@AstroBarker](https://discourse.julialang.org/u/AstroBarker)\
**Replies:** 6\
**Last updated:** [October 19, 2022, 5:52pm UTC](https://discourse.julialang.org/t/broadcasting-with-functions-of-structs/88975 "2022-10-19T17:52:47Z")

</div>

Hey folks, I have a struct with some large arrays that need to be updated in place. The updates are not quite trivial and are in a function. What I would like to be able to do is something of the sort @. updatefunc( my\_…

---

## [Probe if a variable exists in a JLD2-file](https://discourse.julialang.org/t/probe-if-a-variable-exists-in-a-jld2-file/88969)

<div class="topic-metadata">

**Author:** [@ellocco](https://discourse.julialang.org/u/ellocco)\
**Replies:** 3\
**Last updated:** [October 19, 2022, 3:31pm UTC](https://discourse.julialang.org/t/probe-if-a-variable-exists-in-a-jld2-file/88969 "2022-10-19T15:31:59Z")

</div>

Is there a way to probe / evaluate if a variable exists in a JLD2-file?

---

## [SQLite backup](https://discourse.julialang.org/t/sqlite-backup/88654)

<div class="topic-metadata">

**Author:** [@sransome](https://discourse.julialang.org/u/sransome)\
**Replies:** 5\
**Last updated:** [October 19, 2022, 2:33pm UTC](https://discourse.julialang.org/t/sqlite-backup/88654 "2022-10-19T14:33:29Z")

</div>

Hi, Is there a way of using sqlite.jl to execute the API commands like sqlite3\_backup\_init() ?

---

## [Problems installing Sundials](https://discourse.julialang.org/t/problems-installing-sundials/88415)

<div class="topic-metadata">

**Author:** [@guilhermebodin](https://discourse.julialang.org/u/guilhermebodin)\
**Replies:** 15\
**Last updated:** [October 19, 2022, 12:31pm UTC](https://discourse.julialang.org/t/problems-installing-sundials/88415 "2022-10-19T12:31:10Z")

</div>

Hi, I am trying to install the latest version of Sundials on windows but I keep getting this permission denied message. I am running with cmd as an administrator (@v1.8) pkg\> activate --temp Activating new project at …

---

## [Change Julia version for a Jupyter notebook](https://discourse.julialang.org/t/change-julia-version-for-a-jupyter-notebook/44359)

<div class="topic-metadata">

**Author:** [@Ryan\_Chan](https://discourse.julialang.org/u/Ryan_Chan)\
**Replies:** 1\
**Last updated:** [August 5, 2020, 9:09pm UTC](https://discourse.julialang.org/t/change-julia-version-for-a-jupyter-notebook/44359 "2020-08-05T21:09:33Z")

</div>

Hi all, I have recently started to learn Julia and have been using JuliaAcademy. I have downloaded the latest Julia version (v1.5.0), however, the Jupyter notebooks for the courses are written in Julia 1.4.2. This mean…

---

## [Tests failing while running Base.runtests("Pkg")](https://discourse.julialang.org/t/tests-failing-while-running-base-runtests-pkg/88941)

<div class="topic-metadata">

**Author:** [@Vinod\_Kumar\_K](https://discourse.julialang.org/u/Vinod_Kumar_K)\
**Replies:** 1\
**Last updated:** [October 19, 2022, 10:37am UTC](https://discourse.julialang.org/t/tests-failing-while-running-base-runtests-pkg/88941 "2022-10-19T10:37:56Z")

</div>

julia\> Base.runtests(“Pkg”) Running parallel tests with: nworkers() = 1 nthreads() = 1 Sys.CPU\_THREADS = 4 Sys.total\_memory() = 8192.000 PiB Sys.free\_memory() = 8192.000 PiB Test (Worker) | Time (s) | GC (s) | GC…

---

## [Interpolate a function in an Expr (macro) in called module scope](https://discourse.julialang.org/t/interpolate-a-function-in-an-expr-macro-in-called-module-scope/88952)

<div class="topic-metadata">

**Author:** [@circonflexe](https://discourse.julialang.org/u/circonflexe)\
**Replies:** 1\
**Last updated:** [October 19, 2022, 10:02am UTC](https://discourse.julialang.org/t/interpolate-a-function-in-an-expr-macro-in-called-module-scope/88952 "2022-10-19T10:02:20Z")

</div>

Here is some (heavily simplified) code: module M function foobar end macro define\_foobar\_method() :($foobar() = 1) end end # module M Note that the function foobar is not exported by the module M; I would like the ma…

---

## [What exactly qualifies as „lexically enclosed use“ when using @sync?](https://discourse.julialang.org/t/what-exactly-qualifies-as-lexically-enclosed-use-when-using-sync/88922)

<div class="topic-metadata">

**Author:** [@told](https://discourse.julialang.org/u/told)\
**Replies:** 2\
**Last updated:** [October 19, 2022, 8:34am UTC](https://discourse.julialang.org/t/what-exactly-qualifies-as-lexically-enclosed-use-when-using-sync/88922 "2022-10-19T08:34:50Z")

</div>

The documentation for @sync states that: Wait until all lexically-enclosed uses of @async , @spawn , @spawnat and @distributed are complete. All exceptions thrown by enclosed async operations are collected and thrown …

---

## [CTRL-C crashing REPL in hot loop](https://discourse.julialang.org/t/ctrl-c-crashing-repl-in-hot-loop/88915)

<div class="topic-metadata">

**Author:** [@Iulian.Cioarca](https://discourse.julialang.org/u/Iulian.Cioarca)\
**Replies:** 2\
**Last updated:** [October 19, 2022, 6:18am UTC](https://discourse.julialang.org/t/ctrl-c-crashing-repl-in-hot-loop/88915 "2022-10-19T06:18:01Z")

</div>

I experienced this issue on Julia 1.8.2 (Windows), with a fairly complex Dash app (+ DataFrames, CSV and other packages in an environment). It even happend with a hot loop: while true end # CTRL-C This kills the workf…

---

## [Test failures for Sockets ,Base.runtests("Sockets")](https://discourse.julialang.org/t/test-failures-for-sockets-base-runtests-sockets/88898)

<div class="topic-metadata">

**Author:** [@Vinod\_Kumar\_K](https://discourse.julialang.org/u/Vinod_Kumar_K)\
**Replies:** 2\
**Last updated:** [October 19, 2022, 4:23am UTC](https://discourse.julialang.org/t/test-failures-for-sockets-base-runtests-sockets/88898 "2022-10-19T04:23:47Z")

</div>

Error in testset Sockets: Error During Test at /julia/juliabuild/usr/share/julia/stdlib/v1.8/Sockets/test/runtests.jl:376 Got exception outside of a @test InexactError: trunc(UInt16, 65536) Stacktrace: \[1\] throw\_ine…

[Previous page](https://discourse.julialang.org/c/usage/6.md?page=379)

[Next page](https://discourse.julialang.org/c/usage/6.md?page=381)
