Base.∘メソッドを拡張しようとしています。 syntax: expected "end" in definition of function "Base"
私が間違っているのは何: function Base.∘(f₁::Transformation, f₂::Transformation)
println("baz")
end
を定義しようとすると、次のエラーを与えますか
はジュリア0.5では次のように記述することができます: using DataFrames, Plots, StatPlots
df = DataFrame(
fruit = ["orange","orange","orange","orange","apple","apple","apple","apple"],
year = [2010,2011,2012,2013,2010
@noinline g(x::Int) = x > 2 ? 1 : nothing
function test(x::Int)
a = g(x)
if a == nothing
f(a)
# Do I need f(a::Void)
else
f(a)
# Do I need f(a::Int)
end
e
: function count_hands(n)
c::Int=0
for i=1:n
c+=rand(Bool)
end
c
end
我々は別のプロセスでaとbを計算したい ./julia -p 2として、我々はジュリアを実行し、我々が持っている: julia> @everywhere include("count_hands.jl")
julia 0.6の新しいwhere構文についてちょっと混乱しています。私は明示的な変換を行うことなく、辞書のベクトルを受け取る機能が欲しい a=Dict(["a"=>"b"])
b=Dict(["a"=>3])
c=Dict(["a"=>"c"])
: 私はこのような何かを持っています。 私は試してみました: function bbb(a::Vector{Dict{String, Any