Vector of Vectors: Type Issue and Tuple Question
I am trying to understand the difference between the two ways I found to create a vector of vectors below. I found Option 1 in this post, which works nicely but isn’t very customizable. Option 2 also...
View ArticleGetting started with Julia and Robotics Projects
Hello, I am a recent mechanical engineering graduate and discovered Julia online. I am interested in simulating and optimizing some custom robotics designs and wanted some input from people who are...
View ArticleNot defined error
Sooooo confusing using Julia I don’t understand why the following simple codes doesn’t work at all with error message AbstractGlidingVehicle not defined. Even my other custom package is similarly...
View ArticleProblems with Lathe TrainTestSplit
I am attempting to use Lathe for Linear Regression but unfortunately the documentation is unreachable (webpage lathe.ai/docs/ returns an error). All the tutorials that I have seen about it (e.g. here)...
View ArticleWhat are lower bounds for types?
I’m trying to understand what lower bounds are for types. I ran the following code which shows which subtypes (recursively) of number satisfies/rejects Int <: T <: Real in hope of gaining an...
View ArticleUsing union() and list comprehesions
I have two-element array whose elements are Sets, x = [ Set([:a,:b,:c]), Set([:c]) ], I would like to make union of the array elements as one resulting set, Set([:a, :b, :c]). I am having issue with...
View ArticleCall a constructor by interpolation
I need to programmatically initialize an empty DataFrame using a vector of names and a vector of types: Here is an example of doing this explicitly: DataFrame(mystrings=String[],myints=Int64[]) 0×2...
View ArticleHow to add a row to DataFrame where one field is missing
The MWE below tries to add a row to a DataFrame where some rows have missing values: tps = [String,Int64,Int64] nms = ["str","int","int2"] df = DataFrame(tps,nms) data =...
View ArticleProgramming numeric simulations of thermodynamic systems in Julia
Hi Julia Community, I’m really new to the Julia language and this is my first post in the forum. Moreover english is not my mother tongue, so I hope you can understand my question and help me to...
View ArticleWhat is the type 'Method' and where is it defined?
The @which macro returns a mutable composite type Method. Is this documented anywhere and how do I find the source code for it? I guess it is part of the Julia internals since the usual ways of...
View ArticleEnvironment and PackageCompiler.jl
Is PackageCompiler.jl works depending on which environment is activated? For example, precompiling package A.jl at default env. with replace_default=true option would not affect the same package A.jl...
View ArticleAre custom sysimages cross-platform for the same Julia version?
Hi all, I was wondering the sysimages of PackageCompiler are they cross-platform for the same Julia version? Furthermore (and related) do the sysimages contain lowered LLVM code or do they actually...
View ArticleType alias or newtype wrapper?
Hi! I am writing a small from-scratch ray tracer to get myself acquainted with julia. I’ve defined a color type as struct Color r::UInt8 g::UInt8 b::UInt8 end What would be the most idiomatic...
View ArticleIs it proper practice to have a main method
I’m learning Julia, and right now I’m only working with one file, let’s call it main.jl. Is it proper practice to include a main method, as outlined here? I found this thread from last year, but for...
View ArticleBinning a 2D array
Hi, I am trying to apply my understanding of image binning in Julia (which at its heart is an operation that needs to be performed on a 2D array) . To that end I created a toy array julia> a =...
View ArticleNot able to capture variable (via symbol) from outer scope?
I have the following minimal example: function foo() myvar1 = 55 function bar() println(myvar1) #<- OK s = Symbol("myvar", 1) println(@eval $s) # <-ERROR: LoadError: UndefVarError: myvar1 not...
View ArticleArray of tuples into a pure array of integers
New to Julia from Python so I am not used to all of these types, sorry if this is super simple but I have had no luck in my google searches. Can someone help me turn an array of tuples into a pure...
View ArticleCurrent situation using GLWF/modernGL/shaders
after a couple of years successfully using Julia0.7 to prototype a software to model a painter’s creative process by using my own custom bindings to openGL1.0 using free glut I would like to explore...
View ArticleGlobal sensitivity analysis - Morris Analysis
I am new to Julia and I am looking for a way to do Morris analysis on an system of ODEs. I would like to get a analysis as time series. Additionally, I would like to get the tested parameters to use...
View ArticleIs there a CLI tool?
Hi, so I’m trying to figure out a proper workflow for Julia. Apparently, a lot of people use Juypter Notebooks or the Julia REPL directly in the terminal to code. I have no idea how either one of...
View Article