Collect(a) vs. [a;]
Hi, I don’t get the difference between collect(a) and [a;] for ranges. julia> typeof(collect(5:7)) === typeof([5:7;]) true julia> collect(5:7) == [5:7;] true julia> collect(5:7) 3-element...
View ArticleReading images in HTTP doesn't seem to terminate
using HTTP using Colors # initialize to nothing orig_img = nothing using ImageMagick HTTP.listen() do http::HTTP.Stream global orig_img @show http.message @show HTTP.header(http, "Content-Type") while...
View ArticleTurn off warning from `Mosek` while using `Convex.jl`
Hi, I’m using Mosek as a solver of Convex.jl to solve convex problems. While solving problems, it quite often says warnings like MOSEK warning 705: #4 (nearly) zero elements are specified in sparse...
View ArticleEnsembleProblem change tstops for each trajectory
Hey, I’am trying to use the EnsembleProblem to run an ODE with a big parameter set. Following the problem in the documentation (https://diffeq.sciml.ai/stable/features/callback_functions/ example 1) I...
View ArticleModule with state - how to implement?
I would like to have a module with state: when I’m working in the repl, I load the module and its state is “empty”; as I use the module’s constructors to instantiate variables of a certain type...
View ArticleJuliaFEM cannot be precompiled
Hi julia experts, I installed and built JuliaFEM right after installing Julia1.5 but when I type ‘using JuliaFEM’, I got error: ERROR:LoadError:LoadError:Evaluation into the closed module ‘Calculus’...
View ArticleSluggish Julia start on Win 10. Is it just me? [video] to show
It takes me almost 1 minute to get working! 2 posts - 2 participants Read full topic
View ArticleHDF5: varying size dataset
I’m struggle with using HDF5. I’m trying to append data in .h5 file. So, I wanna make a dataset whose prescribed size is unlimited (on the first axis, specifically). For example, receiving data with...
View ArticleArchitecture: general module and specific module
I guess I am lacking knowledge of design patterns, can someone suggest the right solution (common in Julia) to set of specific modules that reexport general module functionality with one argument...
View ArticleOpen new window for each plot
Hi, how can I make sure I get a new window for each plot when using the Plots package? E.g. if we have p1 = getPlotOne() p2 = getPlotTwo() How do I now get two separate windows? 3 posts - 3...
View ArticleAny good functions to show the structure of an object like...
I tried including Juno in my list of packages but it makes start up so slow! Like 50s. But I only want to use the structure function. I am tempted to rip out just the structure function and make it...
View ArticleHow to select top 5 results per group in dataframe?
I’m looking for a Julian way of selecting a subset of each group. I have a DataFrame with (among others) two columns, say name and length. I want to group over all names and pick the 5 tallest people...
View ArticleUnable to install IJulia
I have installed the latest version of Julia (1.5.1) on my widows browser successfully and am now trying to create the IJulia notebook functionality. I ran the following commands: Import Pkg which...
View ArticleHosting interactive pluto notebook on web/Github
Hello. I’m very new to Julia. I did dabble with it about 3 years ago, but only in the last week have I decided to work much more with it. I’m a very long time R user. I have been working through the...
View ArticlePackage development with or without own environment?
I find it a bit hard to understand environments in relation to package development. If I develop a fairly simple package and mostly want others to just clone (may register later) and use it, is there...
View ArticleContour plots on non-rectangular domain
Is there any way to use the contour and contourf commands from the Plots.jl package to produce figures with non-rectangular domains? Or what would be the most flexible/complete alternative? Suppose I...
View ArticleFixing problems with my plot
Hello! I have a plot which currently looks like: There are something I would like to change about it, which I cannot figure out how to do: Make x and y axis “intersect”, so it does not say “0” twice...
View ArticleCreating a struct with 1D length using unitful.jl
I’m trying to build a data type to hold a measurements of a quantity. I know that this quantity will be a length, but don’t know a priori what unit that length will be. I’m having a bit of trouble...
View ArticleAny difference between : or , in the SubString() method?
introduction = "Hello World" standard_greeting = SubString(introduction, 1:5) println(standard_greeting) # Will print Hello. standard_greeting = SubString(introduction, 1,5) println(standard_greeting)...
View ArticleDispatch on Unicode categories
Hi, I’ve been using Python for a long time and am starting to learn Julia a bit by going through the MIT course as well as Exercism exercises. I recently came across a simple ROT13 exercise in...
View Article