[julia-users] Re: linreg strangely picky about inputs

2016-05-22 Thread Gabriel Gellner
So I am not able to get such a dramatic speed up. Do you mean something beyond: function linreg2{S <: Number, T <: Number}(x::AbstractArray{S}, y::AbstractArray{T}) mx = mean(x) my = mean(y) b1 = Base.covm(x, mx, y, my)/varm(x, mx) b0 = my - b1*mx return [b0, b1] end Which I

[julia-users] How to lauch PGFPlots under Windows10.

2016-05-22 Thread Андрей Логунов
Pkg.added PGFPlots and TikzPictures. In REPL console the package generates this: TikzPictures.TikzPicture("\\begin{axis}[view = {{0}{90}}]\\addplot+ coordinates {\n(1, 2)\n(2, 4)\n(3, 1)\n};\n\\end{axis}\n","","\\usepackage{pgfplots}\n\\pgfplotsset{compat=newest}\n\\pgfplotsset{every axis leg

[julia-users] Re: How to install 0.4.5 on Ubuntu?

2016-05-22 Thread Андрей Логунов
Start with compilers^ sudo apt-get install gcc sudo apt-get install g++ sudo apt-get install gfortran Then on with make: sudo apt-get install cmake Thru Ubuntu PPA (12.04+): sudo add-apt-repository ppa:staticfloat/juliareleases sudo add-apt-repository ppa:staticfloat/julia-deps sudo

[julia-users] Re: Let's Bridge the IRC and Gitter

2016-05-22 Thread Lyndon White
Alright for purpose of testing, I have created an instance of gitter-irc-bot on Heroku. The program was suggested by ScottPJones. It shows up on IRC as *GitterBot*. and on gitter as *oxinabot *with a little robot icon saying IRC. See github profile

[julia-users] Re: linreg strangely picky about inputs

2016-05-22 Thread Gabriel Gellner
On Sunday, May 22, 2016 at 8:37:43 PM UTC-7, Andreas Noack wrote: > > I don't think that linreg has received much attention over the years. Most > often it is almost as simple to use \. It you take a look at linreg then > I'd suggest that you try to write in terms of cov and var and return a > t

[julia-users] Re: linreg strangely picky about inputs

2016-05-22 Thread Gabriel Gellner
So I have a PR https://github.com/JuliaLang/julia/pull/16523 I get an error on AppVeyor build which I don't understand. Any tips, or missed documentation is greatly appreciated! My GitHub kung-fu is fledgling at best. On Saturday, May 21, 2016 at 11:33:20 AM UTC-7, Gabriel Gellner wrote: > > >

[julia-users] Re: linreg strangely picky about inputs

2016-05-22 Thread Andreas Noack
I don't think that linreg has received much attention over the years. Most often it is almost as simple to use \. It you take a look at linreg then I'd suggest that you try to write in terms of cov and var and return a tuple instead of an Array. That will speed up the computation already now an

Re: [julia-users] Re: static compilation

2016-05-22 Thread Jameson
I tried building a new system image on v0.4 starting from an existing sys.so library (as you tried below), and found that it failed with the same "Task cannot be serialized" error. So I guess that use case must have been fixed during v0.5 development. The workaround is to start with inference.j

[julia-users] Re: Parallel computing

2016-05-22 Thread Chris Rackauckas
You need to use @everywhere to have the function defined on the workers. Can we see some code? On Saturday, May 21, 2016 at 6:33:17 PM UTC-7, SHORE SHEN wrote: > > Hi > > Im running a loop, and system shows that only 20% of CPU were used. I then > think that due to the fact that my CPU is 4 core

Re: [julia-users] Suppressing plot windows by default - is this purposeful?

2016-05-22 Thread Chris Rackauckas
As I noted when I explained this solution to him in the Gitter, I think this should be explained here: http://docs.julialang.org/en/release-0.4/manual/noteworthy-differences/. This is a feature for a good reason. It's the same feature that makes it so that you don't have to add semicolins every

[julia-users] Re: Let's Bridge the IRC and Gitter

2016-05-22 Thread Chris Rackauckas
I like this idea. I am fine if it's a different channel: it's easy to sit on different channels on Gitter and get notified to switch between them. I'd IRC but I wouldn't even know a good client to use: I kind of think of it as antiquated and from a previous generation (with no ill will attached

[julia-users] Let's Bridge the IRC and Gitter

2016-05-22 Thread Lyndon White
Hi all, So it should be generally known that Julia has a IRC Channel: http://webchat.freenode.net/?channels=julia and a Gitter https://gitter.im/JuliaLang/julia The Gitter is (AFAICT) moderately active, with a mix of new-comers and experienced users. The IRC is not. As of the last week or so I

Re: [julia-users] Suppressing plot windows by default - is this purposeful?

2016-05-22 Thread Tom Breloff
I still think this is a documentation issue, if anything. Julia is not Matlab (in a good way) and we shouldn't be forced to match their conventions. If you have suggestions for documentation language, please post it! On Sunday, May 22, 2016, Steven G. Johnson wrote: > PyPlot (by default) opens a

Re: [julia-users] why does Julia have both map and broadcast?

2016-05-22 Thread Stefan Karpinski
The only reason I can think of for map to not just do what broadcast does is map's more strict requirements could potentially catch errors. However, I suspect that as soon as you used the result, you would rapidly get an error anyway, so it's possible that we should merge these. There may be some o

Re: [julia-users] Passing a function outputted by a higher order function to C - function not yet c-callable

2016-05-22 Thread Mosè Giordano
Hi Michael, > Thank you for the quick reply. Could you please elaborate on how to pass > the data explicitly as you suggest? I don't quite understand. > This is a very useful post about closures in general: http://julialang.org/blog/2013/05/callback Bye, Mosè

[julia-users] Re: How to install 0.4.5 on Ubuntu?

2016-05-22 Thread Tony Kelman
That page is out of date, the PPA isn't really recommended any more. You can download and extract the generic Linux binaries on almost any distribution.

[julia-users] Re: Pkg.update for packages that changed repository (git remote)

2016-05-22 Thread Tony Kelman
URLs in metadata need to be manually updated when repos are moved. It doesn't need to be done right away because github puts in place a redirect, but that redirect can be interfered with. What problems did you have with Showoff?

Re: [julia-users] Passing a function outputted by a higher order function to C - function not yet c-callable

2016-05-22 Thread Yichao Yu
On Sun, May 22, 2016 at 4:24 PM, Michael Lindon wrote: > Hi Yichao Yu, > > Thank you for the quick reply. Could you please elaborate on how to pass the > data explicitly as you suggest? I don't quite understand. julia> foo(x, y) = convert(Cdouble, x * y) foo (generic function with 1 method) juli

Re: [julia-users] Passing a function outputted by a higher order function to C - function not yet c-callable

2016-05-22 Thread Michael Lindon
Hi Yichao Yu, Thank you for the quick reply. Could you please elaborate on how to pass the data explicitly as you suggest? I don't quite understand. On Sunday, May 22, 2016 at 4:14:02 PM UTC-4, Yichao Yu wrote: > > On Sun, May 22, 2016 at 4:09 PM, Michael Lindon > > wrote: > > I have function

Re: [julia-users] Passing a function outputted by a higher order function to C - function not yet c-callable

2016-05-22 Thread Yichao Yu
On Sun, May 22, 2016 at 4:09 PM, Michael Lindon wrote: > I have function baz which outputs the product of the input at 2: > > function baz{T}(x::T) > return convert(Cdouble,x*2)::Cdouble > end > > I want to use this function in some C function that I am calling. Running > > julia> myptr=cf

[julia-users] Passing a function outputted by a higher order function to C - function not yet c-callable

2016-05-22 Thread Michael Lindon
I have function baz which outputs the product of the input at 2: function baz{T}(x::T) return convert(Cdouble,x*2)::Cdouble end I want to use this function in some C function that I am calling. Running julia> myptr=cfunction(baz,Cdouble,(Ref{Cdouble})) Ptr{Void} @0x7f2623c9c1d0 is f

[julia-users] Re: Pkg.update for packages that changed repository (git remote)

2016-05-22 Thread 'Tobias Knopp' via julia-users
As far as I understand it for now everything just works, because there is a redirect. Not sure if the new URL should be changed in METADATA.jl or if this will be done automatically when the next release is tagged. Tobias Am Sonntag, 22. Mai 2016 19:14:21 UTC+2 schrieb Andreas Lobinger: > > Hell

Re: [julia-users] Suppressing plot windows by default - is this purposeful?

2016-05-22 Thread Steven G. Johnson
PyPlot (by default) opens a window in the REPL, plots inline in IJulia, and is non-interactive (waits for an explicit, blocking show() call to open a window) when run via "julia somescript.jl" ... is that what you want?

[julia-users] Pkg.update for packages that changed repository (git remote)

2016-05-22 Thread Andreas Lobinger
Hello colleagues, looking at METADATA for e.g. Gtk.jl i recognized that the development was moved from JuliaLang to JuliaGraphics. Will this be updated in a single step by Pkg.update or are there manual steps needed? (i had some problems with the ShowOff move). Wishing a happy day, And

[julia-users] OT: getting a sublime text license

2016-05-22 Thread Andreas Lobinger
Hello colleagues, it's offtopic, but i had the feeling i'm not alone testing sublime text. Do you know a way to pay for the license without using Paypal? I'm not a Paypal user and never wanted to be and the classical way of passing through Paypal via valid Credit Card seems now to be following

[julia-users] nested logit model

2016-05-22 Thread tjvyxjq2612
Hi every one, It is my first time to use Julia. I spend a lot time on this language but I still have a lot of questions. Now I want to build nested logit model. I have done this model in STATA but I also need know how to build this model in Julia. Here is the stata code: nlogitgen type = tra

Re: [julia-users] Suppressing plot windows by default - is this purposeful?

2016-05-22 Thread David Parks
Hi Tom, thanks for the reply, and just to be clear, I love your work on Plots, not trying to complain, just discussing a long-term usability point. I don't fully understand the mechanisms under the covers that open a UI window. This is via Electron I presume? You're certainly correct that a UI

[julia-users] Re: How to install 0.4.5 on Ubuntu?

2016-05-22 Thread Henri Girard
Works well on ubuntu with 0.4.5 version Le dimanche 22 mai 2016 12:27:37 UTC+2, Nils Gudat a écrit : > > Slightly stupid question from someone who is forced to use Linux on a > server: how can I get the latest stable version as opposed ot the dev > release? > I followed the instructions from he

[julia-users] Re: vector assignment performance

2016-05-22 Thread Jutho
https://github.com/ahwillia/Einsum.jl or https://github.com/Jutho/TensorOperations.jl might also be of interest Op vrijdag 20 mei 2016 17:17:08 UTC+2 schreef Matt Bauman: > > I believe something just like that is already implemented in > Devectorize.jl's @devec macro. Try: `@devec y[:] = y + a .

Re: [julia-users] parsing error?

2016-05-22 Thread Davide Lasagna
Thanks for pointing to the page I should have read first! :) On Sunday, May 22, 2016 at 3:46:35 PM UTC+1, Joshua Ballanco wrote: > > Hi Davide, > > Looks like an issue of operator precedence: > http://docs.julialang.org/en/release-0.4/manual/mathematical-operations/#operator-precedence > > That i

Re: [julia-users] parsing error?

2016-05-22 Thread Joshua Ballanco
Hi Davide, Looks like an issue of operator precedence:  http://docs.julialang.org/en/release-0.4/manual/mathematical-operations/#operator-precedence That is, since `\` is higher precedence than `:`, your initial line is being parsed as `(randn(3, 3)\1):3`, so the error seems to be correct. Chee

[julia-users] parsing error?

2016-05-22 Thread Davide Lasagna
Hi, Is this a parsing "error" worth reporting? julia> randn(3, 3)\1:3 ERROR: MethodError: no method matching /(::Int64, ::Array{Float64,2}) Closest candidates are: /(::Integer, ::Integer) /(::Real, ::Complex{T<:Real}) /(::Union{Int16,Int32,Int64,Int8}, ::BigFloat) ... [inlined code] fro

Re: [julia-users] Suppressing plot windows by default - is this purposeful?

2016-05-22 Thread STAR0SS
I thought for like one year that plotting was bugged/broken in Julia because of this. I only understood the current behavior while reading a github issue. One issue with the doc is that there's not a centralized one since plotting is done via so many different packages (it's not an issue specif

Re: [julia-users] missing subscript

2016-05-22 Thread Davide Lasagna
Thank! On Friday, May 20, 2016 at 3:03:58 PM UTC+1, Yichao Yu wrote: > > On Fri, May 20, 2016 at 9:51 AM, Davide Lasagna > wrote: > > Hi, > > > > Is there any particular reason why subscripts such as \_n are not > defined > > latex_symbols.jl? > > \_n is included, at least on the version of

Re: [julia-users] Question: How to Define an Array of Pointers Correct to Transfer it to a C function

2016-05-22 Thread Yichao Yu
On Sun, May 22, 2016 at 2:33 AM, Stefan Schnell wrote: > Hello Yichao, > > thanks for your reply. > > Now I tried another way, but without success: > > type TestStruct3 > value::Ptr{UInt16} > value_root > function TestStruct3(value) > value_root = Base.cconvert(Ptr{UI

Re: [julia-users] Suppressing plot windows by default - is this purposeful?

2016-05-22 Thread Tom Breloff
If you have suggestions for the docs, I'm all ears, but I think the default behavior is here to stay. There are too many scenarios where a gui window is not what you want... Writing to a png, inline plotting in IJulia, etc, and it already displays automatically when returned to the repl. On Sunday

[julia-users] Re: How to install 0.4.5 on Ubuntu?

2016-05-22 Thread Nils Gudat
Found it, sudo-apt get install julia=0.4.5-trusty did the trick!

[julia-users] How to install 0.4.5 on Ubuntu?

2016-05-22 Thread Kristoffer Carlsson
It doesn't work to just git checkout v0.4.5 or whichever release you want? Maybe that was in the link you posted, I didn't read it..

[julia-users] How to install 0.4.5 on Ubuntu?

2016-05-22 Thread Nils Gudat
Slightly stupid question from someone who is forced to use Linux on a server: how can I get the latest stable version as opposed ot the dev release? I followed the instructions from here (http://julialang.org/downloads/platform.html), but always end up with a 44-day old 0.5 master version inst

[julia-users] Re: Parallel computing

2016-05-22 Thread Nils Gudat
This is a rather broad question, and I would suggest that you have (another?) close look at the parallel documentation. The errors about functions not defined on worker processes e.g. suggest that you aren't using the @everywh