# General Usage

**URL:** https://discourse.julialang.org/c/usage/6.md?page=1059

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

**Page:** 1060

---

## [Workflow to produce dynamic documents?](https://discourse.julialang.org/t/workflow-to-produce-dynamic-documents/2657)

<div class="topic-metadata">

**Author:** [@sylvaticus](https://discourse.julialang.org/u/sylvaticus)\
**Replies:** 2\
**Last updated:** [March 14, 2017, 8:36am UTC](https://discourse.julialang.org/t/workflow-to-produce-dynamic-documents/2657 "2017-03-14T08:36:47Z")

</div>

Hello, is there any “suggested” workflow to produce dynamic documents with Julia and Juno ? I mean a place where one can mix LaTeX (better) or Markdown (ok) code with Julia code and get it compiled together with Julia …

---

## [Incorrect results from \`@which\` and \`@code\_warntype\` for literal powers](https://discourse.julialang.org/t/incorrect-results-from-which-and-code-warntype-for-literal-powers/2630)

<div class="topic-metadata">

**Author:** [@rdeits](https://discourse.julialang.org/u/rdeits)\
**Replies:** 1\
**Last updated:** [March 14, 2017, 4:15am UTC](https://discourse.julialang.org/t/incorrect-results-from-which-and-code-warntype-for-literal-powers/2630 "2017-03-14T04:15:08Z")

</div>

I’m trying to use the new literal exponent behavior introduced in https://github.com/JuliaLang/julia/pull/20530 and https://github.com/JuliaLang/julia/pull/20889. I think I’m correctly overloading literal\_pow, but variou…

---

## [\`Float\` type like \`Int\` type](https://discourse.julialang.org/t/float-type-like-int-type/1164)

<div class="topic-metadata">

**Author:** [@juliohm](https://discourse.julialang.org/u/juliohm)\
**Replies:** 29\
**Last updated:** [March 14, 2017, 12:32am UTC](https://discourse.julialang.org/t/float-type-like-int-type/1164 "2017-03-14T00:32:13Z")

</div>

I find myself always writing a type alias for floating points in order to make my package neutral to machine word size: typealias Float Float64 Why there is no definition like Int that becomes Int64 or Int32 depending …

---

## [Container broadcasting memory/performance hit in 0.6?](https://discourse.julialang.org/t/container-broadcasting-memory-performance-hit-in-0-6/2647)

<div class="topic-metadata">

**Author:** [@marius311](https://discourse.julialang.org/u/marius311)\
**Replies:** 2\
**Last updated:** [March 13, 2017, 11:25pm UTC](https://discourse.julialang.org/t/container-broadcasting-memory-performance-hit-in-0-6/2647 "2017-03-13T23:25:07Z")

</div>

I don’t understand why the latter two calls below use twice the memory and are much slower than the first call. I had thought this type of broadcasting should work efficiently now but maybe I misunderstood? I’ve checked …

---

## [How to push! new row to array in hdf5 file?](https://discourse.julialang.org/t/how-to-push-new-row-to-array-in-hdf5-file/2608)

<div class="topic-metadata">

**Author:** [@programista](https://discourse.julialang.org/u/programista)\
**Replies:** 3\
**Last updated:** [March 13, 2017, 8:17pm UTC](https://discourse.julialang.org/t/how-to-push-new-row-to-array-in-hdf5-file/2608 "2017-03-13T20:17:27Z")

</div>

How to push! new row to array in hdf5 file without read and write the array? | | |\_| | | | (\_| | | Version 0.5.0 (2016-09-19 18:14 UTC) \_/ |\\\_\_'\_|\_|\_|\\\_\_'\_| | Official http://julialang.org/ release |\_\_/ …

---

## [Very new to programming](https://discourse.julialang.org/t/very-new-to-programming/2642)

<div class="topic-metadata">

**Author:** [@Smaug](https://discourse.julialang.org/u/Smaug)\
**Replies:** 3\
**Last updated:** [March 13, 2017, 6:26pm UTC](https://discourse.julialang.org/t/very-new-to-programming/2642 "2017-03-13T18:26:34Z")

</div>

Hello, 'am Smaug. This is my first post here. I am very very new to programming, I don’t know how things work, and I am scared of terms like multiple dispatch or parallelism 'coz I have no idea what they are. Technica…

---

## [Stack-allocating wrapped C++ objects](https://discourse.julialang.org/t/stack-allocating-wrapped-c-objects/2635)

<div class="topic-metadata">

**Author:** [@barche](https://discourse.julialang.org/u/barche)\
**Replies:** 2\
**Last updated:** [March 13, 2017, 6:05pm UTC](https://discourse.julialang.org/t/stack-allocating-wrapped-c-objects/2635 "2017-03-13T18:05:51Z")

</div>

In CxxWrap.jl, each C++ type has an associated type of the form: type WrappedCxxType ptr::Ptr{Void} # Pointer to the C++ object end The reason for this is that the C++ object may be created using a constructor called…

---

## [Run a macro on all code evaluated by julia](https://discourse.julialang.org/t/run-a-macro-on-all-code-evaluated-by-julia/2633)

<div class="topic-metadata">

**Author:** [@bramtayl](https://discourse.julialang.org/u/bramtayl)\
**Replies:** 5\
**Last updated:** [March 13, 2017, 3:06pm UTC](https://discourse.julialang.org/t/run-a-macro-on-all-code-evaluated-by-julia/2633 "2017-03-13T15:06:04Z")

</div>

Let’s say I have a function that transforms julia code, and I want to prerun it on any code ever evaluated by Julia. Is there a way to do this? If not, it seems like a great way to customize the Julia experience

---

## [How to compress HDF5 data?](https://discourse.julialang.org/t/how-to-compress-hdf5-data/2636)

<div class="topic-metadata">

**Author:** [@programista](https://discourse.julialang.org/u/programista)\
**Replies:** 2\
**Last updated:** [March 13, 2017, 2:46pm UTC](https://discourse.julialang.org/t/how-to-compress-hdf5-data/2636 "2017-03-13T14:46:37Z")

</div>

How to compress HDF5 data ? julia\> using HDF5 julia\> fid=h5open("file.h5","w") HDF5 data file: file.h5 julia\> close(fid) julia\> julia\> fid = h5open("file.h5","r+") HDF5 data file: file.h5 julia\> write(fid,"A",rand(…

---

## [How to use \`@test\_skip\` properly?](https://discourse.julialang.org/t/how-to-use-test-skip-properly/2628)

<div class="topic-metadata">

**Author:** [@anon94023334](https://discourse.julialang.org/u/anon94023334)\
**Replies:** 10\
**Last updated:** [March 13, 2017, 2:17pm UTC](https://discourse.julialang.org/t/how-to-use-test-skip-properly/2628 "2017-03-13T14:17:47Z")

</div>

So, we are having intermittent failures with a particular test (say @test foo). According to the docs @test\_skip is made for this scenario. So: @test\_skip begin @test foo end … but CI still fails because the test is…

---

## [Delete! in sparse matrix](https://discourse.julialang.org/t/delete-in-sparse-matrix/2634)

<div class="topic-metadata">

**Author:** [@CarloLucibello](https://discourse.julialang.org/u/CarloLucibello)\
**Replies:** 2\
**Last updated:** [March 13, 2017, 9:52am UTC](https://discourse.julialang.org/t/delete-in-sparse-matrix/2634 "2017-03-13T09:52:31Z")

</div>

suppose you have the following sparse matrix julia\> type A end julia\> m=spzeros(A,10,10) 10×10 SparseMatrixCSC{A,Int64} with 0 stored entries julia\> m\[1,1\] = A() A() Now I would like to remove the element in (1,1). …

---

## [Simple web app](https://discourse.julialang.org/t/simple-web-app/2578)

<div class="topic-metadata">

**Author:** [@yakir12](https://discourse.julialang.org/u/yakir12)\
**Replies:** 4\
**Last updated:** [March 13, 2017, 9:33am UTC](https://discourse.julialang.org/t/simple-web-app/2578 "2017-03-13T09:33:07Z")

</div>

I want to build a simple web app that allows the user to control a few variables (maybe from a slider?) updating a graph from a web browser. Escher is ideal but not an option for Julia v0.5 (see issue 199). Do you guys …

---

## [Looping over variable names inside a function](https://discourse.julialang.org/t/looping-over-variable-names-inside-a-function/2629)

<div class="topic-metadata">

**Author:** [@dpo](https://discourse.julialang.org/u/dpo)\
**Replies:** 2\
**Last updated:** [March 13, 2017, 5:52am UTC](https://discourse.julialang.org/t/looping-over-variable-names-inside-a-function/2629 "2017-03-13T05:52:31Z")

</div>

I’m trying to write what I thought should be a simple loop over local variables names inside a function for debugging purposes. The pattern is very simple: function myfunction(args...; kwargs...) x, y, z = other\_func…

---

## [How to bypass username/password prompt when updating private packages](https://discourse.julialang.org/t/how-to-bypass-username-password-prompt-when-updating-private-packages/2574)

<div class="topic-metadata">

**Author:** [@BVPs](https://discourse.julialang.org/u/BVPs)\
**Replies:** 9\
**Last updated:** [March 12, 2017, 7:39pm UTC](https://discourse.julialang.org/t/how-to-bypass-username-password-prompt-when-updating-private-packages/2574 "2017-03-12T19:39:48Z")

</div>

I have some private packages on GitLab.com, and just added one of them via Pkg.clone("https://gitlab.com/..."). Now, it set things up correctly, but whenever I run Pkg.update(), julia asks me my username and password on G…

---

## [V0.6: isalpha (and similar) deprecation warning for arrays of (Sub)Strings](https://discourse.julialang.org/t/v0-6-isalpha-and-similar-deprecation-warning-for-arrays-of-sub-strings/2623)

<div class="topic-metadata">

**Author:** [@SaschaMann](https://discourse.julialang.org/u/SaschaMann)\
**Replies:** 2\
**Last updated:** [March 12, 2017, 3:41pm UTC](https://discourse.julialang.org/t/v0-6-isalpha-and-similar-deprecation-warning-for-arrays-of-sub-strings/2623 "2017-03-12T15:41:03Z")

</div>

The following code results in a deprecation warning telling one to use all(isalpha, s) instead of isalpha(s): julia\> s = \["abc", "def", "ghi"\] 3-element Array{String,1}: "abc" "def" "ghi" julia\> all(isalpha, s) WARN…

---

## [How to work locally with the same source in v0.5 and v0.6](https://discourse.julialang.org/t/how-to-work-locally-with-the-same-source-in-v0-5-and-v0-6/2621)

<div class="topic-metadata">

**Author:** [@Tamas\_Papp](https://discourse.julialang.org/u/Tamas_Papp)\
**Replies:** 3\
**Last updated:** [March 12, 2017, 2:14pm UTC](https://discourse.julialang.org/t/how-to-work-locally-with-the-same-source-in-v0-5-and-v0-6/2621 "2017-03-12T14:14:29Z")

</div>

I have a package which I have been developing while using v0.5. Now that I would like to prepare it for v0.6. I have both versions of Julia running on my computer just fine. I would prefer to keep fix things in a single…

---

## [Libjulia / c-api : how to unbox SparseMatrixCSC](https://discourse.julialang.org/t/libjulia-c-api-how-to-unbox-sparsematrixcsc/2620)

<div class="topic-metadata">

**Author:** [@Maxime\_Coorevits](https://discourse.julialang.org/u/Maxime_Coorevits)\
**Replies:** 7\
**Last updated:** [March 12, 2017, 2:06pm UTC](https://discourse.julialang.org/t/libjulia-c-api-how-to-unbox-sparsematrixcsc/2620 "2017-03-12T14:06:09Z")

</div>

A new question about the libjulia c-api. My project is fully functional and I’m able to interact with the c-api in my VS2017 / C++ solution. I work on a C++ wrapper of the ACME package that (intensively) use sparse matr…

---

## [Enforcing latest master in REQUIRE](https://discourse.julialang.org/t/enforcing-latest-master-in-require/2617)

<div class="topic-metadata">

**Author:** [@Tamas\_Papp](https://discourse.julialang.org/u/Tamas_Papp)\
**Replies:** 3\
**Last updated:** [March 12, 2017, 9:43am UTC](https://discourse.julialang.org/t/enforcing-latest-master-in-require/2617 "2017-03-12T09:43:43Z")

</div>

I am wondering if there is a way to request the latest master for a package in REQUIRE. Specifically, I made a PR to a package which has been merged to master, and need it for tests to run, so I put a Pkg.checkout in .t…

---

## [Restricting memory available to Julia](https://discourse.julialang.org/t/restricting-memory-available-to-julia/2613)

<div class="topic-metadata">

**Author:** [@mbeltagy](https://discourse.julialang.org/u/mbeltagy)\
**Replies:** 0\
**Last updated:** [March 12, 2017, 12:09am UTC](https://discourse.julialang.org/t/restricting-memory-available-to-julia/2613 "2017-03-12T00:09:20Z")

</div>

I am running a small Julia webapp on Heroku. The machine on which Julia is running would report that report 60GB total memory and 5GB gree. $ free -g total used free shared buffers …

---

## [Pkg.update() failes](https://discourse.julialang.org/t/pkg-update-failes/2607)

<div class="topic-metadata">

**Author:** [@ufechner7](https://discourse.julialang.org/u/ufechner7)\
**Replies:** 4\
**Last updated:** [March 11, 2017, 10:14pm UTC](https://discourse.julialang.org/t/pkg-update-failes/2607 "2017-03-11T22:14:12Z")

</div>

Hello, today I have the following problem: julia\> Pkg.update() INFO: Updating METADATA... INFO: Updating ZLog master... INFO: Updating Lint master... INFO: Computing changes... ERROR: unsatisfiable package requirements…

---

## [Controlling memory allocation using external struct as placeholder](https://discourse.julialang.org/t/controlling-memory-allocation-using-external-struct-as-placeholder/2593)

<div class="topic-metadata">

**Author:** [@davidbp](https://discourse.julialang.org/u/davidbp)\
**Replies:** 5\
**Last updated:** [March 11, 2017, 6:37pm UTC](https://discourse.julialang.org/t/controlling-memory-allocation-using-external-struct-as-placeholder/2593 "2017-03-11T18:37:57Z")

</div>

Hello Guys! This question is about a function that I will post below but it is also about a more generic question which is … How can we efficiently deal with a function f that is called many times and every function cal…

---

## [State of AWS.jl](https://discourse.julialang.org/t/state-of-aws-jl/2587)

<div class="topic-metadata">

**Author:** [@Tomas\_Pevny](https://discourse.julialang.org/u/Tomas_Pevny)\
**Replies:** 1\
**Last updated:** [March 11, 2017, 6:35pm UTC](https://discourse.julialang.org/t/state-of-aws-jl/2587 "2017-03-11T18:35:40Z")

</div>

Hello all, I would like to ask, if someone takes care of AWS.jl. The package seems to be unmaintained, as the pull request to remove warning in Julia 0.5 was not added to the package. Is anyone interested in this packa…

---

## [Is redirect\_stderr broken?](https://discourse.julialang.org/t/is-redirect-stderr-broken/2606)

<div class="topic-metadata">

**Author:** [@jonathanBieler](https://discourse.julialang.org/u/jonathanBieler)\
**Replies:** 3\
**Last updated:** [March 11, 2017, 6:23pm UTC](https://discourse.julialang.org/t/is-redirect-stderr-broken/2606 "2017-03-11T18:23:34Z")

</div>

julia\> redirect\_stdout() (Base.PipeEndpoint(RawFD(21) open, 0 bytes waiting), Base.PipeEndpoint(RawFD(22) open, 0 bytes waiting)) julia\> print("asd") julia\> redirect\_stderr() (Base.PipeEndpoint(RawFD(23) open, 0 bytes …

---

## [Confused by the various string "factory" functions - shouldn't these play nice together?](https://discourse.julialang.org/t/confused-by-the-various-string-factory-functions-shouldnt-these-play-nice-together/2591)

<div class="topic-metadata">

**Author:** [@essenciary](https://discourse.julialang.org/u/essenciary)\
**Replies:** 12\
**Last updated:** [March 11, 2017, 6:21pm UTC](https://discourse.julialang.org/t/confused-by-the-various-string-factory-functions-shouldnt-these-play-nice-together/2591 "2017-03-11T18:21:03Z")

</div>

I’ve stumbled onto some things that I don’t quite understand - it all started with me trying to get join to generate empty strings "" when joining nothings (Voids). Between string, String, convert and string generating …

---

## [Package update error, Optim.jl](https://discourse.julialang.org/t/package-update-error-optim-jl/2600)

<div class="topic-metadata">

**Author:** [@zhangliye](https://discourse.julialang.org/u/zhangliye)\
**Replies:** 4\
**Last updated:** [March 11, 2017, 3:58pm UTC](https://discourse.julialang.org/t/package-update-error-optim-jl/2600 "2017-03-11T15:58:04Z")

</div>

Found an an error when run “Pkg.update()” Windows 7; Julia0.5.0.4 (downloaded from Julia computting website )

---

## [Calling libjulia function from C with unicode](https://discourse.julialang.org/t/calling-libjulia-function-from-c-with-unicode/2596)

<div class="topic-metadata">

**Author:** [@Maxime\_Coorevits](https://discourse.julialang.org/u/Maxime_Coorevits)\
**Replies:** 5\
**Last updated:** [March 11, 2017, 10:07am UTC](https://discourse.julialang.org/t/calling-libjulia-function-from-c-with-unicode/2596 "2017-03-11T10:07:53Z")

</div>

Hello, I’ve post two questions on Stackoverflow about confusion using libjulia in C. http://stackoverflow.com/questions/42625565/libjulia-julia-c-api-named-variable-convention-for-function-call I’m confusing about cal…

---

## [DataFrames related stack overflow](https://discourse.julialang.org/t/dataframes-related-stack-overflow/2563)

<div class="topic-metadata">

**Author:** [@undef](https://discourse.julialang.org/u/undef)\
**Replies:** 2\
**Last updated:** [March 10, 2017, 8:47pm UTC](https://discourse.julialang.org/t/dataframes-related-stack-overflow/2563 "2017-03-10T20:47:42Z")

</div>

Hey there! I’m relatively new to Julia and I’ve encountered an error I don’t understand. It seems like I’m getting a stack overflow when indexing a DataFrame - here’s the error message: ERROR: LoadError: StackOverflow…

---

## [Pkg.update() results in segfault error](https://discourse.julialang.org/t/pkg-update-results-in-segfault-error/2575)

<div class="topic-metadata">

**Author:** [@thushalala](https://discourse.julialang.org/u/thushalala)\
**Replies:** 4\
**Last updated:** [March 10, 2017, 3:46pm UTC](https://discourse.julialang.org/t/pkg-update-results-in-segfault-error/2575 "2017-03-10T15:46:15Z")

</div>

I decided to change installed julia 4.7(everything were fine) to julia 5.1(both are generic linux tarballs unpacked in /opt with PATH set accordingly) and this resulted in error about missing libgit2, so i couldn\`t run j…

---

## [Compiling shared C libraries for julia in macOS](https://discourse.julialang.org/t/compiling-shared-c-libraries-for-julia-in-macos/2577)

<div class="topic-metadata">

**Author:** [@chkwon](https://discourse.julialang.org/u/chkwon)\
**Replies:** 1\
**Last updated:** [March 9, 2017, 9:23pm UTC](https://discourse.julialang.org/t/compiling-shared-c-libraries-for-julia-in-macos/2577 "2017-03-09T21:23:19Z")

</div>

I have two C libraries libfoo and libbar, and libbar requires libfoo. I need to call libbar from julia in macOS. I need to compile them separately. How to compile them? Should they need to be dylb file, or are so file…

---

## [Julia's equivalent to Fortran elemental functions](https://discourse.julialang.org/t/julias-equivalent-to-fortran-elemental-functions/2576)

<div class="topic-metadata">

**Author:** [@PieterjanRobbe](https://discourse.julialang.org/u/PieterjanRobbe)\
**Replies:** 3\
**Last updated:** [March 9, 2017, 8:50pm UTC](https://discourse.julialang.org/t/julias-equivalent-to-fortran-elemental-functions/2576 "2017-03-09T20:50:43Z")

</div>

Fortran has elemental functions. This means that you can define a function for primitive types (int, double…) and they will automatically work for vectors and matrices that contain these primitive types. Consider the e…

[Previous page](https://discourse.julialang.org/c/usage/6.md?page=1058)

[Next page](https://discourse.julialang.org/c/usage/6.md?page=1060)
