# Specific Domains

**URL:** https://discourse.julialang.org/c/domain/10.md?page=355

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

**Page:** 356

---

## [Event handling in jump problems](https://discourse.julialang.org/t/event-handling-in-jump-problems/63882)

<div class="topic-metadata">

**Author:** [@skleinbo](https://discourse.julialang.org/u/skleinbo)\
**Replies:** 3\
**Last updated:** [July 1, 2021, 4:40pm UTC](https://discourse.julialang.org/t/event-handling-in-jump-problems/63882 "2021-07-01T16:40:26Z")

</div>

Consider for the sake of a minimal example the following pure jump problem. rn2 = @reaction\_network begin a, 0 --\> X end a prob2\_jump = JumpProblem(rn2, DiscreteProblem(rn2, \[0\], (0.0, 10.0), \[1.0\]), Direct()) I w…

---

## [Great Makie examples](https://discourse.julialang.org/t/great-makie-examples/63820)

<div class="topic-metadata">

**Author:** [@sdanisch](https://discourse.julialang.org/u/sdanisch)\
**Replies:** 1\
**Last updated:** [June 30, 2021, 2:26pm UTC](https://discourse.julialang.org/t/great-makie-examples/63820 "2021-06-30T14:26:44Z")

</div>

I’d love to show off some outstanding Makie examples at JuliaCon - and in general work towards collecting examples to show off Makies capabilities and get an overview of what people are up to. Code would be great for fu…

---

## [How to make a user-defined objective function with mulitple vector variable and parameter arguments?](https://discourse.julialang.org/t/how-to-make-a-user-defined-objective-function-with-mulitple-vector-variable-and-parameter-arguments/63849)

<div class="topic-metadata">

**Author:** [@thompsonmj](https://discourse.julialang.org/u/thompsonmj)\
**Replies:** 6\
**Last updated:** [July 1, 2021, 2:18am UTC](https://discourse.julialang.org/t/how-to-make-a-user-defined-objective-function-with-mulitple-vector-variable-and-parameter-arguments/63849 "2021-07-01T02:18:35Z")

</div>

I would like to optimize a set of 3 variable vectors to minimize the total variance in a dataset. I think my problem is in passing variable and parameter vectors into my user-defined objective. I found this question on …

---

## [Using Arrow.DictEncode()](https://discourse.julialang.org/t/using-arrow-dictencode/63788)

<div class="topic-metadata">

**Author:** [@jbshannon](https://discourse.julialang.org/u/jbshannon)\
**Replies:** 1\
**Last updated:** [June 30, 2021, 10:45pm UTC](https://discourse.julialang.org/t/using-arrow-dictencode/63788 "2021-06-30T22:45:47Z")

</div>

How exactly does the Arrow.DictEncode() method work? I’ve tried using it to signal that a DataFrame column be dictionary encoding when writing to a .arrow file, but I can’t see any indication that this works. I’ve looked…

---

## [\[Convex.jl\] Objective function of matrix factorization with missing data](https://discourse.julialang.org/t/convex-jl-objective-function-of-matrix-factorization-with-missing-data/34253)

<div class="topic-metadata">

**Author:** [@4aHxKzD](https://discourse.julialang.org/u/4aHxKzD)\
**Replies:** 21\
**Last updated:** [June 30, 2021, 3:05pm UTC](https://discourse.julialang.org/t/convex-jl-objective-function-of-matrix-factorization-with-missing-data/34253 "2021-06-30T15:05:27Z")

</div>

I’m trying to solve a matrix factorization problem with alternating minimization. My data matrix has missing entries and because of that I can not simply write my objective function as: # A is a n x m data matrix n, m…

---

## [Julia + Notebook memory leak](https://discourse.julialang.org/t/julia-notebook-memory-leak/63830)

<div class="topic-metadata">

**Author:** [@Xeos](https://discourse.julialang.org/u/Xeos)\
**Replies:** 2\
**Last updated:** [June 30, 2021, 2:41pm UTC](https://discourse.julialang.org/t/julia-notebook-memory-leak/63830 "2021-06-30T14:41:20Z")

</div>

Hi, I’ve started trying out jupyterlab with IJulia to see if I could free myself from some large data loading processes that take a lot of time at every run. The CSV I’m working on is decently large (2GB) which then ta…

---

## [Why do bigfloats allocate that much ? Could a native rewrite solve the problem?](https://discourse.julialang.org/t/why-do-bigfloats-allocate-that-much-could-a-native-rewrite-solve-the-problem/63809)

<div class="topic-metadata">

**Author:** [@lrnv](https://discourse.julialang.org/u/lrnv)\
**Replies:** 4\
**Last updated:** [June 30, 2021, 1:40pm UTC](https://discourse.julialang.org/t/why-do-bigfloats-allocate-that-much-could-a-native-rewrite-solve-the-problem/63809 "2021-06-30T13:40:29Z")

</div>

Hi. Everything is in the title: I dont think I understood why BigFloats allocate that much, and why nothing could be done about it. Is there some source, article or doc that explains this ? As @JeffreySarnoff showed in…

---

## [ModelingToolkit: troubles using ode\_order\_lowering (A differentiated state's operation must be a \`Sym\`)](https://discourse.julialang.org/t/modelingtoolkit-troubles-using-ode-order-lowering-a-differentiated-states-operation-must-be-a-sym/63716)

<div class="topic-metadata">

**Author:** [@zdenek\_hurak](https://discourse.julialang.org/u/zdenek_hurak)\
**Replies:** 1\
**Last updated:** [June 30, 2021, 11:56am UTC](https://discourse.julialang.org/t/modelingtoolkit-troubles-using-ode-order-lowering-a-differentiated-states-operation-must-be-a-sym/63716 "2021-06-30T11:56:25Z")

</div>

I am trying to model a simple mechanical chain composed of a few masses interconnected with springs and exposed to friction. Such model comes in the form of a few coupled second-order differential equations. These I mode…

---

## [Update parameters in ModelingToolkit using callbacks](https://discourse.julialang.org/t/update-parameters-in-modelingtoolkit-using-callbacks/63770)

<div class="topic-metadata">

**Author:** [@jairorua](https://discourse.julialang.org/u/jairorua)\
**Replies:** 12\
**Last updated:** [June 30, 2021, 8:19am UTC](https://discourse.julialang.org/t/update-parameters-in-modelingtoolkit-using-callbacks/63770 "2021-06-30T08:19:30Z")

</div>

Hello, I was trying to create a simple control loop with modelingtoolkit. The idea was to have a generic controller whose setpoint can be changed using callbacks during a dynamic simulation. For example: using Modelin…

---

## [reactionMechanismSimulator.jl idealGas() call fails due to no default for stoichmatrix](https://discourse.julialang.org/t/reactionmechanismsimulator-jl-idealgas-call-fails-due-to-no-default-for-stoichmatrix/61502)

<div class="topic-metadata">

**Author:** [@ziolai](https://discourse.julialang.org/u/ziolai)\
**Replies:** 7\
**Last updated:** [June 30, 2021, 6:51am UTC](https://discourse.julialang.org/t/reactionmechanismsimulator-jl-idealgas-call-fails-due-to-no-default-for-stoichmatrix/61502 "2021-06-30T06:51:04Z")

</div>

The basic example of idealGas in reactionMechanism.jl fails to due no default for stoichmatrix. Advice to fix is much appreciated. Thx! using ReactionMechanismSimulator phaseDict = readinput("src/superminimal.rms"…

---

## [Delaunay triangulation in best fit plane](https://discourse.julialang.org/t/delaunay-triangulation-in-best-fit-plane/63792)

<div class="topic-metadata">

**Author:** [@sparrowhawk](https://discourse.julialang.org/u/sparrowhawk)\
**Replies:** 0\
**Last updated:** [June 30, 2021, 2:42am UTC](https://discourse.julialang.org/t/delaunay-triangulation-in-best-fit-plane/63792 "2021-06-30T02:42:07Z")

</div>

Hi I have a set of points scattered in 3D x,y, z, with an associated scalar property f. But these points are very nearly planar, and I want the triangulation of f in a “best fit” plane, which I can then import as a VTK f…

---

## [Sub plus (₊) instead of dot in the dot notation in equations displayed by ModelingToolkit](https://discourse.julialang.org/t/sub-plus-instead-of-dot-in-the-dot-notation-in-equations-displayed-by-modelingtoolkit/61113)

<div class="topic-metadata">

**Author:** [@zdenek\_hurak](https://discourse.julialang.org/u/zdenek_hurak)\
**Replies:** 4\
**Last updated:** [June 29, 2021, 6:45pm UTC](https://discourse.julialang.org/t/sub-plus-instead-of-dot-in-the-dot-notation-in-equations-displayed-by-modelingtoolkit/61113 "2021-06-29T18:45:49Z")

</div>

I was just wondering what was the reason for displaying the MTK equations using (for example) capacitor₊n₊v instead of capacitor.n.v (as in the RC Circuit example). Couldn’t dots be used for displaying as well (when they…

---

## [Convex.jl matrix constraints interface : How can i supply this matrix?](https://discourse.julialang.org/t/convex-jl-matrix-constraints-interface-how-can-i-supply-this-matrix/63753)

<div class="topic-metadata">

**Author:** [@lrnv](https://discourse.julialang.org/u/lrnv)\
**Replies:** 2\
**Last updated:** [June 29, 2021, 5:32pm UTC](https://discourse.julialang.org/t/convex-jl-matrix-constraints-interface-how-can-i-supply-this-matrix/63753 "2021-06-29T17:32:36Z")

</div>

Hi, I want to constraint some matrix that is given as a linear functions of the variables to be semi-definite positive. However, I found something strange : function get\_hankels(s,a,b) m = length(s)-1 if iseven…

---

## [GLMakie Method error (Makie.image!)](https://discourse.julialang.org/t/glmakie-method-error-makie-image/63090)

<div class="topic-metadata">

**Author:** [@Jake](https://discourse.julialang.org/u/Jake)\
**Replies:** 9\
**Last updated:** [June 29, 2021, 1:22pm UTC](https://discourse.julialang.org/t/glmakie-method-error-makie-image/63090 "2021-06-29T13:22:14Z")

</div>

I am trying to duplicate the example on the VideoIO github page that uses Makie. My code is very similar to this example but using some cell phone video from a Blackberry Key2. using VideoIO using GLMakie path = strin…

---

## [Display image in Dash app](https://discourse.julialang.org/t/display-image-in-dash-app/63745)

<div class="topic-metadata">

**Author:** [@Aju](https://discourse.julialang.org/u/Aju)\
**Replies:** 0\
**Last updated:** [June 29, 2021, 12:05pm UTC](https://discourse.julialang.org/t/display-image-in-dash-app/63745 "2021-06-29T12:05:02Z")

</div>

Hello, I am currently building an app for image visualisation using Dash platform. But, I am unable to find the right graph to display the image, which could be a 2D array or 3D array with RGB channels. Here is a simple…

---

## [Hypergeometric functions](https://discourse.julialang.org/t/hypergeometric-functions/63621)

<div class="topic-metadata">

**Author:** [@marcobonici](https://discourse.julialang.org/u/marcobonici)\
**Replies:** 6\
**Last updated:** [June 29, 2021, 9:48am UTC](https://discourse.julialang.org/t/hypergeometric-functions/63621 "2021-06-29T09:48:29Z")

</div>

Hello, I need to evaluate the Gauss Hypergeometric functions \_2F\_1(a,b;c;z). Here are some specifications for the arguments of this function a has compex values. The real part is \\sim2 (and is strictly positive), whi…

---

## [What happens if I set more threads than available?](https://discourse.julialang.org/t/what-happens-if-i-set-more-threads-than-available/63717)

<div class="topic-metadata">

**Author:** [@fredih](https://discourse.julialang.org/u/fredih)\
**Replies:** 2\
**Last updated:** [June 29, 2021, 3:06am UTC](https://discourse.julialang.org/t/what-happens-if-i-set-more-threads-than-available/63717 "2021-06-29T03:06:16Z")

</div>

My computer has 8 cores, so use set\_optimizer\_attribute(myModel, "threads", 8) before starting the optimization. What would happen if I use the exact same code on another computer that has, for example, 4 cores? The prog…

---

## [Eigenvectors from quadratic form of a low-rank matrix](https://discourse.julialang.org/t/eigenvectors-from-quadratic-form-of-a-low-rank-matrix/63715)

<div class="topic-metadata">

**Author:** [@mleprovost](https://discourse.julialang.org/u/mleprovost)\
**Replies:** 2\
**Last updated:** [June 28, 2021, 10:07pm UTC](https://discourse.julialang.org/t/eigenvectors-from-quadratic-form-of-a-low-rank-matrix/63715 "2021-06-28T22:07:14Z")

</div>

Hello, I would like to compute the leading eigenvectors of a positive semi-definite matrix A with a low-rank structure. Are you aware of method that only rely on evaluations of y^\\top A x for arbitrary y, x vectors?

---

## [Center colorbar ticks in a categorical colorbar in Makie.jl](https://discourse.julialang.org/t/center-colorbar-ticks-in-a-categorical-colorbar-in-makie-jl/63691)

<div class="topic-metadata">

**Author:** [@Datseris](https://discourse.julialang.org/u/Datseris)\
**Replies:** 4\
**Last updated:** [June 28, 2021, 1:52pm UTC](https://discourse.julialang.org/t/center-colorbar-ticks-in-a-categorical-colorbar-in-makie-jl/63691 "2021-06-28T13:52:45Z")

</div>

MWE: using GLMakie xg = range(0, 10; length = 100) yg = range(0, 10; length = 100) bsn = rand(1:5, (100, 100)) fig = Figure(resolution = (700,600)) display(fig) colors = \[:black, :blue, :red, :teal, :yellow\] cmap = …

---

## [3D scatter with AlgebraOfGraphics.jl](https://discourse.julialang.org/t/3d-scatter-with-algebraofgraphics-jl/63686)

<div class="topic-metadata">

**Author:** [@juliohm](https://discourse.julialang.org/u/juliohm)\
**Replies:** 7\
**Last updated:** [June 28, 2021, 1:18pm UTC](https://discourse.julialang.org/t/3d-scatter-with-algebraofgraphics-jl/63686 "2021-06-28T13:18:50Z")

</div>

Is it possible to get a 3D scatter plot with AlgebraOfGraphics.jl? I tried it with data(df) \* mapping(:X, :Y, :Z) |\> draw but it only shows a 2D scatter as if the3rd argument :Z was ignored.

---

## [Help with constraints to select and/or insert columns to a matrix](https://discourse.julialang.org/t/help-with-constraints-to-select-and-or-insert-columns-to-a-matrix/63654)

<div class="topic-metadata">

**Author:** [@DrChainsaw](https://discourse.julialang.org/u/DrChainsaw)\
**Replies:** 3\
**Last updated:** [June 28, 2021, 10:48am UTC](https://discourse.julialang.org/t/help-with-constraints-to-select-and-or-insert-columns-to-a-matrix/63654 "2021-06-28T10:48:12Z")

</div>

I suppose this might be more of a generic MIP formulation question, but I’m not sure stackexchange would accept it and in here I can at least provide some almost working code using JuMP. Simple context free question is …

---

## [Drawing a median line in a histogram in Makie](https://discourse.julialang.org/t/drawing-a-median-line-in-a-histogram-in-makie/63359)

<div class="topic-metadata">

**Author:** [@ericphanson](https://discourse.julialang.org/u/ericphanson)\
**Replies:** 5\
**Last updated:** [June 28, 2021, 10:14am UTC](https://discourse.julialang.org/t/drawing-a-median-line-in-a-histogram-in-makie/63359 "2021-06-28T10:14:33Z")

</div>

I can’t figure out a non-manual way to do this: mwe\_fig = let fig = Figure() data = randn(1000) .+ 1 ax = Axis(fig\[1,1\]; xlabel="Value", ylabel="Count") hist!(ax, data) m = median(data) m\_color = Makie.wong\_colors…

---

## [Weights update in Flux](https://discourse.julialang.org/t/weights-update-in-flux/63657)

<div class="topic-metadata">

**Author:** [@Mariana](https://discourse.julialang.org/u/Mariana)\
**Replies:** 2\
**Last updated:** [June 28, 2021, 9:24am UTC](https://discourse.julialang.org/t/weights-update-in-flux/63657 "2021-06-28T09:24:16Z")

</div>

Hello! I am trying to use Flux to train a neural network but, in this case I don’t have the target values for the output. I will try to formulate a simpler version of my problem. Suppose I have an input input = \[0.8 0…

---

## [Get a legend with twinx()](https://discourse.julialang.org/t/get-a-legend-with-twinx/63672)

<div class="topic-metadata">

**Author:** [@Paolo\_Jara](https://discourse.julialang.org/u/Paolo_Jara)\
**Replies:** 1\
**Last updated:** [June 28, 2021, 8:39am UTC](https://discourse.julialang.org/t/get-a-legend-with-twinx/63672 "2021-06-28T08:39:50Z")

</div>

Hi, I’m using the twinx () command, is there a way to have both labels in the same legend? using Plots x12=randn(10) y12=1000\*randn(10) plot(x12, label="x12") plot!(twinx(), y12, c=:red, legend=:bottomleft, label="y12")…

---

## [Round CategoricalArrays.cut labels](https://discourse.julialang.org/t/round-categoricalarrays-cut-labels/63674)

<div class="topic-metadata">

**Author:** [@jzr](https://discourse.julialang.org/u/jzr)\
**Replies:** 1\
**Last updated:** [June 28, 2021, 7:09am UTC](https://discourse.julialang.org/t/round-categoricalarrays-cut-labels/63674 "2021-06-28T07:09:47Z")

</div>

How can I round the labels to two digits without changing anything else? using CategoricalArrays cut(rand(5), 2, labels=((from, to, i;kw...)-\>"$(round(from, digits=2))-$(round(to, digits=2))")) ERROR: MethodError: no m…

---

## [First CUDA Program- Addressing Scalar Indexing](https://discourse.julialang.org/t/first-cuda-program-addressing-scalar-indexing/63396)

<div class="topic-metadata">

**Author:** [@loki](https://discourse.julialang.org/u/loki)\
**Replies:** 5\
**Last updated:** [June 28, 2021, 5:50am UTC](https://discourse.julialang.org/t/first-cuda-program-addressing-scalar-indexing/63396 "2021-06-28T05:50:41Z")

</div>

Hello, I am trying to get my feet wet in the world of CUDA programming. I started with some CPU code that I previously written but have been having some trouble with Scalar Indexing slowing down the computation. The prob…

---

## [JuMP optimization with vector input and analytical gradient](https://discourse.julialang.org/t/jump-optimization-with-vector-input-and-analytical-gradient/63664)

<div class="topic-metadata">

**Author:** [@nicolas](https://discourse.julialang.org/u/nicolas)\
**Replies:** 5\
**Last updated:** [June 27, 2021, 10:58pm UTC](https://discourse.julialang.org/t/jump-optimization-with-vector-input-and-analytical-gradient/63664 "2021-06-27T22:58:11Z")

</div>

In JuMP’s manual, there are simple instructions to either optimize by providing an analytical gradient function or by providing a vector input with splatting: Nonlinear Modeling · JuMP. I have been trying to combine the …

---

## [Can't get a user defined function to work in my Turing Model specification](https://discourse.julialang.org/t/cant-get-a-user-defined-function-to-work-in-my-turing-model-specification/63487)

<div class="topic-metadata">

**Author:** [@DoktorMike](https://discourse.julialang.org/u/DoktorMike)\
**Replies:** 6\
**Last updated:** [June 27, 2021, 8:02am UTC](https://discourse.julialang.org/t/cant-get-a-user-defined-function-to-work-in-my-turing-model-specification/63487 "2021-06-27T08:02:56Z")

</div>

I have this simple Turing model which I cannot get to work. The full MWE is given below. using Turing, Distributions function myfilter(x::AbstractVector, λ) xnew = x xnew\[1\] = x\[1\] for i in 2:length(x) …

---

## [Export just the plotting area with Makie](https://discourse.julialang.org/t/export-just-the-plotting-area-with-makie/63629)

<div class="topic-metadata">

**Author:** [@EvoArt](https://discourse.julialang.org/u/EvoArt)\
**Replies:** 2\
**Last updated:** [June 27, 2021, 6:37am UTC](https://discourse.julialang.org/t/export-just-the-plotting-area-with-makie/63629 "2021-06-27T06:37:30Z")

</div>

Is it possible to save just the plotting area as a PDF from Cairo Makie? Hiding decorations and spines gets close. But there is still a small border around the output.

---

## [Fastest plotting library?](https://discourse.julialang.org/t/fastest-plotting-library/62018)

<div class="topic-metadata">

**Author:** [@Iulian.Cioarca](https://discourse.julialang.org/u/Iulian.Cioarca)\
**Replies:** 53\
**Last updated:** [June 26, 2021, 6:35pm UTC](https://discourse.julialang.org/t/fastest-plotting-library/62018 "2021-06-26T18:35:10Z")

</div>

I need to generate a lot of plots(thousands) and save them to disk as png. Nothing fancy, just some scatter plots with legend, preferably with the option to adjust the resolution(number of points per plot is less than 10…

[Previous page](https://discourse.julialang.org/c/domain/10.md?page=354)

[Next page](https://discourse.julialang.org/c/domain/10.md?page=356)
