# New to Julia

**URL:** https://discourse.julialang.org/c/first-steps/8.md?page=68

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

**Page:** 69

---

## [Very slow loading speed of TIFF images](https://discourse.julialang.org/t/very-slow-loading-speed-of-tiff-images/99826)

<div class="topic-metadata">

**Author:** [@Kadii](https://discourse.julialang.org/u/Kadii)\
**Replies:** 15\
**Last updated:** [October 3, 2023, 1:07am UTC](https://discourse.julialang.org/t/very-slow-loading-speed-of-tiff-images/99826 "2023-10-03T01:07:09Z")

</div>

I’m very new to Julia. I’m trying to replace my Matlab code with Julia. I compared TIFF image loading speeds in Matlab and Julia, but the Matlab’s imread() is way faster than the Images’ load(). Is there any way to speed…

---

## [Replace all values greater than 1 in a DataFrame with 1](https://discourse.julialang.org/t/replace-all-values-greater-than-1-in-a-dataframe-with-1/104397)

<div class="topic-metadata">

**Author:** [@aadam](https://discourse.julialang.org/u/aadam)\
**Replies:** 10\
**Last updated:** [October 1, 2023, 12:40pm UTC](https://discourse.julialang.org/t/replace-all-values-greater-than-1-in-a-dataframe-with-1/104397 "2023-10-01T12:40:10Z")

</div>

What’s the most idiomatic way of achieving this in Julia? Can this be done as a one-liner? Something like this: df\[df.\> 0\] .= 1

---

## [Using varinfo() very slow when there is 3d data in the struct structure](https://discourse.julialang.org/t/using-varinfo-very-slow-when-there-is-3d-data-in-the-struct-structure/104454)

<div class="topic-metadata">

**Author:** [@13299118606](https://discourse.julialang.org/u/13299118606)\
**Replies:** 0\
**Last updated:** [October 1, 2023, 7:34am UTC](https://discourse.julialang.org/t/using-varinfo-very-slow-when-there-is-3d-data-in-the-struct-structure/104454 "2023-10-01T07:34:23Z")

</div>

There is a bug in using varinfo when there is three-dimensional data in the struct structure. When there is 3d data inside the structure, it will greatly slow down the corresponding response speed when using varinfo. The…

---

## [How to call the original Base.show function extended in DataFrames.jl while overriding it?](https://discourse.julialang.org/t/how-to-call-the-original-base-show-function-extended-in-dataframes-jl-while-overriding-it/104437)

<div class="topic-metadata">

**Author:** [@raythurnevoid](https://discourse.julialang.org/u/raythurnevoid)\
**Replies:** 3\
**Last updated:** [October 1, 2023, 3:52am UTC](https://discourse.julialang.org/t/how-to-call-the-original-base-show-function-extended-in-dataframes-jl-while-overriding-it/104437 "2023-10-01T03:52:55Z")

</div>

I’m using the DataFrames.jl package and I want to change the default behavior of show(), I want to print all the rows and columns without passing additional arguments because I want it to work seamlessly while calling di…

---

## [How to make GLMakie observables work](https://discourse.julialang.org/t/how-to-make-glmakie-observables-work/104445)

<div class="topic-metadata">

**Author:** [@ollie\_d](https://discourse.julialang.org/u/ollie_d)\
**Replies:** 1\
**Last updated:** [October 1, 2023, 3:44am UTC](https://discourse.julialang.org/t/how-to-make-glmakie-observables-work/104445 "2023-10-01T03:44:11Z")

</div>

Still really struggling to get anything done with glmakie using GLMakie points = Observable(Point2f) push!(points, Point2f(1.0,1.0)) fig = Figure() ax = Axis(fig\[1,1\]) scatter(points, markersize = 40) push!(points,…

---

## [\`range\` of \`DateTime\`s](https://discourse.julialang.org/t/range-of-datetime-s/29060)

<div class="topic-metadata">

**Author:** [@aplavin](https://discourse.julialang.org/u/aplavin)\
**Replies:** 13\
**Last updated:** [September 30, 2023, 6:05pm UTC](https://discourse.julialang.org/t/range-of-datetime-s/29060 "2023-09-30T18:05:25Z")

</div>

I want to create a uniformly-spaced range of DateTime values with e.g. 100 points between two given values. range function doesn’t work for me: range(DateTime(2000, 1, 1, 0, 0), DateTime(2000, 1, 2, 0, 0), length=100) gi…

---

## [Unexpected behavior when assigning value to variable compared to using the value itself](https://discourse.julialang.org/t/unexpected-behavior-when-assigning-value-to-variable-compared-to-using-the-value-itself/104414)

<div class="topic-metadata">

**Author:** [@Michael\_Hess](https://discourse.julialang.org/u/Michael_Hess)\
**Replies:** 1\
**Last updated:** [September 29, 2023, 10:26pm UTC](https://discourse.julialang.org/t/unexpected-behavior-when-assigning-value-to-variable-compared-to-using-the-value-itself/104414 "2023-09-29T22:26:32Z")

</div>

Hello, I am still pretty new to Julia, so I’m sure this is a silly question, but I am having a hard time searching for an explanation. I am seeing some strange behavior I was hoping someone could clarify for me. Essent…

---

## [\`NaN\` in Statistical Hypothesis Testing](https://discourse.julialang.org/t/nan-in-statistical-hypothesis-testing/104380)

<div class="topic-metadata">

**Author:** [@Sahil\_Khan](https://discourse.julialang.org/u/Sahil_Khan)\
**Replies:** 2\
**Last updated:** [September 29, 2023, 1:15pm UTC](https://discourse.julialang.org/t/nan-in-statistical-hypothesis-testing/104380 "2023-09-29T13:15:20Z")

</div>

How can we ignore missing values or NaN during testing? A = \[0.1, NaN, 0.16\] B = \[1.0, 0.9, 0.82\] EqualVarianceTTest(A, B) output: Two sample t-test (equal variance) ---------------------------------- Population deta…

---

## [Help in introduction to julia course](https://discourse.julialang.org/t/help-in-introduction-to-julia-course/104379)

<div class="topic-metadata">

**Author:** [@bagge](https://discourse.julialang.org/u/bagge)\
**Replies:** 2\
**Last updated:** [September 29, 2023, 8:00am UTC](https://discourse.julialang.org/t/help-in-introduction-to-julia-course/104379 "2023-09-29T08:00:49Z")

</div>

Hi. In the plotting exercise 8.1 I get an error method I do not understand. Exercises 8.1 Given x = -10:10 plot y vs. x for y = x² When I try the following I get an error: x = -10:10 y = x ^ 2 MethodError: no meth…

---

## [Running 'scatter' from withing a function does nothing](https://discourse.julialang.org/t/running-scatter-from-withing-a-function-does-nothing/104366)

<div class="topic-metadata">

**Author:** [@ollie\_d](https://discourse.julialang.org/u/ollie_d)\
**Replies:** 8\
**Last updated:** [September 29, 2023, 4:48am UTC](https://discourse.julialang.org/t/running-scatter-from-withing-a-function-does-nothing/104366 "2023-09-29T04:48:24Z")

</div>

I’ve made a function to start my simulation. If I run the line scatter(x,y) outside of the function it works fine and new dots appear. Within the function it runs but nothing appears. Do I always have to start the plot f…

---

## [\`+\` not defined!?](https://discourse.julialang.org/t/not-defined/104288)

<div class="topic-metadata">

**Author:** [@ollie\_d](https://discourse.julialang.org/u/ollie_d)\
**Replies:** 9\
**Last updated:** [September 28, 2023, 6:39pm UTC](https://discourse.julialang.org/t/not-defined/104288 "2023-09-28T18:39:02Z")

</div>

I’m new to Julia but this error message has me thinking its not even worth trying. This code: using Plots x= 2.0 y=9.0 dx = 0.1 dy = -0.1 plot((x,y), xlim = (0,10.0), ylim = (0,10.0), markershape=:o) function u…

---

## [ERROR: LAPACKException(4)](https://discourse.julialang.org/t/error-lapackexception-4/104301)

<div class="topic-metadata">

**Author:** [@Sahil\_Khan](https://discourse.julialang.org/u/Sahil_Khan)\
**Replies:** 0\
**Last updated:** [September 27, 2023, 8:13am UTC](https://discourse.julialang.org/t/error-lapackexception-4/104301 "2023-09-27T08:13:36Z")

</div>

Can someone explain what this error is about? and what could be possible solution? I can’t share my model but it is differential equations based and have equations such du\[1\] = a\*(b)^n \* c\*(k)^m + a\*b. So, it contains e…

---

## [Error in nonmutating ODE function inside Turing (but mutating version not working beyond toy example)](https://discourse.julialang.org/t/error-in-nonmutating-ode-function-inside-turing-but-mutating-version-not-working-beyond-toy-example/104244)

<div class="topic-metadata">

**Author:** [@caesoma](https://discourse.julialang.org/u/caesoma)\
**Replies:** 13\
**Last updated:** [September 27, 2023, 12:50pm UTC](https://discourse.julialang.org/t/error-in-nonmutating-ode-function-inside-turing-but-mutating-version-not-working-beyond-toy-example/104244 "2023-09-27T12:50:00Z")

</div>

Hi, all, I I am trying to implement Turing HMC/NUTS inference of parameters from a model of coupled ODEs. Simulating that model works without issue, and I believe its details are not relevant (at a first pass, at least)…

---

## [CSV.read seems to expect at least 2 columns](https://discourse.julialang.org/t/csv-read-seems-to-expect-at-least-2-columns/104249)

<div class="topic-metadata">

**Author:** [@Axze-rgb](https://discourse.julialang.org/u/Axze-rgb)\
**Replies:** 12\
**Last updated:** [September 26, 2023, 10:39am UTC](https://discourse.julialang.org/t/csv-read-seems-to-expect-at-least-2-columns/104249 "2023-09-26T10:39:43Z")

</div>

Hello, I am using CSV.read to load a single column dataframe. Here is the command: df\_MQBZ=CSV.read(“MQBZ.hist”, DataFrame, header=false) That works but here is the result \> Column1 Column2 Missing String15 1 mis…

---

## [What visualisation library for cloth/physics sim](https://discourse.julialang.org/t/what-visualisation-library-for-cloth-physics-sim/104183)

<div class="topic-metadata">

**Author:** [@ollie\_d](https://discourse.julialang.org/u/ollie_d)\
**Replies:** 2\
**Last updated:** [September 25, 2023, 9:59pm UTC](https://discourse.julialang.org/t/what-visualisation-library-for-cloth-physics-sim/104183 "2023-09-25T21:59:40Z")

</div>

Sorry for the basic question. I want to make a cloth sim in 2d and then 3d and was wondering which package I should be using to display points and lines? Do i just use plots or is there something more suitable? thanks

---

## [MATLAB/Simulink model simulation and modeling with s-functions and variable-step solver](https://discourse.julialang.org/t/matlab-simulink-model-simulation-and-modeling-with-s-functions-and-variable-step-solver/104220)

<div class="topic-metadata">

**Author:** [@alparg-mv](https://discourse.julialang.org/u/alparg-mv)\
**Replies:** 19\
**Last updated:** [September 25, 2023, 5:25pm UTC](https://discourse.julialang.org/t/matlab-simulink-model-simulation-and-modeling-with-s-functions-and-variable-step-solver/104220 "2023-09-25T17:25:44Z")

</div>

As a 10+ year old company working on HVAC system modeling on MATLAB/Simulink, we would like to transition to Julia for faster simulation and modeling of our Simulink model, where we also plan to accelerate the Simulation…

---

## [Gradient accumulation using chainrulecore](https://discourse.julialang.org/t/gradient-accumulation-using-chainrulecore/104208)

<div class="topic-metadata">

**Author:** [@mary](https://discourse.julialang.org/u/mary)\
**Replies:** 1\
**Last updated:** [September 25, 2023, 2:20pm UTC](https://discourse.julialang.org/t/gradient-accumulation-using-chainrulecore/104208 "2023-09-25T14:20:15Z")

</div>

Hi, I am using chainrulecore and zygote and rrule to define my accumulation derivation formulation. the derivative of my function is ∑\_(i=1)^n▒〖w^t da/dr u〗 in order to solve this i have defined below code. Note that…

---

## [Multiple shooting and neural ode in Rc models](https://discourse.julialang.org/t/multiple-shooting-and-neural-ode-in-rc-models/104013)

<div class="topic-metadata">

**Author:** [@Marco\_Nesta](https://discourse.julialang.org/u/Marco_Nesta)\
**Replies:** 3\
**Last updated:** [September 25, 2023, 12:54pm UTC](https://discourse.julialang.org/t/multiple-shooting-and-neural-ode-in-rc-models/104013 "2023-09-25T12:54:27Z")

</div>

Good morning everyone, I am working on using neural ode the optimization of RC models for house consumption. In the following code I have defined a first state where P and T are exogenous variables. could you give me ad…

---

## [DateTime Curiosity: Dates.epochms2datetime](https://discourse.julialang.org/t/datetime-curiosity-dates-epochms2datetime/104205)

<div class="topic-metadata">

**Author:** [@g-gundam](https://discourse.julialang.org/u/g-gundam)\
**Replies:** 5\
**Last updated:** [September 25, 2023, 8:45am UTC](https://discourse.julialang.org/t/datetime-curiosity-dates-epochms2datetime/104205 "2023-09-25T08:45:08Z")

</div>

I’m new to Julia but not new to programming, and I’m wondering why Dates.epochms2datetime returned a negative value. using Dates unix\_0 = unix2datetime(0) # 1970-01-01T00:00:00 # So far, so good. Dates.value(unix\_0) #…

---

## [Using zygote for a summation derivation](https://discourse.julialang.org/t/using-zygote-for-a-summation-derivation/104192)

<div class="topic-metadata">

**Author:** [@mary](https://discourse.julialang.org/u/mary)\
**Replies:** 0\
**Last updated:** [September 24, 2023, 6:42am UTC](https://discourse.julialang.org/t/using-zygote-for-a-summation-derivation/104192 "2023-09-24T06:42:22Z")

</div>

Hi, I am using zygote and rrule to define my derivation formulation. the derivative of my function is df/dr = sum1st to Nth step(w^T \* da/dr) in order to solve this i have defined below code. Note that i saved all val…

---

## [Julia Discourse advice](https://discourse.julialang.org/t/julia-discourse-advice/104150)

<div class="topic-metadata">

**Author:** [@aikimark](https://discourse.julialang.org/u/aikimark)\
**Replies:** 5\
**Last updated:** [September 22, 2023, 9:47pm UTC](https://discourse.julialang.org/t/julia-discourse-advice/104150 "2023-09-22T21:47:17Z")

</div>

I’m new here and still learning Julia. I want to contribute to Lilith Hafner’s Scratch Quicksort code as a first step in helping the Julia language/community. Before I start my coding, I wanted to ask some questions. …

---

## [Best way to drop an entry of a CartesianIndex?](https://discourse.julialang.org/t/best-way-to-drop-an-entry-of-a-cartesianindex/104127)

<div class="topic-metadata">

**Author:** [@jeffreyesun](https://discourse.julialang.org/u/jeffreyesun)\
**Replies:** 4\
**Last updated:** [September 22, 2023, 3:07pm UTC](https://discourse.julialang.org/t/best-way-to-drop-an-entry-of-a-cartesianindex/104127 "2023-09-22T15:07:09Z")

</div>

Out of curiosity, what is the best way to drop one entry of an idx::CartesianIndex? Or, generally, to access a slice of it. It’s forbidden to do idx\[2:5\], so right now I’m doing: CartesianIndex(Tuple(idx)\[2:5\]). Just c…

---

## [Issue with saving plot as pdf](https://discourse.julialang.org/t/issue-with-saving-plot-as-pdf/104147)

<div class="topic-metadata">

**Author:** [@Sahil\_Khan](https://discourse.julialang.org/u/Sahil_Khan)\
**Replies:** 3\
**Last updated:** [September 22, 2023, 2:47pm UTC](https://discourse.julialang.org/t/issue-with-saving-plot-as-pdf/104147 "2023-09-22T14:47:41Z")

</div>

yerror bar in plot generated on vs code shows different level of thickness for yerror bar in comparision to saved pdf file. In vs code : In pdf format: (you can notice thickness has increased) In png format (it …

---

## [Problems with installing jupyter via miniconda](https://discourse.julialang.org/t/problems-with-installing-jupyter-via-miniconda/104145)

<div class="topic-metadata">

**Author:** [@SirTill](https://discourse.julialang.org/u/SirTill)\
**Replies:** 1\
**Last updated:** [September 22, 2023, 12:16pm UTC](https://discourse.julialang.org/t/problems-with-installing-jupyter-via-miniconda/104145 "2023-09-22T12:16:00Z")

</div>

Hello guys! I wanted to install jupyter for jupyter notebooks using IJulia. I successfully added IJulia, but when I try notebook()it first asks me, to install jupyter via Conda. If I say yes, the process stops and I get…

---

## [Is the doc of VegaLote.jl up to date?](https://discourse.julialang.org/t/is-the-doc-of-vegalote-jl-up-to-date/104125)

<div class="topic-metadata">

**Author:** [@Axze-rgb](https://discourse.julialang.org/u/Axze-rgb)\
**Replies:** 4\
**Last updated:** [September 21, 2023, 10:27pm UTC](https://discourse.julialang.org/t/is-the-doc-of-vegalote-jl-up-to-date/104125 "2023-09-21T22:27:40Z")

</div>

Hello, I have asked this before but as a late edit in a thread . Therefore I thought I might as well make a dedicated thread. I have compared vegalite and glmakie and settled fot vegalite, I found Makie harder. Anyway, …

---

## [Vegalite plot, facetting with different x scales for each row](https://discourse.julialang.org/t/vegalite-plot-facetting-with-different-x-scales-for-each-row/104111)

<div class="topic-metadata">

**Author:** [@Axze-rgb](https://discourse.julialang.org/u/Axze-rgb)\
**Replies:** 0\
**Last updated:** [September 21, 2023, 2:22pm UTC](https://discourse.julialang.org/t/vegalite-plot-facetting-with-different-x-scales-for-each-row/104111 "2023-09-21T14:22:28Z")

</div>

Hello, I am plotting some features alongside 6 different chromosomes; each chromosome has a different length. The dataframe looks like this: chromosome position count String7 Int64 Int64 1 “Chrom\_3” 10000 68 2 “Chr…

---

## [Saving update state output](https://discourse.julialang.org/t/saving-update-state-output/103962)

<div class="topic-metadata">

**Author:** [@mary](https://discourse.julialang.org/u/mary)\
**Replies:** 7\
**Last updated:** [September 21, 2023, 5:35am UTC](https://discourse.julialang.org/t/saving-update-state-output/103962 "2023-09-21T05:35:25Z")

</div>

Hi I am using below function to compare a scalar value and then use update state to update the inputs of function and get the updated value. function new\_EnergyState(ψPlusPrev\_in,ψhPos\_in) ψPlus\_in = ψhPos\_in i…

---

## [Trying to get an Expr from a type](https://discourse.julialang.org/t/trying-to-get-an-expr-from-a-type/103865)

<div class="topic-metadata">

**Author:** [@jeffreyesun](https://discourse.julialang.org/u/jeffreyesun)\
**Replies:** 6\
**Last updated:** [September 20, 2023, 5:33pm UTC](https://discourse.julialang.org/t/trying-to-get-an-expr-from-a-type/103865 "2023-09-20T17:33:44Z")

</div>

Hi all. I have a variable bar::DataType and I want to get the expression of that datatype, as follows. bar = Foo{T} Expr(bar) # :(Foo{T}). However, this gives an error, and I cannot seem to get it through interpolation…

---

## [Is array/vector handling this hard?](https://discourse.julialang.org/t/is-array-vector-handling-this-hard/104035)

<div class="topic-metadata">

**Author:** [@voroskoi](https://discourse.julialang.org/u/voroskoi)\
**Replies:** 14\
**Last updated:** [September 20, 2023, 4:57pm UTC](https://discourse.julialang.org/t/is-array-vector-handling-this-hard/104035 "2023-09-20T16:57:51Z")

</div>

Hi, I just started learning Julia and I try to solve some basic ML tasks. It is quite common to generate a vector of indices for the training data and I would like to generate the complement. For example I have a Vecto…

---

## [DataFrame Filtering](https://discourse.julialang.org/t/dataframe-filtering/104066)

<div class="topic-metadata">

**Author:** [@Sahil\_Khan](https://discourse.julialang.org/u/Sahil_Khan)\
**Replies:** 10\
**Last updated:** [September 20, 2023, 3:25pm UTC](https://discourse.julialang.org/t/dataframe-filtering/104066 "2023-09-20T15:25:43Z")

</div>

In following example I want to filter few things specific from both column at same time. I can get end result that I showed below by filtering separately and then I can combine to get end DataFrame but it doesn’t feel ri…

[Previous page](https://discourse.julialang.org/c/first-steps/8.md?page=67)

[Next page](https://discourse.julialang.org/c/first-steps/8.md?page=69)
