diff --git a/docs/src/comparisons/bioconductor.md b/docs/src/comparisons/bioconductor.md index 44eba2e..4aa4a10 100644 --- a/docs/src/comparisons/bioconductor.md +++ b/docs/src/comparisons/bioconductor.md @@ -9,15 +9,15 @@ * Packages cover a broard range of methods for the analysis and manipulation of genomic data -**A few equivalent applications between BioJulia and Bioconductor:** +**A few similar applications between BioJulia and Bioconductor:** -| Application | BioJulia packages | Bioconductor packages | -|:--------------------|:-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|:----------------------------------------| -| Data structures | [BioSymbols](https://biojulia.dev/BioSymbols.jl/stable/), [KmerAnalysis](https://github.com/BioJulia/KmerAnalysis.jl), [IntervalTrees](https://biojulia.dev/IntervalTrees.jl/stable/) | `Biobase` | -| Sequence annotation | [GenomicFeatures](https://biojulia.dev/GenomicFeatures.jl/stable/), [GenomicAnnotations](https://biojulia.dev/GenomicAnnotations.jl/dev/), [FormatSpecimens](https://github.com/BioJulia/FormatSpecimens.jl) | `AnnotationHub` | -| Input/Output | [FASTX](https://biojulia.dev/FASTX.jl/stable/), [XAM](https://biojulia.dev/XAM.jl/stable/), [BigWig](https://biojulia.dev/BigWig.jl/dev/),... | `BiocIO`, `Biostrings`, `ShortRead`,... | -| Sequence alignment | [BioSequences](https://biojulia.dev/BioSequences.jl/stable/), [BioAlignments](https://biojulia.dev/BioAlignments.jl/stable/) | `Biostrings` | -| Expression analysis | [SingleCellProjections](https://biojulia.dev/SingleCellProjections.jl/dev/) | `DESeq2` | +| Application | BioJulia packages | Bioconductor packages | +|:--------------------|:-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|:------------------------------------------| +| Data structures | [BioSymbols](https://biojulia.dev/BioSymbols.jl/stable/), [KmerAnalysis](https://github.com/BioJulia/KmerAnalysis.jl), [IntervalTrees](https://biojulia.dev/IntervalTrees.jl/stable/) | `Biobase` | +| Sequence annotation | [GenomicFeatures](https://biojulia.dev/GenomicFeatures.jl/stable/), [GenomicAnnotations](https://biojulia.dev/GenomicAnnotations.jl/dev/), [FormatSpecimens](https://github.com/BioJulia/FormatSpecimens.jl) | `AnnotationHub` | +| Input/Output | [FASTX](https://biojulia.dev/FASTX.jl/stable/), [XAM](https://biojulia.dev/XAM.jl/stable/), [BigWig](https://biojulia.dev/BigWig.jl/dev/), etc. | `BiocIO`, `Biostrings`, `ShortRead`, etc. | +| Sequence alignment | [BioSequences](https://biojulia.dev/BioSequences.jl/stable/), [BioAlignments](https://biojulia.dev/BioAlignments.jl/stable/) | `Biostrings` | +| Expression analysis | [SingleCellProjections](https://biojulia.dev/SingleCellProjections.jl/dev/) | `DESeq2` | **A few package/ecosystem equivalents between Julia and R:** @@ -32,18 +32,18 @@ **A few notable differences between Julia and R:** -| Julia | R | -|:-----------------------------------------------------------------------|:---------------------------------------------------------------------------------| -| High-level, general-purpose compiled language | High-level, interpreted language for statistical computing | -| Dynamically typed with multiple dispatch and optional type annotations | Dynamically typed without type annotations support | -| Built-in parallelism via threads, coroutines (Tasks) | Parallelism via external libraries (BLAS, `parallel`,...) | -| Extensive metaprogramming (Lisp-like macros, generated functions,...) | Less extensive metaprogramming (function factories, expression manipulation,...) | -| Single implementation available (JuliaLang) | Multiple implementations available (pqR, Renjin,...) | +| Julia | R | +|:-----------------------------------------------------------------------|:----------------------------------------------------------------------------------| +| High-level, general-purpose compiled language | High-level, interpreted language for statistical computing and data visualization | +| Dynamically typed with multiple dispatch and optional type annotations | Dynamically typed without type annotations support | +| Built-in parallelism via threads, coroutines (Tasks) | Parallelism via external libraries (BLAS, `parallel`, etc.) | +| Lisp-like (homoiconic, macro-based) metaprogramming | Partially homoiconic, non-standard evaluation metaprogramming | +| Single implementation available (JuliaLang) | Multiple implementations available (pqR, Renjin, etc.) | **To transition from R to Julia:** -* See [Noteworthy differences from +* Consult the [Noteworthy differences from R](https://docs.julialang.org/en/v1/manual/noteworthy-differences/#Noteworthy-differences-from-R) - in the Julia manual for a more in-depth comparison + section in the Julia manual for a more in-depth comparison * Use [RCall.jl](https://github.com/JuliaInterop/RCall.jl.git) to seamlessly integrate R code into your Julia project * Use @@ -51,5 +51,5 @@ to seamlessly integrate Julia code into your R project * Check out the [Tidier.jl ecosystem](https://tidierorg.github.io/Tidier.jl/dev/) for packages similar to - those commonly found in `tidyverse` + those commonly found in R's tidyverse diff --git a/docs/src/comparisons/biojava.md b/docs/src/comparisons/biojava.md index b6ba43e..05054b8 100644 --- a/docs/src/comparisons/biojava.md +++ b/docs/src/comparisons/biojava.md @@ -6,13 +6,13 @@ `org.biojava` package * Launched in 2002 with six major releases covering more than 11 Java releases -**A few equivalent applications between BioJulia and BioJava:** +**A few similar applications between BioJulia and BioJava:** -| Application | BioJulia packages | BioJava modules | -|:--------------------------|:----------------------------------------------------------------------------------------------------------------------------------------------|:------------------------------------------------| -| Input/Output | [FASTX](https://biojulia.dev/FASTX.jl/stable/), [XAM](https://biojulia.dev/XAM.jl/stable/), [BigWig](https://biojulia.dev/BigWig.jl/dev/),... | `nbio.genome.io.fastq`, `nbio.ontology.obo`,... | -| Sequence alignment | [BioSequences](https://biojulia.dev/BioSequences.jl/stable/), [BioAlignments](https://biojulia.dev/BioAlignments.jl/stable/) | `nbio.sequence`, `nbio.alignment` | -| Macromolecular structures | [BioStructures](https://biojulia.dev/BioStructures.jl/stable/) | `nbio.structure` | +| Application | BioJulia packages | BioJava modules | +|:--------------------------|:------------------------------------------------------------------------------------------------------------------------------------------------|:--------------------------------------------------| +| Input/Output | [FASTX](https://biojulia.dev/FASTX.jl/stable/), [XAM](https://biojulia.dev/XAM.jl/stable/), [BigWig](https://biojulia.dev/BigWig.jl/dev/), etc. | `nbio.genome.io.fastq`, `nbio.ontology.obo`, etc. | +| Sequence alignment | [BioSequences](https://biojulia.dev/BioSequences.jl/stable/), [BioAlignments](https://biojulia.dev/BioAlignments.jl/stable/) | `nbio.sequence`, `nbio.alignment` | +| Macromolecular structures | [BioStructures](https://biojulia.dev/BioStructures.jl/stable/) | `nbio.structure` | **A few package/ecosystem equivalents between Julia and Java:** @@ -28,20 +28,20 @@ **A few notable differences between Julia and Java:** -| Julia | Java | -|:-----------------------------------------------------------------------|:-----------------------------------------------------------------------------------------| -| High-level, general-purpose compiled language | High-level, object-oriented, two-step (compiled and interpreted) language | -| Expression-based (statements yield a value) | Statement-based (assignment as a statement) | -| Dynamically typed with multiple dispatch and optional type annotations | Statically typed with required type declarations | -| Built-in parallelism via threads, coroutines (Tasks) | Built-in parallelism via threads, streams, fibers (Project Loom) | -| Extensive metaprogramming (Lisp-like macros, homoiconicity,...) | Less extensive metaprogramming (reflection, annotations,...) | -| Included default package manager | No default package manager (dependency/build management tools include Maven, Gradle,...) | -| Single implementation available (JuliaLang) | Multiple implementations available (OpenJDK, GraalVM,...) | +| Julia | Java | +|:-----------------------------------------------------------------------|:-------------------------------------------------------------------------------------------| +| High-level, general-purpose compiled language | High-level, object-oriented, two-step (compiled and interpreted) language | +| Expression-based (statements yield a value) | Statement-based (statements don't always yield a value) | +| Dynamically typed with multiple dispatch and optional type annotations | Statically typed with required type declarations | +| Built-in parallelism via threads, coroutines (Tasks) | Built-in parallelism via threads, streams, fibers (Project Loom) | +| Lisp-like (homoiconic, macro-based) metaprogramming | Reflection-based runtime metaprogramming | +| Included default package manager | No default package manager (dependency/build management tools include Maven, Gradle, etc.) | +| Single implementation available (JuliaLang) | Multiple implementations available (OpenJDK, GraalVM, etc.) | **To transition from Java to Julia:** * Use [JavaCall.jl](https://juliainterop.github.io/JavaCall.jl/) to seamlessly integrate Java code into your Julia project -* See [Running External +* Consult the [Running External Programs](https://docs.julialang.org/en/v1/manual/running-external-programs/) - in the Julia manual for running Java scripts or other programs from Julia + section in the Julia manual for running Java scripts or other programs from Julia diff --git a/docs/src/comparisons/bioperl.md b/docs/src/comparisons/bioperl.md index 7826b1b..708844b 100644 --- a/docs/src/comparisons/bioperl.md +++ b/docs/src/comparisons/bioperl.md @@ -7,40 +7,40 @@ * Launched in 2002 and has contributed to major scientific achievements including the Human Genome Project -**A few equivalent application tools between BioJulia and BioPerl:** +**A few similar applications between BioJulia and BioPerl:** -| Application | BioJulia packages | BioPerl modules/objects | -|:--------------------|:----------------------------------------------------------------------------------------------------------------------------------------------|:-------------------------| -| Input/Output | [FASTX](https://biojulia.dev/FASTX.jl/stable/), [XAM](https://biojulia.dev/XAM.jl/stable/), [BigWig](https://biojulia.dev/BigWig.jl/dev/),... | `SeqIO` | -| Sequence alignment | [BioSequences](https://biojulia.dev/BioSequences.jl/stable/), [BioAlignments](https://biojulia.dev/BioAlignments.jl/stable/) | `AlignIO`, `SimpleAlign` | -| Data structures | [Kmers](https://biojulia.dev/Kmers.jl/stable/), [IntervalTrees](https://biojulia.dev/IntervalTrees.jl/stable/) | `Bio::Kmer`, `Bio::Tree` | -| Population Genetics | [PopGen](https://biojulia.dev/PopGen.jl/) | `PopGen` | +| Application | BioJulia packages | BioPerl modules/objects | +|:--------------------|:------------------------------------------------------------------------------------------------------------------------------------------------|:-------------------------| +| Input/Output | [FASTX](https://biojulia.dev/FASTX.jl/stable/), [XAM](https://biojulia.dev/XAM.jl/stable/), [BigWig](https://biojulia.dev/BigWig.jl/dev/), etc. | `SeqIO` | +| Sequence alignment | [BioSequences](https://biojulia.dev/BioSequences.jl/stable/), [BioAlignments](https://biojulia.dev/BioAlignments.jl/stable/) | `AlignIO`, `SimpleAlign` | +| Data structures | [Kmers](https://biojulia.dev/Kmers.jl/stable/), [IntervalTrees](https://biojulia.dev/IntervalTrees.jl/stable/) | `Bio::Kmer`, `Bio::Tree` | +| Population Genetics | [PopGen](https://biojulia.dev/PopGen.jl/) | `PopGen` | **A few package/ecosystem equivalents between Julia and Perl5:** -| Application | Julia | Perl5 | -|:---------------------------|:------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|:--------------------------------------| -| Data manipulation/analysis | [DataFrames](https://dataframes.juliadata.org/stable/), [CSV](https://csv.juliadata.org/stable/), [Query](https://www.queryverse.org/Query.jl/stable/) | `PDL`, `Text-CSV` | -| Plotting/visualization | [Plots](https://docs.juliaplots.org/stable/), [Gadfly](http://gadflyjl.org/stable/), [Makie](https://docs.makie.org/stable/), [TidierPlots](https://github.com/TidierOrg/TidierPlots.jl) | `GDGraph`, `Chart-GGPlot` | -| Statistical analysis | [Statistics](https://docs.julialang.org/en/v1/stdlib/Statistics/), [HypothesisTests](https://github.com/JuliaStats/HypothesisTests.jl), [GLM](https://github.com/JuliaStats/GLM.jl) | `Statistics-Descriptive`, `PDL-Stats` | -| Numerical mathematics | [LinearAlgebra](https://docs.julialang.org/en/v1/stdlib/LinearAlgebra/), [Symbolics](https://symbolics.juliasymbolics.org/stable/) | `PDL-LinearAlgebra`, `Math-Symbolic` | -| Notebook/report generator | [IJulia](https://julialang.github.io/IJulia.jl/stable/), [Pluto](https://plutojl.org/) | `Devel-IPerl` | -| Web applications | [Genie](https://genieframework.com/), [Franklin](https://franklinjl.org/) | `Catalyst`, `Mojolicious` | +| Application | Julia | Perl5 | +|:---------------------------|:-----------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|:--------------------------------------| +| Data manipulation/analysis | [DataFrames](https://dataframes.juliadata.org/stable/), [CSV](https://csv.juliadata.org/stable/), [Query](https://www.queryverse.org/Query.jl/stable/) | `PDL`, `Text-CSV` | +| Plotting/visualization | [Plots](https://docs.juliaplots.org/stable/), [Gadfly](http://gadflyjl.org/stable/), [Makie](https://docs.makie.org/stable/), [TidierPlots](https://github.com/TidierOrg/TidierPlots.jl) | `GDGraph`, `Chart-GGPlot` | +| Statistical analysis | [Statistics](https://docs.julialang.org/en/v1/stdlib/Statistics/), [HypothesisTests](https://github.com/JuliaStats/HypothesisTests.jl), [GLM](https://github.com/JuliaStats/GLM.jl) | `Statistics-Descriptive`, `PDL-Stats` | +| Numerical mathematics | [LinearAlgebra](https://docs.julialang.org/en/v1/stdlib/LinearAlgebra/), [Symbolics](https://symbolics.juliasymbolics.org/stable/) | `PDL-LinearAlgebra`, `Math-Symbolic` | +| Notebook/report generator | [IJulia](https://julialang.github.io/IJulia.jl/stable/), [Pluto](https://plutojl.org/) | `Devel-IPerl` | +| Web applications | [Genie](https://genieframework.com/), [Franklin](https://franklinjl.org/) | `Catalyst`, `Mojolicious` | **A few notable differences between Julia and Perl5:** -| Julia | Perl5 | -|:-----------------------------------------------------------------------|:--------------------------------------------------------------------------------| -| High-level, general-purpose compiled language | High-level, general-purpose interpreted language | -| Dynamically typed with multiple dispatch and optional type annotations | Dynamically typed without type annotations support | -| Built-in parallelism via threads, coroutines (Tasks) | Parallelism via threads, external modules (`Coro`, `Parallel`,...) | -| Lisp-inspired metaprogramming (S-expressions, homoiconicity,...) | Macro-less metaprogramming capabilities (eval, symbol table manipulation,...) | -| Single language implementation (JuliaLang) | Family of related languages/implementations (Perl5, Perl6/Raku, ActivePerl,...) | +| Julia | Perl5 | +|:-----------------------------------------------------------------------|:----------------------------------------------------------------------------------| +| High-level, general-purpose compiled language | High-level, general-purpose interpreted language | +| Dynamically typed with multiple dispatch and optional type annotations | Dynamically typed without type annotations support | +| Built-in parallelism via threads, coroutines (Tasks) | Parallelism via threads, external modules (`Coro`, `Parallel`, etc.) | +| Lisp-like (homoiconic, macro-based) metaprogramming | Primarily runtime metaprogramming | +| Single language implementation (JuliaLang) | Family of related languages/implementations (Perl5, Perl6/Raku, ActivePerl, etc.) | **To transition from Perl5 to Julia:** * Read the [Julia manual](https://docs.julialang.org/) for an in-depth look at its internals and features -* See [Running External +* Consult the [Running External Programs](https://docs.julialang.org/en/v1/manual/running-external-programs/) - in the manual for running Perl scripts or other programs from Julia + section in the manual for running Perl scripts or other programs from Julia diff --git a/docs/src/comparisons/biopython.md b/docs/src/comparisons/biopython.md index 218ac82..82352cc 100644 --- a/docs/src/comparisons/biopython.md +++ b/docs/src/comparisons/biopython.md @@ -9,14 +9,14 @@ * Capabilities cover a number of molecular biology applications including sequence alignment, population genetics, and machine learning -**A few equivalent application tools between BioJulia and Biopython:** +**A few similar applications between BioJulia and Biopython:** -| Application | BioJulia packages | Biopython objects/modules | -|:--------------------|:----------------------------------------------------------------------------------------------------------------------------------------------|:---------------------------| -| Sequence annotation | [GenomicFeatures](https://biojulia.dev/GenomicFeatures.jl/stable/), [GenomicAnnotations](https://biojulia.dev/GenomicAnnotations.jl/dev/) | `Seq`, `SeqRecord` | -| Input/Output | [FASTX](https://biojulia.dev/FASTX.jl/stable/), [XAM](https://biojulia.dev/XAM.jl/stable/), [BigWig](https://biojulia.dev/BigWig.jl/dev/),... | `Bio.SeqIO`, `Bio.AlignIO` | -| Sequence alignment | [BioSequences](https://biojulia.dev/BioSequences.jl/stable/), [BioAlignments](https://biojulia.dev/BioAlignments.jl/stable/) | `Bio.Align` | -| Population genetics | [PopGen](https://biojulia.dev/PopGen.jl/) | `Bio.PopGen` | +| Application | BioJulia packages | Biopython objects/modules | +|:--------------------|:------------------------------------------------------------------------------------------------------------------------------------------------|:---------------------------| +| Sequence annotation | [GenomicFeatures](https://biojulia.dev/GenomicFeatures.jl/stable/), [GenomicAnnotations](https://biojulia.dev/GenomicAnnotations.jl/dev/) | `Seq`, `SeqRecord` | +| Input/Output | [FASTX](https://biojulia.dev/FASTX.jl/stable/), [XAM](https://biojulia.dev/XAM.jl/stable/), [BigWig](https://biojulia.dev/BigWig.jl/dev/), etc. | `Bio.SeqIO`, `Bio.AlignIO` | +| Sequence alignment | [BioSequences](https://biojulia.dev/BioSequences.jl/stable/), [BioAlignments](https://biojulia.dev/BioAlignments.jl/stable/) | `Bio.Align` | +| Population genetics | [PopGen](https://biojulia.dev/PopGen.jl/) | `Bio.PopGen` | **A few package/ecosystem equivalents between Julia and Python3:** @@ -32,21 +32,21 @@ **A few notable differences between Julia and Python3:** -| Julia | Python3 | -|:-----------------------------------------------------------------------|:-----------------------------------------------------------------------------| -| High-level, general-purpose compiled language | High-level, general-purpose interpreted language | -| Expression-based (statements yield a value) | Statement-based (assignment as a statement) | -| Dynamically typed with multiple dispatch and optional type annotations | Dynamically typed with optional type annotations | -| Built-in parallelism via threads, coroutines (Tasks) | Limited (GIL) built-in parallelism via threads, async/await | -| Extensive metaprogramming (Lisp-like macros, homoiconicity,...) | Less extensive metaprogramming (decorators, metaclasses,...) | +| Julia | Python3 | +|:-----------------------------------------------------------------------|:------------------------------------------------------------| +| High-level, general-purpose compiled language | High-level, general-purpose interpreted language | +| Expression-based (statements yield a value) | Statement-based (statements don't always yield a value) | +| Dynamically typed with multiple dispatch and optional type annotations | Dynamically typed with optional type annotations | +| Built-in parallelism via threads, coroutines (Tasks) | Limited (GIL) built-in parallelism via threads, async/await | +| Lisp-like (homoiconic, macro-based) metaprogramming | Reflection-based runtime metaprogramming | Included default package manager | No default package manager (poetry, conda, and other alternatives available) | -| Single implementation available (JuliaLang) | Multiple implementations available (PyPy, Numba,...) | +| Single implementation available (JuliaLang) | Multiple implementations available (PyPy, Numba, etc.) | | Arrays are column-major (columns are contiguous in memory) | (Numpy) arrays are row-major by default (rows are contiguous in memory) | **To transition from Python3 to Julia:** -* See [Noteworthy differences from +* Consult the [Noteworthy differences from Python](https://docs.julialang.org/en/v1/manual/noteworthy-differences/#Noteworthy-differences-from-Python) - in the Julia manual for a more in-depth comparison + section in the Julia manual for a more in-depth comparison * Use [PythonCall.jl](https://github.com/cjdoris/PythonCall.jl.git)/[CondaPkg.jl](https://github.com/JuliaPy/CondaPkg.jl.git) to seamlessly integrate Python3 code into your Julia project diff --git a/docs/src/comparisons/bioruby.md b/docs/src/comparisons/bioruby.md index 08bbcbe..75bfe83 100644 --- a/docs/src/comparisons/bioruby.md +++ b/docs/src/comparisons/bioruby.md @@ -8,12 +8,12 @@ * Primarily composed of wrapper classes/modules for common bioinformatics, molecular biology applications -**A few equivalent application tools between BioJulia and BioRuby:** +**A few similar applications between BioJulia and BioRuby:** -| Application | BioJulia packages | BioRuby classes/modules | -|:-------------------|:----------------------------------------------------------------------------------------------------------------------------------------------|:----------------------------------| -| Sequence alignment | [BioSequences](https://biojulia.dev/BioSequences.jl/stable/), [BioAlignments](https://biojulia.dev/BioAlignments.jl/stable/) | `Bio::Sequence`, `Bio::Alignment` | -| Input/Output | [FASTX](https://biojulia.dev/FASTX.jl/stable/), [XAM](https://biojulia.dev/XAM.jl/stable/), [BigWig](https://biojulia.dev/BigWig.jl/dev/),... | `Bio::Fasta`, `Bio::Fastq`,... | +| Application | BioJulia packages | BioRuby classes/modules | +|:-------------------|:------------------------------------------------------------------------------------------------------------------------------------------------|:----------------------------------| +| Sequence alignment | [BioSequences](https://biojulia.dev/BioSequences.jl/stable/), [BioAlignments](https://biojulia.dev/BioAlignments.jl/stable/) | `Bio::Sequence`, `Bio::Alignment` | +| Input/Output | [FASTX](https://biojulia.dev/FASTX.jl/stable/), [XAM](https://biojulia.dev/XAM.jl/stable/), [BigWig](https://biojulia.dev/BigWig.jl/dev/), etc. | `Bio::Fasta`, `Bio::Fastq`, etc. | **A few package/ecosystem equivalents between Julia and Ruby:** @@ -29,18 +29,18 @@ **A few notable differences between Julia and Ruby:** -| Julia | Ruby | -|:-----------------------------------------------------------------------|:-------------------------------------------------------------------------------| -| High-level, general-purpose compiled language | High-level, general-purpose interpreted language | -| Dynamically typed with multiple dispatch and optional type annotations | Dynamically typed with optional type annotations (Sorbet, RBS) | -| Built-in parallelism via threads, coroutines (Tasks) | Built-in parallelism via threads, fibers | -| Lisp-inspired metaprogramming (S-expressions, homoiconicity,...) | Macro-less metaprogramming capabilities (dynamic reflection, eval methods,...) | -| Single implementation available (JuliaLang) | Multiple implementations available (TruffleRuby, mruby,...) | +| Julia | Ruby | +|:-----------------------------------------------------------------------|:---------------------------------------------------------------| +| High-level, general-purpose compiled language | High-level, general-purpose interpreted language | +| Dynamically typed with multiple dispatch and optional type annotations | Dynamically typed with optional type annotations (Sorbet, RBS) | +| Built-in parallelism via threads, coroutines (Tasks) | Built-in parallelism via threads, fibers | +| Lisp-like (homoiconic, macro-based) metaprogramming | Primarily runtime metaprogramming | +| Single implementation available (JuliaLang) | Multiple implementations available (TruffleRuby, mruby, etc.) | **To transition from Ruby to Julia:** * Read the [Julia manual](https://docs.julialang.org/) for an in-depth look at its internals and features -* See [Running External +* Consult the [Running External Programs](https://docs.julialang.org/en/v1/manual/running-external-programs/) - in the manual for running Ruby scripts or other programs from Julia + section in the manual for running Ruby scripts or other programs from Julia diff --git a/docs/src/comparisons/scikitbio.md b/docs/src/comparisons/scikitbio.md index 7bfbef3..c19b18f 100644 --- a/docs/src/comparisons/scikitbio.md +++ b/docs/src/comparisons/scikitbio.md @@ -7,7 +7,7 @@ * Launched in 2014 based on a BSD-relicensing of PyCogent and QIIME code and is currently in beta/maintenance mode -**A few equivalent application tools between BioJulia and scikit-bio:** +**A few similar applications between BioJulia and scikit-bio:** | Application | BioJulia packages | scikit-bio modules | |:-------------------|:----------------------------------------------------------------------------------------------------------------------------------------------|:------------------------------------| @@ -29,21 +29,21 @@ **A few notable differences between Julia and Python3:** -| Julia | Python3 | -|:-----------------------------------------------------------------------|:-----------------------------------------------------------------------------| -| High-level, general-purpose compiled language | High-level, general-purpose interpreted language | -| Expression-based (statements yield a value) | Statement-based (assignment as a statement) | -| Dynamically typed with multiple dispatch and optional type annotations | Dynamically typed with optional type annotations | -| Built-in parallelism via threads, coroutines (Tasks) | Limited (GIL) built-in parallelism via threads, async/await | -| Extensive metaprogramming (Lisp-like macros, homoiconicity,...) | Less extensive metaprogramming (decorators, metaclasses,...) | +| Julia | Python3 | +|:-----------------------------------------------------------------------|:------------------------------------------------------------| +| High-level, general-purpose compiled language | High-level, general-purpose interpreted language | +| Expression-based (statements yield a value) | Statement-based (statements don't always yield a value) | +| Dynamically typed with multiple dispatch and optional type annotations | Dynamically typed with optional type annotations | +| Built-in parallelism via threads, coroutines (Tasks) | Limited (GIL) built-in parallelism via threads, async/await | +| Lisp-like (homoiconic, macro-based) metaprogramming | Reflection-based runtime metaprogramming | Included default package manager | No default package manager (poetry, conda, and other alternatives available) | -| Single implementation available (JuliaLang) | Multiple implementations available (PyPy, Numba,...) | +| Single implementation available (JuliaLang) | Multiple implementations available (PyPy, Numba, etc.) | | Arrays are column-major (columns are contiguous in memory) | (Numpy) arrays are row-major by default (rows are contiguous in memory) | **To transition from Python3 to Julia:** -* See [Noteworthy differences from +* Consult the [Noteworthy differences from Python](https://docs.julialang.org/en/v1/manual/noteworthy-differences/#Noteworthy-differences-from-Python) - in the Julia manual for a more in-depth comparison + section in the Julia manual for a more in-depth comparison * Use [PythonCall.jl](https://github.com/cjdoris/PythonCall.jl.git)/[CondaPkg.jl](https://github.com/JuliaPy/CondaPkg.jl.git) to seamlessly integrate Python3 code into your Julia project diff --git a/docs/src/getting_started/biojuliainstallation.md b/docs/src/getting_started/biojuliainstallation.md index 0d33d9b..23c77eb 100644 --- a/docs/src/getting_started/biojuliainstallation.md +++ b/docs/src/getting_started/biojuliainstallation.md @@ -3,9 +3,8 @@ ## Standard installation As with any Julia package, you can easily install any BioJulia package with the -help of the [official package manager](https://pkgdocs.julialang.org/v1/) -included by default with every Julia installation. All you need to know is the -name of the package of interest! +help of the [official built-in package manager](https://pkgdocs.julialang.org/v1/). +All you need to know is the name of the package of interest! There are two standard methods to install a package: @@ -13,13 +12,13 @@ There are two standard methods to install a package: The Julia package manager, similarly to conda and others, organizes dependencies according to the "environment" they are in, meaning in which directory the packages are installed to. The default Julia session adds - packages to a "global" environment, usually the .julia/environments/v1.x + packages to a "global" environment, usually the `.julia/environments/v1.x` directory. When you are developing a package, you must activate its project-specific environment by calling `activate MyProjectName` (see [Package development](@ref pkg-devel) below) so that you can isolate your - dependencies from the global environment and manage them independently. See - [Working with Environment](https://pkgdocs.julialang.org/v1/environments/) - for more details. + dependencies from the global environment and manage them independently. Consult + the [Working with Environment](https://pkgdocs.julialang.org/v1/environments/) + section of the Julia package manager manual for more details. * **The package manager (Pkg) module** @@ -34,7 +33,7 @@ julia> using !!! note One excellent trick is that any Julia code with the `julia>` prompt included at the beginning of the line can be copy/pasted as is into the - REPL! See the [Julia REPL](@ref julia-repl) section for more. + REPL! See the [Julia REPL](@ref julia-repl) section for more details. * **Pkg mode** @@ -47,7 +46,7 @@ julia> using julia> using ``` -!!! note J +!!! note Just like with the previous method, you can copy/paste code with the `(@v1.x) pkg>` prompt included and Julia will work correctly! You can even skip having to enter Pkg mode by just entering directly `(@v1.x) pkg> @@ -62,7 +61,7 @@ the package manager can also help you by first cloning the package repository to your development machine. Pkg will then load the required dependencies in a new dependency environment based on the package's `Project.toml` file. Thereafter, both the direct and indirect dependencies can be locked using a generated -`Manifest.toml` if needed and a pull request can be submitted. +`Manifest.toml` if desired and a pull request can be submitted. There are two standard methods to set up Julia for developing a package: @@ -97,9 +96,9 @@ julia> using already installed the package locally, simply make sure to point Pkg to the right path as shown above. -You can now change your source code and load them into the Julia session with +You can now change your source code and load it into the Julia session with `using `. To test your code, run `(@v1.9) pkg> test` to -run the package's test suite to ensure that everything works correctly. When you +execute the package's test suite and ensure that everything works correctly. When you are done developing the package, enter `(@v1.9) pkg> free` to stop tracking the package. diff --git a/docs/src/getting_started/casescenarios.md b/docs/src/getting_started/casescenarios.md index fa9601e..b094b16 100644 --- a/docs/src/getting_started/casescenarios.md +++ b/docs/src/getting_started/casescenarios.md @@ -1,38 +1,38 @@ # [Case Scenarios](@id casescenarios) !!! note - These scenarios are based on experiences and case studies from fellow - members of the BioJulia/Julia community! + These scenarios are inspired by stories from fellow members of the + BioJulia/Julia community! -## Industry +## Industry !!! tip Visit [JuliaHub](https://juliahub.com/case-studies/) for real-world case - studies of Julia in multiple areas of industry! + studies of Julia in multiple industries! A biotechnology-oriented collaborative research organization has ordered their IT department to organize the first in-house software development division. -Researchers and other essential personnel are divided into teams that each serve -one client at a time, though they all share the same laboratory and equipment. -The need for an in-house programming division has arisen based on feedback from -these teams facing many similar problems with the current workplace setup: - -* The researchers may not be digitally literate, thus they require more - accessible user experiences -* Lessening the number of tools they are required to learn would ideally reduce +Researchers are divided into teams that each serve one client at a time, though +they all share the same laboratory and equipment. The need for an in-house +programming division has arisen based on feedback from these teams facing many +similar problems with the current workplace setup: + +- Researchers may not be digitally literate, thus they require more accessible + user interfaces +- Lessening the number of tools they are required to learn would ideally reduce complexity and onboarding time -* Some workflows can be repetitive and could take advantage of some automation +- Some workflows can be repetitive and could take advantage of some automation to reduce overall time -It is thus decided that an employee-facing platform should be created that will -host a suite of simple, web-based software tools. These can include tools usable -by any employee or by only one or several teams depending on their needs. The -new division is given the following objectives: +It is thus decided that a researcher-facing platform should be created that +will host a suite of simple, web-based software tools. These can include tools +usable by any researcher or by only one or several teams depending on their +needs. The new division is given the following objectives: -* Collaborate with the researchers and understand their software requirements -* Use modern languages/frameworks to avoid technical headaches and allow for +- Collaborate with researchers and understand their software requirements +- Use modern languages/frameworks to avoid technical headaches and allow for faster onboarding -* Ensure access to both general and scientific libraries when needed for a +- Ensure access to both general and scientific libraries when needed for a specific tool Upon reviewing these objectives, the division begins discussing which tech @@ -41,9 +41,9 @@ desire to allow for fast time-to-deployment and performance, it is agreed that a modern, higher-level programming language would be ideal. One of the collaborating researchers suggests they look into Julia, which has been the scripting language of choice amongst some of the teams for automating several -workflows, and the division gives it a go following some research and planning. +workflows, and the division decides to push ahead with a trial. -The platform and first two tools for the collaborating researcher's team are +The platform and first two tools for the collaborating research team are prototyped. The stack is built upon the [Genie](https://genieframework.com/) web framework, which, crucially, enables authorization/authentication support on a team-by-team basis and HTML/CSS/JS interoperability. The entire platform is @@ -51,67 +51,56 @@ designed as a reactive app that can be deployed anywhere and is almost entirely written in Julia for both the frontend and backend. Further Genie ecosystem packages and plugins spur potential ideas like taking advantage of the included no-code [UI builder](https://learn.genieframework.com/guides/genie-builder) for -producing analytics dashboards built by each team without advanced programming -expertise. +producing team analytics dashboards. The first tool conceived allows teams to upload, download, and manage files or datasets within the company's shared drive from the web. It is designed to -handle data management on its own without the employees needing to remember +handle data management on its own without the researchers needing to remember specific drive locations or other details, their only responsibility being -categorization (data pulled from which instrument, for which project, -etc.). The tool is able to manage the data by working with the company's S3 and -S3 Glacier storage instances via the -[AWS](https://juliacloud.github.io/AWS.jl/stable/) package. A user-facing -feature is also included that generates an `Artifacts.toml` file, allowing -researchers to use Julia's [Artifact -system](https://pkgdocs.julialang.org/v1/artifacts/) to declaratively point to -select data and download them when required for their local needs. For the more -tech savvy user, an input feature is set up to allow for -[DuckDB](https://duckdb.org/) database queries for large datasets. An [official -Julia package](https://duckdb.org/docs/api/julia.html) is provided for this -DBMS, however, one incredible feature of the language is the ability to bundle -external programs written in other languages and treat them as first-class Julia -packages, known as -[JLLs](https://docs.binarybuilder.org/stable/jll/#JLL-packages). The official -package wraps the `DuckDB_jll` bundle, which the developers can manage as a -separate dependency for more direct interaction with the DBMS. This feature, to -their delight, also means that porting over common, open scientific software for -more specific tools can be as simple as generating their JLLs and managing them -directly via Julia. Seamless interoperability also extends to the ability to -interact with codes from other languages such as Python with +categorization (data pulled from which instrument, for which project, etc.). The +tool is able to manage the data by working with the company's S3 and S3 Glacier +storage instances via the [AWS](https://juliacloud.github.io/AWS.jl/stable/) +package. A user-facing feature is also included that generates an +`Artifacts.toml` file, allowing researchers to use Julia's +[Artifact system](https://pkgdocs.julialang.org/v1/artifacts/) to declaratively +point to select data and download them when required. For the more tech savvy +user, an input feature is set up to allow for [DuckDB](https://duckdb.org/) +database queries for large datasets. An +[official Julia package](https://duckdb.org/docs/api/julia.html) is provided for +this DBMS, however, a +[JLL](https://docs.binarybuilder.org/stable/jll/#JLL-packages) is also available +for more direct use of the DuckDB program. The ability to bundle external +programs written in other languages and treat them as first-class Julia packages +also means that porting over common scientific tools greatly simplifies +dependency management for both developers and researchers. Seamless +interoperability also extends to the ability to interact with codes from other +languages such as Python with [PythonCall](https://juliapy.github.io/PythonCall.jl/stable/)/[CondaPkg](https://github.com/JuliaPy/CondaPkg.jl) and R with [RCall](https://juliainterop.github.io/RCall.jl/stable/). -The second tool conceived is designed specifically for the collaborating +The second tool conceived is designed specifically for a collaborating researcher who needs to determine total cell count following each cell passage. -The user uploads a photo of a stained cell culture sample, along with inputs -such as total medium volume and dilution factor. The developers make use of the +The researcher uploads a photo of a stained cell culture sample, along with +inputs such as total medium volume and dilution factor. The developers make use +of the [ImageSegmentation](https://juliaimages.org/stable/pkgs/segmentation/#ImageSegmentation.jl) package for differentiating live and dead cells through the use of the watershed algorithm. A side-by-side view is generated with the original and segmented image, as well as the total number of markers indicating the amount of live -cells, being differentiable due to their staining. Although only a prototype, -the developers believe it would be more than possible, thanks to the number of -large Julia packages already available, to employ basic machine learning to -simplify the process and increase accuracy. Aside from other imaging packages -like [ImageAxes](https://juliaimages.org/stable/pkgs/axes/#ImageAxes.jl), OpenCV -has already been ported over [as a -JLL](https://juliahub.com/ui/Packages/General/OpenCV_jll) for direct -development, and a host of packages are available within the -[SciML](https://sciml.ai/) ecosystem for building the machine learning model. - -The trial period with the collaborating researcher's team proves to be a -success, and the company decides to fully commit to this platform, almost fully -written in Julia, with additional resources and manpower. Novel ideas are -excitedly tossed about internally over which tools can further improve -workflows, such as replacing their electronic lab notebook systems with +cells.o Although only a prototype, the developers believe it would be more than +possible to employ basic machine learning using the [SciML](https://sciml.ai/) +ecosystem. + +The trial period with the collaborating research team proves to be a success, +and the company decides to fully commit to this Julia platform. Novel ideas are +tossed about internally over which tools can further improve workflows, such as +replacing their electronic lab notebook systems with [Pluto](https://plutojl.org/) and embedding a quick statistics calculator for -linear regression modelling with packages including -[GLM](https://juliastats.org/GLM.jl/stable/) and [Makie](https://makie.org/). It -is even discussed how Julia may allow the company to eventually commercialize -these tools for other contract research organizations that face the same -challenges. - +linear regression modelling with [GLM](https://juliastats.org/GLM.jl/stable/) +and [Makie](https://makie.org/). It is even discussed how this platform may +allow the company to eventually commercialize these tools for other contract +research organizations that face the same challenges. + ## Research !!! tip @@ -122,34 +111,34 @@ challenges. A freshly minted researcher begins the morning with a new directive from the principal investigator. Their lab specializes in translational cancer immunotherapy, and as of late have been exploring a potential avenue for T-cell -activation in patients with with a rare type of lymphoma. It is hoped that +activation in patients with a rare type of lymphoma. It is hoped that strengthening the expression of specific peptides involved in cellular adaptive -immune response can lead to more effective treatment of this specific cancer. -One patient's blood has been sampled and delivered to the lab, with the goal of -extacting and combing through the resulting expression data from various -antigen-presenting cells (APCs) to identify abnormal peptide expression levels. +immune response can lead to more effective treatment. One patient's blood has +been sampled and delivered to the lab, with the goal of extacting and combing +through the resulting expression data from various antigen-presenting cells +(APCs) to identify abnormal peptide expression levels. The researcher understands that the exploratory nature of this project will require an interactive environment from which results can be rapidly generated -and saved/discarded when need be. Previously, a number of challenges would get -in the way of this workflow: +and saved/discarded. Previously, a number of challenges would get in the way of +this workflow: -* Working with interactive languages had proven to be a hassle due to issues +- Working with interactive languages had proven to be a hassle due to issues like competing build systems and environments -* The REPL experience was often lacking due to missing features or lack of +- The REPL experience was often lacking due to missing features or lack of integrations with other tools like a package manager -* Notebooks, while good for experimenting, can come with their own problems such - as slow speeds and difficulties with deployment and versioning -* Writing high-performance software would require lower-level languages like C +- Existing digital notebook solutions suffer from lackluster performance and + difficulties with deployment and versioning +- Writing high-performance software would require lower-level languages like C or Fortran, which would prove difficult for scientists without a computer science background -They remember previously experimenting with Julia before it was considered -stable, and decide to give it a second go. Installation proved to be very simple -with the [juliaup](https://github.com/JuliaLang/juliaup#installation) tool, and -they proceed to read up on the basics from the [Julia -manual](https://docs.julialang.org/en/v1/). The first step, upon loading the -Julia REPL, is to add the +They remember having heard of Julia from colleagues, and decide to give it a go. +Installation proved to be very simple with the +[juliaup](https://github.com/JuliaLang/juliaup#installation) tool, and they +proceed to read up on the basics from the +[Julia manual](https://docs.julialang.org/en/v1/). The first step, upon loading +the Julia REPL, is to add the [DrWatson](https://juliadynamics.github.io/DrWatson.jl/stable/) package to better track the project. With DrWatson and the built-in package manager, the researcher can geneate reproducible code for simulations, plotting, and data @@ -158,13 +147,12 @@ preparation. At the same time, the researcher isolates the APCs via a microfluidic cell-sorting device. The patient's cells are encapsulated into individual droplets from which single-cell profiling can occur via Droplet-Sequencing -(Drop-seq). The resulting data is stored in [.h5 -files](https://www.wikiwand.com/en/Hierarchical_Data_Format) on the lab's shared -drive. The researcher generates an `Artifacts.toml` file that utilizes Julia's -built-in [Artifact system](https://pkgdocs.julialang.org/v1/artifacts/) to point -to these files in a persistent and reproducible manner every time the project -needs to be shared with others on their own machines. The researcher makes quick -work of loading the data into Julia with the +(Drop-seq). The resulting data is stored in +[.h5 files](https://www.wikiwand.com/en/Hierarchical_Data_Format) on the lab's +shared drive. The researcher generates an `Artifacts.toml` file that utilizes +Julia's built-in [Artifact system](https://pkgdocs.julialang.org/v1/artifacts/) +to point to these files in a persistent and reproducible manner. The researcher +makes quick work of loading the data into Julia with the [HDF5](https://juliaio.github.io/HDF5.jl/stable/) package, and applies a number of steps with [DataFrames](https://dataframes.juliadata.org/stable/), [TidierData](https://tidierorg.github.io/TidierData.jl/latest/), and @@ -174,103 +162,99 @@ filter the data. Finally, principle component analysis (PCA) with is conducted, visualized with the help of the [Makie](https://makie.org/) plotting package. -The whole project is saved by DrWatson and shared with the P. I. for further -discussion. PCA analysis leads them to focus on a narrow subset of APCs with -elevated peptide expression levels which will be followed up in subsequent -studies. The researcher prepares a more digestible format of the results as a -[Pluto notebook](https://plutojl.org/) to share with colleagues the more -pertinent observations, and finally a more formal research report with Julia -code included is written with [Weave](https://weavejl.mpastell.com/stable/). The -lab is impressed with what was achieved with Julia, with many remarking how -effortless it seemed to achieve excellent performance with such a high-level -language. +The whole project is saved by DrWatson and shared with the principal +investigator for further discussion. PCA analysis leads them to focus on a +narrow subset of APCs with elevated peptide expression levels which will be +further investigated in subsequent studies. The researcher prepares a more +digestible format of the results as a [Pluto notebook](https://plutojl.org/) to +share with colleagues the more pertinent observations, and finally a more formal +research report with Julia code included is written with +[Weave](https://weavejl.mpastell.com/stable/). The lab is impressed with what +was achieved with Julia, with many remarking how effortless it seemed to achieve +great performance with such a high-level language. ## Education A new teacher was recently hired to teach a biostatistics course for first-year students at the University of Concordia. This will be a new offering at the university, thus they have been given free reign to design their own course -plan. They are most interested in engaging students with a fun, practical -component, including assignments that are trivial to set up, easy for students -to learn, and that draw from real-world examples. They look for inspiration from -similar courses, and finds that many are aiming to develop a strong foundation -in statistical programming for handling data analysis, hypothesis testing, and -other tasks. +plan. They are most interested in engaging students with a series of practical +components, including hands-on demonstrations and involved coding projects. They +look for inspiration from similar courses, and finds that many are aiming to +develop a strong foundation in statistical programming for handling data +analysis, hypothesis testing, and other tasks. A number of these courses teach R or Python3, which have been entrenched in statistics for a number of years. They also appear to be popular with new programmers due to being high-level and easy to learn. However, the new teacher encounters a number of issues that raise concern: -* Performance would become an issue with larger datasets or visual plots, with - the interpreter taking too long to generate output and thus wasting valuable +- Performance would become an issue with larger datasets or visual plots, with + the language taking too long to generate output and thus wasting valuable class time -* Both languages have been around for a long time, with a number of quirks and - design decisions that have not aged well such as implicit mutation or lack of - type annotations -* Setting up reproducible environments with all the necessary bits (packages, - data, ...) in either language is challenging, with a number of limitations and - choices presented including package manager, language implementation, etc. -* R is designed specifically for statistical computing, with concepts not found - in other, more general languages (S3/S4 class system, factors, ...) which - could confuse students with previous programming knowledge or those wishing to - learn more common computer science concepts -* There is a desire to avoid the "two-language problem" wherein parts of either - language are written in another and thus introduce unneeded complexity - -A fellow professor recommends that they look into Julia, which has already found -success within certain departments. Beyond addressing many of the issues -encountered with R and Python3, it is especially enjoyable how fast the -performance is, how the default package manager allows for reproducibility and -ease of use, and how close to mathematical writing Julia can get whilst -remaining readable. +- Both languages come with a number of design decisions that may confuse + beginners, such as how they handle missing values and introduce complex + object-oriented systems +- Setting up reproducible environments with all the necessary bits + (dependencies, data) in either language is challenging, with a number of + limitations and choices presented including package manager, language + implementation, etc. +- There is a desire to avoid the "two-language problem" wherein parts of either + language are written in another and thus introduce unneeded complexity + +A fellow professor recommends they look into Julia, which has already found +success within certain departments. The teacher consults the +[Julia manual](https://docs.julialang.org/en/v1/) and toys with the language +itself and several statistical packages. They discover that Julia possesses a +number of features relevant for both teaching and engaging with the course, +including the built-in package manager and rich REPL experience, and decides to +proceed forward with it. The first objective is to create a presentation format with good aesthetics that -can also show off and run code. They discover how to set up interactive -notebooks with [Pluto](https://plutojl.org/) that will be hosted in a [central -repository](https://github.com/) or online via a website or with solutions like -[Binder](https://pluto-on-binder.glitch.me/). This has a number of advantages -compared to PowerPoint or Markdown presentations: - -* Easily run and experiment with code cells within a reproducible environment -* Dependency management automatically handled via the built-in package manager -* Share the code and lessons with students either as notebooks or as exported +can also demonstrate code samples. They discover how to set up interactive +notebooks with [Pluto](https://plutojl.org/) that will be hosted in a +[central repository](https://github.com/) or online via a website or with +solutions like [Binder](https://pluto-on-binder.glitch.me/). This has a number +of advantages compared to PowerPoint or Markdown presentations: + +- Easily run and experiment with code cells within a reproducible environment +- Dependency management automatically handled via the built-in package manager +- Share the code and lessons with students either as notebooks or as exported PDF/HTML pages To bundle the datasets with the notebooks, they take advantage of Julia's [Artifact system](https://pkgdocs.julialang.org/v1/artifacts/) for handling and -retrieving data from almost anywhere on the Internet. +retrieving data from almost anywhere on the Internet. With the course infrastructure set, attention is now put towards creating the actual course material. They can cover a number of biostatistics topics using -powerful, well-established Julia packages: +powerful, well-established Julia packages: -* [Plots](https://docs.juliaplots.org/stable/) or - [Makie](https://docs.makie.org/stable/) for data visualization -* [DataFrames](https://dataframes.juliadata.org/stable/), +- [Plots](https://docs.juliaplots.org/stable/) or + [Makie](https://docs.makie.org/stable/) for data visualization +- [DataFrames](https://dataframes.juliadata.org/stable/), [CSV](https://csv.juliadata.org/stable/), and - [Tidier](https://tidierorg.github.io/Tidier.jl/dev/) for data handling -* [Statistics] and [StatsBase] for general statistical functionality (scalar + [Tidier](https://tidierorg.github.io/Tidier.jl/dev/) for data handling +- [Statistics] and [StatsBase] for general statistical functionality (scalar statistics, estimation, ...) -* [Distributions](https://juliastats.org/Distributions.jl/stable/) for +- [Distributions](https://juliastats.org/Distributions.jl/stable/) for probability and sampling -* [HypothesisTests](https://juliastats.org/HypothesisTests.jl/stable/) for +- [HypothesisTests](https://juliastats.org/HypothesisTests.jl/stable/) for parametric (ANOVA, chi-squared, ...) and non-parametric testing -* [GLM](https://juliastats.org/GLM.jl/stable/) for generalized linear modelling -* [Flux](https://fluxml.ai/) or +- [GLM](https://juliastats.org/GLM.jl/stable/) for generalized linear modelling +- [Flux](https://fluxml.ai/) or [MLJ](https://alan-turing-institute.github.io/MLJ.jl/stable/) for basic machine learning -The course agenda is now almost complete. However, just before the start of the -semester, a new lesson on Tukey's honest significance test is added. -Unfortunately, there is no package written in Julia for this test, and there is -little time left to develop the code on their own. Luckily, Julia posseses -amazing interoperability with both Python3 and R, and they discover how to both -call and bundle Scipy's `stats.tukey_hsd` function via +The course agenda is almost complete. However, just before the start of the +semester, a new lesson on Tukey's honest significance test is added. There is no +package written in Julia yet for this test, and there is little time left to +develop the code on their own. Luckily, Julia posseses incredible +interoperability with both Python3 and R, and they discover how to both call and +bundle Scipy's `stats.tukey_hsd` function via [PythonCall](https://cjdoris.github.io/PythonCall.jl/stable/) and [CondaPkg](https://github.com/cjdoris/CondaPkg.jl). -The teacher goes on to deliver one of the best courses that semester, empowered -by Julia to deliver an engaging, interactive experience that teaches students -both the fundamentals of biostatistics and of quality programming. - +The teacher goes on to smoothly deliver the newly introduced course, empowered +by Julia to deliver an engaging experience for teaching students both the +fundamentals of biostatistics and of quality programming. diff --git a/docs/src/getting_started/juliainstallation.md b/docs/src/getting_started/juliainstallation.md index 5507fb0..6ea0ee4 100644 --- a/docs/src/getting_started/juliainstallation.md +++ b/docs/src/getting_started/juliainstallation.md @@ -1,12 +1,7 @@ # [Installing Julia](@id juliainstallation) -There are a number of methods available to install Julia that each have their -own advantages: - -!!! note - It is NOT recommended to install Julia from your distribution's package - manager, as no such installation is officially endorsed by the Julia project - and thus may be out-of-date and broken/unmaintained! +There are a number of official methods available to install Julia, each with +their own purposes and advantages: ## juliaup (recommended) @@ -15,37 +10,36 @@ multiplexer tool designed to handle your Julia installation from the command-line. It is the easiest and most convenient installation option, and is available on almost all platforms that support Julia. -* If you are running **Linux or Mac**, enter the following command in your +- If you are running **Linux or Mac**, enter the following command in your terminal: + ``` curl -fsSL https://install.julialang.org | sh -``` +``` + +- If you are running **Windows**, enter the following: -* If you are running **Windows**, enter the following: ``` winget install julia -s msstore ``` -* If you have the **Rust** programming language installed on your machine, you - can install `juliaup` via the Cargo package manager: +- If you have the **Rust** programming language installed on your machine, you + can generate the `juliaup` executable via the Cargo package manager: !!! warning - This is not a recommended option as this will involve compiling the - actual `juliaup` executable on your machine + This is not recommended for the most users, and should be avoided + unless you cannot download the official juliaup executable. ``` cargo install juliaup -``` - -You can use the first and last commands listed to install Julia via `juliaup` in -a container (see [Docker/Podman](#Docker/Podman) below) +``` ## Docker/Podman An [official Docker image](https://hub.docker.com/_/julia) is available, allowing you to build containers with Julia already installed. This can be a -preferred method of installation if you wish to test out Julia in a sandboxed, -ephemeral (temporary) instance or are looking to include Julia in a +preferred method of installation if you wish to run Ju lia in a sandboxed, +ephemeral (temporary) instance or are looking to include Julia in a containerized application. You must first download the image via the Docker or Podman command-line tool: @@ -64,18 +58,17 @@ You can specify which version of the image you wish to install via tags, such as To create a container instance, run the following command: !!! note - You may skip the previous step if you have not already downloaded the - image, Docker/Podman will automatically begin installing it for you here! + If you had skipped the previous test, then Docker/Podman will + automatically begin installing the container image for you here! ``` docker run -it --rm --network host julia:latest ``` The above command creates an interactive container that will be deleted the -moment you exit via the `--rm` option and that will also share the same network -namespace as your machine via the `--network host` option (allow for automatic -port bindings). You may remove either option to disable their respective -behaviours. +moment you exit via the `--rm` option and that will share your machine's network +namespace via the `--network host` option (allow for automatic port bindings). +You may remove either option to disable these behaviours. The image itself can serve as a base for your custom container built from a Dockerfile/Containerfile: @@ -98,33 +91,26 @@ RUN apt update && \ curl -fsSL https://install.julialang.org | sh -s -- -y # install juliaup non-interactively RUN juliaup add release - -# Second option: install juliaup in a Rust image (not recommended) -FROM rust:latest - -RUN cargo install juliaup ``` -## Direct download +## Manual download -You can also install Julia as a downloadable executable from the Julia website's -[Download section](https://julialang.org/downloads/). You must make sure to -install the correct Julia build for your machine based on: -* native instruction set (x86_64, i686, ARM, Apple Silicon, PowerPC) -* operating system type (Windows, MacOS, Linux (Glibc), Linux (Musl), FreeBSD) -* bit compute type (32-bit, 64-bit) -* desired level of support (Tier 1 (guaranteed to build and pass all tests) - through Tier 4) +You can also install the Julia executable directly from the Julia website's +[Manual Download section](https://julialang.org/downloads/#manual_download). You +must make sure to install the correct Julia executable based on your machine's: -Make sure to follow the exact installation steps for your machine in order to -ensure the best experience. +- native instruction set (x86_64, i686, ARM, Apple Silicon, PowerPC) +- operating system type (Windows, MacOS, Linux (Glibc), Linux (Musl), FreeBSD) +- bit compute type (32-bit, 64-bit) -## Build from source +Make sure to follow the +[platform specific instructions](https://julialang.org/downloads/platform/) for +your machine in order to ensure the best experience. -For building/testing purposes, you may build Julia from the source code that is -fully available in the [Julia GitHub -repository](https://github.com/JuliaLang/julia.git). Simply enter `git clone -https://github.com/JuliaLang/julia.git` to copy the entire source on your -machine, create a new git branch via `git checkout -b name-of-branch`, add your -modifications, and run `make` to start the Makefile build. +## Build from source +You may build Julia from the source code that is openly available in the +[Julia GitHub repository](https://github.com/JuliaLang/julia.git). Please +consult the +[Building Julia (Detailed) section](https://docs.julialang.org/en/v1/devdocs/build/build/) +of the Julia manual for more details. diff --git a/docs/src/getting_started/toolsinstallation.md b/docs/src/getting_started/toolsinstallation.md index 5579a11..a048eb0 100644 --- a/docs/src/getting_started/toolsinstallation.md +++ b/docs/src/getting_started/toolsinstallation.md @@ -3,13 +3,13 @@ ## [Julia REPL](@id julia-repl) A REPL, or read-eval-print loop, represents a language "shell" or program that -allows the user to communicate with the programming language interactively with -immediate feedback. This allows for exploring the language more deeply than via -a script, with rapid prototyping being much quicker and easier to perform. +allows the user to communicate with the programming language interactively. This +allows for rapid prototyping and exploring the language more deeply with +immediate feedback. The Julia REPL is included by default in every Julia installation and boasts a -number of features to the point that it alone can almost be considered a proper -IDE. It should appear the moment you enter `julia` into your terminal: +number of features found in many integrated development environments (IDEs). It +should appear the moment you enter `julia` into your terminal: ``` _ _ _(_)_ | Documentation: https://docs.julialang.org @@ -20,24 +20,24 @@ IDE. It should appear the moment you enter `julia` into your terminal: _/ |\__'_|_|_|\__'_| | Official https://julialang.org/ release |__/ | -julia> +julia> ``` -Not every feature that the REPL provides will be shown, however here is a quick -list that most Julia users should know to make the most of this shell: +Here is a quick rundown of features most Julia users should know to make the +most of the REPL: -* There are 5 Julia REPL modes that serve separate purposes: +- There are 5 Julia REPL modes that serve separate purposes: 1. The Julian (default) mode wherein one can write, load, and test out code 2. Help mode for printing documentation for functions, keywords, etc. 3. Pkg mode for working with the included package manager and manipulating dependencies/packages 4. Shell mode to execute system commands (run a terminal from Julia which - itself is running from a terminal!) + itself is running from a terminal!) 5. Search modes (forward, reverse) to look through your history of inputs | Prompt | Key binding | -|:---------------------:|:---------------------------:| +| :-------------------: | :-------------------------: | | `julia> ` | None (default mode) | | `help?> ` | `?` or `??` (extended help) | | `(@v1.x) pkg> ` | `]` | @@ -45,90 +45,86 @@ list that most Julia users should know to make the most of this shell: | `(reverse-i-search):` | `^R` | | `(forward-i-search):` | `^S` | -* If you have a code editor installed on your development machine, you can go - back and forth between the Julia session and the editor by entering `julia> - edit("")`. You can jump right back into the Julia session once - you're finished! -* You can get a list of matches to a partially written word by entering the TAB - key, which also serves to render an Unicode symbol in the REPL (full list - available in the [Unicode - Input](https://docs.julialang.org/en/v1/manual/unicode-input/) section of the - Julia manual): - +- If you have a code editor installed on your machine, you can go back and forth + between the Julia session and the editor by entering + `julia> edit("")`. You can jump right back into the Julia + session once you're finished. +- You can get a list of matches to a partially written word by entering the TAB + key, which also serves to render a Unicode character in the REPL (full list + available in the + [Unicode Input](https://docs.julialang.org/en/v1/manual/unicode-input/) + section of the Julia manual): + ```julia julia> pri[TAB] primitive type print println printstyled julia> \pi[TAB] # renders π ``` -* You can run a standalone script by entering `include("")` in - Julian mode. For greater control, the equivalent of Python3's `if __name__ == - __main__` condition would be `if abspath() == @__FILE__` + +- You can run a standalone script by entering `include("")` in + Julian mode. For greater control, the equivalent of Python3's + `if __name__ == __main__` condition would be + `if abspath() == @__FILE__` !!! warning - One common gotcha with the Julia REPL is that there are currently - certain code changes that cannot be performed without restarting your - session, such as redefining structs (see the example below). You can - mitigate this by adding the + One common gotcha with the Julia REPL is that certain code changes + cannot be performed without restarting your session, such as redefining + structs (see the example below). You can mitigate this by adding the [Revise](https://timholy.github.io/Revise.jl/stable/) package, although restarting the session is the simplest option. - ```julia + ```julia julia> struct Point - x::Int - y::Int - end - + x::Int + y::Int + end + julia> struct Point x::Int z::Int - end + end ERROR: invalid redefinition of constant Point Stacktrace: [1] top-level scope @ REPL[2]:1 - ``` + ``` -To learn more, see the [The Julia -REPL](https://docs.julialang.org/en/v1/stdlib/REPL/) section in the Julia -manual. +Consult the [The Julia REPL](https://docs.julialang.org/en/v1/stdlib/REPL/) +section in the Julia manual for more details. ## Visual Studio Code extension -The Julia organization officially supports the [julia-vscode -extension](https://www.julia-vscode.org/) which, together with VSCode, provides -a complete solution for developing in Julia similar to a fully integrated -development environment (IDE). This boasts a number of advantages compared to a -pure REPL-driven solution: +The Julia organization officially supports the +[julia-vscode extension](https://www.julia-vscode.org/) which, together with VS +Code, provides a complete solution for developing in Julia similar to an IDE. +This boasts a number of advantages compared to a pure REPL-driven solution: -* Built-in syntax highlighting and code completion -* GUI interaction for managing options and commands -* Advanced profiling/debugging features -* Additional extensions support +- Built-in syntax highlighting and code completion +- GUI interaction for managing options and commands +- Advanced profiling/debugging features +- Additional extensions support -To install vscode, follow the instructions on how to install the official binary -for your development machine from the [official -website](https://code.visualstudio.com/). Next, click on the Extension icon in -the side Activity Bar and search for "Julia". The official Julia extension -should be the first extension available. You can also install Julia within the -Quick Open input panel by pressing `Ctrl + P` and entering `ext install -julialang.language-julia`. +Follow the installation instructions from the +[official website](https://code.visualstudio.com/). After opening VS Code, click +on the Extension icon in the side Activity Bar and search for "Julia". The +official Julia extension should be the first extension available. You can also +install Julia within the Quick Open input panel by pressing `Ctrl + P` and +entering `ext install julialang.language-julia`. -![Julia VSCode Extension](../assets/JuliaVSCodeExtension.png) +![Julia VS Code Extension](../assets/JuliaVSCodeExtension.png) -Install the extension and restart vscode. We also recommend installing some +Install the extension and restart VS Code. We also recommend installing some additional extensions that will further improve the development experience: -* [Even Better - TOML](https://marketplace.visualstudio.com/items?itemName=tamasfe.even-better-toml) +- [Even Better TOML](https://marketplace.visualstudio.com/items?itemName=tamasfe.even-better-toml) (`ext install tamasfe.even-better-toml`) for working with the package TOML files (Project.toml, Manifest.toml, Artifacts.toml,...) -* [GitLens](https://marketplace.visualstudio.com/items?itemName=eamodio.gitlens) +- [GitLens](https://marketplace.visualstudio.com/items?itemName=eamodio.gitlens) (`ext install eamodio.gitlens`) for enhancing Git workflows You can experiment with Julia extension features in the Quick Open panel by writing Julia and consulting the available options. To learn more, visit the -[Julia in Visual Studio -Code](https://code.visualstudio.com/docs/languages/julia) page or the [Julia -extension's](https://www.julia-vscode.org/) official website. +[Julia in Visual Studio Code](https://code.visualstudio.com/docs/languages/julia) +page or the [Julia extension's](https://www.julia-vscode.org/) official website. ## Alternative Editor/IDE extensions @@ -137,7 +133,7 @@ supported extension, community extensions are available for a range of code editors/IDEs: - [julia-emacs](https://github.com/JuliaEditorSupport/julia-emacs.git) that - integrates a new major mode for developing in Julia + integrates a new major mode for developing in Julia - [julia-vim](https://github.com/JuliaEditorSupport/julia-vim.git) to enable Julia support for Vim/Neovim - [julia-sublime](https://github.com/JuliaEditorSupport/Julia-sublime.git) to @@ -165,52 +161,57 @@ There are two standard methods for working with Julia in notebooks: The Julia organization officially supports the [IJulia](https://julialang.github.io/IJulia.jl/stable/) kernel, or backend, for -Jupyter notebooks, which is the most popular web-based notebook solution. +Jupyter notebooks, which is the most popular web-based notebook solution. To install IJulia/Jupyter and run the notebook server: -!!! note - Instead of loading Pkg, one can simply activate pkg mode with the `]` key and enter `(@v1.9) pkg> add ` - - 1. Install Julia via any method mentioned in the [Installing Julia](@ref juliainstallation) section - 2. Open the Julia REPL by entering `julia` into your terminal - 3. Add the IJulia package via the built-in package manager: `julia> using Pkg;Pkg.add("IJulia")` - 4. Load IJulia and launch the notebook server: `julia> using IJulia; notebook()` - (run `notebook(detached=true)` if you wish that the notebook, and `notebook(dir="/some/path")` if you wish to open a notebook in a ) - server sruns in the background even if the Julia session is closed) - 5. Enter `y` to install Jupyter via Conda if you have not done so already on - your machine +!!! note + Instead of loading Pkg, one can simply activate pkg mode with the `]` + key and enter `(@v1.9) pkg> add ` + +1. Install Julia via any method mentioned in the [Installing Julia](@ref + juliainstallation) section +2. Open the Julia REPL by entering `julia` into your terminal +3. Add the IJulia package via the built-in package manager: + `julia> using Pkg;Pkg.add("IJulia")` +4. Load IJulia and launch the notebook server: `julia> using IJulia; notebook()` + (run `notebook(detached=true)` if you wish that the notebook, and + `notebook(dir="/some/path")` if you wish to open a notebook in a ) server + sruns in the background even if the Julia session is closed) +5. Enter `y` to install Jupyter via Conda if you have not done so already on + your machine The notebook dashboard should open within your web browser. If you already have jupyter installed ([Installing Jupyter](https://jupyter.org/install)), you can enter `n` when prompted by the Julia REPL and instead run `jupyter notebook` -from the terminal. Visit the [Running -IJulia](https://julialang.github.io/IJulia.jl/stable/manual/running/#Running-IJulia) +from the terminal. Visit the +[Running IJulia](https://julialang.github.io/IJulia.jl/stable/manual/running/#Running-IJulia) section in the official IJulia docs for more information. ### Pluto notebooks [Pluto.jl](https://plutojl.org/) is an alternative notebook solution built with Julia in mind. It integrates well with the language and boasts a number of -features that are not available or are difficult to achieve with the Jupyter -solution: +features that are not available or are difficult to achieve with Jupyter: -* Works with Julia's built-in package manager for native reproducibility -* Live docs feature, essentially Julia's help mode available within the notebook -* Works with normal Julia (.jl) files as opposed to .ipynb files -* Extendable via packages like +- Works with Julia's built-in package manager for native reproducibility +- Live docs feature (essentially Julia's help mode available within the + notebook) +- Works with normal Julia (.jl) files as opposed to .ipynb files +- Extendable via packages like [PlutoUI](https://featured.plutojl.org/basic/plutoui.jl) and [PlutoPDF](https://github.com/JuliaPluto/PlutoPDF.jl.git) To install and run the Pluto server: - 1. Install Julia via any method mentioned in the [Installing Julia](@ref juliainstallation) section - 2. Open the Julia REPL by entering `julia` into your terminal - 3. Add the Pluto package via the built-in package manager: `julia> using Pkg;Pkg.add("Pluto")` - 4. Load Pluto and launch the notebook server: `julia> using Pluto; Pluto.run()` - 5. Copy/paste the given URL (http://localhost:...) into your web browser - -A number of featured notebooks are [available -online](https://featured.plutojl.org/) that include basic tutorials and powerful -demonstrations achieved with Pluto. - +1. Install Julia via any method mentioned in the [Installing Julia](@ref + juliainstallation) section +2. Open the Julia REPL by entering `julia` into your terminal +3. Add the Pluto package via the built-in package manager: + `julia> using Pkg;Pkg.add("Pluto")` +4. Load Pluto and launch the notebook server: `julia> using Pluto; Pluto.run()` +5. Copy/paste the given URL (http://localhost:...) into your web browser + +A number of featured notebooks are +[available online](https://featured.plutojl.org/) that include basic tutorials +and powerful demonstrations achieved with Pluto.