Re: [julia-users] Getting length of step range in function.

2015-11-10 Thread Tom Breloff
To be a little more explicit. You are "masking" the function `Base.length` with your local variable `length`. So when you write `length(range)` you are trying to "call" your local variable like it's a function. On Tue, Nov 10, 2015 at 9:47 AM, Yichao Yu wrote: > On Tue, Nov

Re: [julia-users] Re: Google releases TensorFlow as open source

2015-11-10 Thread Tom Breloff
I'm interested as well. Who wants to claim TensorFlow.jl? On Tue, Nov 10, 2015 at 9:11 AM, Ben Moran wrote: > I'm very interested in this. I haven't gone through the details yet but > they say that C++ API currently only supports a subset of the Python API > (weird!). > >

[julia-users] Re: How to interrupt a loop with a keyboard keystroke

2015-11-10 Thread Cedric St-Jean
This works too: try while true end catch x if isa(x, InterruptException) return array end end On Tuesday, November 10, 2015 at 8:23:47 AM UTC-5, Felipe Jiménez wrote: > > Thank you, Palli and Cedri. > > Palli's answer shows it's not as easy as I thought. Cedric's answer

[julia-users] Re: Google releases TensorFlow as open source

2015-11-10 Thread Ben Moran
I'm very interested in this. I haven't gone through the details yet but they say that C++ API currently only supports a subset of the Python API (weird!). One possibility is to use PyCall to wrap the Python version, like was done for PyPlot, SymPy and like I began tentatively for Theano here

[julia-users] Re: Chi square test in Julia?

2015-11-10 Thread Joshua Duncan
I found your Chi-Square test and am trying to use it. It appears to work with one array but not with two. My steps are below: This works: ChisqTest([1,2,3,4]) This doesn't: ChisqTest([1,2,3,4],[1,2,2,4]) It errors with the following: LoadError: MethodError: `ChisqTest` has no method

[julia-users] Re: Google releases TensorFlow as open source

2015-11-10 Thread Randy Zwitch
For me, the bigger question is how does TensorFlow fit in/fill in gaps in currently available Julia libraries? I'm not saying that someone who is sufficiently interested shouldn't wrap the library, but it'd be great to identify what major gaps remain in ML for Julia and figure out if

[julia-users] Fill below a density plot with color in Winston

2015-11-10 Thread milktrader
Suppose you have a density plot ... using Winston, KernelDensity k = kde(rand(100)) Winston.plot(k) Which would look something similar to this: 1) How

Re: [julia-users] Google releases TensorFlow as open source

2015-11-10 Thread Stefan Karpinski
Time for a JuliaML org? On Tuesday, November 10, 2015, Tom Breloff wrote: > I'm interested as well. Who wants to claim TensorFlow.jl? > > On Tue, Nov 10, 2015 at 9:11 AM, Ben Moran > wrote: > >> I'm

Re: [julia-users] Getting length of step range in function.

2015-11-10 Thread Yichao Yu
On Tue, Nov 10, 2015 at 9:37 AM, Ben Ward wrote: > Hi, > > You can get the length of a StepRange: > > julia> length(2:1:9) > > > 8 > > > But if I try to do so inside a function I get an error about not finding a > call method: > > julia> function myfun(width::Int,

Re: [julia-users] Re: How to interrupt a loop with a keyboard keystroke

2015-11-10 Thread Páll Haraldsson
On þri 10.nóv 2015 12:03, Páll Haraldsson wrote: The only game library I know available to Julia is kind of an overkill..: https://github.com/zyedidia/SFML.jl But this is something (a wrapper for a C++ game library) they have to deal with (and much more..) and you could even let a joystick

[julia-users] Re: how to specify degrees of freedom for OneSampleTTest?

2015-11-10 Thread j verzani
If you have the sample data, it is just the length of the data minus 1, so does not need to be specified, as it is computed. On Tuesday, November 10, 2015 at 9:47:43 AM UTC-5, Evan wrote: > > I want to do the following with some time series data: > > Calculate 95% confidence interval for mean

[julia-users] Re: Fill below a density plot with color in Winston

2015-11-10 Thread milktrader
> The solution to the two-color problem is ... > using Winston, KernelDensity k = kde(rand(100)) k1 = k.x[k.x .< .5]; k2 = k.x[k.x .> .5]; f1 = FillBelow(k1, k.density[1:length(k1)], color="blue"); f2 = FillBelow(k2, k.density[length(k1)+1:end], color="red"); p = FramedPlot() add(p, f1,

Re: [julia-users] Google releases TensorFlow as open source

2015-11-10 Thread Steve Kelly
FWIW I think this may be the C API: https://github.com/tensorflow/tensorflow/blob/master/tensorflow/core/public/tensor_c_api.h On Nov 10, 2015 11:05 AM, "Stefan Karpinski" wrote: > Time for a JuliaML org? > > On Tuesday, November 10, 2015, Tom Breloff

Re: [julia-users] Google releases TensorFlow as open source

2015-11-10 Thread milktrader
Yep +1 On Tuesday, November 10, 2015 at 11:05:05 AM UTC-5, Stefan Karpinski wrote: > > Time for a JuliaML org? > > On Tuesday, November 10, 2015, Tom Breloff > wrote: > >> I'm interested as well. Who wants to claim TensorFlow.jl? >> >> On Tue, Nov 10, 2015 at 9:11 AM, Ben

Re: [julia-users] Re: PyPlot won't close first figure drawn

2015-11-10 Thread lewis
I posted as an issue over on PyPlot. I got a reply about Python but not about the problem. Please point out how I have been negative. I've tried to provide information and one other user confirms that he has also seen the problem. I thought I was being pretty clear to just ask for clues or

[julia-users] Re: Fill below a density plot with color in Winston

2015-11-10 Thread milktrader
To answer question #1 only, this works ... using Winston, KernelDensity k = kde(rand(100)) fieldnames(k) # outputs ... # 2-element Array{Symbol,1}: # :x # :density f = FillBelow(k.x, k.density, color="blue") p = FramedPlot() add(p,f)

[julia-users] Re: Fill below a density plot with color in Winston

2015-11-10 Thread milktrader
I'll be honest, the code to do this in R is substantially more non-intuitive. Nice work Mike! On Tuesday, November 10, 2015 at 12:51:32 PM UTC-5, milktrader wrote: > > > The solution to the two-color problem is ... >> > > using Winston, KernelDensity > > k = kde(rand(100)) > > k1 = k.x[k.x .<

Re: [julia-users] Re: PyPlot won't close first figure drawn

2015-11-10 Thread Tom Breloff
Lewis: There are a couple things to note: - This belongs as a PyPlot issue... it's not really appropriate for julia-users - I think people have been slow to help you, not because you're a "noob", but because of your extreme negativity so far. You've spent enough time on this that

Re: [julia-users] WinRPM fails to install for fresh Julia 0.4.0 installation on Windows

2015-11-10 Thread jpclemens0
_ _ _ _(_)_ | A fresh approach to technical computing (_) | (_) (_)| Documentation: http://docs.julialang.org _ _ _| |_ __ _ | Type "?help" for help. | | | | | | |/ _` | | | | |_| | | | (_| | | Version 0.4.0 (2015-10-08 06:20 UTC) _/

[julia-users] Re: Median filter

2015-11-10 Thread Dan
As a quick stopgap, you could use the following: medianfilter1(v,ws) = [median(v[i:(i+ws-1)]) for i=1:(length(v)-ws+1)] medianfilter(v) = medianfilter1(vcat(0,v,0),3) `medianfilter` does a 3 window median filter. It is not the fastest implementation, but it works (hopefully). On Tuesday,

[julia-users] Re: PyPlot won't close first figure drawn

2015-11-10 Thread lewis
I'd still really like help with this. Here are some possible problems with the way just the first figure is being handled within PyPlot: 1.being put in the figure_queue, which holds figures for IJulia--this shouldn't be happening as I am not using IJulia in this case; 2. somehow

Re: [julia-users] Google releases TensorFlow as open source

2015-11-10 Thread Diego Javier Zea
+1 It would be good to have a *TensorFlow.jl*!

[julia-users] Re: Chi square test in Julia?

2015-11-10 Thread cormullion
Try a matrix?

[julia-users] Re: Chi square test in Julia?

2015-11-10 Thread Benjamin Deonovic
Hey Joshua, Just saw your post. I will investigate into what the issue is. I wrote this quite a while ago when I was just learning Julia! On Tuesday, November 10, 2015 at 9:10:10 AM UTC-6, Joshua Duncan wrote: > > I found your Chi-Square test and am trying to use it. It appears to work > with

[julia-users] Re: Chi square test in Julia?

2015-11-10 Thread Benjamin Deonovic
Looks like the state of Julia's "Factors" (PooledDataArrays) is still quite a fast evolving monster. Because of this there hasn't been a proper implementation of R's "table" function. For now, if you want to run ChisqTest in Julia on two vectors do it on the matrix you would obtain in R by

Re: [julia-users] Re: CUDART and CURAND problem on running the same "do" loop twice

2015-11-10 Thread Andrei Zh
> But I can replicate the bug if I use CURAND. I'd suggest filing an issue > with > that package. Most likely it needs to (and, you need to) initialize > resources > according to these instructions: > https://github.com/JuliaGPU/CUDArt.jl#initializing-and-freeing-ptx-modules > > CURAND.jl

[julia-users] Re: Chi square test in Julia?

2015-11-10 Thread Benjamin Deonovic
Okay I have figured out the issue. I will fix it so it works the way you expected it to work. Before the fix goes live though it should work to do: ChisqTest([1,2,3,4],[1,2,2,4], 4) *note the 4 The issue was when I submitted the code to HypothesisTests.jl the only way to create a contingency

[julia-users] How to interrupt a loop with a keyboard keystroke

2015-11-10 Thread Felipe Jiménez
I have a long loop going. It solves a solitaire board-game by brute force search, and depending on the initial configuration it could take seconds or years to finish, I never know. I would like to be able to interrupt the loop at any time and save its state (basically the values in an Array

Re: [julia-users] Using Meshes.ji

2015-11-10 Thread Rohit Thankachan
I've made a few changes to the file Steve pointed you to. It can be found at https://gist.github.com/rohitvarkey/5be4542faff17014afc7. If you use Escher to run that file, you can load .obj files by just typing in the filename (provided you ran the Escher server from the directory the file

[julia-users] Error plotting graph - plot function returns nothing

2015-11-10 Thread 'Antoine Messager' via julia-users
Dear all, I am currently trying to plot graphs. I installed both GraphViz and Graph packages. I then try to follow the example given in the documentation (and written below). I first had to deal with the issue listed here #172 . Thus I changed

[julia-users] Re: DataFrame to JSON

2015-11-10 Thread JobJob
Good stuff. Here's a stab at the inverse: function json2df(jsonstr) dictvec = JSON.parse(jsonstr) DataFrame(Dict(map(k->(k=>[row[k] for row in dictvec]), keys(dictvec[1 ] end

[julia-users] Moore foundation grant.

2015-11-10 Thread Lampkld
Congratulations on the exciting news! I have played around with Julia A bit and love the language , But Found Its Lacking Some robust stats/ml/data manipulation infrastructure. Can anyone tell me if these areas are slated to be worked on from the grant money? I'm trying to get some foresight

[julia-users] Re: Google releases TensorFlow as open source

2015-11-10 Thread Valentin Churavy
It fits in the same niche that Mocha.jl and MXNet.jl are filling right now. MXNet is a ML library that shares many of the same design ideas of TensorFlow and has great Julia support https://github.com/dmlc/MXNet.jl On Wednesday, 11 November 2015 01:04:00 UTC+9, Randy Zwitch wrote: > > For me,

[julia-users] General help with concepts: splatting/slurping, inlining, tuple access, function chaining

2015-11-10 Thread 'Greg Plowman' via julia-users
I have some naïve and probably stupid questions about writing efficient code in Julia. I almost didn't post this because I'm not sure if this is the right place for asking for this type of conceptual help. I do hope it is appropriate. I apologise in advance if it's not. I have been trying to

[julia-users] Median filter

2015-11-10 Thread Rajn
I was wondering if a 'median filter' algorithm is available in Julia? There was some discussion on this topic in 2013. Wonder if someone built it eventually. I am looking for something similar to medflt1 of Matlab. Thanks

[julia-users] Getting length of step range in function.

2015-11-10 Thread Ben Ward
Hi, You can get the length of a StepRange: *julia> **length(2:1:9)* *8* But if I try to do so inside a function I get an error about not finding a call method: *julia> **function myfun(width::Int, step::Int, length::Int)* *clip = Int(floor(width / 2))* *start = 1 +

[julia-users] how to specify degrees of freedom for OneSampleTTest?

2015-11-10 Thread Evan
I want to do the following with some time series data: Calculate 95% confidence interval for mean defined as +/-sigma(x)qt(0.025, N*-1) / sqrt(N*) where sigma(x) is the standard deviation at any point x and qt(0.025, N*-1) is the 2.5 percentage point of the Student-t distribution with N*-1

[julia-users] Re: How to interrupt a loop with a keyboard keystroke

2015-11-10 Thread Páll Haraldsson
On Tuesday, November 10, 2015 at 10:07:17 AM UTC, Felipe Jiménez wrote: >while true > # do stuff # > if (keyboard was pressed) && (key was 'p') # for "pause" > > > Any ideas? > Hopefully I'm not complicating, something like this seems not be enough (as you could be

[julia-users] Re: How to interrupt a loop with a keyboard keystroke

2015-11-10 Thread Cedric St-Jean
Couldn't you periodically (every N iterations) save the array to disk? Or even better, put it in a global variable? On Tuesday, November 10, 2015 at 5:07:17 AM UTC-5, Felipe Jiménez wrote: > > I have a long loop going. It solves a solitaire board-game by brute force > search, and depending on

Re: [julia-users] Re: CUDART and CURAND problem on running the same "do" loop twice

2015-11-10 Thread Tim Holy
See the code in src/device.jl that implements the do-block syntax (especially functions that take a function as their first argument). It's not a big file, so shouldn't be too hard to figure out what's happening. --Tim On Tuesday, November 10, 2015 02:16:52 PM Andrei Zh wrote: > > But I can

[julia-users] Re: How to interrupt a loop with a keyboard keystroke

2015-11-10 Thread Felipe Jiménez
Thank you, Palli and Cedri. Palli's answer shows it's not as easy as I thought. Cedric's answer is practical without overkill, so I'll go that way by now. Still if someone writes a Julia readchar() or readkey() function that is similar to readline() but does not wait for Enter to be pressed, I

[julia-users] Re: Google releases TensorFlow as open source

2015-11-10 Thread Alireza Nejati
If anyone draws up an initial implementation (or pathway to implementation, even), I'd gladly contribute. I think it's highly strategically important to have a julia interface to TensorFlow.

[julia-users] Re: Google releases TensorFlow as open source

2015-11-10 Thread Alireza Nejati
Randy: To answer your question, I'd reckon that the two major gaps in julia that TensorFlow could fill are: 1. Lack of automatic differentiation on arbitrary graph structures. 2. Lack of ability to map computations across cpus and clusters. Funny enough, I was thinking about (1) for the past