# Latest

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

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

**Page:** 1844

---

## [Commands in package](https://discourse.julialang.org/t/commands-in-package/33426)

<div class="topic-metadata">

**Author:** [@amind3211](https://discourse.julialang.org/u/amind3211)\
**Replies:** 2\
**Last updated:** [January 17, 2020, 2:34pm UTC](https://discourse.julialang.org/t/commands-in-package/33426 "2020-01-17T14:34:50Z")

</div>

1.how can i find or show the items , command or everything you call it in a package ? like SpeedOfLightInVacuum in PhysicalConstants.jl (by the way what do you call them ?)

---

## [Is it possible, that DataFrame row has a name, like colums have? For instance: df\[:GR,:col\]](https://discourse.julialang.org/t/is-it-possible-that-dataframe-row-has-a-name-like-colums-have-for-instance-df-gr-col/33470)

<div class="topic-metadata">

**Author:** [@BMval](https://discourse.julialang.org/u/BMval)\
**Replies:** 2\
**Last updated:** [January 17, 2020, 2:24pm UTC](https://discourse.julialang.org/t/is-it-possible-that-dataframe-row-has-a-name-like-colums-have-for-instance-df-gr-col/33470 "2020-01-17T14:24:44Z")

</div>

Is it possible, that DataFrame row has a name like columns have? For instance: df\[:GR,:col\] P.S. I know that it can’t be done like df\[df.name.==“GR”,:col\] thank you

---

## [Deserealize from/to JSON](https://discourse.julialang.org/t/deserealize-from-to-json/33486)

<div class="topic-metadata">

**Author:** [@jw3126](https://discourse.julialang.org/u/jw3126)\
**Replies:** 1\
**Last updated:** [January 17, 2020, 1:14pm UTC](https://discourse.julialang.org/t/deserealize-from-to-json/33486 "2020-01-17T13:14:36Z")

</div>

I would like to have a quick and dirty way to load/save custom julia structs to a human readable format, say JSON. Goals Human readable Works out of the box for user defined structs Should be simple to implement Should…

---

## [Package undefvarerror: top level scope at none:0](https://discourse.julialang.org/t/package-undefvarerror-top-level-scope-at-none-0/33482)

<div class="topic-metadata">

**Author:** [@diepreye\_ayabina](https://discourse.julialang.org/u/diepreye_ayabina)\
**Replies:** 2\
**Last updated:** [January 17, 2020, 12:49pm UTC](https://discourse.julialang.org/t/package-undefvarerror-top-level-scope-at-none-0/33482 "2020-01-17T12:49:37Z")

</div>

So I just started learning Julia. I installed the Julia 1.0.5 64 bit windows version. Installation went smoothly. However I have not been able to add IJulia package. Each time I type Pkg.add(“IJulia”) , I get the error m…

---

## [Parametric type](https://discourse.julialang.org/t/parametric-type/33487)

<div class="topic-metadata">

**Author:** [@ohmsweetohm1](https://discourse.julialang.org/u/ohmsweetohm1)\
**Replies:** 1\
**Last updated:** [January 17, 2020, 12:48pm UTC](https://discourse.julialang.org/t/parametric-type/33487 "2020-01-17T12:48:38Z")

</div>

Is it possible to write a parametric type with default type? struct Point{T} x::T y::T end struct Foo a::Point{Float64} b::Point # should be the default type: Point{Float64} c::Point{Int} end

---

## [Julia Linear System Solver (\`mldivide()\`)](https://discourse.julialang.org/t/julia-linear-system-solver-mldivide/33447)

<div class="topic-metadata">

**Author:** [@RoyiAvital](https://discourse.julialang.org/u/RoyiAvital)\
**Replies:** 6\
**Last updated:** [January 17, 2020, 12:37pm UTC](https://discourse.julialang.org/t/julia-linear-system-solver-mldivide/33447 "2020-01-17T12:37:19Z")

</div>

In the question Solution of Underdetermined Systems Using LAPACK @stevengj mentioned that the \\ operator in Julia returns the Minimum Norm Solution for Under determined System. The Matrix Division operator, \\ according…

---

## [BSON unable to load struct with array of subtypes](https://discourse.julialang.org/t/bson-unable-to-load-struct-with-array-of-subtypes/33483)

<div class="topic-metadata">

**Author:** [@HenriDeh](https://discourse.julialang.org/u/HenriDeh)\
**Replies:** 0\
**Last updated:** [January 17, 2020, 11:25am UTC](https://discourse.julialang.org/t/bson-unable-to-load-struct-with-array-of-subtypes/33483 "2020-01-17T11:25:11Z")

</div>

Am I coding wrong or should I open an issue ? BSON cannot load an struct that has an array of a subtype field. julia\> using BSON julia\> mutable struct Bar arrreal::Array{\<:Real,1} end julia\> bar = Bar(Re…

---

## [API design for dispatching on type of action](https://discourse.julialang.org/t/api-design-for-dispatching-on-type-of-action/33478)

<div class="topic-metadata">

**Author:** [@pszufe](https://discourse.julialang.org/u/pszufe)\
**Replies:** 1\
**Last updated:** [January 17, 2020, 11:22am UTC](https://discourse.julialang.org/t/api-design-for-dispatching-on-type-of-action/33478 "2020-01-17T11:22:44Z")

</div>

Which is prefered design of an API - dispatching on Type or dispatching on type of argument? Consider the simple code below abstract type Ab end struct B \<: Ab end struct C \<: Ab end f(x::Int,::Type{B}) = "I am B and …

---

## [PhD student position(s) in mathematics for artificial intelligence](https://discourse.julialang.org/t/phd-student-position-s-in-mathematics-for-artificial-intelligence/33479)

<div class="topic-metadata">

**Author:** [@mschauer](https://discourse.julialang.org/u/mschauer)\
**Replies:** 0\
**Last updated:** [January 17, 2020, 10:55am UTC](https://discourse.julialang.org/t/phd-student-position-s-in-mathematics-for-artificial-intelligence/33479 "2020-01-17T10:55:40Z")

</div>

We are looking for a PhD candidate in mathematics for artificial intelligence for a project on Stochastic continuous-depth neural networks. This is not directly related to Julia but there is a considerable overlap in in…

---

## [Can Versions.toml point to git branch instead of fixed git commit?](https://discourse.julialang.org/t/can-versions-toml-point-to-git-branch-instead-of-fixed-git-commit/33442)

<div class="topic-metadata">

**Author:** [@schlichtanders](https://discourse.julialang.org/u/schlichtanders)\
**Replies:** 7\
**Last updated:** [January 16, 2020, 4:51pm UTC](https://discourse.julialang.org/t/can-versions-toml-point-to-git-branch-instead-of-fixed-git-commit/33442 "2020-01-16T16:51:11Z")

</div>

for creating one’s own registry one has to specify Versions.toml for each package currently it seems like you have to link versions to concrete git commits via hash, however for development it would be very helpful to l…

---

## [When should we use \`@nospecialize\`?](https://discourse.julialang.org/t/when-should-we-use-nospecialize/10392)

<div class="topic-metadata">

**Author:** [@pablosanjose](https://discourse.julialang.org/u/pablosanjose)\
**Replies:** 8\
**Last updated:** [January 17, 2020, 8:04am UTC](https://discourse.julialang.org/t/when-should-we-use-nospecialize/10392 "2020-01-17T08:04:40Z")

</div>

The manual is sketchy about the use of @nospecialize (maybe it is still WIP?). I gather it is a necessary optimisation to avoid overburdening the dispatch tables. Is the end user advised to use this macro in some specifi…

---

## ["higher level" c interface package](https://discourse.julialang.org/t/higher-level-c-interface-package/33381)

<div class="topic-metadata">

**Author:** [@purplishrock](https://discourse.julialang.org/u/purplishrock)\
**Replies:** 2\
**Last updated:** [January 17, 2020, 6:00am UTC](https://discourse.julialang.org/t/higher-level-c-interface-package/33381 "2020-01-17T06:00:26Z")

</div>

I seem to remember a package mentioned in these hallowed threads, which implemented a higher level C interface, in particular, I think that it handled structures well, especially if they had things like bitfields. it do…

---

## [How to fix blurry PyPlot plots in hidpi machine in jupyter](https://discourse.julialang.org/t/how-to-fix-blurry-pyplot-plots-in-hidpi-machine-in-jupyter/33471)

<div class="topic-metadata">

**Author:** [@Chong\_Wang](https://discourse.julialang.org/u/Chong_Wang)\
**Replies:** 0\
**Last updated:** [January 17, 2020, 4:45am UTC](https://discourse.julialang.org/t/how-to-fix-blurry-pyplot-plots-in-hidpi-machine-in-jupyter/33471 "2020-01-17T04:45:03Z")

</div>

In a hidpi machine, the inline plots of jupyter via PyPlot.jl are blurry. Previously, I usually use the PyPlot.svg(true) option. However, this will slow down the browser considerably if the plot is really large. I noti…

---

## [Cannot find var's name when I eval an expr](https://discourse.julialang.org/t/cannot-find-vars-name-when-i-eval-an-expr/33460)

<div class="topic-metadata">

**Author:** [@Fang](https://discourse.julialang.org/u/Fang)\
**Replies:** 2\
**Last updated:** [January 17, 2020, 4:19am UTC](https://discourse.julialang.org/t/cannot-find-vars-name-when-i-eval-an-expr/33460 "2020-01-17T04:19:44Z")

</div>

Hi I wanna use eval an expr but the error says that the var’s name cannot be found. My function is below : function cal(jac, rate, Q) n\_spec = size(jac, 1) jac\_value = zeros(Float64, n\_spec, n\_spec) for i…

---

## [Why is heap memory "bad"?](https://discourse.julialang.org/t/why-is-heap-memory-bad/33290)

<div class="topic-metadata">

**Author:** [@affans](https://discourse.julialang.org/u/affans)\
**Replies:** 6\
**Last updated:** [January 17, 2020, 4:00am UTC](https://discourse.julialang.org/t/why-is-heap-memory-bad/33290 "2020-01-17T04:00:22Z")

</div>

I’ve been trying to understand some details of how certain programming languages work and certain paradigms such as immutability of variables. In particular I am trying to understand what stack/heap memory is and how it …

---

## [Changing package dependency revisions (AWSCore/HTTP)](https://discourse.julialang.org/t/changing-package-dependency-revisions-awscore-http/33428)

<div class="topic-metadata">

**Author:** [@jade\_mackay](https://discourse.julialang.org/u/jade_mackay)\
**Replies:** 2\
**Last updated:** [January 17, 2020, 12:14am UTC](https://discourse.julialang.org/t/changing-package-dependency-revisions-awscore-http/33428 "2020-01-17T00:14:21Z")

</div>

I need to use AWSCore though a proxy. The current release of AWSCore (0.6.7) specifies compatibility with dependency HTTP version 0.8. The HTTP proxy functionality I need has been merged to master but has yet to be relea…

---

## [Empty JuliaDB](https://discourse.julialang.org/t/empty-juliadb/33450)

<div class="topic-metadata">

**Author:** [@alphasig329](https://discourse.julialang.org/u/alphasig329)\
**Replies:** 1\
**Last updated:** [January 16, 2020, 10:57pm UTC](https://discourse.julialang.org/t/empty-juliadb/33450 "2020-01-16T22:57:19Z")

</div>

Is it possible to initialize an empty JuliaDB table with columns names?

---

## [CSV.Write DataFrame boolean columns as 0 or 1, not as string: "false" and "true"](https://discourse.julialang.org/t/csv-write-dataframe-boolean-columns-as-0-or-1-not-as-string-false-and-true/33449)

<div class="topic-metadata">

**Author:** [@BMval](https://discourse.julialang.org/u/BMval)\
**Replies:** 8\
**Last updated:** [January 16, 2020, 9:06pm UTC](https://discourse.julialang.org/t/csv-write-dataframe-boolean-columns-as-0-or-1-not-as-string-false-and-true/33449 "2020-01-16T21:06:23Z")

</div>

When I save a DataFrame with boolean columns, CSV.write them as strings: “false” and “true”, so it increases file sizes. How to save the boolean columns into 0 and 1. Thank you in advance.

---

## [Yet another Artifacts question - when is a download triggered?](https://discourse.julialang.org/t/yet-another-artifacts-question-when-is-a-download-triggered/33452)

<div class="topic-metadata">

**Author:** [@dmbates](https://discourse.julialang.org/u/dmbates)\
**Replies:** 1\
**Last updated:** [January 16, 2020, 8:08pm UTC](https://discourse.julialang.org/t/yet-another-artifacts-question-when-is-a-download-triggered/33452 "2020-01-16T20:08:49Z")

</div>

My Artifacts.toml file contains \[TestData\] git-tree-sha1 = "9d575764bc1c1a7860c34c5b153251e5f2ee6704" lazy = true \[\[TestData.download\]\] sha256 = "7fcd1e390c59530e9ea00939afd1798813e3727b" url = "https://ndo…

---

## [TensorFlow Issue with Logistic Regression Example](https://discourse.julialang.org/t/tensorflow-issue-with-logistic-regression-example/33454)

<div class="topic-metadata">

**Author:** [@abianco](https://discourse.julialang.org/u/abianco)\
**Replies:** 0\
**Last updated:** [January 16, 2020, 8:00pm UTC](https://discourse.julialang.org/t/tensorflow-issue-with-logistic-regression-example/33454 "2020-01-16T20:00:33Z")

</div>

After a fresh installation of Julia on CentOS 7.2, I added TensorFlow, ran the “basic usage” test in README.md and passed it. Then, after installing also the Distributions and Printf packages, I tried to run the “logisti…

---

## [Variable from dictionary key](https://discourse.julialang.org/t/variable-from-dictionary-key/33357)

<div class="topic-metadata">

**Author:** [@PizzaQuattroStagioni](https://discourse.julialang.org/u/PizzaQuattroStagioni)\
**Replies:** 3\
**Last updated:** [January 16, 2020, 6:07pm UTC](https://discourse.julialang.org/t/variable-from-dictionary-key/33357 "2020-01-16T18:07:50Z")

</div>

I have a dictionary and I want to extract a value from the dictionary and hand it over to a variable. The problem is: when I give the value from the dictionary to the variable and add a value to the variable (in the way …

---

## [Add fill method accepting constructor function](https://discourse.julialang.org/t/add-fill-method-accepting-constructor-function/33424)

<div class="topic-metadata">

**Author:** [@Alex1](https://discourse.julialang.org/u/Alex1)\
**Replies:** 10\
**Last updated:** [January 16, 2020, 5:05pm UTC](https://discourse.julialang.org/t/add-fill-method-accepting-constructor-function/33424 "2020-01-16T17:05:06Z")

</div>

Initialising array of arrays fill(\[\], 2) would end up in an error, as all arrays will be actually the same array. I suggest provide additional method for fill function, accepting constructor function fill(() -\> \[\], 2). …

---

## [How to redraw a subplot instead of overlaying, GR](https://discourse.julialang.org/t/how-to-redraw-a-subplot-instead-of-overlaying-gr/18473)

<div class="topic-metadata">

**Author:** [@Donut\_Meepo](https://discourse.julialang.org/u/Donut_Meepo)\
**Replies:** 3\
**Last updated:** [January 16, 2020, 4:55pm UTC](https://discourse.julialang.org/t/how-to-redraw-a-subplot-instead-of-overlaying-gr/18473 "2020-01-16T16:55:39Z")

</div>

Hi, I am trying to fill the subplots of a layout using GR backend layout = @layout \[grid(1,2); grid(1,2); grid(1,1)\]; plot(layout=layout) #draw at position2 plot!(1:10, rand(10), subplot=2) #want to redraw instead of o…

---

## [Why is Julia messing up my variables?](https://discourse.julialang.org/t/why-is-julia-messing-up-my-variables/32289)

<div class="topic-metadata">

**Author:** [@lko](https://discourse.julialang.org/u/lko)\
**Replies:** 9\
**Last updated:** [January 16, 2020, 4:31pm UTC](https://discourse.julialang.org/t/why-is-julia-messing-up-my-variables/32289 "2020-01-16T16:31:12Z")

</div>

Can one of you explain to me what is going on here and how to avoid it? Can you reproduce this behaviour? When I define x as x = zeros(10) x .= .05 x I get Vector{Float64} with 10 elements 0.0500 0.0500 0.0500 0.050…

---

## [Best Way to Declare Arrays](https://discourse.julialang.org/t/best-way-to-declare-arrays/33411)

<div class="topic-metadata">

**Author:** [@squirrel](https://discourse.julialang.org/u/squirrel)\
**Replies:** 11\
**Last updated:** [January 16, 2020, 4:20pm UTC](https://discourse.julialang.org/t/best-way-to-declare-arrays/33411 "2020-01-16T16:20:06Z")

</div>

I’m trying to wrap my head around arrays in Julia. In Java, if you have an array (int\[\] arr, for example) with 100 elements, then to add another element, you have to make another array with size 101 and copy all the old…

---

## [How to use a minimise mean squared loss function in Julia for gradient descent?](https://discourse.julialang.org/t/how-to-use-a-minimise-mean-squared-loss-function-in-julia-for-gradient-descent/33439)

<div class="topic-metadata">

**Author:** [@PyDataBlog](https://discourse.julialang.org/u/PyDataBlog)\
**Replies:** 0\
**Last updated:** [January 16, 2020, 1:00pm UTC](https://discourse.julialang.org/t/how-to-use-a-minimise-mean-squared-loss-function-in-julia-for-gradient-descent/33439 "2020-01-16T13:00:22Z")

</div>

Hi everyone, I’m very new to Julia and I’m currently trying to understand the language by building from scratch multivariate linear regression using gradient descent. I’m coming from a Python/R background so apologies if…

---

## [Multithreading and ProductIterator](https://discourse.julialang.org/t/multithreading-and-productiterator/33405)

<div class="topic-metadata">

**Author:** [@Yunde](https://discourse.julialang.org/u/Yunde)\
**Replies:** 6\
**Last updated:** [January 16, 2020, 12:30pm UTC](https://discourse.julialang.org/t/multithreading-and-productiterator/33405 "2020-01-16T12:30:29Z")

</div>

Trying to use @threads to Base.Iterators.ProductIterator for optimization problem. Here is a simplified example: x = 1:3; y = 5:7; Threads.@threads for i in Iterators.product(x, y) id = Threads.threadid(); @info…

---

## [Packed struct](https://discourse.julialang.org/t/packed-struct/33394)

<div class="topic-metadata">

**Author:** [@garychow](https://discourse.julialang.org/u/garychow)\
**Replies:** 2\
**Last updated:** [January 16, 2020, 11:16am UTC](https://discourse.julialang.org/t/packed-struct/33394 "2020-01-16T11:16:29Z")

</div>

Hi, I have some binary data which I would like to unpack to some struct. However, as far as I know julia does not support the packed (ie non aligned without padding) struct and that make it impossible to use unsafe\_wrap…

---

## [Install package of Julia in Cocalc](https://discourse.julialang.org/t/install-package-of-julia-in-cocalc/33239)

<div class="topic-metadata">

**Author:** [@1634](https://discourse.julialang.org/u/1634)\
**Replies:** 14\
**Last updated:** [January 13, 2020, 5:43pm UTC](https://discourse.julialang.org/t/install-package-of-julia-in-cocalc/33239 "2020-01-13T17:43:44Z")

</div>

Hi community, Do anyone have a suggested instruction for doing so? My attempts are listed as below. As there is no existent manual for installing package of Julia in Cocalc, I attempted to read an equivalent for R. " …

---

## [Closures as "classic object-oriented programming"](https://discourse.julialang.org/t/closures-as-classic-object-oriented-programming/33434)

<div class="topic-metadata">

**Author:** [@mzaffalon](https://discourse.julialang.org/u/mzaffalon)\
**Replies:** 3\
**Last updated:** [January 16, 2020, 10:49am UTC](https://discourse.julialang.org/t/closures-as-classic-object-oriented-programming/33434 "2020-01-16T10:49:06Z")

</div>

This blog post shows how one could use closures to implement public/private members. I cannot understand why I can access for instance get\_age with the dot newDuck("Bill").get\_age(): I thought the only way to access it …

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

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