# Latest

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

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

**Page:** 1672

---

## [Is "include" safe to use inside a function?](https://discourse.julialang.org/t/is-include-safe-to-use-inside-a-function/10867)

<div class="topic-metadata">

**Author:** [@mohamed82008](https://discourse.julialang.org/u/mohamed82008)\
**Replies:** 43\
**Last updated:** [August 3, 2020, 4:03pm UTC](https://discourse.julialang.org/t/is-include-safe-to-use-inside-a-function/10867 "2020-08-03T16:03:02Z")

</div>

Is the following safe to do? #testinclude.jl a = 2 julia\> function f() include("testinclude.jl") return a end f (generic function with 1 method) julia\> f() 2

---

## [\[solved\] Agents.jl spending 3/4 of its time doing something before it even starts to compute?](https://discourse.julialang.org/t/solved-agents-jl-spending-3-4-of-its-time-doing-something-before-it-even-starts-to-compute/44109)

<div class="topic-metadata">

**Author:** [@dlakelan](https://discourse.julialang.org/u/dlakelan)\
**Replies:** 11\
**Last updated:** [August 3, 2020, 3:58pm UTC](https://discourse.julialang.org/t/solved-agents-jl-spending-3-4-of-its-time-doing-something-before-it-even-starts-to-compute/44109 "2020-08-03T15:58:41Z")

</div>

I’m running a simulation with 10000 agents in a continuous space. Even 4 time steps takes minutes… Netlogo can do a similar thing in milliseconds. So of course I hit the profiler: 131╎131 @Base/dict.jl:279; ht\_key…

---

## [Same constructors, less code written](https://discourse.julialang.org/t/same-constructors-less-code-written/44120)

<div class="topic-metadata">

**Author:** [@JeffreySarnoff](https://discourse.julialang.org/u/JeffreySarnoff)\
**Replies:** 7\
**Last updated:** [August 3, 2020, 3:03pm UTC](https://discourse.julialang.org/t/same-constructors-less-code-written/44120 "2020-08-03T15:03:48Z")

</div>

Now that Julia constructors are so well supported, we could avoid writing convert functions where there is a promote\_rule and the proper conversion is to apply the promotion selected type constructor. Please see my next…

---

## [Pkg artifact download when lazy=true](https://discourse.julialang.org/t/pkg-artifact-download-when-lazy-true/44196)

<div class="topic-metadata">

**Author:** [@yalwan-iqvia](https://discourse.julialang.org/u/yalwan-iqvia)\
**Replies:** 0\
**Last updated:** [August 3, 2020, 3:02pm UTC](https://discourse.julialang.org/t/pkg-artifact-download-when-lazy-true/44196 "2020-08-03T15:02:16Z")

</div>

I’m building a docker image with an application contained within and all pre-requisites are provided. This is important because the image runs without an internet connection. However I found (to my surprise) that some ar…

---

## [Idiomatic way to specialise method over array shape/dims](https://discourse.julialang.org/t/idiomatic-way-to-specialise-method-over-array-shape-dims/44131)

<div class="topic-metadata">

**Author:** [@Plop](https://discourse.julialang.org/u/Plop)\
**Replies:** 8\
**Last updated:** [August 3, 2020, 2:58pm UTC](https://discourse.julialang.org/t/idiomatic-way-to-specialise-method-over-array-shape-dims/44131 "2020-08-03T14:58:54Z")

</div>

It seems that array dimensions is not included in the type definition (which is really reasonable). I was wondering if there was a mechanism in Julia to force method specialisation based on array dimensions. Typically, …

---

## [Help to check if an element in a Tables.jl is defined](https://discourse.julialang.org/t/help-to-check-if-an-element-in-a-tables-jl-is-defined/44110)

<div class="topic-metadata">

**Author:** [@Ronis\_BR](https://discourse.julialang.org/u/Ronis_BR)\
**Replies:** 6\
**Last updated:** [August 3, 2020, 2:12pm UTC](https://discourse.julialang.org/t/help-to-check-if-an-element-in-a-tables-jl-is-defined/44110 "2020-08-03T14:12:02Z")

</div>

Hi! I am trying to print tables that comply with Tables.jl specification. However, this tables can have undefined elements, such as: julia\> df = DataFrame(B=Int64.(1:9), A = Vector{Any}(undef, 9)) I am having a proble…

---

## [Ubuntu archive not updating?](https://discourse.julialang.org/t/ubuntu-archive-not-updating/44188)

<div class="topic-metadata">

**Author:** [@ldsands](https://discourse.julialang.org/u/ldsands)\
**Replies:** 3\
**Last updated:** [August 3, 2020, 1:59pm UTC](https://discourse.julialang.org/t/ubuntu-archive-not-updating/44188 "2020-08-03T13:59:14Z")

</div>

Hello everyone, Index of /ubuntu/pool/universe/j/julia which houses the Julia binaries that is used by apt-get on ubuntu has not been updated since April. Is there a reason for this? I figured I’d post this here first a…

---

## [Avoid allocations](https://discourse.julialang.org/t/avoid-allocations/44187)

<div class="topic-metadata">

**Author:** [@nhavt](https://discourse.julialang.org/u/nhavt)\
**Replies:** 3\
**Last updated:** [August 3, 2020, 1:44pm UTC](https://discourse.julialang.org/t/avoid-allocations/44187 "2020-08-03T13:44:40Z")

</div>

Hi there, suppose that I have a Float64 vector x. I wish to identify non-zero elements of this vector. Below are my proposal for that. f1!(y,x) = y .= (x .!=0 )\[:\]; function f2!(y,x) @inbounds @simd for i ∈ eachinde…

---

## [The Newtonian Casino](https://discourse.julialang.org/t/the-newtonian-casino/44173)

<div class="topic-metadata">

**Author:** [@johnh](https://discourse.julialang.org/u/johnh)\
**Replies:** 3\
**Last updated:** [August 3, 2020, 12:58pm UTC](https://discourse.julialang.org/t/the-newtonian-casino/44173 "2020-08-03T12:58:12Z")

</div>

I would recommend the book The Eudamonic Pie to everyone here. Published as the Newtonian Casino in the UK. It is a thrilling tale of hackers who go to Vegas with computers concealed in their shoes. I cannot help but t…

---

## [Differences in these expressions?](https://discourse.julialang.org/t/differences-in-these-expressions/44115)

<div class="topic-metadata">

**Author:** [@Hawk](https://discourse.julialang.org/u/Hawk)\
**Replies:** 6\
**Last updated:** [August 3, 2020, 12:40pm UTC](https://discourse.julialang.org/t/differences-in-these-expressions/44115 "2020-08-03T12:40:03Z")

</div>

When learning metaprogramming in Julia, I am a little bit confusing about these behavior like below julia\> Meta.show\_sexpr(:(:($(1+2)))) (:quote,(:$,(:call,:+,1,2))) julia\> Meta.show\_sexpr(:($(1+2))) 3 Julia\> Meta.sho…

---

## [OnlinePackage.jl](https://discourse.julialang.org/t/onlinepackage-jl/44162)

<div class="topic-metadata">

**Author:** [@bramtayl](https://discourse.julialang.org/u/bramtayl)\
**Replies:** 4\
**Last updated:** [August 3, 2020, 12:31pm UTC](https://discourse.julialang.org/t/onlinepackage-jl/44162 "2020-08-03T12:31:41Z")

</div>

Hi all, just wanted to note that I’ve published a new version of OnlinePackage updated for the post-github-action era. The package has had a bit of growing pains, as PkgTemplates has gained more features and github-actio…

---

## [How to copy a Julia DataFrame in a threaded loop?](https://discourse.julialang.org/t/how-to-copy-a-julia-dataframe-in-a-threaded-loop/44136)

<div class="topic-metadata">

**Author:** [@Bebio](https://discourse.julialang.org/u/Bebio)\
**Replies:** 8\
**Last updated:** [August 3, 2020, 11:36am UTC](https://discourse.julialang.org/t/how-to-copy-a-julia-dataframe-in-a-threaded-loop/44136 "2020-08-03T11:36:16Z")

</div>

First of all, I am a very beginner I’ve got the following problem : A DataFrame named cr1 with 553 columns Then, I make two loops as follow : cr2=copy(cr1) #-----------------# #Loop on scenarios# #----------…

---

## [How to coerce types from data loaded via ExcelFiles.jl](https://discourse.julialang.org/t/how-to-coerce-types-from-data-loaded-via-excelfiles-jl/44161)

<div class="topic-metadata">

**Author:** [@fnbillimoria](https://discourse.julialang.org/u/fnbillimoria)\
**Replies:** 1\
**Last updated:** [August 3, 2020, 11:05am UTC](https://discourse.julialang.org/t/how-to-coerce-types-from-data-loaded-via-excelfiles-jl/44161 "2020-08-03T11:05:32Z")

</div>

Hi, I am loading a sheet from an excel file using ExcelFiles.jl. I wish to convert the types for some of the columns that are loaded as a dataframe. Some of the columns load as a float, and I wish to coerce them to an …

---

## [@elapsed for function with return values](https://discourse.julialang.org/t/elapsed-for-function-with-return-values/44180)

<div class="topic-metadata">

**Author:** [@yxieGT](https://discourse.julialang.org/u/yxieGT)\
**Replies:** 1\
**Last updated:** [August 3, 2020, 10:40am UTC](https://discourse.julialang.org/t/elapsed-for-function-with-return-values/44180 "2020-08-03T10:40:14Z")

</div>

Is there a macro in Julia to return the elapsed time of a function with return values?

---

## [On the output value of JuMP](https://discourse.julialang.org/t/on-the-output-value-of-jump/44084)

<div class="topic-metadata">

**Author:** [@dty](https://discourse.julialang.org/u/dty)\
**Replies:** 6\
**Last updated:** [August 3, 2020, 9:21am UTC](https://discourse.julialang.org/t/on-the-output-value-of-jump/44084 "2020-08-03T09:21:35Z")

</div>

How to output the value of my decision variable in workspace？ I tried to use value at the end of the program, but it didn’t work. At present, the effective way is to write value() one by one in repl.

---

## [Atom - setting julia path](https://discourse.julialang.org/t/atom-setting-julia-path/40513)

<div class="topic-metadata">

**Author:** [@rami](https://discourse.julialang.org/u/rami)\
**Replies:** 5\
**Last updated:** [August 3, 2020, 7:45am UTC](https://discourse.julialang.org/t/atom-setting-julia-path/40513 "2020-08-03T07:45:57Z")

</div>

Hello, I am trying to set julia path on Atom IDE on Mac. Here is the setting of julia on my machine: ~ ❯ which julia /usr/local/bin/julia ~ ❯ ls -l /usr/local/bin/julia lrwxr-xr-x 1 ramikrispin admin 62 Dec 13 00:39…

---

## [Jupyter integration](https://discourse.julialang.org/t/jupyter-integration/44170)

<div class="topic-metadata">

**Author:** [@Nithin\_M](https://discourse.julialang.org/u/Nithin_M)\
**Replies:** 2\
**Last updated:** [August 3, 2020, 7:01am UTC](https://discourse.julialang.org/t/jupyter-integration/44170 "2020-08-03T07:01:06Z")

</div>

I am having error in connecting Julia with jupyter notebook…

---

## [System image as an artifact - download pre-build system images](https://discourse.julialang.org/t/system-image-as-an-artifact-download-pre-build-system-images/44106)

<div class="topic-metadata">

**Author:** [@Roger-luo](https://discourse.julialang.org/u/Roger-luo)\
**Replies:** 7\
**Last updated:** [August 3, 2020, 6:26am UTC](https://discourse.julialang.org/t/system-image-as-an-artifact-download-pre-build-system-images/44106 "2020-08-03T06:26:33Z")

</div>

Hi folks, you might have noticed my previous announcement on Comonicon.jl, I planned to support distributable system images for CLIs so users can directly download the system images instead of building it themselves loc…

---

## [How to handle/ignore missing values when fitting differential equations?](https://discourse.julialang.org/t/how-to-handle-ignore-missing-values-when-fitting-differential-equations/43866)

<div class="topic-metadata">

**Author:** [@Irene](https://discourse.julialang.org/u/Irene)\
**Replies:** 3\
**Last updated:** [August 3, 2020, 4:58am UTC](https://discourse.julialang.org/t/how-to-handle-ignore-missing-values-when-fitting-differential-equations/43866 "2020-08-03T04:58:21Z")

</div>

Hi, I have a time-series of hourly weather data records that you can check here. You can see that for every hour in these two days (July 16-17 2018), we have a measurement of temperature, and other variables. I am inter…

---

## [Efficient Black/White Colormap plot](https://discourse.julialang.org/t/efficient-black-white-colormap-plot/44157)

<div class="topic-metadata">

**Author:** [@gideonsimpson](https://discourse.julialang.org/u/gideonsimpson)\
**Replies:** 1\
**Last updated:** [August 3, 2020, 2:29am UTC](https://discourse.julialang.org/t/efficient-black-white-colormap-plot/44157 "2020-08-03T02:29:03Z")

</div>

I’m trying to efficiently create visualizations of a 2D Ising model (i.e., see Ising model - Wikipedia). Using Julia plots contour seems wasteful, and is definitely slow. Is there some simple black/white plot that coul…

---

## [CSV Segmentation fault in project environment](https://discourse.julialang.org/t/csv-segmentation-fault-in-project-environment/44124)

<div class="topic-metadata">

**Author:** [@Donut\_Meepo](https://discourse.julialang.org/u/Donut_Meepo)\
**Replies:** 3\
**Last updated:** [August 3, 2020, 1:57am UTC](https://discourse.julialang.org/t/csv-segmentation-fault-in-project-environment/44124 "2020-08-03T01:57:25Z")

</div>

Hello guys, I added CSV.jl to my project environment (\]add CSV). When I used the CSV package, I got segmentation fault and exit of the REPL. But when I use the @v1.4 environment everything works normal. I try to remove …

---

## [JuliaMono font on Windows 10](https://discourse.julialang.org/t/juliamono-font-on-windows-10/44057)

<div class="topic-metadata">

**Author:** [@MartinOtter](https://discourse.julialang.org/u/MartinOtter)\
**Replies:** 19\
**Last updated:** [August 2, 2020, 9:17pm UTC](https://discourse.julialang.org/t/juliamono-font-on-windows-10/44057 "2020-08-02T21:17:17Z")

</div>

Tried JuliaMono font on Windows 10 with vscode/julia (1.0.0). In all cases, I set font to JuliaMono: Julia Manual: Copied to Word: Copied to file in vscode: Copied to REPL in cmd window: Copied to REPL in vscod…

---

## [PGFPlotsX - How to save figure?](https://discourse.julialang.org/t/pgfplotsx-how-to-save-figure/44145)

<div class="topic-metadata">

**Author:** [@Ahmed\_Salih](https://discourse.julialang.org/u/Ahmed_Salih)\
**Replies:** 4\
**Last updated:** [August 2, 2020, 8:31pm UTC](https://discourse.julialang.org/t/pgfplotsx-how-to-save-figure/44145 "2020-08-02T20:31:01Z")

</div>

Hello! I have some code as: p = scatter((data\[1,id1\],data\[2,id1\]), markersize = 3.5, markerstrokestyle = :dot, aspect\_ratio=:equal, color = :orange, label = "…

---

## [Plotting one column of a csv file](https://discourse.julialang.org/t/plotting-one-column-of-a-csv-file/44150)

<div class="topic-metadata">

**Author:** [@johnh](https://discourse.julialang.org/u/johnh)\
**Replies:** 1\
**Last updated:** [August 2, 2020, 8:21pm UTC](https://discourse.julialang.org/t/plotting-one-column-of-a-csv-file/44150 "2020-08-02T20:21:06Z")

</div>

I know this will show me as dumb as a warthog. Not as an ox as our @oxinabox is very smart. I am experimenting with Pluto.jl - which is great! I have a CSV file with a header row. I Can select one column using the stri…

---

## [Plot 2D graph ,color of scatter points associate with value](https://discourse.julialang.org/t/plot-2d-graph-color-of-scatter-points-associate-with-value/44148)

<div class="topic-metadata">

**Author:** [@Dyranne](https://discourse.julialang.org/u/Dyranne)\
**Replies:** 0\
**Last updated:** [August 2, 2020, 7:17pm UTC](https://discourse.julialang.org/t/plot-2d-graph-color-of-scatter-points-associate-with-value/44148 "2020-08-02T19:17:15Z")

</div>

The first question is using ORCA julia\> using ORCA \[ Info: Precompiling ORCA \[47be7bcc-f1a6-5447-8b36-7eeeff7534fd\] ERROR: LoadError: ORCA not installed properly. Please call \`Pkg.build("ORCA")\` Stacktrace: \[1\] error(:…

---

## [How to set up a remote connexion using codespace](https://discourse.julialang.org/t/how-to-set-up-a-remote-connexion-using-codespace/44138)

<div class="topic-metadata">

**Author:** [@luraess](https://discourse.julialang.org/u/luraess)\
**Replies:** 3\
**Last updated:** [August 2, 2020, 6:59pm UTC](https://discourse.julialang.org/t/how-to-set-up-a-remote-connexion-using-codespace/44138 "2020-08-02T18:59:30Z")

</div>

Kudos for the latest VS Code features presented by David Anthoff at JuliaCon 2020 \[https://live.juliacon.org/talk/HBTFT7\] ! All seems to run smooth, out of the box. By the end of your presentation (@ 23:52), you speak a…

---

## [Variable declaration](https://discourse.julialang.org/t/variable-declaration/44142)

<div class="topic-metadata">

**Author:** [@mamo](https://discourse.julialang.org/u/mamo)\
**Replies:** 2\
**Last updated:** [August 2, 2020, 6:50pm UTC](https://discourse.julialang.org/t/variable-declaration/44142 "2020-08-02T18:50:09Z")

</div>

Dear, send me some suggestion for a proper declaration of this variable @variable(model, CHANGE\[k in FAMILY, l in FAMILY, j in UNITS, t in TIME, t1 in TIME: k\<\>l and t+1=t1\], Bin) The problem is in k\<\>l (k must be di…

---

## [Installing TikzGraphs for BayesNets](https://discourse.julialang.org/t/installing-tikzgraphs-for-bayesnets/44146)

<div class="topic-metadata">

**Author:** [@Christopher\_Fisher](https://discourse.julialang.org/u/Christopher_Fisher)\
**Replies:** 0\
**Last updated:** [August 2, 2020, 6:35pm UTC](https://discourse.julialang.org/t/installing-tikzgraphs-for-bayesnets/44146 "2020-08-02T18:35:45Z")

</div>

Hi all- I am trying to install TikzGraphs, which is a dependency for BayesNets. Unfortunately, I am having trouble installing pgf. It gives the following message: (base) dfish@dfish-MS-7850:~$ sudo apt-get install pgf…

---

## [Request to package developers: Please eliminate ambiguities with Base](https://discourse.julialang.org/t/request-to-package-developers-please-eliminate-ambiguities-with-base/44123)

<div class="topic-metadata">

**Author:** [@jishnub](https://discourse.julialang.org/u/jishnub)\
**Replies:** 4\
**Last updated:** [August 2, 2020, 5:35pm UTC](https://discourse.julialang.org/t/request-to-package-developers-please-eliminate-ambiguities-with-base/44123 "2020-08-02T17:35:03Z")

</div>

It’s often frustrating when you want your package to depend on an amazing package A, but doing do introduces ambiguities in Base functions that A has not eliminated. There are several packages that I’ve come across recen…

---

## [Using group in scatter plots correctly?](https://discourse.julialang.org/t/using-group-in-scatter-plots-correctly/44132)

<div class="topic-metadata">

**Author:** [@Ahmed\_Salih](https://discourse.julialang.org/u/Ahmed_Salih)\
**Replies:** 5\
**Last updated:** [August 2, 2020, 5:21pm UTC](https://discourse.julialang.org/t/using-group-in-scatter-plots-correctly/44132 "2020-08-02T17:21:28Z")

</div>

Hello! I am trying to make a scatterplot where there exist two groups, one called “0” and one called “1”. The group values is stored in a vector “z”. Over time the points in group “0”, come to group “1”, something like …

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

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