diff --git a/.github/workflows/CI.yml b/.github/workflows/CI.yml index c94f60e..84cef1d 100644 --- a/.github/workflows/CI.yml +++ b/.github/workflows/CI.yml @@ -44,7 +44,7 @@ jobs: - uses: actions/checkout@v2 - uses: julia-actions/setup-julia@v1 with: - version: '1' + version: '1.9' - uses: julia-actions/julia-buildpkg@v1 - uses: julia-actions/julia-docdeploy@v1 env: diff --git a/src/MParT.jl b/src/MParT.jl index 7931dd8..708fab6 100644 --- a/src/MParT.jl +++ b/src/MParT.jl @@ -320,9 +320,12 @@ end """ - TriangularMap(maps::Vector) + TriangularMap(maps::Vector, move_coeffs::Bool = true) Creates a `TriangularMap` from a vector of `ConditionalMapBase` objects. +The new object takes ownership of the coeffs of the maps in `maps` if +`move_coeffs` is true. + # Examples ```jldoctest julia> dim, order = 5, 3; @@ -336,9 +339,9 @@ julia> components = [CreateComponent(mset, opts) for mset in msets]; julia> trimap = TriangularMap(components); ``` """ -function TriangularMap(maps::Vector) +function TriangularMap(maps::Vector, move_coeffs::Bool = true) maps = StdVector([map for map in maps]) - TriangularMap(maps) + TriangularMap(maps, move_coeffs) end """